/* Explain: Styling for various UI components, including headers, cards, buttons, and layout elements. */
.announce {
    background: var(--footer-bg);
    color: #ffffff;
    text-align: center;
    font-size: 12px;
    padding: 8px 12px;
    letter-spacing: 0.2px;
}

.announce strong {
    color: var(--accent-color);
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 40;
    padding: 12px 0;
    background: var(--surface-color);
}

.nav-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 72px;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 22px;
    background: var(--surface-color);
    box-shadow: var(--shadow-soft);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 26px;
    letter-spacing: -1px;
    color: var(--text-color);
}

.brand-mark {
    display: grid;
    width: 30px;
    height: 30px;
    place-items: center;
    border-radius: 9px;
    background: linear-gradient(135deg, #2f6bff 0%, #00b3d6 100%);
    color: #ffffff;
    font-size: 15px;
}

.brand-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-top: 6px;
    border-radius: 999px;
    background: var(--primary-color);
}

.brand-logo {
    display: block;
    height: 42px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
}

.brand-logo-footer {
    height: 44px;
}

@media (max-width: 640px) {
    .brand-logo {
        height: 32px;
    }
}

.nav-links {
    display: flex;
    gap: 26px;
    font-size: 13px;
    color: var(--text-muted);
}

.nav-links a {
    transition: color 200ms ease;
}

.nav-links a:hover,
.nav-links a.is-active {
    color: var(--primary-color);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 9px;
}

.cart-icon {
    background: var(--surface-color);
    color: var(--text-color);
}

.cart-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    width: 46px;
    height: 46px;
    border-radius: 16px;
    background: var(--text-color);
    color: #ffffff;
    font-size: 17px;
    font-weight: 700;
    transition: background 200ms ease, transform 200ms ease, box-shadow 200ms ease;
}

.cart-btn:hover {
    background: var(--primary-color);
    transform: translateY(-1px);
    box-shadow: var(--shadow-button);
}

.cart-btn-label {
    display: none;
    font-size: 13px;
}

@media (min-width: 640px) {
    .cart-btn {
        width: auto;
        padding: 0 20px;
        border-radius: 999px;
    }

    .cart-btn-label {
        display: inline;
    }
}

.cart-badge {
    position: absolute;
    top: -7px;
    inset-inline-start: -7px;
    display: inline-grid;
    min-width: 20px;
    height: 20px;
    place-items: center;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--accent-color);
    color: var(--accent-ink);
    font-size: 11px;
    font-weight: 800;
}

.icon-btn {
    position: relative;
    display: grid;
    width: 46px;
    height: 46px;
    place-items: center;
    border: 1px solid var(--border-color);
    border-radius: 16px;
    background: var(--surface-color);
    color: var(--text-color);
    font-size: 17px;
    transition: background 200ms ease, color 200ms ease, border-color 200ms ease;
}

.icon-btn:hover {
    background: var(--primary-color);
    color: #ffffff;
    border-color: var(--primary-color);
}

.cart-count {
    position: absolute;
    top: -3px;
    inset-inline-end: -3px;
    display: grid;
    min-width: 17px;
    height: 17px;
    place-items: center;
    padding: 0 3px;
    border-radius: 99px;
    background: var(--primary-color);
    color: #ffffff;
    font-size: 10px;
}

.nav-overlay {
    position: fixed;
    inset: 0;
    z-index: 60;
    overflow-y: auto;
    background: var(--background-color);
}

.hero {
    position: relative;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    min-height: 440px;
    margin-top: 28px;
    overflow: hidden;
    border-radius: 28px;
    background: linear-gradient(118deg, #e8e6ff 0%, #d9d2ff 48%, #f5f3ff 100%);
}

.hero-copy {
    z-index: 1;
    padding: 68px 60px;
}

.eyebrow {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--primary-hover);
    text-transform: uppercase;
}

.hero-title {
    max-width: 540px;
    margin: 14px 0 18px;
    font-size: clamp(34px, 5vw, 64px);
    font-weight: 800;
    line-height: 1.14;
    letter-spacing: -2px;
    color: var(--text-color);
}

.hero-text {
    max-width: 430px;
    margin: 0 0 28px;
    color: #666375;
    font-size: 15px;
    line-height: 1.9;
}

.btn-solid {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 50px;
    padding: 0 26px;
    border: none;
    border-radius: 13px;
    background: var(--text-color);
    color: #ffffff;
    font-weight: 700;
    transition: background 250ms ease, transform 250ms ease;
}

.btn-solid:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
}

.btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 50px;
    padding: 0 24px;
    border: 1px solid rgba(117, 84, 246, 0.35);
    border-radius: 13px;
    background: rgba(255, 255, 255, 0.6);
    color: var(--text-color);
    font-weight: 700;
    transition: background 250ms ease, border-color 250ms ease;
}

.btn-ghost:hover {
    border-color: var(--primary-color);
    background: #ffffff;
}

.hero-art {
    position: relative;
    min-height: 440px;
}

.hero-art img {
    position: absolute;
    top: 6%;
    inset-inline-end: 3%;
    width: 90%;
    height: 88%;
    object-fit: cover;
    border-radius: 20px;
}

.floating-card {
    position: absolute;
    bottom: 28px;
    inset-inline-end: 24px;
    z-index: 2;
    padding: 14px 18px;
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-soft);
    font-size: 12px;
    color: var(--text-muted);
}

.floating-card b {
    display: block;
    font-family: var(--font-heading);
    font-size: 19px;
    color: var(--text-color);
}

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 23px;
}

.section-head h2 {
    font-size: clamp(30px, 5vw, 46px);
    font-weight: 800;
    letter-spacing: -1px;
}

.section-head span {
    font-size: 12px;
    color: var(--text-muted);
}

.cat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.cat-card {
    display: block;
    padding: 20px 12px;
    border: 1px solid var(--border-color);
    border-radius: 18px;
    background: var(--surface-color);
    text-align: center;
    transition: border-color 200ms ease, transform 200ms ease;
}

.cat-card:hover {
    border-color: #b8aaff;
    transform: translateY(-3px);
}

.cat-icon {
    display: grid;
    height: 48px;
    margin-bottom: 7px;
    place-items: center;
    color: var(--primary-color);
    font-size: 26px;
}

.cat-card span {
    font-size: 13px;
    color: #555460;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}

.p-card {
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--border-color);
    border-radius: 19px;
    background: var(--surface-color);
    transition: transform 200ms ease, box-shadow 200ms ease;
}

.p-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-soft);
}

.p-pic {
    position: relative;
    display: grid;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    place-items: center;
    background: #f1f1f5;
}

.p-pic img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.p-tag {
    position: absolute;
    top: 13px;
    inset-inline-end: 13px;
    padding: 5px 9px;
    border-radius: 7px;
    background: var(--accent-color);
    color: var(--accent-ink);
    font-size: 10px;
    font-weight: 700;
}

.p-heart {
    position: absolute;
    top: 12px;
    inset-inline-start: 12px;
    display: grid;
    width: 32px;
    height: 32px;
    place-items: center;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.85);
    color: #777681;
    transition: color 200ms ease, background 200ms ease;
}

.p-heart.is-active {
    background: var(--primary-color);
    color: #ffffff;
}

.p-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 15px 16px 16px;
}

.p-rating {
    color: #f3a52c;
    font-size: 11px;
}

.p-rating span {
    margin-inline-start: 5px;
    color: #999;
}

.p-name {
    margin: 8px 0 12px;
    font-size: 14px;
    font-weight: 700;
    color: var(--text-color);
}

.p-price {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    font-family: var(--font-heading);
    font-size: 17px;
    font-weight: 800;
    color: var(--text-color);
}

.p-old {
    margin-inline-start: 6px;
    color: #9a989f;
    font-size: 11px;
    font-weight: 400;
    text-decoration: line-through;
}

.p-add {
    display: grid;
    width: 36px;
    height: 36px;
    place-items: center;
    border: none;
    border-radius: 10px;
    background: var(--text-color);
    color: #ffffff;
    font-size: 16px;
    transition: background 200ms ease;
}

.p-add:hover {
    background: var(--primary-color);
}

.promo {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 62px;
    padding: 28px 35px;
    border-radius: 24px;
    background: var(--accent-color);
    color: var(--accent-ink);
}

.promo h2 {
    font-size: clamp(22px, 3vw, 26px);
    margin-bottom: 4px;
}

.promo p {
    margin: 0;
    font-size: 13px;
}

.promo a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 20px;
    border-radius: 11px;
    background: #ffffff;
    color: var(--accent-ink);
    font-weight: 700;
    white-space: nowrap;
}

.benefit-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 62px;
    padding: 31px 0 38px;
    border-top: 1px solid var(--border-color);
}

.benefit {
    display: flex;
    align-items: center;
    gap: 13px;
}

.benefit-icon {
    color: var(--primary-color);
    font-size: 24px;
}

.benefit b {
    display: block;
    font-size: 13px;
}

.benefit span {
    display: block;
    margin-top: 3px;
    color: var(--text-muted);
    font-size: 11px;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-color);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.field {
    width: 100%;
    border: 1px solid var(--border-color);
    border-radius: 13px;
    background: var(--field-bg);
    padding: 0.85rem 1rem;
    color: var(--text-color);
    font-family: var(--font-body);
}

.field:focus {
    border-color: var(--primary-color);
    outline: none;
}

.search-field {
    width: 100%;
    border: 1px solid var(--border-color);
    border-radius: 13px;
    background: var(--field-bg);
    padding: 0.85rem 1.2rem;
    color: var(--text-color);
    font-family: var(--font-body);
}

.search-field:focus {
    border-color: var(--primary-color);
    outline: none;
}

.filter-chip {
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: var(--surface-color);
    padding: 0.5rem 1.1rem;
    color: var(--text-color);
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 250ms ease;
}

.filter-chip:hover {
    border-color: var(--primary-color);
}

.filter-chip.is-active {
    border-color: transparent;
    background: var(--primary-color);
    color: #ffffff;
}

.toast {
    position: fixed;
    inset-inline: 0;
    bottom: 1.5rem;
    z-index: 120;
    width: max-content;
    max-width: 90vw;
    margin-inline: auto;
    border-radius: 999px;
    padding: 0.85rem 1.4rem;
    font-size: 0.9rem;
    font-weight: 700;
    box-shadow: 0 20px 50px rgba(37, 33, 59, 0.2);
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 300ms ease, transform 300ms ease;
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}

.toast.success {
    background: var(--primary-color);
    color: #ffffff;
}

.toast.error {
    background: #c0392b;
    color: #ffffff;
}

.form-status.success {
    color: #4a6b53;
}

.form-status.error {
    color: #9b4a3d;
}

.cart-row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 16px;
    background: var(--surface-color);
    padding: 1rem;
}

.cart-thumb {
    width: 84px;
    height: 84px;
    border-radius: 12px;
    object-fit: cover;
}

.qty-btn {
    display: inline-flex;
    width: 2.4rem;
    height: 2.4rem;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: var(--field-bg);
    color: var(--text-color);
    font-weight: 700;
    transition: background 200ms ease;
}

.qty-btn:hover {
    background: var(--secondary-color);
}

@media (max-width: 1024px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .hero {
        grid-template-columns: 1fr;
        min-height: auto;
    }

    .hero-copy {
        padding: 48px 28px;
    }

    .hero-art {
        min-height: 300px;
    }

    .benefit-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .cat-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .cart-row {
        grid-template-columns: auto 1fr;
    }

    .cart-row-actions {
        grid-column: 1 / -1;
        justify-content: flex-end;
    }

    .promo {
        flex-direction: column;
        align-items: flex-start;
    }
}

.section-title-anim {
    display: inline-block;
    background-size: 300% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    animation: titleShine 4s linear infinite;
    transition: transform 250ms ease;
}

.section-title-anim:hover {
    transform: scale(1.05);
}

@keyframes titleShine {
    0% {
        background-position: 0% 50%;
    }

    100% {
        background-position: 300% 50%;
    }
}

.head-c1 {
    background-image: linear-gradient(90deg, #7554f6, #b23bff, #ff4d8d, #7554f6);
}

.head-c2 {
    background-image: linear-gradient(90deg, #2f6bff, #00b3d6, #4ade80, #2f6bff);
}

.head-c3 {
    background-image: linear-gradient(90deg, #ff8a00, #ff2e63, #ffd93d, #ff8a00);
}

.head-c4 {
    background-image: linear-gradient(90deg, #8b5cf6, #ec4899, #f59e0b, #8b5cf6);
}

.head-c5 {
    background-image: linear-gradient(90deg, #06b6d4, #6366f1, #a855f7, #06b6d4);
}

.head-c6 {
    background-image: linear-gradient(90deg, #f43f5e, #fb923c, #facc15, #f43f5e);
}

.head-c7 {
    background-image: linear-gradient(90deg, #10b981, #22d3ee, #3b82f6, #10b981);
}

.p-name a {
    color: inherit;
    transition: color 200ms ease;
}

.p-name a:hover {
    color: var(--primary-color);
}

.color-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: var(--surface-color);
    color: var(--text-color);
    font-size: 0.85rem;
    font-weight: 600;
    transition: border-color 200ms ease, background 200ms ease;
}

.color-chip:hover {
    border-color: var(--primary-color);
}

.color-chip.is-active {
    border-color: var(--primary-color);
    background: var(--secondary-color);
}

.color-dot {
    width: 16px;
    height: 16px;
    border-radius: 999px;
    border: 1px solid rgba(0, 0, 0, 0.12);
}

.product-thumb {
    padding: 0;
    overflow: hidden;
    border: 2px solid var(--border-color);
    border-radius: 14px;
    background: var(--surface-color);
    transition: border-color 200ms ease;
}

.product-thumb:hover,
.product-thumb.is-active {
    border-color: var(--primary-color);
}