:root {
    --purple-1000: #190b22;
    --purple-950: #281036;
    --purple-900: #351044;
    --purple-850: #45185d;
    --purple-800: #5a1f79;
    --purple-700: #732ba2;
    --purple-600: #8e43bd;
    --purple-300: #c99de2;
    --purple-100: #f2e8f8;
    --pink-500: #f05a9d;
    --pink-300: #ff9bc8;
    --orange-600: #eb4f18;
    --orange-500: #ff6129;
    --yellow-400: #ffd84f;
    --ink: #21142c;
    --muted: #716878;
    --line: #e5d7ec;
    --surface: #ffffff;
    --surface-soft: #fbf7fd;
    --shadow: 0 24px 62px rgba(54, 17, 72, .16);
    --shadow-soft: 0 12px 32px rgba(54, 17, 72, .10);
    --radius: 22px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: "DM Sans", sans-serif;
    color: var(--ink);
    background: #faf7fc;
    line-height: 1.55;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
.container { width: min(1160px, calc(100% - 32px)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; left: 16px; top: -80px; z-index: 999; background: white; padding: 12px 16px; border-radius: 8px; transition: top .2s; }
.skip-link:focus { top: 16px; }

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: linear-gradient(90deg, rgba(27,10,38,.98), rgba(65,20,80,.98));
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255,255,255,.10);
}
.header-inner { min-height: 92px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand img { width: 268px; height: auto; border-radius: 12px; }
.header-actions { display: flex; gap: 10px; align-items: center; }
.offers-link, .icon-link, .admin-link { font-weight: 800; font-size: .9rem; padding: 10px 14px; border-radius: 12px; }
.offers-link, .icon-link { color: rgba(255,255,255,.88); }
.offers-link:hover, .icon-link:hover { background: rgba(255,255,255,.10); color: white; }
.admin-link { border: 1px solid rgba(255,255,255,.72); color: var(--purple-900); background: white; }
.admin-link:hover { border-color: var(--purple-600); box-shadow: 0 7px 18px rgba(91,31,121,.10); }

.hero-showcase {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    min-height: 500px;
    padding: 38px 0 96px;
    color: white;
    background:
        radial-gradient(circle at 11% 42%, rgba(255,142,199,.35), transparent 24%),
        radial-gradient(circle at 88% 34%, rgba(255,212,107,.26), transparent 21%),
        radial-gradient(circle at 52% 100%, rgba(142,67,189,.58), transparent 34%),
        linear-gradient(115deg, #1e0b2b 0%, #4a175f 42%, #7b319a 72%, #3a123f 100%);
}
.hero-showcase::before,
.hero-showcase::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: -1;
}
.hero-showcase::before {
    opacity: .76;
    background-image:
        radial-gradient(circle, rgba(255,255,255,.95) 0 1px, transparent 1.8px),
        radial-gradient(circle, rgba(255,169,216,.85) 0 1.4px, transparent 2.2px),
        radial-gradient(circle, rgba(255,221,139,.9) 0 1px, transparent 2px);
    background-size: 48px 48px, 83px 83px, 121px 121px;
    background-position: 0 0, 21px 16px, 34px 44px;
    mask-image: linear-gradient(to right, #000, transparent 42%, transparent 58%, #000);
}
.hero-showcase::after {
    background:
        linear-gradient(90deg, rgba(11,5,17,.55), transparent 24%, transparent 76%, rgba(11,5,17,.55)),
        linear-gradient(180deg, transparent 65%, rgba(24,8,33,.32));
}
.hero-stage { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; text-align: center; }
.hero-stars {
    position: absolute;
    inset: 0;
    z-index: -1;
    opacity: .35;
    background: radial-gradient(ellipse at center, rgba(255,255,255,.14), transparent 56%);
}
.hero-brand-image {
    width: min(760px, 94vw);
    border-radius: 24px;
    box-shadow: 0 32px 86px rgba(9,3,14,.42);
}
.hero-tagline {
    margin: 16px 0 0;
    font-size: clamp(1.12rem, 2.2vw, 1.55rem);
    font-weight: 800;
    text-shadow: 0 3px 12px rgba(0,0,0,.55);
}
.hero-description { max-width: 650px; margin: 8px 0 22px; color: rgba(255,255,255,.84); }
.hero-button { min-width: 155px; }

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 13px;
    padding: 13px 20px;
    font-weight: 800;
    cursor: pointer;
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.button:hover { transform: translateY(-2px); }
.button-primary {
    color: white;
    background: linear-gradient(135deg, var(--orange-500), var(--orange-600));
    box-shadow: 0 13px 28px rgba(235,79,24,.28);
}
.button-secondary { background: white; color: var(--purple-800); border: 1px solid var(--line); }
.button-buy {
    width: 100%;
    color: white;
    background: linear-gradient(135deg, #ff6a2f, #ec4d17);
    box-shadow: 0 10px 22px rgba(235,79,24,.22);
}
.button-large { min-height: 55px; width: 100%; margin-top: 10px; }

.search-section { position: relative; z-index: 5; margin-top: -58px; }
.offer-panel {
    padding: 20px;
    background: rgba(255,255,255,.97);
    border: 1px solid rgba(103,38,133,.18);
    border-radius: 23px;
    box-shadow: var(--shadow);
}
.category-list { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.category-chip {
    flex: 0 0 auto;
    padding: 9px 17px;
    border-radius: 999px;
    border: 1px solid #dfcce9;
    background: white;
    color: var(--purple-900);
    font-size: .9rem;
    font-weight: 700;
}
.category-chip:hover, .category-chip.active { color: white; background: linear-gradient(135deg, var(--purple-800), var(--purple-700)); border-color: var(--purple-800); }
.search-form { display: grid; grid-template-columns: 1fr auto; gap: 12px; margin-top: 15px; }
.search-field {
    min-height: 54px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fcf9fd;
}
.search-field:focus-within { border-color: var(--purple-600); box-shadow: 0 0 0 3px rgba(116,43,163,.10); }
.search-icon { font-size: 1.55rem; color: var(--purple-700); transform: rotate(-18deg); }
.search-field input { width: 100%; border: 0; outline: 0; background: transparent; color: var(--ink); }
.search-button { min-width: 108px; }

.section { padding: 74px 0; }
.featured-section {
    padding-top: 92px;
    background:
        radial-gradient(circle at 3% 50%, rgba(238,111,174,.12), transparent 25%),
        radial-gradient(circle at 97% 80%, rgba(140,64,185,.12), transparent 24%),
        #fbf8fd;
}
.catalog-section { background: white; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 30px; }
.centered-heading { justify-content: center; text-align: center; }
.section-heading h2 { margin: 0; font-size: clamp(1.8rem, 4vw, 2.65rem); line-height: 1.1; letter-spacing: -.035em; color: var(--purple-950); }
.section-heading p { margin: 9px 0 0; color: var(--muted); }
.eyebrow { display: inline-block; margin-bottom: 9px; color: var(--pink-500); text-transform: uppercase; letter-spacing: .13em; font-size: .73rem; font-weight: 800; }
.result-count { color: var(--muted); font-weight: 700; }

.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.product-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    background: rgba(255,255,255,.98);
    border: 1px solid rgba(104,36,139,.32);
    border-radius: 22px;
    box-shadow: var(--shadow-soft);
    transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.product-card:hover { transform: translateY(-7px); box-shadow: var(--shadow); border-color: var(--purple-600); }
.product-image-wrap {
    position: relative;
    display: block;
    aspect-ratio: 1.18 / 1;
    overflow: hidden;
    background:
        radial-gradient(circle at 25% 35%, rgba(255,126,190,.24), transparent 29%),
        radial-gradient(circle at 80% 70%, rgba(137,62,183,.22), transparent 31%),
        linear-gradient(145deg, #fff, #f6e9f8);
}
.product-image-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: .44;
    background-image: radial-gradient(circle, rgba(255,255,255,.95) 0 1px, transparent 1.7px);
    background-size: 29px 29px;
    mask-image: linear-gradient(135deg, #000, transparent 62%);
}
.product-image { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.product-card:hover .product-image { transform: scale(1.045); }
.discount-badge, .featured-badge { position: absolute; top: 13px; z-index: 2; border-radius: 999px; padding: 6px 10px; font-size: .73rem; font-weight: 800; box-shadow: 0 7px 16px rgba(0,0,0,.13); }
.discount-badge { right: 13px; color: white; background: var(--orange-600); }
.featured-badge { left: 13px; color: var(--purple-950); background: var(--yellow-400); }
.product-body { display: flex; flex-direction: column; flex: 1; padding: 20px; }
.product-category { color: var(--pink-500); text-transform: uppercase; letter-spacing: .09em; font-size: .69rem; font-weight: 800; }
.product-body h3 { margin: 7px 0 9px; color: #1f1030; font-size: 1.18rem; line-height: 1.25; }
.product-body h3 a:hover { color: var(--purple-700); }
.product-body p { margin: 0 0 14px; color: var(--muted); font-size: .92rem; }
.coupon { display: inline-flex; align-items: center; align-self: flex-start; padding: 6px 9px; color: #8b3919; background: #fff0e8; border: 1px dashed #f2a07b; border-radius: 9px; font-size: .76rem; font-weight: 800; }
.coupon.large { font-size: .9rem; padding: 8px 11px; }
.price-row { margin-top: auto; padding-top: 17px; }
.price-row del, .detail-price del { display: block; color: #988e9e; font-size: .81rem; }
.price-row strong { display: block; color: var(--purple-900); font-size: 1.35rem; }
.card-actions { display: grid; grid-template-columns: 1fr 44px; gap: 9px; margin-top: 14px; }
.share-button { border: 1px solid var(--line); background: white; border-radius: 13px; cursor: pointer; color: var(--purple-800); font-weight: 900; font-size: 1.2rem; }
.share-button:hover { background: var(--purple-100); }
.shopee-note { display: block; margin-top: 11px; color: #5e5365; text-align: center; font-size: .78rem; font-weight: 600; }

.pagination { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 16px; margin-top: 42px; }
.pagination a { font-weight: 800; color: var(--purple-700); }
.pagination span { color: var(--muted); }
.empty-state { text-align: center; padding: 70px 20px; border: 1px dashed #c9b0d8; border-radius: var(--radius); background: var(--surface-soft); }
.empty-state > span { font-size: 3rem; }
.empty-state h3 { font-size: 1.5rem; margin: 12px 0 5px; }
.empty-state p { color: var(--muted); margin: 0 0 24px; }

.trust-section {
    position: relative;
    overflow: hidden;
    padding: 10px 0 78px;
    background: white;
}
.trust-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.trust-grid article { display: flex; gap: 15px; padding: 22px; border: 1px solid #e9dcef; border-radius: 18px; background: linear-gradient(145deg, #fff, #f7edf9); }
.trust-grid article > span { font-size: 2rem; }
.trust-grid strong { display: block; color: var(--purple-900); }
.trust-grid p { margin: 4px 0 0; color: var(--muted); font-size: .88rem; }

.detail-section {
    min-height: 70vh;
    padding: 44px 0 76px;
    background:
        radial-gradient(circle at 0 20%, rgba(240,90,157,.12), transparent 26%),
        radial-gradient(circle at 100% 70%, rgba(115,43,162,.12), transparent 26%),
        #fbf8fd;
}
.breadcrumbs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; color: var(--muted); font-size: .88rem; }
.breadcrumbs a:hover { color: var(--purple-700); }
.product-detail { display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, .88fr); gap: 52px; align-items: start; padding: 28px; border: 1px solid rgba(104,36,139,.20); border-radius: 28px; background: white; box-shadow: var(--shadow); }
.detail-image-wrap { position: relative; aspect-ratio: 1; overflow: hidden; border: 1px solid var(--line); border-radius: 24px; background: linear-gradient(145deg, #fff, #f5e9f8); }
.detail-image-wrap img { width: 100%; height: 100%; object-fit: cover; }
.detail-discount { top: 18px; right: 18px; font-size: .9rem; }
.detail-content h1 { margin: 12px 0 16px; color: var(--purple-950); font-size: clamp(2rem, 5vw, 3.35rem); line-height: 1.02; letter-spacing: -.05em; }
.detail-summary { margin-bottom: 20px; color: var(--muted); font-size: 1.08rem; }
.detail-price { margin: 24px 0 8px; }
.detail-price strong { display: block; color: var(--purple-900); font-size: 2rem; }
.affiliate-notice { display: flex; gap: 11px; align-items: flex-start; margin-top: 18px; padding: 14px; color: var(--muted); background: var(--surface-soft); border-radius: 14px; font-size: .84rem; }
.affiliate-notice p { margin: 0; }
.description-box { margin-top: 42px; padding: 30px; background: white; border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow-soft); }
.description-box h2 { margin-top: 0; color: var(--purple-950); }

.site-footer { padding: 58px 0 22px; color: rgba(255,255,255,.78); background: linear-gradient(135deg, var(--purple-1000), var(--purple-900)); }
.footer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; }
.footer-logo { width: 270px; border-radius: 14px; box-shadow: 0 14px 30px rgba(0,0,0,.22); }
.site-footer h2 { color: white; font-size: 1rem; }
.site-footer p { max-width: 520px; }
.footer-bottom { display: flex; justify-content: space-between; gap: 20px; margin-top: 40px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.12); font-size: .82rem; }
.toast { position: fixed; right: 20px; bottom: 20px; z-index: 100; padding: 12px 16px; color: white; background: var(--purple-950); border-radius: 12px; box-shadow: var(--shadow); transform: translateY(120px); opacity: 0; transition: .25s ease; }
.toast.show { transform: translateY(0); opacity: 1; }
.error-page { min-height: 62vh; display: grid; place-items: center; text-align: center; padding: 70px 0; }
.error-page span { font-size: 4rem; }
.error-page h1 { margin: 10px 0; font-size: clamp(2rem, 5vw, 3.5rem); }
.error-page p { margin-bottom: 25px; color: var(--muted); }

@media (max-width: 980px) {
    .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .product-detail { grid-template-columns: 1fr; gap: 34px; }
    .trust-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
    .container { width: min(100% - 22px, 1160px); }
    .header-inner { min-height: 78px; }
    .brand img { width: 210px; }
    .offers-link, .icon-link { display: none; }
    .admin-link { padding: 8px 10px; font-size: .8rem; }
    .hero-showcase { min-height: 410px; padding: 30px 0 78px; }
    .hero-brand-image { border-radius: 17px; }
    .hero-description { max-width: 94%; font-size: .92rem; }
    .search-section { margin-top: -42px; }
    .offer-panel { padding: 14px; }
    .search-form { grid-template-columns: 1fr; }
    .search-button { width: 100%; }
    .section { padding: 56px 0; }
    .featured-section { padding-top: 76px; }
    .section-heading { align-items: flex-start; flex-direction: column; gap: 8px; }
    .centered-heading { align-items: center; text-align: center; }
    .product-grid { grid-template-columns: 1fr; }
    .product-image-wrap { aspect-ratio: 1.32 / 1; }
    .footer-grid { grid-template-columns: 1fr; gap: 24px; }
    .footer-bottom { flex-direction: column; }
    .detail-section { padding-top: 24px; }
    .product-detail { padding: 16px; }
    .detail-content h1 { font-size: 2.35rem; }
}

@media (max-width: 430px) {
    .hero-showcase { min-height: 375px; }
    .hero-tagline { font-size: 1.02rem; }
    .hero-description { display: none; }
    .category-chip { padding: 8px 13px; }
    .product-body { padding: 17px; }
    .card-actions { grid-template-columns: 1fr 42px; }
    .button { padding-inline: 14px; }
}
