@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:wght,FILL@100..700,0..1&display=swap");

:root {
    --header-primary: #b02b34;
    --header-primary-container: #fb6265;
    --header-on-primary: #ffffff;
    --header-on-primary-container: #64000f;
    --header-inverse-surface: #2f3131;
    --header-surface-variant: #e2e2e2;
    --header-outline: #8d706f;
    --header-outline-variant: #e0bfbd;
    --header-max-width: 1280px;
}

.material-symbols-outlined {
    direction: ltr;
    display: inline-block;
    font-family: "Material Symbols Outlined";
    font-feature-settings: "liga";
    font-size: 24px;
    font-style: normal;
    font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
    font-weight: normal;
    letter-spacing: normal;
    line-height: 1;
    text-transform: none;
    white-space: nowrap;
    word-wrap: normal;
}

.site-header {
    font-family: "Inter", Arial, sans-serif;
}

body > main {
    margin-top: 68px;
}

header .navbar {
    background: var(--header-inverse-surface);
    border-bottom: 1px solid var(--header-outline-variant);
    border-radius: 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
    display: block;
    left: 0;
    padding: 0;
    position: fixed;
    right: 0;
    top: 0;
    width: 100%;
    z-index: 1000;
}

header .navbar__inner {
    align-items: center;
    display: flex;
    gap: 16px;
    justify-content: space-between;
    margin: 0 auto;
    max-width: var(--header-max-width);
    min-height: 68px;
    padding: 16px 40px;
    width: 100%;
}

header .brand {
    align-items: baseline;
    color: var(--header-on-primary);
    display: inline-flex;
    flex-shrink: 0;
    font-size: 24px;
    font-style: italic;
    font-weight: 900;
    letter-spacing: -0.03em;
    line-height: 1;
    text-decoration: none;
    text-transform: uppercase;
    transition: transform 150ms ease;
    white-space: nowrap;
}

header .brand:active {
    transform: scale(0.95);
}

header .brand__primary {
    color: var(--header-primary-container);
}

header .brand__secondary {
    color: var(--header-on-primary);
    margin-left: 6px;
}

header .header-search {
    align-items: center;
    display: flex;
    flex-direction: row;
    gap: 0;
    position: relative;
    width: auto;
}

header .header-search .material-symbols-outlined {
    color: rgba(226, 226, 226, 0.8);
    font-size: 20px;
    left: 16px;
    pointer-events: none;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
}

header .header-search input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(141, 112, 111, 0.3);
    border-radius: 4px;
    color: var(--header-on-primary);
    font: 400 14px/20px "Inter", Arial, sans-serif;
    min-height: 40px;
    outline: none;
    padding: 8px 16px 8px 40px;
    transition: border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
    width: 100%;
}

header .header-search input::placeholder {
    color: rgba(226, 226, 226, 0.5);
}

header .header-search input:focus {
    background: rgba(255, 255, 255, 0.07);
    border-color: var(--header-primary-container);
    box-shadow: 0 0 0 1px var(--header-primary-container);
}

header .header-search--desktop {
    flex: 1 1 280px;
    max-width: 448px;
    width: 100%;
}

header .header-search--mobile,
header .nav-search-item {
    display: none;
}

header .content-nav {
    align-items: center;
    display: flex;
    flex: 0 1 auto;
    gap: 16px;
    justify-content: center;
    list-style: none;
    margin: 0;
    overflow: visible;
    padding: 0;
    transition: max-height 0.4s ease, opacity 0.3s ease;
}

header .item_menu {
    align-items: center;
    display: flex;
}

header .nav-link,
header nav a {
    background: none;
    color: var(--header-on-primary);
    font: 600 14px/16px "Inter", Arial, sans-serif;
    letter-spacing: 0.05em;
    padding: 0;
    text-decoration: none;
    transition: color 180ms ease, transform 150ms ease;
    white-space: nowrap;
    -webkit-text-fill-color: currentColor;
}

header .nav-link:hover {
    color: var(--header-primary-container);
}

header .nav-link:active {
    transform: scale(0.95);
}

header .nav-link.active {
    border-bottom: 2px solid var(--header-primary-container);
    color: var(--header-primary-container);
    font-weight: 700;
    padding-bottom: 4px;
}

header .carrito_usuario {
    align-items: center;
    display: flex;
    flex-shrink: 0;
    gap: 16px;
    justify-content: center;
    width: auto;
}

header .icon-action {
    align-items: center;
    border-radius: 999px;
    color: var(--header-primary-container);
    display: inline-flex;
    height: 32px;
    justify-content: center;
    position: relative;
    text-decoration: none;
    transition: background 180ms ease, transform 150ms ease;
    width: 32px;
}

header .icon-action:hover {
    background: rgba(226, 226, 226, 0.12);
}

header .icon-action:active {
    transform: scale(0.95);
}

header .icon-action img {
    display: block;
    height: 24px;
    object-fit: contain;
    width: 24px;
}

header .cart-badge {
    align-items: center;
    background: var(--header-primary-container);
    border-radius: 999px;
    color: var(--header-on-primary-container);
    display: inline-flex;
    font-size: 10px;
    font-weight: 800;
    height: 16px;
    justify-content: center;
    min-width: 16px;
    padding: 0 4px;
    position: absolute;
    right: -4px;
    top: -4px;
}

header .hamburguesa {
    align-items: center;
    background: transparent;
    border: 0;
    border-radius: 999px;
    cursor: pointer;
    display: none;
    flex-direction: column;
    gap: 4px;
    height: 32px;
    justify-content: center;
    padding: 6px;
    transition: background 180ms ease, transform 150ms ease;
    width: 32px;
}

header .hamburguesa:hover {
    background: rgba(226, 226, 226, 0.12);
}

header .hamburguesa:active {
    transform: scale(0.95);
}

header .hamburguesa:focus {
    outline: none;
}

header .hamburguesa:focus-visible {
    outline: 2px solid var(--header-primary-container);
    outline-offset: 2px;
}

header .hamburguesa span {
    background: var(--header-primary-container);
    border-radius: 12px;
    height: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
    width: 20px;
}

.messages-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: calc(100% - 40px);
    position: fixed;
    right: 20px;
    top: 88px;
    width: auto;
    z-index: 1200;
}

.message {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
    color: #111111;
    font-size: 0.95rem;
    line-height: 1.4;
    opacity: 1;
    padding: 14px 18px;
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.message-success {
    background: #eff9ef;
    border-color: #2a7a1f;
    color: #174a12;
}

.message-warning {
    background: #fff5e3;
    border-color: #d48a0d;
    color: #7f5200;
}

.message-error,
.message-danger {
    background: #fee2e2;
    border-color: #b91c1c;
    color: #7f1d1d;
}

.fade-out {
    opacity: 0;
    transform: translateY(-10px);
}

header .hamburguesa.open span:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

header .hamburguesa.open span:nth-child(2) {
    opacity: 0;
}

header .hamburguesa.open span:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
}

@media screen and (max-width: 1180px) {
    header .navbar__inner {
        padding-inline: 24px;
    }

    header .content-nav {
        gap: 12px;
    }

    header .brand {
        font-size: 21px;
    }
}

@media screen and (max-width: 1024px) {
    header .content-nav {
        background: var(--header-inverse-surface);
        border-top: 1px solid rgba(141, 112, 111, 0.35);
        display: none;
        flex-direction: column;
        gap: 0;
        left: 0;
        max-height: 0;
        opacity: 0;
        padding: 0 24px;
        pointer-events: none;
        position: absolute;
        right: 0;
        top: 100%;
        width: 100%;
    }

    header .content-nav.active {
        display: flex;
        max-height: 720px;
        opacity: 1;
        padding-bottom: 16px;
        padding-top: 16px;
        pointer-events: auto;
    }

    header .item_menu {
        justify-content: center;
        padding: 12px 0;
        width: 100%;
    }

    header .nav-link.active {
        border-bottom-color: transparent;
        padding-bottom: 0;
    }

    header .hamburguesa {
        display: inline-flex;
    }
}

@media screen and (max-width: 768px) {
    body > main {
        margin-top: 60px;
    }

    header .navbar__inner {
        gap: 10px;
        min-height: 60px;
        padding: 10px 15px;
    }

    header .brand {
        flex-direction: column;
        font-size: 17px;
        letter-spacing: -0.02em;
    }

    header .brand__secondary {
        margin-left: 0;
        margin-top: 2px;
    }

    header .header-search--desktop {
        display: none;
    }

    header .nav-search-item {
        display: block;
        padding: 0 0 12px;
        width: 100%;
    }

    header .header-search--mobile {
        display: flex;
        margin: 0 auto;
        max-width: 420px;
        width: 100%;
    }

    header .carrito_usuario {
        gap: 8px;
        margin-left: auto;
    }

    header .icon-action,
    header .hamburguesa {
        height: 30px;
        width: 30px;
    }
}

@media screen and (max-width: 380px) {
    header .brand {
        font-size: 15px;
    }

    header .carrito_usuario {
        gap: 4px;
    }
}
