:root {
  --baby-blue: #8FD3F4;
  --baby-blue-strong: #5BB8E8;
  --baby-blue-deep: #2E8FC7;
  --baby-blue-tint: #E6F6FD;
  --baby-blue-soft: #F4FBFE;
  --ink: #17324A;
  --muted: #5F7D99;
  --white: #FFFFFF;
  --line: #DEEDF6;
  --radius: 16px;
  --radius-sm: 12px;
  --shadow: 0 8px 24px rgba(46, 143, 199, 0.16);
  --shadow-soft: 0 4px 14px rgba(46, 143, 199, 0.10);
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
  --font-head: 'Poppins', var(--font-body);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

img, svg { display: block; }

a { text-decoration: none; color: inherit; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-head);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.3px;
}

.logo-mark { width: 32px; height: 32px; border-radius: 8px; }

.logo span { color: var(--ink); }
.logo strong { color: var(--baby-blue-strong); }

.menu-btn {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: var(--baby-blue-soft);
  border: 1px solid var(--line);
  border-radius: 12px;
  cursor: pointer;
}

.menu-btn span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--baby-blue-deep);
  border-radius: 2px;
  transition: 0.25s ease;
}

.menu-btn[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-btn[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.site-nav {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--white);
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
  display: none;
  flex-direction: column;
  padding: 10px 18px 18px;
}

.site-nav.open { display: flex; }

.site-nav a {
  padding: 14px 4px;
  font-weight: 500;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
}

.site-nav a:last-child { border-bottom: none; }

.nav-cta {
  margin-top: 6px;
  text-align: center;
  background: var(--baby-blue-tint);
  color: var(--baby-blue-deep) !important;
  border-radius: var(--radius-sm);
}

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(160deg, var(--baby-blue-tint) 0%, #D5EFFA 55%, var(--baby-blue-soft) 100%);
}

.hero-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 44px 20px 40px;
}

.hero-tag {
  display: inline-block;
  background: rgba(255, 255, 255, 0.75);
  color: var(--baby-blue-deep);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--baby-blue);
}

.hero h1 {
  font-family: var(--font-head);
  font-size: 30px;
  line-height: 1.15;
  letter-spacing: -0.6px;
  margin: 16px 0 12px;
  max-width: 14em;
}

.hero p {
  color: var(--muted);
  font-size: 15px;
  max-width: 32em;
}

.search-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--white);
  border: 1px solid var(--baby-blue);
  border-radius: 999px;
  padding: 6px 6px 6px 16px;
  margin: 22px 0 18px;
  max-width: 480px;
  box-shadow: var(--shadow-soft);
}

.search-ico { width: 18px; height: 18px; color: var(--muted); flex-shrink: 0; }

.search-bar input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  font-size: 14px;
  font-family: var(--font-body);
  background: transparent;
  color: var(--ink);
}

.search-bar button {
  border: none;
  background: var(--baby-blue-strong);
  color: var(--white);
  font-weight: 600;
  font-size: 14px;
  padding: 10px 18px;
  border-radius: 999px;
  cursor: pointer;
  flex-shrink: 0;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--baby-blue-strong);
  color: var(--white);
  font-weight: 600;
  font-size: 15px;
  padding: 13px 22px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease, background 0.2s ease;
}

.btn-primary:active { transform: scale(0.97); }
.btn-primary.center { margin: 26px auto 0; display: flex; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.8);
  color: var(--baby-blue-deep);
  font-weight: 600;
  font-size: 15px;
  padding: 13px 22px;
  border-radius: 999px;
  border: 1px solid var(--baby-blue);
}

.hero-stats {
  display: flex;
  gap: 26px;
  margin-top: 30px;
}

.hero-stats div { display: flex; flex-direction: column; }

.hero-stats strong {
  font-family: var(--font-head);
  font-size: 20px;
  color: var(--baby-blue-deep);
}

.hero-stats span {
  font-size: 12px;
  color: var(--muted);
}

/* ---------- Sections ---------- */
.categories, .featured { padding: 42px 20px; }

.section-head { margin-bottom: 22px; max-width: 1080px; margin-left: auto; margin-right: auto; }

.section-head h2 {
  font-family: var(--font-head);
  font-size: 22px;
  letter-spacing: -0.4px;
}

.section-head p { color: var(--muted); font-size: 13px; margin-top: 4px; }

.cat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  max-width: 1080px;
  margin: 0 auto;
}

.cat-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.cat-card svg { width: 36px; height: 36px; }

.cat-card h3 { font-size: 14px; font-weight: 600; }

.cat-card p { font-size: 12px; color: var(--muted); }

.cat-card.active,
.cat-card:hover {
  border-color: var(--baby-blue-strong);
  box-shadow: var(--shadow-soft);
}

/* ---------- Products ---------- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  max-width: 1080px;
  margin: 0 auto;
}

.product-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s ease;
}

.product-card:hover { box-shadow: var(--shadow-soft); }

.product-thumb {
  position: relative;
  aspect-ratio: 1 / 1;
  background: linear-gradient(150deg, var(--baby-blue-tint), var(--baby-blue-soft));
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-thumb svg { width: 46%; height: 46%; }

.product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.badge {
  position: absolute;
  top: 10px;
  left: 10px;
  font-size: 11px;
  font-weight: 600;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--white);
  color: var(--baby-blue-deep);
  border: 1px solid var(--baby-blue);
}

.badge.hot { background: #FFF3E6; color: #C97B2E; border-color: #F5D9B8; }

.product-info { padding: 12px 12px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }

.product-code { font-size: 11px; color: var(--muted); font-weight: 500; letter-spacing: 0.4px; }

.product-name { font-size: 14px; font-weight: 600; line-height: 1.3; }

.product-meta { font-size: 12px; color: var(--muted); }

.product-price {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-top: 2px;
}

.product-price .price { font-family: var(--font-head); font-size: 16px; color: var(--baby-blue-deep); font-weight: 700; }
.product-price .unit { font-size: 11px; color: var(--muted); }

.product-card .btn-ghost {
  margin-top: 10px;
  padding: 9px 14px;
  font-size: 13px;
  width: 100%;
  background: var(--baby-blue-soft);
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--baby-blue-soft);
  border-top: 1px solid var(--line);
  padding: 34px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.logo--foot { font-size: 18px; }

.footer-desc { font-size: 13px; color: var(--muted); margin-top: 10px; max-width: 24em; }

.footer-col h3 { font-size: 13px; font-weight: 600; margin-bottom: 10px; }

.footer-col a {
  display: block;
  font-size: 13px;
  color: var(--muted);
  padding: 4px 0;
}

.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  color: var(--muted);
}

/* ---------- Filtering helper ---------- */
.hidden { display: none !important; }

/* ---------- Larger screens ---------- */
@media (min-width: 640px) {
  .cat-grid, .product-grid { grid-template-columns: repeat(3, 1fr); }
  .hero h1 { font-size: 38px; }
}

@media (min-width: 900px) {
  .menu-btn { display: none; }
  .site-nav {
    position: static;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 24px;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
  }
  .site-nav a { border: none; padding: 8px 0; font-size: 15px; }
  .nav-cta {
    margin: 0;
    padding: 10px 18px;
    background: var(--baby-blue-tint);
    border-radius: 999px;
  }
  .cat-grid, .product-grid { grid-template-columns: repeat(4, 1fr); }
  .hero-inner { padding: 80px 20px; }
  .hero h1 { font-size: 44px; max-width: none; }
  .hero p { font-size: 17px; }
  .hero-tag { font-size: 13px; }
  .hero-stats { gap: 44px; }
  .hero-stats strong { font-size: 24px; }
  .hero-stats span { font-size: 13px; }
  .section-head h2 { font-size: 26px; }
  .cat-card { padding: 22px 18px; }
  .cat-card svg { width: 44px; height: 44px; }
  .cat-card h3 { font-size: 16px; }
  .cat-card p { font-size: 13px; }
  .product-name { font-size: 16px; }
  .site-footer { flex-direction: row; flex-wrap: wrap; gap: 30px; }
  .footer-bottom { flex: 1 1 100%; flex-direction: row; justify-content: space-between; }
}

@media (min-width: 1200px) {
  .cat-grid, .product-grid { grid-template-columns: repeat(5, 1fr); }
}

/* ---------- Product order page ---------- */
.back-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--baby-blue-deep);
  padding: 10px 0;
}

.mobile-back { display: inline-flex; margin-bottom: 14px; }

.product-detail {
  max-width: 1080px;
  margin: 0 auto;
  padding: 18px 20px 30px;
}

.pd-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.pd-thumb {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(150deg, var(--baby-blue-tint), var(--baby-blue-soft));
}

.pd-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 8px;
}

.pd-thumb svg { width: 34%; height: 34%; }

.pd-info { display: flex; flex-direction: column; gap: 10px; }

.pd-tag {
  align-self: flex-start;
  background: var(--baby-blue-tint);
  color: var(--baby-blue-deep);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  padding: 5px 11px;
  border-radius: 999px;
}

.pd-code { font-size: 12px; color: var(--muted); font-weight: 500; letter-spacing: 0.4px; }

.pd-name {
  font-family: var(--font-head);
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.4px;
}

.pd-price {
  font-family: var(--font-head);
  font-size: 30px;
  font-weight: 700;
  color: var(--baby-blue-deep);
}

.pd-price .cur { font-size: 18px; }
.pd-price .unit { font-size: 13px; color: var(--muted); font-weight: 500; }

.pd-note {
  background: var(--baby-blue-soft);
  border: 1px solid var(--line);
  border-left: 3px solid var(--baby-blue-strong);
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}

.qty-row { display: flex; align-items: center; justify-content: space-between; margin-top: 4px; }

.qty-label { font-size: 13px; font-weight: 600; }

.qty-stepper {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--baby-blue);
  border-radius: 999px;
  background: var(--baby-blue-soft);
  overflow: hidden;
}

.qty-stepper button {
  width: 42px;
  height: 42px;
  border: none;
  background: transparent;
  color: var(--baby-blue-deep);
  font-size: 20px;
  cursor: pointer;
}

.qty-stepper input {
  width: 48px;
  height: 42px;
  border: none;
  outline: none;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--white);
  -moz-appearance: textfield;
}

.qty-stepper input::-webkit-outer-spin-button,
.qty-stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.pd-actions { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }

.pd-actions .btn-primary,
.pd-actions .btn-ghost { width: 100%; padding: 15px 22px; font-size: 16px; }

.pd-trust {
  margin-top: 6px;
  border-top: 1px dashed var(--line);
  padding-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12.5px;
  color: var(--muted);
}

.pd-trust span::before { content: "✓  "; color: var(--baby-blue-strong); font-weight: 700; }

.related { padding: 6px 20px 42px; }

.not-found {
  max-width: 1080px;
  margin: 0 auto;
  padding: 60px 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.not-found h2 { font-family: var(--font-head); }

.not-found p { color: var(--muted); font-size: 14px; }

@media (min-width: 800px) {
  .pd-grid {
    flex-direction: row;
    align-items: flex-start;
    gap: 30px;
  }
  .pd-thumb { flex: 1 1 46%; max-width: 480px; }
  .pd-info { flex: 1 1 54%; padding-top: 6px; }
  .pd-name { font-size: 28px; }
  .pd-actions { flex-direction: row; }
  .pd-note { max-width: 36em; }
}