:root {
  --paper: #f4f0e8;
  --ink: #141414;
  --red: #f04f3d;
  --acid: #d7f34a;
  --lilac: #c8bdff;
  --blue: #b8d7ff;
  --line: rgba(20, 20, 20, 0.18);
  --white: #fffdf8;
  --sans: "DM Sans", "Pretendard", sans-serif;
  --serif: "Gowun Batang", serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  line-height: 1.5;
}

body.cart-open {
  overflow: hidden;
}

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

button,
input {
  font: inherit;
}

button {
  color: inherit;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: -80px;
  z-index: 100;
  background: var(--ink);
  color: white;
  padding: 12px 16px;
}

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.notice {
  background: var(--ink);
  color: white;
  min-height: 34px;
  display: grid;
  place-items: center;
  padding: 7px 16px;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-align: center;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  height: 76px;
  padding: 0 4vw;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  background: rgba(244, 240, 232, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.04em;
}

.brand small {
  margin-left: 8px;
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.16em;
}

.desktop-nav {
  display: flex;
  gap: 28px;
  font-size: 13px;
}

.desktop-nav a,
.text-link {
  position: relative;
}

.desktop-nav a::after,
.text-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -4px;
  border-bottom: 1px solid;
  transition: right 220ms ease;
}

.desktop-nav a:hover::after,
.text-link:hover::after {
  right: 0;
}

.cart-trigger {
  justify-self: end;
  border: 0;
  background: transparent;
  padding: 10px 0 10px 16px;
  cursor: pointer;
  font-size: 13px;
}

.cart-count {
  display: inline-grid;
  min-width: 23px;
  height: 23px;
  margin-left: 6px;
  place-items: center;
  border-radius: 50%;
  background: var(--red);
  color: white;
  font-size: 11px;
}

.hero {
  min-height: calc(100vh - 110px);
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  border-bottom: 1px solid var(--line);
}

.hero-copy {
  padding: clamp(70px, 9vw, 145px) 6vw 80px 4vw;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.eyebrow {
  margin: 0 0 22px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
}

.hero h1 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(48px, 6.6vw, 108px);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.065em;
}

.hero h1 em {
  color: var(--red);
  font-style: normal;
}

.hero-lead {
  max-width: 530px;
  margin: 36px 0 0;
  font-family: var(--serif);
  font-size: clamp(16px, 1.4vw, 21px);
  line-height: 1.8;
  word-break: keep-all;
}

.hero-actions {
  margin-top: 42px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0 24px;
  border: 1px solid var(--ink);
  cursor: pointer;
  font-size: 13px;
  transition: transform 160ms ease, background 160ms ease;
}

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

.button-dark {
  background: var(--ink);
  color: white;
}

.text-link {
  font-size: 13px;
}

.hero-art {
  position: relative;
  overflow: hidden;
  min-height: 620px;
  display: grid;
  place-items: center;
  background: var(--lilac);
}

.hero-product {
  position: relative;
  z-index: 2;
  width: min(70%, 460px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 253, 248, 0.9);
  box-shadow: 28px 34px 0 rgba(20, 20, 20, 0.12);
  transform: rotate(-4deg);
}

.hero-product img {
  width: 70%;
  height: 70%;
  object-fit: contain;
  filter: drop-shadow(10px 18px 18px rgba(20, 20, 20, 0.2));
  transform: rotate(4deg) scale(1.12);
}

.hero-wordmark {
  position: absolute;
  left: 6%;
  bottom: 2%;
  z-index: 3;
  font-family: var(--serif);
  font-size: clamp(70px, 10vw, 154px);
  line-height: 1;
  letter-spacing: -0.12em;
  color: var(--red);
  transform: rotate(-6deg);
}

.hero-orbit {
  position: absolute;
  border: 1px solid rgba(20, 20, 20, 0.55);
  border-radius: 50%;
}

.hero-orbit-one {
  width: 120%;
  aspect-ratio: 1;
  transform: rotate(24deg) scaleY(0.46);
}

.hero-orbit-two {
  width: 88%;
  aspect-ratio: 1;
  transform: rotate(-36deg) scaleY(0.54);
}

.hero-stamp {
  position: absolute;
  right: 7%;
  top: 9%;
  z-index: 3;
  width: 94px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--acid);
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: 0.12em;
  transform: rotate(9deg);
}

.marquee {
  overflow: hidden;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  background: var(--acid);
}

.marquee-track {
  width: max-content;
  display: flex;
  align-items: center;
  gap: 34px;
  animation: slide 26s linear infinite;
  font-size: 13px;
  letter-spacing: 0.15em;
}

.marquee-track i {
  font-style: normal;
}

@keyframes slide {
  to { transform: translateX(-50%); }
}

.section {
  padding: 120px 4vw;
}

.section-heading {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  align-items: end;
  gap: 40px;
  margin-bottom: 56px;
}

.section-heading h2,
.story h2,
.guide h2,
.newsletter h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(38px, 4.4vw, 68px);
  font-weight: 400;
  letter-spacing: -0.055em;
  line-height: 1.18;
}

.section-heading > p {
  justify-self: end;
  margin: 0;
  max-width: 520px;
  color: rgba(20, 20, 20, 0.68);
  font-size: 14px;
  line-height: 1.8;
}

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

.product-card {
  min-width: 0;
}

.product-visual {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  background: #ebe5d9;
}

.product-badge {
  position: absolute;
  left: 14px;
  top: 14px;
  z-index: 2;
  padding: 7px 9px;
  background: rgba(255, 253, 248, 0.86);
  font-size: 9px;
  letter-spacing: 0.14em;
}

.product-image {
  width: 76%;
  height: 76%;
  object-fit: contain;
  mix-blend-mode: multiply;
  transition: transform 320ms ease;
}

.product-card:hover .product-image {
  transform: scale(1.05);
}

.product-card:nth-child(2n) .product-visual { background: #e8dfcc; }
.product-card:nth-child(3n) .product-visual { background: #e1e5d3; }
.product-card:nth-child(4n) .product-visual { background: #ead9cf; }

.product-card.is-sold-out .product-image {
  filter: grayscale(1);
  opacity: 0.5;
}

.product-card.is-sold-out .product-badge {
  background: var(--ink);
  color: var(--white);
}

.product-info {
  min-height: 94px;
  padding: 18px 2px 12px;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid var(--line);
}

.product-name,
.product-price,
.product-note {
  margin: 0;
}

.product-name,
.product-price {
  font-size: 14px;
  font-weight: 600;
}

.product-note {
  margin-top: 5px;
  color: rgba(20, 20, 20, 0.58);
  font-size: 11px;
}

.product-price {
  white-space: nowrap;
}

.add-button {
  width: 100%;
  padding: 12px 2px;
  display: flex;
  justify-content: space-between;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
  font-size: 12px;
}

.variant-field {
  padding: 14px 2px;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  color: rgba(20, 20, 20, 0.62);
  font-size: 11px;
}

.variant-field select {
  width: 100%;
  height: 38px;
  padding: 0 32px 0 12px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--white);
  color: var(--ink);
  font: inherit;
}

.add-button:hover {
  color: var(--red);
}

.add-button:disabled {
  color: rgba(20, 20, 20, 0.42);
  cursor: not-allowed;
}

.variant-field select:disabled {
  color: rgba(20, 20, 20, 0.45);
  cursor: not-allowed;
}

.story {
  display: grid;
  grid-template-columns: 0.25fr 1.05fr 0.7fr;
  gap: 4vw;
  align-items: center;
  background: var(--ink);
  color: var(--paper);
}

.story-index {
  align-self: start;
  font-size: 12px;
  letter-spacing: 0.15em;
}

.story-copy p:last-child {
  max-width: 680px;
  margin: 36px 0 0;
  color: rgba(244, 240, 232, 0.68);
  font-family: var(--serif);
  font-size: 17px;
  line-height: 1.9;
  word-break: keep-all;
}

.story-art {
  aspect-ratio: 1;
  display: grid;
  grid-template-rows: 1fr auto auto;
  align-items: end;
  padding: 26px;
  background: var(--red);
  color: var(--ink);
  transform: rotate(3deg);
}

.story-art > span {
  align-self: start;
  font-family: var(--serif);
  font-size: clamp(100px, 14vw, 230px);
  line-height: 0.8;
  color: var(--paper);
}

.story-line {
  margin-bottom: 16px;
  border-top: 1px solid;
}

.story-art small {
  letter-spacing: 0.14em;
}

.values {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  padding-top: 0;
  padding-bottom: 0;
  border-bottom: 1px solid var(--line);
}

.values article {
  min-height: 300px;
  padding: 50px 3vw;
  border-right: 1px solid var(--line);
}

.values article:last-child {
  border-right: 0;
}

.values article > span {
  font-size: 11px;
  letter-spacing: 0.14em;
}

.values h3 {
  margin: 76px 0 14px;
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 400;
}

.values p {
  max-width: 330px;
  margin: 0;
  color: rgba(20, 20, 20, 0.64);
  font-size: 13px;
  line-height: 1.8;
}

.guide {
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 8vw;
}

.guide-copy > p:last-child {
  max-width: 430px;
  margin-top: 28px;
  color: rgba(20, 20, 20, 0.64);
  font-size: 13px;
  line-height: 1.8;
}

.accordion-list {
  border-top: 1px solid var(--ink);
}

.accordion-list details {
  border-bottom: 1px solid var(--line);
}

.accordion-list summary {
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  cursor: pointer;
  list-style: none;
  font-family: var(--serif);
  font-size: 17px;
}

.accordion-list summary::-webkit-details-marker {
  display: none;
}

.accordion-list details[open] summary span {
  transform: rotate(45deg);
}

.accordion-list summary span {
  transition: transform 200ms ease;
}

.accordion-list details p {
  margin: -6px 0 26px;
  color: rgba(20, 20, 20, 0.62);
  font-size: 13px;
}

.newsletter {
  padding: 100px 4vw;
  background: var(--lilac);
  text-align: center;
}

.email-form {
  max-width: 580px;
  margin: 44px auto 0;
  display: flex;
  border-bottom: 1px solid var(--ink);
}

.email-form input {
  flex: 1;
  min-width: 0;
  height: 56px;
  border: 0;
  background: transparent;
  outline: none;
}

.email-form button {
  border: 0;
  background: transparent;
  cursor: pointer;
  font-size: 13px;
}

.form-message {
  min-height: 24px;
  margin: 15px 0 0;
  font-size: 12px;
}

footer {
  padding: 70px 4vw 26px;
  background: var(--ink);
  color: var(--paper);
}

.footer-brand {
  padding-bottom: 60px;
  border-bottom: 1px solid rgba(244, 240, 232, 0.2);
  font-size: clamp(54px, 11vw, 170px);
  font-weight: 500;
  letter-spacing: -0.08em;
  line-height: 0.8;
}

.footer-grid {
  padding: 48px 0 70px;
  display: grid;
  grid-template-columns: 0.7fr 0.6fr 1.2fr;
  gap: 50px;
}

.footer-label {
  margin-bottom: 18px !important;
  color: rgba(244, 240, 232, 0.48);
  font-size: 10px !important;
  letter-spacing: 0.14em;
}

.footer-grid p,
.footer-grid a {
  display: block;
  margin: 6px 0;
  font-size: 12px;
}

.business-info p:not(.footer-label) {
  color: rgba(244, 240, 232, 0.62);
}

.copyright {
  margin: 0;
  color: rgba(244, 240, 232, 0.42);
  font-size: 10px;
  letter-spacing: 0.1em;
}

.cart-backdrop {
  position: fixed;
  inset: 0;
  z-index: 69;
  background: rgba(20, 20, 20, 0.42);
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 70;
  width: min(92vw, 460px);
  height: 100dvh;
  padding: 26px;
  display: flex;
  flex-direction: column;
  background: var(--white);
  transform: translateX(101%);
  transition: transform 280ms ease;
}

.cart-open .cart-backdrop {
  opacity: 1;
  pointer-events: auto;
}

.cart-open .cart-drawer {
  transform: translateX(0);
}

.cart-header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--ink);
}

.cart-header .eyebrow {
  margin-bottom: 4px;
}

.cart-header h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: 34px;
  font-weight: 400;
}

.icon-button {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
}

.cart-progress {
  margin: 16px 0 0;
  padding: 10px 12px;
  background: var(--acid);
  font-size: 11px;
  text-align: center;
}

.cart-items {
  overflow-y: auto;
}

.cart-item {
  padding: 19px 0;
  display: grid;
  grid-template-columns: 62px 1fr auto;
  gap: 14px;
  align-items: center;
  border-bottom: 1px solid var(--line);
}

.cart-swatch {
  width: 62px;
  aspect-ratio: 1;
  background: var(--lilac);
}

.cart-swatch[data-id^="roasted-yam"] { background: #d78f66; }
.cart-swatch[data-id^="glutinous-nurungji"] { background: #d8bd69; }
.cart-swatch[data-id^="millet-rice"] { background: #aebd79; }
.cart-swatch[data-id^="red-rice-peanut-taffy"] { background: #bd875f; }
.cart-swatch[data-id^="purple-yam"] { background: #9a789f; }

.cart-item-name,
.cart-item-price {
  margin: 0;
  font-size: 12px;
}

.cart-item-price {
  margin-top: 4px;
  color: rgba(20, 20, 20, 0.58);
}

.quantity-control {
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
}

.quantity-control button {
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.quantity-control span {
  min-width: 22px;
  text-align: center;
  font-size: 11px;
}

.cart-empty {
  flex: 1;
  display: grid;
  place-content: center;
  justify-items: center;
  text-align: center;
}

.cart-empty > span {
  font-size: 52px;
  color: var(--lilac);
}

.cart-empty p {
  margin: 16px 0;
  font-family: var(--serif);
}

.cart-empty a {
  border-bottom: 1px solid;
  font-size: 12px;
}

.cart-summary {
  margin-top: auto;
  padding-top: 24px;
  border-top: 1px solid var(--ink);
}

.cart-summary > div {
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
  font-size: 12px;
}

.cart-summary .cart-total {
  margin: 18px 0;
  font-size: 15px;
}

.checkout-button {
  width: 100%;
}

.cart-caption {
  margin: 10px 0 0;
  color: rgba(20, 20, 20, 0.55);
  font-size: 10px;
  text-align: center;
}

.payment-dialog {
  width: min(90vw, 520px);
  padding: 46px;
  border: 0;
  background: var(--paper);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.28);
}

.payment-dialog::backdrop {
  background: rgba(20, 20, 20, 0.62);
}

.payment-dialog h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: 34px;
  font-weight: 400;
}

.payment-dialog > p:not(.eyebrow) {
  margin: 22px 0 30px;
  color: rgba(20, 20, 20, 0.68);
  font-size: 13px;
  line-height: 1.8;
}

.dialog-close {
  position: absolute;
  right: 18px;
  top: 18px;
}

.dialog-confirm {
  width: 100%;
}

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

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

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

  .story {
    grid-template-columns: 0.2fr 1fr;
  }

  .story-art {
    grid-column: 2;
    width: min(70%, 460px);
    margin-top: 30px;
  }
}

@media (max-width: 680px) {
  .site-header {
    height: 64px;
    grid-template-columns: 1fr 1fr;
  }

  .desktop-nav {
    display: none;
  }

  .hero {
    min-height: auto;
  }

  .hero-copy {
    min-height: 550px;
    padding: 70px 20px;
  }

  .hero h1 {
    font-size: 50px;
  }

  .hero-lead {
    font-size: 15px;
  }

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

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

  .hero-product {
    width: 64%;
  }

  .hero-wordmark {
    font-size: 72px;
  }

  .section {
    padding: 80px 20px;
  }

  .section-heading {
    grid-template-columns: 1fr;
    align-items: start;
    margin-bottom: 40px;
  }

  .section-heading > p {
    justify-self: start;
  }

  .product-grid {
    grid-template-columns: 1fr;
    gap: 52px;
  }

  .product-info {
    min-height: 112px;
    flex-direction: column;
    justify-content: flex-start;
  }

  .product-note {
    min-height: 34px;
  }

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

  .story-index {
    display: none;
  }

  .story-art {
    grid-column: 1;
    width: 88%;
    margin: 32px auto 0;
  }

  .values {
    grid-template-columns: 1fr;
    padding: 0;
  }

  .values article {
    min-height: 250px;
    padding: 42px 20px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .values h3 {
    margin-top: 52px;
  }

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

  .newsletter {
    padding: 80px 20px;
  }

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

  .payment-dialog {
    padding: 42px 24px 26px;
  }
}

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