/* ---- Rezervasyon wizard ---- */

.rez-wizard {
  max-width: 980px;
  margin-inline: auto;
}

.rez-header {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(260px, 0.45fr);
  gap: clamp(28px, 6vw, 88px);
  align-items: end;
  margin-bottom: clamp(40px, 6vw, 76px);
}

.rez-header .h-display { margin-block: 0; }

.rez-intro {
  font-size: clamp(16px, 1.2vw, 18px);
  line-height: 1.6;
  color: var(--ink-on-cream-muted);
  margin-top: clamp(16px, 1.8vw, 24px);
  max-width: 54ch;
}

.rez-intro a {
  color: var(--terracotta);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---- Progress ---- */

.rez-progress {
  margin-bottom: clamp(30px, 5vw, 54px);
}

.rez-progress__track {
  width: 100%;
  height: 2px;
  background: var(--rule-cream);
  position: relative;
  margin-bottom: 16px;
}

.rez-progress__fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  background: var(--terracotta);
  transition: width 500ms var(--ease-out);
}

.rez-progress__meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.rez-progress__label,
.rez-progress__counter {
  font-size: 11px;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--terracotta);
}

/* ---- Steps ---- */

.rez-step {
  display: none;
  min-height: 260px;
}

.rez-step--active {
  display: block;
  animation: rez-step-in 380ms var(--ease-out) both;
}

@keyframes rez-step-in {
  from {
    opacity: 0;
    transform: translateX(calc(24px * var(--rez-dir, 1)));
    filter: blur(3px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
    filter: blur(0);
  }
}

.rez-step__q {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(30px, 4vw, 50px);
  line-height: 1.08;
  letter-spacing: -0.01em;
  text-align: left;
  color: var(--ink-on-cream);
  margin-bottom: clamp(24px, 3.5vw, 44px);
  text-wrap: balance;
}

/* ---- Cards ---- */

.rez-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.rez-cards--single {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 clamp(16px, 3vw, 34px);
  border-top: 1px solid var(--rule-cream);
}

.rez-cards--3col {
  grid-template-columns: repeat(3, 1fr);
}

.rez-card {
  background: color-mix(in oklch, var(--cream-deep) 52%, transparent);
  border: 1px solid var(--rule-cream);
  padding: clamp(20px, 2.5vw, 30px) clamp(18px, 2.5vw, 28px);
  text-align: left;
  cursor: pointer;
  position: relative;
  transition:
    border-color 240ms var(--ease-out),
    background 240ms var(--ease-out),
    transform 240ms var(--ease-out);
}

.rez-card:hover {
  border-color: var(--terracotta);
  background: color-mix(in oklch, var(--cream-deep) 72%, var(--terracotta) 6%);
  transform: translateY(-2px);
}

.rez-card:focus-visible {
  outline: 2px solid var(--brass);
  outline-offset: 4px;
}

/* Selected: terracotta border + warm tint + scale confirmation */
.rez-card.is-selected {
  border-color: var(--terracotta);
  background: color-mix(in oklch, var(--terracotta) 12%, var(--cream-deep));
  transform: translateY(-1px);
}

.rez-card.is-selected .rez-card__label {
  color: var(--terracotta);
}

.rez-card.is-selected .rez-card__num {
  color: var(--terracotta);
}

.rez-card.is-selected::after {
  content: "";
  position: absolute;
  top: 14px;
  right: 16px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--terracotta);
  animation: rez-dot-in 200ms var(--ease-out) both;
}

@keyframes rez-dot-in {
  from { transform: scale(0); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

.rez-card.is-pressing {
  transform: scale(0.97);
  transition-duration: 60ms;
}

/* ---- Category cards (step 1 + treatment cards step 2) ---- */

.rez-card--cat {
  min-height: 136px;
  display: grid;
  align-content: end;
  padding: clamp(24px, 3vw, 36px);
}

.rez-card__num {
  display: block;
  font-family: var(--body);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--brass);
  margin-bottom: 12px;
  transition: color 240ms var(--ease-out);
}

.rez-card--cat .rez-card__label {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(18px, 2vw, 26px);
  letter-spacing: -0.005em;
  text-transform: none;
  line-height: 1.15;
  transition: color 240ms var(--ease-out);
}

.rez-card--treatment {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  align-items: baseline;
  min-height: 0;
  padding: 17px 0;
  border: 0;
  border-bottom: 1px solid var(--rule-cream);
  background: transparent;
}

.rez-card--treatment:hover,
.rez-card--treatment.is-selected {
  background: transparent;
  transform: translateX(6px);
}

.rez-card--treatment.is-selected::after {
  top: 16px;
  right: 0;
}

.rez-card--treatment .rez-card__num {
  margin-bottom: 0;
}

.rez-card--treatment .rez-card__label {
  font-family: var(--display);
  font-size: clamp(18px, 1.8vw, 24px);
  font-weight: 300;
  line-height: 1.16;
  letter-spacing: -0.005em;
  text-transform: none;
}

/* Default card label (steps 3 & 4) */
.rez-card__label {
  display: block;
  font-size: clamp(11px, 1.1vw, 14px);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--ink-on-cream);
  line-height: 1.4;
  transition: color 240ms var(--ease-out);
}

.rez-card__sub {
  display: block;
  margin-top: 10px;
  font-size: 12px;
  letter-spacing: 0;
  color: var(--ink-on-cream-muted);
  font-style: italic;
  line-height: 1.4;
}

/* ---- Step 3: Date and hour ---- */

.rez-date-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(16px, 3vw, 34px);
}

.rez-date-wrap {
  display: none;
  margin-top: 0;
  border-top: 1px solid var(--rule-cream);
  padding-top: 18px;
}

.rez-date-wrap.is-visible {
  display: block;
}

.rez-date-label {
  display: block;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-on-cream-muted);
  margin-bottom: 10px;
}

.rez-date-input {
  background: color-mix(in oklch, var(--cream-deep) 46%, transparent);
  border: 1px solid var(--rule-cream);
  color: var(--ink-on-cream);
  font-size: clamp(18px, 2.2vw, 24px);
  padding: 16px 18px;
  width: 100%;
  font-family: var(--body);
  transition: border-color var(--t-base) var(--ease-out), background var(--t-base) var(--ease-out);
  color-scheme: light;
}

.rez-date-input:focus {
  outline: none;
  border-color: var(--terracotta);
  background: var(--cream-deep);
}

select.rez-date-input {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--ink-on-cream-muted) 50%),
    linear-gradient(135deg, var(--ink-on-cream-muted) 50%, transparent 50%);
  background-position:
    calc(100% - 22px) 50%,
    calc(100% - 16px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 46px;
}

.rez-field-note {
  margin-top: 18px;
  color: var(--ink-on-cream-muted);
  font-size: 14px;
  line-height: 1.5;
}

/* ---- Step 5: Notes ---- */

.rez-field {
  display: grid;
  gap: 10px;
}

.rez-field label {
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-on-cream-muted);
}

.rez-textarea {
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--rule-cream);
  color: var(--ink-on-cream);
  font-size: 17px;
  line-height: 1.6;
  padding: 12px 0;
  width: 100%;
  min-height: 120px;
  resize: vertical;
  font-family: var(--body);
  transition: border-color var(--t-base) var(--ease-out);
}

.rez-textarea:focus {
  outline: none;
  border-bottom-color: var(--terracotta);
}

.rez-textarea::placeholder {
  color: var(--ink-on-cream-muted);
  opacity: 0.7;
}

.rez-skip {
  display: block;
  text-align: center;
  margin-top: 28px;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brass);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: color-mix(in oklch, var(--brass) 50%, transparent);
  transition: color var(--t-base) var(--ease-out), text-decoration-color var(--t-base) var(--ease-out);
}

.rez-skip:hover {
  color: var(--terracotta);
  text-decoration-color: var(--terracotta);
}

/* ---- Step 6: Contact ---- */

.rez-fields {
  display: grid;
  gap: clamp(18px, 2.5vw, 28px);
}

/* ---- Error messages ---- */

.rez-error {
  display: none;
  font-size: 12px;
  color: oklch(48% 0.16 28);
  letter-spacing: 0.04em;
  margin-top: 6px;
}

.rez-error--visible {
  display: block;
}

/* ---- Navigation ---- */

.rez-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: clamp(32px, 4.5vw, 56px);
  padding-top: clamp(24px, 3.5vw, 40px);
  border-top: 1px solid var(--rule-cream);
}

.rez-nav__back {
  background: none;
  border: none;
  padding: 6px 0;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-on-cream-muted);
  cursor: pointer;
  visibility: hidden;
  transition: color var(--t-base) var(--ease-out);
  font-family: var(--body);
}

.rez-nav__back--visible {
  visibility: visible;
}

.rez-nav__back:hover {
  color: var(--terracotta);
}

.rez-nav__back:focus-visible {
  outline: 2px solid var(--brass);
  outline-offset: 4px;
}

.rez-reassure {
  text-align: center;
  margin-top: clamp(20px, 2.5vw, 32px);
  margin-bottom: clamp(32px, 5vw, 56px);
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--ink-on-cream-muted);
}

/* ---- Cream surface overrides for shared components ---- */

/* Field inputs inherit --ink-on-cream from surface but border needs the cream rule */
.surface-cream .field input,
.surface-cream .field textarea {
  border-bottom-color: var(--rule-cream);
}

.surface-cream .field input:focus,
.surface-cream .field textarea:focus {
  border-bottom-color: var(--terracotta);
}

/* Consent text color and checkbox border */
.surface-cream .consent {
  color: var(--ink-on-cream-muted);
}

.surface-cream .consent input[type="checkbox"] {
  border-color: oklch(20% 0.018 40 / 0.28);
}

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

@media (max-width: 520px) {
  .rez-header {
    grid-template-columns: 1fr;
    gap: 18px;
    margin-bottom: 34px;
  }

  .rez-header .eyebrow {
    margin-bottom: 12px;
  }

  .rez-header .h-display {
    font-size: clamp(42px, 12vw, 58px);
  }

  .rez-intro {
    font-size: 15px;
  }

  .rez-progress {
    margin-bottom: 28px;
  }

  .rez-progress__label,
  .rez-progress__counter {
    font-size: 10px;
    letter-spacing: 0.16em;
  }

  .rez-cards,
  .rez-cards--single,
  .rez-date-grid {
    grid-template-columns: 1fr;
  }

  .rez-cards--3col {
    gap: 8px;
  }

  .rez-card {
    padding: 18px 16px;
  }

  .rez-card--cat {
    min-height: 112px;
    padding: 20px 18px;
  }

  .rez-card--cat .rez-card__label {
    font-size: clamp(16px, 5vw, 20px);
  }

  .rez-card__label {
    font-size: 10px;
    letter-spacing: 0.08em;
  }

  .rez-step__q {
    font-size: clamp(28px, 8vw, 38px);
    margin-bottom: 22px;
  }

  .rez-card--treatment {
    grid-template-columns: 36px 1fr;
    padding: 15px 0;
  }

  .rez-card--treatment .rez-card__label {
    font-size: clamp(18px, 5.4vw, 22px);
  }

  .rez-card--treatment:hover,
  .rez-card--treatment.is-selected {
    transform: none;
  }

  .rez-nav {
    margin-top: 28px;
    padding-top: 22px;
  }
}

@media (max-width: 380px) {
  .rez-cards {
    gap: 8px;
  }
}
