:root {
  --coffee: #9d7047;
  --coffee-light: #d7ad76;
  --coffee-deep: #2b1713;
}

.coffee-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at 16% 8%, rgba(157, 112, 71, .15), transparent 28%),
    radial-gradient(circle at 88% 28%, rgba(113, 84, 167, .17), transparent 30%),
    #070611;
}

.coffee-steam {
  position: fixed;
  z-index: -1;
  width: 360px;
  height: 720px;
  border-radius: 50%;
  border-left: 1px solid rgba(215, 173, 118, .12);
  filter: blur(2px);
  opacity: .45;
  pointer-events: none;
}

.steam-one {
  top: 5%;
  right: 4%;
  transform: rotate(22deg);
  animation: steamFloat 11s ease-in-out infinite;
}

.steam-two {
  bottom: -18%;
  left: 2%;
  transform: rotate(-28deg) scale(.8);
  animation: steamFloat 14s -4s ease-in-out infinite reverse;
}

@keyframes steamFloat {
  0%, 100% { translate: 0 0; opacity: .2; }
  50% { translate: 18px -32px; opacity: .55; }
}

.ritual-header {
  position: relative;
  z-index: 10;
  width: min(1320px, calc(100% - 40px));
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 auto;
  border-bottom: 1px solid rgba(255, 255, 255, .06);
}

.ritual-back {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #998fa3;
  font-size: 12px;
  transition: color .2s ease;
}

.ritual-back:hover {
  color: var(--gold-soft);
}

.coffee-main {
  width: min(1320px, calc(100% - 40px));
  margin: 0 auto;
  padding: 64px 0 100px;
}

.coffee-intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  align-items: center;
  gap: 50px;
  min-height: 310px;
  padding: 20px 34px 68px;
}

.coffee-intro h1 {
  max-width: 820px;
  font-family: "Cinzel", serif;
  font-size: clamp(42px, 5.2vw, 72px);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -.03em;
}

.coffee-intro h1 em {
  display: block;
  color: var(--coffee-light);
  font-style: italic;
  font-weight: 500;
}

.coffee-intro > div:first-child > p:last-child {
  max-width: 680px;
  margin-top: 24px;
  color: var(--muted);
  line-height: 1.8;
}

.cup-orbit {
  position: relative;
  width: 270px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  margin-left: auto;
}

.cup-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(215, 173, 118, .22);
}

.ring-one {
  inset: 0;
  animation: coffeeSpin 30s linear infinite;
}

.ring-one::before,
.ring-two::before {
  content: "";
  position: absolute;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--coffee-light);
  box-shadow: 0 0 16px rgba(215, 173, 118, .7);
}

.ring-one::before {
  top: 11%;
  left: 17%;
}

.ring-two {
  inset: 20%;
  border-style: dashed;
  animation: coffeeSpin 20s linear reverse infinite;
}

.ring-two::before {
  right: -4px;
  top: 50%;
}

@keyframes coffeeSpin {
  to { transform: rotate(360deg); }
}

.cup-icon {
  display: grid;
  place-items: center;
  width: 118px;
  height: 118px;
  border: 1px solid rgba(215, 173, 118, .2);
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(157, 112, 71, .18), transparent 67%);
  color: var(--coffee-light);
  font-size: 54px;
  box-shadow: 0 0 54px rgba(157, 112, 71, .15);
}

.orbit-star {
  position: absolute;
  color: var(--gold-soft);
}

.star-a {
  top: 5%;
  right: 23%;
}

.star-b {
  left: 6%;
  bottom: 24%;
  opacity: .55;
}

.coffee-shell {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  min-height: 700px;
  overflow: hidden;
  border: 1px solid rgba(240, 215, 155, .13);
  border-radius: 26px;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, .018), transparent 48%),
    rgba(11, 8, 20, .82);
  box-shadow: 0 34px 100px rgba(0, 0, 0, .3);
}

.coffee-sidebar {
  padding: 40px 28px;
  border-right: 1px solid rgba(255, 255, 255, .06);
  background: rgba(255, 255, 255, .012);
}

.sidebar-label {
  color: #716878;
  font-family: "Cinzel", serif;
  font-size: 9px;
  letter-spacing: .22em;
}

.coffee-progress {
  margin-top: 24px;
  list-style: none;
}

.coffee-progress li {
  position: relative;
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 12px;
  min-height: 88px;
  color: #5f5868;
}

.coffee-progress li:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 34px;
  bottom: 4px;
  left: 15px;
  width: 1px;
  background: rgba(255, 255, 255, .08);
}

.coffee-progress li > span {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 31px;
  height: 31px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 50%;
  background: #0c0915;
  font-family: "Cinzel", serif;
  font-size: 9px;
}

.coffee-progress li strong,
.coffee-progress li small {
  display: block;
}

.coffee-progress li strong {
  margin-top: 4px;
  color: #7f7687;
  font-family: "Cinzel", serif;
  font-size: 12px;
}

.coffee-progress li small {
  margin-top: 6px;
  color: #504a57;
  font-size: 10px;
}

.coffee-progress li.active > span,
.coffee-progress li.complete > span {
  border-color: rgba(215, 173, 118, .5);
  color: var(--coffee-light);
  box-shadow: 0 0 22px rgba(157, 112, 71, .15);
}

.coffee-progress li.active strong,
.coffee-progress li.complete strong {
  color: var(--text);
}

.coffee-progress li.active small {
  color: #918799;
}

.photo-guide {
  margin-top: 34px;
  padding: 22px 0;
  border-top: 1px solid rgba(255, 255, 255, .06);
  border-bottom: 1px solid rgba(255, 255, 255, .06);
}

.photo-guide ul {
  display: grid;
  gap: 10px;
  margin-top: 17px;
  padding-left: 17px;
  color: #81798a;
  font-size: 11px;
  line-height: 1.5;
}

.photo-guide li::marker {
  color: var(--coffee-light);
}

.ritual-note {
  display: flex;
  gap: 10px;
  margin-top: 26px;
  color: #6c6474;
  font-size: 10px;
  line-height: 1.55;
}

.ritual-note span {
  flex: 0 0 auto;
  color: var(--gold);
}

.coffee-content {
  min-width: 0;
  padding: 52px clamp(26px, 5vw, 70px) 60px;
}

.coffee-step {
  animation: coffeeStepIn .45s ease;
}

@keyframes coffeeStepIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

.coffee-step[hidden] {
  display: none;
}

.step-heading {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 16px;
  margin-bottom: 36px;
}

.step-heading > span {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(215, 173, 118, .26);
  border-radius: 50%;
  color: var(--coffee-light);
  font-family: "Cinzel", serif;
  font-size: 10px;
}

.step-heading .eyebrow {
  margin-bottom: 10px;
}

.step-heading h2,
.success-step h2 {
  font-family: "Cinzel", serif;
  font-size: clamp(28px, 3.2vw, 44px);
  font-weight: 600;
  line-height: 1.18;
}

.step-description {
  max-width: 680px;
  margin-top: 12px;
  color: var(--muted);
  line-height: 1.7;
}

.intent-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

.intent-option {
  min-height: 142px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 20px;
  border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 17px;
  background: rgba(255, 255, 255, .018);
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: transform .25s ease, border-color .25s ease, background .25s ease;
}

.intent-option:hover {
  transform: translateY(-4px);
  border-color: rgba(215, 173, 118, .34);
}

.intent-option.active {
  border-color: rgba(215, 173, 118, .55);
  background:
    radial-gradient(circle at 22% 12%, rgba(157, 112, 71, .18), transparent 48%),
    rgba(255, 255, 255, .025);
  box-shadow: inset 0 0 35px rgba(157, 112, 71, .07);
}

.intent-option > span {
  margin-bottom: 22px;
  color: var(--coffee-light);
  font-size: 24px;
}

.intent-option strong {
  font-family: "Cinzel", serif;
  font-size: 13px;
}

.intent-option small {
  margin-top: 8px;
  color: #776e7f;
  font-size: 10px;
  line-height: 1.4;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  margin-top: 26px;
}

.field {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.field > span {
  color: #c6bdcb;
  font-size: 12px;
}

.field > span small {
  color: #6f6776;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 13px;
  outline: none;
  background: rgba(255, 255, 255, .025);
  color: var(--text);
  font: inherit;
  transition: border-color .2s ease, background .2s ease;
}

.field input,
.field select {
  height: 52px;
  padding: 0 15px;
}

.field textarea {
  min-height: 122px;
  resize: vertical;
  padding: 15px 16px 32px;
  line-height: 1.6;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: rgba(215, 173, 118, .5);
  background: rgba(255, 255, 255, .035);
}

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

.field select option {
  background: #100c1c;
  color: var(--text);
}

.question-field {
  margin-top: 18px;
}

.character-count {
  position: absolute;
  right: 14px;
  bottom: 10px;
  color: #5f5866;
  font-size: 10px;
}

.character-count b {
  font-weight: 500;
}

.step-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 34px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, .06);
}

.single-action {
  justify-content: flex-end;
}

.primary-button:disabled,
.secondary-button:disabled {
  cursor: not-allowed;
  opacity: .34;
  transform: none;
  box-shadow: none;
}

.secondary-button {
  min-height: 50px;
  padding: 0 22px;
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 999px;
  background: transparent;
  color: #a69cab;
  cursor: pointer;
  transition: border-color .2s ease, color .2s ease;
}

.secondary-button:hover {
  border-color: rgba(215, 173, 118, .35);
  color: var(--coffee-light);
}

.upload-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.upload-card {
  position: relative;
  min-height: 350px;
  overflow: hidden;
  border: 1px dashed rgba(215, 173, 118, .28);
  border-radius: 20px;
  background:
    radial-gradient(circle at 50% 18%, rgba(157, 112, 71, .1), transparent 40%),
    rgba(255, 255, 255, .016);
  cursor: pointer;
  transition: transform .25s ease, border-color .25s ease, background .25s ease;
}

.upload-card:hover {
  transform: translateY(-5px);
  border-color: rgba(215, 173, 118, .55);
  background:
    radial-gradient(circle at 50% 18%, rgba(157, 112, 71, .16), transparent 42%),
    rgba(255, 255, 255, .022);
}

.upload-card input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.upload-empty {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 28px;
  text-align: center;
}

.upload-number {
  position: absolute;
  top: 19px;
  left: 20px;
  color: #655c69;
  font-family: "Cinzel", serif;
  font-size: 9px;
}

.upload-icon {
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  margin-bottom: 24px;
  border: 1px solid rgba(215, 173, 118, .2);
  border-radius: 50%;
  color: var(--coffee-light);
  font-size: 30px;
}

.upload-empty strong {
  font-family: "Cinzel", serif;
  font-size: 16px;
}

.upload-empty small {
  max-width: 180px;
  margin-top: 9px;
  color: #736b79;
  font-size: 10px;
  line-height: 1.5;
}

.upload-empty b {
  margin-top: 22px;
  color: var(--coffee-light);
  font-size: 11px;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 5px;
}

.upload-preview {
  position: absolute;
  inset: 0;
  display: none;
}

.upload-card.has-image .upload-empty {
  display: none;
}

.upload-card.has-image .upload-preview {
  display: block;
}

.upload-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.preview-overlay {
  position: absolute;
  inset: auto 0 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 58px 16px 15px;
  background: linear-gradient(transparent, rgba(4, 3, 8, .92));
}

.preview-overlay strong {
  font-family: "Cinzel", serif;
  font-size: 11px;
}

.preview-overlay button {
  padding: 8px 11px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 999px;
  background: rgba(7, 6, 17, .72);
  color: #d8cedd;
  font-size: 9px;
  cursor: pointer;
}

.upload-status {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 20px;
  margin-top: 24px;
}

.upload-status > div:first-child {
  display: flex;
  align-items: baseline;
  gap: 5px;
  min-width: 130px;
}

.upload-status span {
  color: var(--coffee-light);
  font-family: "Cinzel", serif;
  font-size: 23px;
}

.upload-status small {
  color: #716978;
}

.status-bar {
  height: 4px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, .06);
}

.status-bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--coffee), var(--gold-soft));
  transition: width .35s ease;
}

.upload-error {
  min-height: 20px;
  margin-top: 13px;
  color: #cf8d8d;
  font-size: 11px;
}

.review-layout {
  display: grid;
  grid-template-columns: .78fr 1.22fr;
  gap: 16px;
}

.review-card {
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 18px;
  background: rgba(255, 255, 255, .018);
}

.review-card-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .06);
}

.review-card-heading span {
  color: var(--coffee-light);
  font-size: 20px;
}

.review-card-heading h3 {
  font-family: "Cinzel", serif;
  font-size: 16px;
}

.review-info dl {
  margin-top: 4px;
}

.review-info dl > div {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(255, 255, 255, .045);
}

.review-info dt {
  color: #6e6675;
  font-size: 10px;
}

.review-info dd {
  color: #d5ccd9;
  font-size: 12px;
  text-align: right;
}

.review-question {
  margin-top: 20px;
  padding: 16px;
  border-radius: 13px;
  background: rgba(157, 112, 71, .07);
}

.review-question span {
  color: var(--coffee-light);
  font-family: "Cinzel", serif;
  font-size: 9px;
  letter-spacing: .16em;
}

.review-question p {
  margin-top: 9px;
  color: #b8afbe;
  font-size: 11px;
  line-height: 1.65;
}

.review-photo-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 18px;
}

.review-photo-grid figure {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 13px;
  background: #0b0812;
}

.review-photo-grid img {
  width: 100%;
  aspect-ratio: .78;
  display: block;
  object-fit: cover;
}

.review-photo-grid figcaption {
  padding: 10px 8px;
  color: #8e8594;
  font-size: 9px;
  text-align: center;
}

.consent-line {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 22px;
  padding: 17px;
  border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 14px;
  color: #8d8493;
  font-size: 11px;
  line-height: 1.55;
  cursor: pointer;
}

.consent-line input {
  margin-top: 2px;
  accent-color: var(--coffee);
}

.success-step {
  max-width: 720px;
  margin: 0 auto;
  padding: 50px 0 20px;
  text-align: center;
}

.success-symbol {
  position: relative;
  display: grid;
  place-items: center;
  width: 150px;
  height: 150px;
  margin: 0 auto 34px;
  border: 1px solid rgba(215, 173, 118, .32);
  border-radius: 50%;
  color: var(--coffee-light);
  font-size: 70px;
  box-shadow:
    0 0 80px rgba(157, 112, 71, .17),
    inset 0 0 50px rgba(157, 112, 71, .08);
}

.success-symbol::before,
.success-symbol::after {
  content: "";
  position: absolute;
  border: 1px dashed rgba(240, 215, 155, .12);
  border-radius: 50%;
  animation: coffeeSpin 26s linear infinite;
}

.success-symbol::before {
  inset: -22px;
}

.success-symbol::after {
  inset: -42px;
  animation-direction: reverse;
  animation-duration: 36s;
}

.success-step > p:not(.eyebrow) {
  max-width: 610px;
  margin: 20px auto 0;
  color: var(--muted);
  line-height: 1.75;
}

.success-code {
  max-width: 360px;
  margin: 30px auto 0;
  padding: 17px 22px;
  border: 1px solid rgba(215, 173, 118, .15);
  border-radius: 15px;
  background: rgba(157, 112, 71, .06);
}

.success-code small,
.success-code strong {
  display: block;
}

.success-code small {
  color: #726a77;
  font-size: 8px;
  letter-spacing: .18em;
}

.success-code strong {
  margin-top: 7px;
  color: var(--coffee-light);
  font-family: "Cinzel", serif;
  letter-spacing: .12em;
}

.result-actions {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-top: 36px;
}

@media (max-width: 1080px) {
  .intent-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .coffee-shell {
    grid-template-columns: 220px minmax(0, 1fr);
  }

  .coffee-sidebar {
    padding: 34px 22px;
  }

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

  .upload-card:last-child {
    grid-column: 1 / -1;
    min-height: 300px;
  }

  .review-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 780px) {
  .ritual-header,
  .coffee-main {
    width: min(100% - 28px, 1320px);
  }

  .ritual-header {
    height: 74px;
  }

  .ritual-back {
    font-size: 0;
  }

  .ritual-back span {
    font-size: 18px;
  }

  .coffee-main {
    padding-top: 36px;
  }

  .coffee-intro {
    grid-template-columns: 1fr;
    min-height: auto;
    padding: 20px 12px 48px;
    text-align: center;
  }

  .coffee-intro h1 {
    font-size: clamp(40px, 12vw, 58px);
  }

  .coffee-intro > div:first-child > p:last-child {
    margin-left: auto;
    margin-right: auto;
  }

  .cup-orbit {
    width: 220px;
    margin: 4px auto 0;
  }

  .coffee-shell {
    grid-template-columns: 1fr;
  }

  .coffee-sidebar {
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
  }

  .coffee-progress {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
  }

  .coffee-progress li {
    min-height: auto;
    grid-template-columns: 34px 1fr;
  }

  .coffee-progress li:not(:last-child)::after {
    display: none;
  }

  .photo-guide {
    display: none;
  }

  .ritual-note {
    margin-top: 14px;
  }

  .coffee-content {
    padding: 38px 22px 46px;
  }

  .intent-grid {
    grid-template-columns: repeat(2, 1fr);
  }

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

@media (max-width: 560px) {
  .coffee-intro {
    text-align: left;
  }

  .coffee-intro h1 em {
    display: inline;
  }

  .cup-orbit {
    display: none;
  }

  .coffee-sidebar {
    padding: 22px 16px;
  }

  .coffee-progress li {
    display: flex;
    align-items: center;
    gap: 8px;
  }

  .coffee-progress li small {
    display: none;
  }

  .coffee-progress li strong {
    margin: 0;
    font-size: 10px;
  }

  .coffee-progress li > span {
    flex: 0 0 29px;
    width: 29px;
    height: 29px;
  }

  .ritual-note {
    display: none;
  }

  .coffee-content {
    padding: 32px 15px 38px;
  }

  .step-heading {
    grid-template-columns: 1fr;
  }

  .step-heading > span {
    width: 38px;
    height: 38px;
  }

  .intent-grid {
    grid-template-columns: 1fr 1fr;
    gap: 9px;
  }

  .intent-option {
    min-height: 126px;
    padding: 16px;
  }

  .intent-option > span {
    margin-bottom: 17px;
  }

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

  .upload-card,
  .upload-card:last-child {
    grid-column: auto;
    min-height: 330px;
  }

  .upload-status {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .step-actions,
  .result-actions {
    flex-direction: column-reverse;
  }

  .step-actions > *,
  .result-actions > * {
    width: 100%;
  }

  .review-photo-grid {
    grid-template-columns: 1fr;
  }

  .review-photo-grid img {
    aspect-ratio: 1.2;
  }

  .review-info dl > div {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  .review-info dd {
    text-align: left;
  }

  .success-step {
    padding-top: 30px;
  }

  .success-symbol {
    width: 118px;
    height: 118px;
    font-size: 54px;
  }
}
