:root {
  --pink: #ff5ca8;
  --pink-dark: #e63f91;
  --pink-soft: #fff0f7;
  --yellow: #ffd700;
  --yellow-soft: #fff9d8;
  --blue: #2196f3;
  --blue-soft: #eaf5ff;
  --ink: #1f2330;
  --muted: #6f7483;
  --line: #e8e8ef;
  --surface: #ffffff;
  --page: #faf9fc;
  --success: #1e9e66;
  --danger: #d84a5b;
  --warning: #b67c00;
  --shadow: 0 18px 50px rgba(39, 24, 46, .10);
  --shadow-soft: 0 8px 28px rgba(39, 24, 46, .08);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
  --topbar-height: 68px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: var(--ink); background: var(--page); }
button, input, select, textarea { font: inherit; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.bi { color: var(--pink); }

.topbar {
  position: fixed; inset: 0 0 auto; height: var(--topbar-height); z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px max(18px, env(safe-area-inset-left));
  color: #fff; background: linear-gradient(135deg, var(--pink), #ff7ebb);
  box-shadow: 0 8px 24px rgba(255, 92, 168, .25);
}
.topbar .bi { color: #fff; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 1.08rem; font-weight: 800; letter-spacing: -.02em; }
.brand-mark { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 14px; background: rgba(255,255,255,.2); }
.brand-mark .bi { font-size: 1.2rem; }
.notification-link { position: relative; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 16px; background: rgba(255,255,255,.18); }
.notification-link .bi { font-size: 1.15rem; }
.badge-count { position: absolute; top: -4px; right: -5px; min-width: 20px; height: 20px; padding: 0 5px; display: grid; place-items: center; border-radius: 999px; background: var(--yellow); color: #332a00; border: 2px solid var(--pink); font-size: .68rem; font-weight: 900; }

.page-shell { width: min(1180px, calc(100% - 28px)); margin: 0 auto; padding: calc(var(--topbar-height) + 24px) 0 118px; }
.narrow-shell { width: min(980px, calc(100% - 28px)); }

.bottom-nav {
  position: fixed; z-index: 60; left: 50%; bottom: max(14px, env(safe-area-inset-bottom)); transform: translateX(-50%);
  width: min(94%, 510px); min-height: 70px; padding: 8px 10px;
  display: grid; grid-template-columns: repeat(4, 1fr); align-items: center;
  background: rgba(255,255,255,.96); border: 1px solid rgba(255,255,255,.7); border-radius: 26px;
  box-shadow: 0 18px 55px rgba(25, 20, 35, .2); backdrop-filter: blur(16px);
}
.bottom-nav-item { position: relative; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: #7b7f8c; font-size: .69rem; font-weight: 700; padding: 8px 3px; border-radius: 17px; }
.bottom-nav-item .bi { font-size: 1.25rem; color: var(--pink); }
.bottom-nav-item.active { color: var(--pink-dark); background: var(--pink-soft); }
.nav-icon-wrap { position: relative; line-height: 1; }
.cart-badge { top: -10px; right: -14px; border-color: #fff; }

.hero { position: relative; overflow: hidden; display: grid; gap: 26px; padding: 30px 22px; border-radius: var(--radius-xl); background: linear-gradient(145deg, #fff 0%, #fff2f8 50%, #fff9d9 100%); border: 1px solid #ffe2ef; box-shadow: var(--shadow-soft); }
.hero::after { content: ""; position: absolute; width: 230px; height: 230px; right: -90px; bottom: -120px; border-radius: 50%; background: rgba(33,150,243,.12); }
.hero-copy { position: relative; z-index: 2; }
.eyebrow { display: inline-flex; align-items: center; gap: 7px; color: var(--pink-dark); font-size: .77rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.hero h1, .page-header h1, .confirmation-hero h1 { margin: 10px 0 14px; font-size: clamp(2rem, 8vw, 4.5rem); line-height: .98; letter-spacing: -.055em; }
.hero p, .page-header p, .confirmation-hero p { color: var(--muted); font-size: 1rem; line-height: 1.7; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.button { min-height: 44px; padding: 11px 17px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 14px; font-weight: 800; cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease; }
.button:hover { transform: translateY(-1px); }
.button:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.button-primary { color: #fff; background: linear-gradient(135deg, var(--pink), var(--pink-dark)); box-shadow: 0 10px 22px rgba(255,92,168,.25); }
.button-primary .bi { color: #fff; }
.button-secondary { color: var(--ink); background: #fff; border: 1px solid var(--line); }
.button-large { min-height: 52px; padding-inline: 22px; }
.button-small { min-height: 38px; padding: 8px 13px; font-size: .84rem; }
.button-full { width: 100%; }
.hero-visual { min-height: 190px; position: relative; display: grid; place-items: center; }
.hero-orb { position: absolute; display: grid; place-items: center; border-radius: 28px; box-shadow: var(--shadow); }
.hero-orb .bi { font-size: 2rem; }
.hero-orb-pink { width: 112px; height: 112px; left: 14%; top: 28px; background: #fff; transform: rotate(-8deg); }
.hero-orb-yellow { width: 92px; height: 92px; right: 16%; top: 0; background: var(--yellow-soft); transform: rotate(9deg); }
.hero-orb-blue { width: 106px; height: 106px; right: 28%; bottom: 0; background: var(--blue-soft); transform: rotate(-3deg); }
.hero-orb-blue .bi { color: var(--blue); }
.hero-orb-yellow .bi { color: #c59200; }

.trust-strip { display: grid; gap: 10px; margin: 16px 0 34px; }
.trust-strip > div { display: flex; align-items: center; gap: 12px; padding: 15px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); }
.trust-strip .bi { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 13px; background: var(--pink-soft); font-size: 1.15rem; }
.trust-strip span { display: flex; flex-direction: column; }
.trust-strip small { color: var(--muted); margin-top: 2px; }
.section-block { margin-top: 28px; }
.section-heading { display: flex; justify-content: space-between; align-items: end; gap: 14px; margin-bottom: 16px; }
.section-heading h2, .panel h2, .order-summary h2 { margin: 5px 0 0; font-size: 1.35rem; letter-spacing: -.025em; }
.section-heading > a { color: var(--pink-dark); font-weight: 800; font-size: .86rem; white-space: nowrap; }

.product-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.product-card { min-width: 0; overflow: hidden; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: 0 6px 22px rgba(38,29,45,.055); }
.product-image-link { position: relative; display: block; aspect-ratio: 1 / .92; overflow: hidden; background: #f2f2f5; }
.product-image { width: 100%; height: 100%; object-fit: cover; transition: transform .25s ease; }
.product-card:hover .product-image { transform: scale(1.035); }
.product-placeholder { display: grid; place-items: center; background: linear-gradient(135deg, var(--pink-soft), var(--blue-soft)); }
.product-placeholder .bi { font-size: 2.2rem; opacity: .65; }
.product-type-chip { position: absolute; left: 8px; top: 8px; display: inline-flex; align-items: center; gap: 5px; padding: 6px 8px; border-radius: 999px; background: rgba(255,255,255,.92); box-shadow: 0 6px 20px rgba(0,0,0,.08); font-size: .64rem; font-weight: 900; }
.product-card-body { min-width: 0; flex: 1; display: flex; flex-direction: column; padding: 12px; }
.product-name { font-weight: 900; line-height: 1.25; letter-spacing: -.015em; }
.product-short { margin: 7px 0 12px; color: var(--muted); font-size: .78rem; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.product-card-footer { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.product-price { color: var(--pink-dark); font-size: .95rem; }
.icon-button { width: 38px; height: 38px; padding: 0; display: grid; place-items: center; border: 0; border-radius: 13px; background: var(--pink-soft); cursor: pointer; }
.icon-button .bi { font-size: 1.05rem; }
.icon-button.disabled { background: #f1f1f4; }
.icon-button.disabled .bi { color: #aaa; }

.page-header { padding: 26px 4px 22px; }
.page-header.compact { padding-bottom: 12px; }
.page-header h1 { font-size: clamp(2rem, 7vw, 3.5rem); }
.page-header p { max-width: 680px; margin-bottom: 0; }
.filter-bar { display: grid; gap: 10px; padding: 14px; margin-bottom: 20px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); }
.search-field { position: relative; }
.search-field .bi { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); }
.search-field input { padding-left: 40px; }
input, select, textarea { width: 100%; min-height: 46px; padding: 11px 13px; color: var(--ink); background: #fff; border: 1px solid #dfe0e7; border-radius: 12px; outline: none; }
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--pink); box-shadow: 0 0 0 4px rgba(255,92,168,.12); }
label { display: grid; gap: 7px; font-size: .83rem; font-weight: 800; }
label small, label em { color: var(--muted); font-size: .72rem; font-style: normal; font-weight: 500; }
.optional { color: var(--muted); font-weight: 500; }

.product-detail { display: grid; gap: 24px; }
.product-detail-media { position: relative; overflow: hidden; min-height: 320px; border-radius: var(--radius-xl); background: #f1f1f5; }
.product-detail-media > img { width: 100%; height: 100%; min-height: 320px; object-fit: cover; }
.product-detail-placeholder { min-height: 320px; display: grid; place-items: center; background: linear-gradient(135deg, var(--pink-soft), var(--blue-soft)); }
.product-detail-placeholder .bi { font-size: 4rem; }
.product-detail-copy h1 { margin: 12px 0 7px; font-size: clamp(2rem, 8vw, 4rem); letter-spacing: -.055em; line-height: 1; }
.back-link { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: .84rem; font-weight: 800; }
.detail-price { margin: 0 0 18px; color: var(--pink-dark); font-size: 1.65rem; font-weight: 950; }
.detail-short { font-size: 1.05rem; line-height: 1.6; }
.rich-description { color: var(--muted); white-space: pre-line; line-height: 1.7; }
.stock-line { display: flex; align-items: center; gap: 8px; margin: 18px 0; font-weight: 800; }
.in-stock { color: var(--success); }
.in-stock .bi { color: var(--success); }
.out-stock { color: var(--danger); }
.out-stock .bi { color: var(--danger); }
.add-form { display: flex; align-items: end; gap: 10px; flex-wrap: wrap; }
.add-form label { width: 100px; }

.flash { max-width: 980px; margin: 0 auto 15px; display: flex; gap: 10px; align-items: flex-start; padding: 13px 15px; border-radius: 14px; font-weight: 700; }
.flash-success { color: #136e49; background: #e9fff5; border: 1px solid #b9edd6; }
.flash-success .bi { color: var(--success); }
.flash-error { color: #963242; background: #fff0f2; border: 1px solid #ffd0d6; }
.flash-error .bi { color: var(--danger); }
.error-list { margin-bottom: 16px; padding: 15px 18px; border-radius: 15px; color: #8c2e3d; background: #fff0f2; border: 1px solid #ffd0d6; }
.error-list ul { margin: 8px 0 0; padding-left: 19px; }

.empty-state { min-height: 300px; padding: 40px 20px; display: grid; place-items: center; align-content: center; text-align: center; background: #fff; border: 1px dashed #d8d8e2; border-radius: var(--radius-xl); }
.empty-state > .bi { font-size: 3.3rem; }
.empty-state h3 { margin: 14px 0 5px; }
.empty-state p { max-width: 440px; margin: 0 0 18px; color: var(--muted); }

.cart-layout, .checkout-layout, .confirmation-layout { display: grid; gap: 16px; }
.cart-items { display: grid; gap: 10px; }
.cart-item { display: grid; grid-template-columns: 82px 1fr; gap: 12px; padding: 12px; background: #fff; border: 1px solid var(--line); border-radius: 18px; }
.cart-item > img, .cart-thumb-placeholder { width: 82px; height: 82px; object-fit: cover; border-radius: 14px; background: var(--pink-soft); }
.cart-thumb-placeholder { display: grid; place-items: center; }
.cart-item-info { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.cart-item-info h3 { margin: 0; font-size: .97rem; }
.cart-item-info span { color: var(--muted); font-size: .75rem; }
.cart-item-info strong { color: var(--pink-dark); font-size: .88rem; }
.cart-actions { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.cart-actions form:first-child { display: flex; align-items: center; gap: 7px; }
.cart-actions input { width: 70px; min-height: 38px; padding: 7px; }
.text-button, .danger-link { padding: 0; border: 0; background: transparent; cursor: pointer; font-size: .76rem; font-weight: 800; }
.text-button { color: var(--pink-dark); }
.danger-link { color: var(--danger); }
.danger-link .bi { color: var(--danger); }
.order-summary, .panel { padding: 20px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-soft); }
.summary-row { display: flex; justify-content: space-between; gap: 15px; padding: 12px 0; color: var(--muted); border-bottom: 1px solid var(--line); }
.summary-row.total { margin-bottom: 14px; color: var(--ink); font-size: 1.08rem; border-bottom: 0; }
.summary-row.total strong { color: var(--pink-dark); }
.continue-link { display: flex; justify-content: center; align-items: center; gap: 7px; margin-top: 13px; color: var(--muted); font-size: .78rem; font-weight: 800; }

.checkout-form h2 { display: flex; align-items: center; gap: 9px; margin: 0 0 16px; }
.checkout-form h2:not(:first-child) { margin-top: 26px; }
.form-grid { display: grid; gap: 13px; }
.full-field { grid-column: 1 / -1; }
.payment-options { display: grid; gap: 10px; }
.payment-option { position: relative; grid-template-columns: auto 44px 1fr auto; align-items: center; gap: 10px; min-height: 74px; padding: 12px; border: 1px solid var(--line); border-radius: 16px; cursor: pointer; }
.payment-option input { width: 18px; min-height: auto; accent-color: var(--pink); }
.payment-option:has(input:checked) { border-color: var(--pink); background: var(--pink-soft); box-shadow: 0 0 0 3px rgba(255,92,168,.1); }
.payment-icon { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 13px; background: #fff; }
.payment-option > span:nth-of-type(2) { display: flex; flex-direction: column; gap: 3px; }
.payment-option small { color: var(--muted); font-size: .7rem; }
.check-icon { opacity: 0; }
.payment-option:has(input:checked) .check-icon { opacity: 1; }
.checkout-item { display: flex; justify-content: space-between; gap: 10px; padding: 10px 0; color: var(--muted); font-size: .82rem; border-bottom: 1px solid var(--line); }
.checkout-item strong { color: var(--ink); white-space: nowrap; }
.secure-note { display: flex; gap: 7px; color: var(--muted); font-size: .72rem; line-height: 1.5; }

.confirmation-hero { text-align: center; padding: 20px 0 26px; }
.confirmation-icon { width: 72px; height: 72px; margin: 0 auto 14px; display: grid; place-items: center; border-radius: 24px; background: #e9fff5; }
.confirmation-icon .bi { color: var(--success); font-size: 2.2rem; }
.confirmation-hero h1 { font-size: clamp(2rem, 8vw, 3.6rem); }
.confirmation-hero p { max-width: 660px; margin: 0 auto; }
.status-pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 7px; margin-top: 15px; }
.status-pill { display: inline-flex; width: fit-content; align-items: center; padding: 6px 9px; border-radius: 999px; font-size: .68rem; font-weight: 900; white-space: nowrap; }
.status-pending, .status-awaiting_payment { color: #8a6200; background: #fff4c5; }
.status-declared, .status-processing { color: #166a9f; background: #e7f5ff; }
.status-paid, .status-confirmed, .status-completed { color: #146e4a; background: #e7fbf2; }
.status-failed, .status-refunded, .status-cancelled, .status-rejected { color: #963242; background: #ffebee; }
.payment-instructions h2, .downloads-panel h2 { display: flex; align-items: center; gap: 9px; margin-top: 0; }
.steps-list { margin: 18px 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.steps-list li { display: flex; align-items: center; gap: 12px; color: var(--muted); line-height: 1.5; }
.steps-list li > span { flex: 0 0 34px; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 12px; color: var(--pink-dark); background: var(--pink-soft); font-weight: 950; }
.merchant-number-card { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px; border-radius: 18px; background: linear-gradient(135deg, var(--pink-soft), var(--yellow-soft)); border: 1px solid #ffd7e9; }
.merchant-number-card > div { display: flex; flex-direction: column; }
.merchant-number-card small { color: var(--muted); }
.merchant-number-card strong { font-size: 1.45rem; letter-spacing: .03em; }
.copy-button { padding: 9px 11px; border: 1px solid #f0bfd6; border-radius: 12px; background: #fff; color: var(--pink-dark); font-weight: 850; cursor: pointer; }
.warning-note { display: flex; gap: 8px; color: var(--warning); font-size: .78rem; line-height: 1.5; }
.warning-note .bi { color: var(--warning); }
.reference-form { display: grid; gap: 12px; margin-top: 20px; }
.success-box { display: flex; gap: 13px; padding: 15px; border-radius: 16px; background: #e9fff5; color: #146e4a; }
.success-box .bi { color: var(--success); font-size: 1.5rem; }
.success-box p { margin: 3px 0 0; }
.customer-mini { display: grid; gap: 8px; margin-top: 16px; color: var(--muted); font-size: .78rem; }
.customer-mini span { display: flex; align-items: center; gap: 8px; }
.downloads-panel { margin-top: 16px; }
.muted-message { color: var(--muted); }
.download-list { display: grid; gap: 10px; }
.download-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 14px; }
.download-item > div { display: flex; flex-direction: column; gap: 3px; }
.download-item small { color: var(--muted); }

.notification-list { display: grid; gap: 10px; }
.notification-card { display: grid; grid-template-columns: 44px 1fr auto; align-items: center; gap: 11px; padding: 14px; background: #fff; border: 1px solid var(--line); border-radius: 17px; }
.notification-card.unread { border-color: #ffc2df; background: var(--pink-soft); }
.notification-icon { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 14px; background: #fff; }
.notification-card > span:nth-child(2) { display: flex; flex-direction: column; gap: 5px; }
.notification-card strong { font-size: .84rem; line-height: 1.4; }
.notification-card small { color: var(--muted); font-size: .7rem; }
.clear-form { display: flex; justify-content: center; margin-top: 16px; }

.about-grid { display: grid; gap: 12px; }
.about-card { padding: 22px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); }
.about-card > .bi { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 17px; background: var(--pink-soft); font-size: 1.35rem; }
.about-card h2 { margin: 16px 0 7px; }
.about-card p { margin: 0; color: var(--muted); line-height: 1.65; }
.contact-panel { margin-top: 18px; }
.contact-list { display: grid; gap: 9px; margin-top: 18px; }
.contact-list > * { display: flex; align-items: center; gap: 11px; padding: 11px; border: 1px solid var(--line); border-radius: 14px; }
.contact-list > * > .bi { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; background: var(--pink-soft); }
.contact-list span { display: flex; flex-direction: column; }
.contact-list small { color: var(--muted); }
.error-page { min-height: 80vh; display: grid; place-items: center; align-content: center; text-align: center; }
.error-page h1 { margin: 15px 0 5px; }
.error-page p { max-width: 520px; color: var(--muted); }
.error-illustration { width: 80px; height: 80px; display: grid; place-items: center; border-radius: 26px; background: var(--pink-soft); }
.error-illustration .bi { font-size: 2.3rem; }

@media (min-width: 600px) {
  .page-shell { width: min(1180px, calc(100% - 44px)); }
  .hero { padding: 44px; }
  .trust-strip { grid-template-columns: repeat(3, 1fr); }
  .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
  .filter-bar { grid-template-columns: minmax(260px, 1fr) 180px auto; align-items: center; }
  .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about-grid { grid-template-columns: repeat(3, 1fr); }
  .cart-item { grid-template-columns: 94px 1fr auto; align-items: center; }
  .cart-item > img, .cart-thumb-placeholder { width: 94px; height: 94px; }
  .cart-actions { grid-column: auto; display: grid; justify-items: end; }
}

@media (min-width: 820px) {
  :root { --topbar-height: 74px; }
  .topbar { padding-inline: max(28px, calc((100vw - 1180px) / 2)); }
  .hero { grid-template-columns: 1.25fr .75fr; align-items: center; min-height: 430px; }
  .hero-visual { min-height: 300px; }
  .hero-orb-pink { width: 145px; height: 145px; }
  .hero-orb-yellow { width: 120px; height: 120px; }
  .hero-orb-blue { width: 135px; height: 135px; }
  .product-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .product-detail { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); align-items: center; }
  .product-detail-media, .product-detail-media > img, .product-detail-placeholder { min-height: 560px; }
  .cart-layout { grid-template-columns: minmax(0, 1fr) 320px; align-items: start; }
  .checkout-layout, .confirmation-layout { grid-template-columns: minmax(0, 1fr) 340px; align-items: start; }
  .order-summary { position: sticky; top: calc(var(--topbar-height) + 16px); }
  .contact-panel { display: grid; grid-template-columns: .8fr 1.2fr; gap: 24px; align-items: center; }
  .contact-list { margin-top: 0; }
}

@media (min-width: 1100px) {
  .product-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
  .product-card-body { padding: 16px; }
  .product-name { font-size: 1.04rem; }
  .product-short { font-size: .84rem; }
}
