/* ─── TOKENS (duplicated in case style.css not loaded) ── */
:root {
  --sage:       #708871;
  --sage-dark:  #4a5c4b;
  --sage-light: #a8bba9;
  --forest:     #283128;
  --cream:      #f4f6f4;
  --warm:       #ede8e0;
  --stone:      #e4e0d8;
  --charcoal:   #1c221c;
  --muted:      #6b7a6b;
  --white:      #ffffff;

  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans:  'DM Sans', sans-serif;

  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 20px;
  --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { font-size: 16px; }
body {
  font-family: var(--sans);
  background: var(--cream);
  color: var(--charcoal);
  min-height: 100vh;
}
a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }
button { cursor: pointer; font-family: var(--sans); }

/* ─── AUTH LAYOUT ────────────────────────────────────── */
.auth-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 100vh;
}

/* ─── LEFT PANEL ─────────────────────────────────────── */
.auth-panel {
  background: var(--forest);
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 2.5rem 3rem 3rem;
  overflow: hidden;
}

/* Decorative blurred circle */
.auth-panel__deco {
  position: absolute;
  bottom: -80px;
  right: -80px;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(112,136,113,0.25) 0%, transparent 70%);
  pointer-events: none;
}

/* Second decorative element */
.auth-panel::before {
  content: '';
  position: absolute;
  top: -60px;
  left: -60px;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  border: 1px solid rgba(112,136,113,0.15);
  pointer-events: none;
}

.auth-panel__logo img {
  height: 40px;
  width: auto;
  opacity: 0.9;
  position: relative;
  z-index: 1;
}

.auth-panel__content {
  position: relative;
  z-index: 1;
  max-width: 360px;
}

.auth-panel__eyebrow {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--sage-light);
  margin-bottom: 1rem;
}

.auth-panel__title {
  font-family: var(--serif);
  font-size: clamp(2rem, 3.5vw, 3rem);
  font-weight: 300;
  line-height: 1.15;
  color: var(--white);
  margin-bottom: 1.2rem;
}

.auth-panel__title em {
  font-style: italic;
  color: var(--sage-light);
}

.auth-panel__sub {
  font-size: 0.9rem;
  line-height: 1.7;
  color: rgba(255,255,255,0.55);
}

/* ─── RIGHT PANEL ────────────────────────────────────── */
.auth-form-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem;
  background: var(--cream);
}

.auth-form-wrap {
  width: 100%;
  max-width: 420px;
}

.auth-form-header {
  margin-bottom: 2rem;
}

.auth-form-title {
  font-family: var(--serif);
  font-size: 2.2rem;
  font-weight: 300;
  color: var(--charcoal);
  margin-bottom: 0.4rem;
}

.auth-form-sub {
  font-size: 0.85rem;
  color: var(--muted);
}

/* ─── ALERT ──────────────────────────────────────────── */
.auth-alert {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.8rem 1rem;
  border-radius: var(--r-sm);
  font-size: 0.82rem;
  margin-bottom: 1.5rem;
}

.auth-alert svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.auth-alert--error {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

.auth-alert--success {
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid #bbf7d0;
}

/* ─── FORM FIELDS ────────────────────────────────────── */
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 1.3rem;
  margin-bottom: 1.5rem;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-field label {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--charcoal);
  letter-spacing: 0.03em;
}

.form-field__input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.form-field__icon {
  position: absolute;
  left: 0.9rem;
  width: 16px;
  height: 16px;
  stroke: var(--muted);
  fill: none;
  stroke-width: 1.6;
  pointer-events: none;
  flex-shrink: 0;
}

.form-field__input-wrap input {
  width: 100%;
  padding: 0.8rem 1rem 0.8rem 2.6rem;
  border: 1.5px solid #cdd4cd;
  border-radius: var(--r-md);
  font-family: var(--sans);
  font-size: 0.88rem;
  color: var(--charcoal);
  background: var(--white);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-field__input-wrap input::placeholder { color: #b0bdb0; }

.form-field__input-wrap input:focus {
  border-color: var(--sage);
  box-shadow: 0 0 0 3px rgba(112,136,113,0.12);
}

/* Password eye toggle */
.form-field__eye {
  position: absolute;
  right: 0.9rem;
  background: none;
  border: none;
  padding: 0;
  display: flex;
  align-items: center;
  color: var(--muted);
  transition: color 0.2s;
}

.form-field__eye:hover { color: var(--sage-dark); }

.form-field__eye svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
}

/* ─── SUBMIT BUTTON ──────────────────────────────────── */
.auth-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.9rem 1.5rem;
  background: var(--forest);
  color: var(--white);
  border: none;
  border-radius: var(--r-md);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  margin-top: 0.4rem;
  transition: background 0.2s, transform 0.15s;
}

.auth-submit svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  transition: transform 0.2s var(--ease);
}

.auth-submit:hover {
  background: var(--sage-dark);
  transform: translateY(-1px);
}

.auth-submit:hover svg { transform: translateX(3px); }

/* ─── LINKS ──────────────────────────────────────────── */
.auth-switch {
  text-align: center;
  font-size: 0.83rem;
  color: var(--muted);
  margin-bottom: 1.2rem;
}

.auth-switch a {
  color: var(--sage-dark);
  font-weight: 500;
  border-bottom: 1px solid var(--sage-dark);
  transition: color 0.2s;
}

.auth-switch a:hover { color: var(--sage); border-color: var(--sage); }

.auth-back {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  color: var(--muted);
  transition: color 0.2s;
}

.auth-back svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.auth-back:hover { color: var(--charcoal); }

/* ─── DIVIDER ────────────────────────────────────────── */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin: 0.5rem 0 1.2rem;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(40,49,40,0.1);
}

.auth-divider span {
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.08em;
}

/* ─── SIGNUP EXTRAS ──────────────────────────────────── */
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-field--full { grid-column: 1 / -1; }

/* Textarea field */
.form-field__textarea-wrap {
  position: relative;
  display: flex;
}

.form-field__icon--top {
  top: 0.85rem;
  align-self: flex-start;
}

.form-field__textarea-wrap textarea {
  width: 100%;
  padding: 0.8rem 1rem 0.8rem 2.6rem;
  border: 1.5px solid #cdd4cd;
  border-radius: var(--r-md);
  font-family: var(--sans);
  font-size: 0.88rem;
  color: var(--charcoal);
  background: var(--white);
  outline: none;
  resize: vertical;
  min-height: 80px;
  line-height: 1.6;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-field__textarea-wrap textarea::placeholder { color: #b0bdb0; }

.form-field__textarea-wrap textarea:focus {
  border-color: var(--sage);
  box-shadow: 0 0 0 3px rgba(112,136,113,0.12);
}

/* Date input */
input[type="date"] {
  color-scheme: light;
}

/* Success state */
.auth-success-state {
  text-align: center;
  padding: 2rem 0;
}

.auth-success-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #dcfce7;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
}

.auth-success-icon svg {
  width: 28px;
  height: 28px;
  stroke: #16a34a;
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ─── RESPONSIVE ─────────────────────────────────────── */
@media (max-width: 768px) {
  .auth-layout {
    grid-template-columns: 1fr;
  }

  .auth-panel {
    min-height: 200px;
    padding: 2rem;
  }

  .auth-panel__content {
    display: none;
  }

  .auth-form-panel {
    padding: 2.5rem 1.5rem 3rem;
    align-items: flex-start;
  }

  .auth-form-wrap { max-width: 100%; }
}