/* ======================================================================
   Móc Len Nhà Bông — style.css
   ====================================================================== */

:root {
  --cream: #fffaf5;
  --paper: #fffdfb;
  --ink: #3f342e;
  --muted: #6f5d52;
  --rose: #d97b8c;
  --rose-dark: #bf6274;
  --rose-soft: #fbe9ec;
  --sage: #78966f;
  --sage-soft: #edf3e9;
  --brown: #6f5344;
  --line: #ecdfd5;
  --shadow: 0 20px 45px -28px rgba(96, 63, 47, 0.45);
  --shadow-soft: 0 10px 30px -18px rgba(96, 63, 47, 0.4);
  --radius: 22px;
  --font-body: "Be Vietnam Pro", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --header-h: 72px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

body.no-scroll {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

[hidden] {
  display: none !important;
}

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

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

p {
  margin: 0;
}

.container {
  width: min(1180px, 100% - 48px);
  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: absolute;
  top: -60px;
  left: 16px;
  z-index: 200;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 12px;
}

:focus-visible {
  outline: 2px solid var(--rose-dark);
  outline-offset: 3px;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  transition: transform 0.18s ease, background-color 0.18s ease,
    border-color 0.18s ease, box-shadow 0.18s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn-primary {
  background: var(--rose);
  color: #fff;
  box-shadow: 0 12px 24px -14px rgba(191, 98, 116, 0.9);
}

.btn-primary:hover {
  background: var(--rose-dark);
}

.btn-ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--ink);
}

.btn-ghost:hover {
  border-color: var(--rose);
  background: var(--rose-soft);
}

.btn-block {
  width: 100%;
}

.link-btn {
  padding: 0;
  border: 0;
  background: none;
  color: var(--rose-dark);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.icon-btn {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  color: var(--ink);
  transition: background-color 0.18s ease, border-color 0.18s ease;
}

.icon-btn:hover {
  background: var(--rose-soft);
  border-color: var(--rose);
}

.icon-btn svg {
  width: 18px;
  height: 18px;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  height: var(--header-h);
  background: rgba(255, 250, 245, 0.88);
  border-bottom: 1px solid rgba(236, 223, 213, 0.7);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 100%;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 11px;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: var(--rose-soft);
  color: var(--rose);
}

.logo-mark svg {
  width: 28px;
  height: 28px;
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.logo-text strong {
  font-family: var(--font-display);
  font-size: 1.18rem;
  letter-spacing: 0.01em;
}

.logo-text em {
  font-style: normal;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 34px;
  margin-left: auto;
  margin-right: 18px;
}

.main-nav a {
  position: relative;
  font-size: 0.93rem;
  font-weight: 500;
  color: var(--brown);
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 100%;
  height: 1.5px;
  background: var(--rose);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.22s ease;
}

.main-nav a:hover::after {
  transform: scaleX(1);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cart-btn {
  position: relative;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  color: var(--ink);
  transition: background-color 0.18s ease, border-color 0.18s ease;
}

.cart-btn:hover {
  background: var(--rose-soft);
  border-color: var(--rose);
}

.cart-btn svg {
  width: 22px;
  height: 22px;
}

.cart-count {
  position: absolute;
  top: -4px;
  right: -4px;
  display: grid;
  place-items: center;
  min-width: 21px;
  height: 21px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--rose-dark);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1;
}

.cart-count.is-bump {
  animation: bump 0.35s ease;
}

@keyframes bump {
  40% {
    transform: scale(1.32);
  }
}

.menu-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
}

.menu-btn span {
  display: block;
  height: 1.5px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

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

.menu-btn[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

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

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(48px, 7vw, 86px) 0 clamp(56px, 7vw, 92px);
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(10px);
  pointer-events: none;
}

.hero::before {
  width: 560px;
  height: 560px;
  top: -240px;
  right: -120px;
  background: radial-gradient(circle, #fbe4e8 0%, rgba(251, 228, 232, 0) 68%);
}

.hero::after {
  width: 480px;
  height: 480px;
  bottom: -260px;
  left: -160px;
  background: radial-gradient(circle, #eef3e7 0%, rgba(238, 243, 231, 0) 68%);
}

.hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  align-items: center;
  gap: clamp(32px, 6vw, 76px);
}

.eyebrow {
  margin-bottom: 14px;
  font-size: 0.73rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--rose-dark);
}

.hero h1 {
  font-size: clamp(2.5rem, 5.4vw, 4.35rem);
  letter-spacing: -0.02em;
}

.hero h1 em {
  position: relative;
  font-style: italic;
  color: var(--rose-dark);
}

.hero h1 em::after {
  content: "";
  position: absolute;
  left: 2%;
  right: 2%;
  bottom: 0.06em;
  height: 0.12em;
  border-radius: 999px;
  background: rgba(217, 123, 140, 0.28);
}

.hero .lead {
  max-width: 46ch;
  margin-top: 22px;
  color: var(--muted);
  font-size: 1.03rem;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  margin: 34px 0 0;
  padding: 0;
  list-style: none;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--brown);
}

.hero-points li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-points li::before {
  content: "✿";
  color: var(--sage);
  font-size: 0.9rem;
}

.hero-media {
  position: relative;
  min-height: 460px;
}

.hero-card {
  position: absolute;
  margin: 0;
  overflow: hidden;
  border: 6px solid var(--paper);
  border-radius: 28px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.hero-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-card--main {
  top: 0;
  right: 6%;
  width: min(340px, 74%);
  aspect-ratio: 4 / 5;
  transform: rotate(3deg);
}

.hero-card--sub {
  bottom: 0;
  left: 0;
  width: min(260px, 58%);
  aspect-ratio: 1 / 1;
  transform: rotate(-5deg);
}

.hero-sticker {
  position: absolute;
  right: 2%;
  bottom: 12%;
  display: grid;
  place-items: center;
  width: 108px;
  height: 108px;
  border-radius: 50%;
  background: var(--sage);
  color: #fff;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.02rem;
  line-height: 1.25;
  text-align: center;
  transform: rotate(8deg);
  box-shadow: 0 14px 30px -16px rgba(84, 112, 76, 0.8);
}

.hero-sticker::before {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px dashed rgba(255, 255, 255, 0.55);
  border-radius: 50%;
}

/* ---------- Perks ---------- */

.perks {
  border-block: 1px solid var(--line);
  background: rgba(255, 253, 251, 0.75);
}

.perks-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  padding-block: 26px;
}

.perk {
  display: flex;
  align-items: flex-start;
  gap: 13px;
}

.perk-icon {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--rose-soft);
  color: var(--rose-dark);
  font-size: 1rem;
}

.perk strong {
  display: block;
  font-size: 0.86rem;
  font-weight: 700;
}

.perk span:not(.perk-icon) {
  display: block;
  margin-top: 2px;
  font-size: 0.76rem;
  line-height: 1.45;
  color: var(--muted);
}

/* ---------- Products ---------- */

.products-section {
  padding: clamp(60px, 8vw, 96px) 0;
}

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

.section-head h2 {
  font-size: clamp(2rem, 3.6vw, 2.9rem);
}

.section-desc {
  max-width: 42ch;
  color: var(--muted);
  font-size: 0.94rem;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  padding: 9px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--brown);
  transition: background-color 0.18s ease, border-color 0.18s ease,
    color 0.18s ease;
}

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

.chip.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff8f2;
}

.toolbar-right {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.search {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.search:focus-within {
  border-color: var(--rose);
  box-shadow: 0 0 0 4px rgba(217, 123, 140, 0.12);
}

.search svg {
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  color: var(--muted);
}

.search input {
  width: 210px;
  padding: 10px 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 0.86rem;
}

.search input::placeholder {
  color: #a8978c;
}

.sort select {
  padding: 10px 34px 10px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background-color: var(--paper);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24'%3E%3Cpath d='m6 9 6 6 6-6' fill='none' stroke='%238a776c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  font-size: 0.86rem;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 26px;
  padding-top: 32px;
}

.product-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease,
    border-color 0.25s ease;
}

.product-card:hover {
  transform: translateY(-6px);
  border-color: #e2cdc0;
  box-shadow: var(--shadow);
}

.product-media {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: #f7efe9;
  overflow: hidden;
  cursor: pointer;
}

.product-media img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.product-card:hover .product-media img {
  transform: scale(1.045);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--sage-soft);
  color: #55704c;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.product-media .badge {
  position: absolute;
  top: 13px;
  left: 13px;
  background: rgba(255, 253, 251, 0.92);
  backdrop-filter: blur(4px);
  box-shadow: 0 4px 12px -6px rgba(96, 63, 47, 0.45);
}

.badge--rose {
  background: var(--rose-soft);
  color: var(--rose-dark);
}

.badge:empty {
  display: none;
}

.product-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 4px;
  padding: 18px 20px 20px;
}

.product-cat {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sage);
}

.product-name {
  font-family: var(--font-display);
  font-size: 1.13rem;
  font-weight: 600;
  line-height: 1.3;
}

.product-name button {
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  text-align: left;
  color: inherit;
}

.product-name button:hover {
  color: var(--rose-dark);
}

.product-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 14px;
}

.product-price {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.add-btn {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--cream);
  color: var(--ink);
  transition: background-color 0.18s ease, color 0.18s ease,
    border-color 0.18s ease, transform 0.18s ease;
}

.add-btn:hover {
  background: var(--rose);
  border-color: var(--rose);
  color: #fff;
  transform: rotate(90deg);
}

.add-btn svg {
  width: 17px;
  height: 17px;
}

.empty-state {
  padding: 64px 0 20px;
  text-align: center;
  color: var(--muted);
}

/* ---------- About ---------- */

.about {
  padding: clamp(56px, 7vw, 90px) 0;
  background: linear-gradient(180deg, #fdf5ef 0%, #fbf1e9 100%);
  border-block: 1px solid var(--line);
}

.about-inner {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: center;
  gap: clamp(32px, 6vw, 70px);
}

.about-media {
  position: relative;
  max-width: 440px;
}

.about-media img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border: 7px solid var(--paper);
  border-radius: 30px;
  box-shadow: var(--shadow);
  transform: rotate(-2deg);
}

.about-tag {
  position: absolute;
  right: -14px;
  bottom: 26px;
  padding: 8px 18px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff8f2;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transform: rotate(3deg);
}

.about-copy h2 {
  font-size: clamp(2rem, 3.6vw, 2.85rem);
}

.about-copy p {
  max-width: 52ch;
  margin-top: 18px;
  color: var(--muted);
  font-size: 0.95rem;
}

.about-copy .btn {
  margin-top: 26px;
}

/* ---------- Contact ---------- */

.contact-band {
  padding: clamp(60px, 8vw, 96px) 0;
}

.contact-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  align-items: center;
  gap: clamp(34px, 6vw, 80px);
}

.contact-band h2 {
  font-size: clamp(2rem, 3.8vw, 3rem);
}

.contact-band .lead {
  max-width: 46ch;
  margin-top: 18px;
  color: var(--muted);
  font-size: 0.95rem;
}

.contact-card {
  padding: 12px 26px 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow-soft);
}

.contact-row {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 17px 0;
  border-bottom: 1px solid var(--line);
}

.contact-row:hover strong {
  color: var(--rose-dark);
}

.contact-icon {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--rose-soft);
  color: var(--rose-dark);
  font-size: 0.95rem;
  font-weight: 700;
}

.contact-row em {
  display: block;
  font-style: normal;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.contact-row strong {
  font-size: 0.98rem;
  font-weight: 600;
  transition: color 0.18s ease;
}

.contact-address {
  padding-top: 18px;
  font-size: 0.8rem;
  color: var(--muted);
}

/* ---------- Footer ---------- */

.site-footer {
  padding: 52px 0 28px;
  border-top: 1px solid var(--line);
  background: var(--paper);
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.8fr) minmax(0, 1fr);
  gap: 40px;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--muted);
}

.footer-col h3 {
  margin: 0 0 4px;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink);
}

.footer-col a {
  width: fit-content;
  transition: color 0.18s ease;
}

.footer-col a:hover {
  color: var(--rose-dark);
}

.footer-brand strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--ink);
}

.footer-brand span {
  display: block;
  margin-top: 2px;
}

.footer-note {
  max-width: 46ch;
  font-size: 0.8rem;
}

.footer-hours {
  font-size: 0.8rem;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 38px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 0.78rem;
  color: var(--muted);
}

.footer-copy,
.footer-note--small {
  margin: 0;
}

/* ---------- Breadcrumb ---------- */

.breadcrumb {
  padding-top: 24px;
  font-size: 0.78rem;
  color: var(--muted);
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.breadcrumb li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.breadcrumb li:not(:last-child)::after {
  content: "/";
  color: #c9b7ab;
}

.breadcrumb a {
  transition: color 0.18s ease;
}

.breadcrumb a:hover {
  color: var(--rose-dark);
}

.breadcrumb [aria-current="page"] {
  color: var(--ink);
}

/* ---------- Category pages ---------- */

.category-hero {
  padding: 28px 0 54px;
}

.category-hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.85fr);
  align-items: center;
  gap: 48px;
}

.category-hero-copy h1 {
  margin-top: 10px;
  font-size: clamp(2.2rem, 5vw, 3.6rem);
}

.category-hero-copy .lead {
  max-width: 52ch;
  margin-top: 16px;
  color: var(--muted);
}

.category-count {
  margin-top: 12px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--sage);
}

.category-hero-copy .btn {
  margin-top: 24px;
}

.category-hero-media {
  margin: 0;
  border-radius: 32px;
  overflow: hidden;
  background: #f7efe9;
  box-shadow: var(--shadow);
}

.category-hero-media img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.category-products {
  padding: 8px 0 56px;
}

.category-others-section {
  padding: 8px 0 76px;
}

.category-others-section h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

.category-others {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.category-other-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 24px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: var(--shadow-soft);
  transition: border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.category-other-link em {
  font-style: normal;
  color: var(--rose-dark);
}

.category-other-link:hover {
  border-color: var(--rose);
  color: var(--rose-dark);
  transform: translateX(3px);
}

/* ---------- Category cards on home ---------- */

.category-section {
  padding: 20px 0 72px;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding-top: 32px;
}

.category-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  border-color: #e2cdc0;
  box-shadow: var(--shadow);
}

.category-card a {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.category-card img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.category-card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 8px;
  padding: 20px 22px 22px;
}

.category-card-body h3 {
  font-size: 1.3rem;
}

.category-card-body p {
  font-size: 0.88rem;
  color: var(--muted);
}

.category-card-body span {
  margin-top: auto;
  padding-top: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--rose-dark);
}

/* ---------- Product detail ---------- */

.product-page {
  padding: 28px 0 64px;
}

.product-page-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
  gap: 52px;
}

.product-page-media {
  position: relative;
  margin: 0;
  border-radius: 32px;
  overflow: hidden;
  background: #f7efe9;
  box-shadow: var(--shadow);
}

.product-page-media img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.product-page-media .badge {
  position: absolute;
  top: 18px;
  left: 18px;
  background: rgba(255, 253, 251, 0.92);
  backdrop-filter: blur(4px);
  box-shadow: 0 4px 12px -6px rgba(96, 63, 47, 0.45);
}

.product-page-info h1 {
  margin-top: 8px;
  font-size: clamp(2rem, 4vw, 2.9rem);
}

.product-page-price {
  margin-top: 14px;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--rose-dark);
}

.product-page-desc {
  margin-top: 16px;
  color: var(--muted);
}

.product-detail-list {
  display: grid;
  gap: 8px;
  margin: 22px 0 0;
  padding: 22px 0 0;
  border-top: 1px solid var(--line);
  list-style: none;
  font-size: 0.9rem;
  color: var(--brown);
}

.product-detail-list li {
  display: flex;
  gap: 10px;
}

.product-detail-list li::before {
  content: "✿";
  flex: 0 0 auto;
  color: var(--sage);
  font-size: 0.8rem;
  line-height: 1.7;
}

.product-page-buy {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 28px;
}

.product-page-buy .btn {
  flex: 1;
  min-width: 200px;
}

.product-hint {
  margin-top: 14px;
  font-size: 0.75rem;
  line-height: 1.55;
  color: var(--muted);
}

.product-back {
  display: inline-block;
  margin-top: 22px;
}

.related-products {
  padding: 12px 0 80px;
}

/* ---------- 404 ---------- */

.not-found {
  padding: 80px 0 100px;
}

.not-found-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  max-width: 720px;
  margin-inline: auto;
  text-align: center;
}

.not-found h1 {
  font-size: clamp(2.4rem, 6vw, 4rem);
}

.not-found .lead {
  max-width: 56ch;
  color: var(--muted);
}

.not-found .btn {
  margin-top: 8px;
}

.not-found-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 10px;
}

.not-found-links a {
  padding: 10px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  font-size: 0.84rem;
  transition: border-color 0.18s ease, color 0.18s ease;
}

.not-found-links a:hover {
  border-color: var(--rose);
  color: var(--rose-dark);
}

/* ---------- Overlay & Drawer ---------- */

.overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(63, 52, 46, 0.42);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.overlay.is-open {
  opacity: 1;
}

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
  width: min(430px, 100%);
  height: 100%;
  background: var(--cream);
  box-shadow: -30px 0 60px -40px rgba(63, 52, 46, 0.6);
  transform: translateX(102%);
  transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
  visibility: hidden;
}

.drawer.is-open {
  transform: translateX(0);
  visibility: visible;
}

.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px;
  border-bottom: 1px solid var(--line);
  background: var(--cream);
}

.drawer-head h2 {
  font-size: 1.45rem;
}

.drawer-view {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-height: 0;
}

.drawer-view[hidden] {
  display: none;
}

.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px 22px;
  overscroll-behavior: contain;
}

.drawer-foot {
  padding: 18px 22px 22px;
  border-top: 1px solid var(--line);
  background: var(--paper);
}

.drawer-foot[hidden] {
  display: none;
}

.cart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 64px 0;
  text-align: center;
  color: var(--muted);
}

.cart-empty span {
  font-size: 2.4rem;
}

.cart-empty p {
  font-size: 0.95rem;
}

.cart-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.cart-item {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 13px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.cart-item:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.cart-item img {
  width: 74px;
  height: 74px;
  border-radius: 14px;
  object-fit: cover;
  background: #f7efe9;
}

.cart-item-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.cart-item-name {
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.35;
}

.cart-item-price {
  font-size: 0.82rem;
  color: var(--muted);
}

.cart-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 5px;
}

.qty {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
}

.qty button {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  color: var(--brown);
  font-size: 1rem;
  line-height: 1;
}

.qty button:hover {
  background: var(--rose-soft);
  color: var(--rose-dark);
}

.qty span {
  min-width: 22px;
  text-align: center;
  font-size: 0.84rem;
  font-weight: 600;
}

.remove-btn {
  padding: 0;
  border: 0;
  background: none;
  font-size: 0.75rem;
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.remove-btn:hover {
  color: var(--rose-dark);
}

.cart-total-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.cart-total-row span {
  font-size: 0.86rem;
  color: var(--muted);
}

.cart-total-row strong {
  font-size: 1.2rem;
}

.cart-note {
  margin-bottom: 14px;
  font-size: 0.74rem;
  line-height: 1.5;
  color: var(--muted);
}

/* ---------- Checkout ---------- */

.back-btn {
  margin-bottom: 14px;
  padding: 0;
  border: 0;
  background: none;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--rose-dark);
}

.checkout-intro {
  margin-bottom: 20px;
  font-size: 0.82rem;
  color: var(--muted);
}

.field {
  display: block;
  margin-bottom: 15px;
}

.field > span,
.field legend {
  display: block;
  margin-bottom: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--brown);
}

.field em {
  font-style: normal;
  color: var(--rose-dark);
}

.field input,
.field textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--paper);
  font-size: 0.88rem;
  resize: vertical;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.field input:focus,
.field textarea:focus {
  outline: 0;
  border-color: var(--rose);
  box-shadow: 0 0 0 4px rgba(217, 123, 140, 0.12);
}

.field input.is-invalid,
.field textarea.is-invalid {
  border-color: #cf5b5b;
  box-shadow: 0 0 0 4px rgba(207, 91, 91, 0.1);
}

.field input::placeholder,
.field textarea::placeholder {
  color: #b3a297;
}

.payment {
  margin: 0 0 16px;
  padding: 0;
  border: 0;
}

.radio {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 9px;
  font-size: 0.85rem;
  cursor: pointer;
}

.radio input {
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  margin-top: 3px;
  accent-color: var(--rose-dark);
}

.form-error {
  margin-bottom: 12px;
  padding: 9px 13px;
  border-radius: 10px;
  background: #fbeaea;
  color: #a83e3e;
  font-size: 0.8rem;
}

.checkout-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  border-top: 1px dashed var(--line);
  font-size: 0.88rem;
  color: var(--muted);
}

.checkout-total strong {
  font-size: 1.15rem;
  color: var(--ink);
}

/* ---------- Order success ---------- */

.order-success {
  text-align: center;
}

.success-mark {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  margin: 8px auto 16px;
  border-radius: 50%;
  background: var(--sage-soft);
  color: var(--sage);
  font-size: 1.5rem;
  font-weight: 700;
}

.order-success h3 {
  font-size: 1.6rem;
}

.success-note {
  margin: 10px 0 18px;
  font-size: 0.85rem;
  color: var(--muted);
}

.order-code {
  font-size: 0.85rem;
  color: var(--muted);
}

.order-code strong {
  color: var(--ink);
  letter-spacing: 0.08em;
}

.order-summary {
  margin: 16px 0 0;
  padding: 16px;
  border: 1px dashed var(--line);
  border-radius: 14px;
  background: var(--paper);
  font-family: var(--font-body);
  font-size: 0.78rem;
  line-height: 1.7;
  text-align: left;
  white-space: pre-wrap;
  color: var(--brown);
}

.order-success .drawer-foot .btn + .btn {
  margin-top: 9px;
}

.order-success .link-btn {
  margin-top: 14px;
}

/* ---------- Toast ---------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 120;
  padding: 12px 22px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff8f2;
  font-size: 0.84rem;
  font-weight: 500;
  box-shadow: 0 18px 40px -18px rgba(40, 25, 18, 0.7);
  opacity: 0;
  transform: translate(-50%, 14px);
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ---------- Reveal on load ---------- */

.product-card,
.perk,
.hero-copy,
.hero-media {
  animation: rise 0.55s ease both;
}

.product-card:nth-child(2n) {
  animation-delay: 0.04s;
}

.product-card:nth-child(3n) {
  animation-delay: 0.08s;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- Responsive ---------- */

@media (max-width: 980px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .hero-media {
    min-height: 420px;
    max-width: 560px;
    margin-inline: auto;
    width: 100%;
  }

  .perks-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }

  .about-inner,
  .contact-inner {
    grid-template-columns: 1fr;
  }

  .about-media {
    max-width: 380px;
  }

  .section-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
}

@media (max-width: 760px) {
  .main-nav {
    position: absolute;
    top: var(--header-h);
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    margin: 0;
    padding: 14px 24px 22px;
    border-bottom: 1px solid var(--line);
    background: var(--cream);
    box-shadow: 0 24px 30px -26px rgba(63, 52, 46, 0.5);
  }

  .main-nav.is-open {
    display: flex;
  }

  .main-nav a {
    width: 100%;
    padding: 10px 0;
    font-size: 1rem;
  }

  .menu-btn {
    display: flex;
  }

  .logo-text em {
    font-size: 0.62rem;
  }

  .hero {
    padding-top: 38px;
  }

  .hero h1 {
    font-size: clamp(2.2rem, 9vw, 3rem);
  }

  .hero-media {
    min-height: 360px;
  }

  .hero-sticker {
    width: 88px;
    height: 88px;
    font-size: 0.86rem;
  }

  .toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .toolbar-right {
    flex-direction: column;
    align-items: stretch;
  }

  .search input {
    width: 100%;
  }

  .sort select {
    width: 100%;
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .product-body {
    padding: 14px 15px 16px;
  }

  .product-name {
    font-size: 1rem;
  }

  .add-btn {
    width: 38px;
    height: 38px;
  }

  .contact-card {
    padding: 6px 20px 18px;
  }
}

@media (max-width: 520px) {
  .container {
    width: min(100% - 32px, 100%);
  }

  .perks-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .product-body {
    padding: 12px 12px 14px;
  }

  .product-name {
    font-size: 0.92rem;
  }

  .product-price {
    font-size: 0.9rem;
  }

  .hero-card--main {
    width: 76%;
  }

  .hero-card--sub {
    width: 52%;
    left: 2%;
  }

  .hero-sticker {
    right: 0;
  }

  .drawer-body {
    padding: 18px;
  }

  .drawer-foot,
  .drawer-head {
    padding-inline: 18px;
  }

  }

@media (max-width: 360px) {
  .product-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .category-hero-inner,
  .product-page-inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .category-hero-media {
    max-width: 520px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 760px) {
  .category-grid {
    grid-template-columns: 1fr;
  }

  .product-page-media {
    border-radius: 24px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

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

@media (max-width: 520px) {
  .category-others {
    grid-template-columns: 1fr;
  }

  .category-hero {
    padding-bottom: 40px;
  }

  .not-found {
    padding: 56px 0 72px;
  }
}
