/* ── BOOK.CSS: Online booking form styles ──────────────────────────────────────
   Design language: dark nav, warm off-white body, gold accents.
   Matches theme.css tokens but scoped to the /book page only.
   ──────────────────────────────────────────────────────────────────────────── */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=DM+Sans:ital,wght@0,400;0,500;1,400&display=swap');

:root {
  --bg-dark:    #0a0c10;
  --bg-body:    #f5f4f1;
  --bg-card:    #ffffff;
  --bg-card2:   #faf9f7;
  --fg:         #1a1a1a;
  --fg-mid:     #444;
  --fg-muted:   #777;
  --accent:     #c49428;
  --accent-lt:  #fdf3d8;
  --accent-bdr: rgba(196, 148, 40, 0.35);
  --border:     #e5e2de;
  --radius:     10px;
  --font-d:     'Space Grotesk', sans-serif;
  --font-b:     'DM Sans', sans-serif;
  --focus-ring: 0 0 0 3px rgba(196, 148, 40, 0.25);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg-body);
  color: var(--fg);
  font-family: var(--font-b);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── NAV ── */
.book-nav {
  background: var(--bg-dark);
  border-bottom: 1px solid rgba(255,255,255,0.05);
  position: sticky;
  top: 0;
  z-index: 100;
}

.book-nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 1rem;
  color: #e8e6e1;
  text-decoration: none;
  letter-spacing: -0.01em;
  transition: color 0.2s;
}

.nav-logo:hover { color: #d4a039; }

.nav-phone {
  font-family: var(--font-d);
  font-size: 0.9rem;
  font-weight: 600;
  color: #d4a039;
  text-decoration: none;
  letter-spacing: -0.01em;
  transition: opacity 0.2s;
}

.nav-phone:hover { opacity: 0.8; }

/* ── MAIN LAYOUT ── */
.book-main { padding: 48px 0 80px; }

.book-container {
  max-width: 1060px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── HEADER ── */
.book-header { margin-bottom: 36px; }

.book-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px;
  background: var(--accent-lt);
  border: 1px solid var(--accent-bdr);
  border-radius: 100px;
  font-family: var(--font-d);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.6px;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.badge-dot {
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.4; }
}

.book-heading {
  font-family: var(--font-d);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--fg);
  margin-bottom: 12px;
}

.book-heading em {
  font-style: normal;
  color: var(--accent);
}

.book-sub {
  font-size: 1.05rem;
  color: var(--fg-muted);
  max-width: 540px;
  line-height: 1.65;
}

/* ── FORM ERROR ── */
.form-error {
  background: #fff1f0;
  border: 1px solid #ffc7c5;
  border-left: 4px solid #e53935;
  color: #b71c1c;
  padding: 14px 18px;
  border-radius: var(--radius);
  font-size: 15px;
  margin-bottom: 24px;
}

/* ── LAYOUT: form + sidebar ── */
.book-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
  align-items: start;
}

/* ── FORM ── */
.book-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.form-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  /* remove default fieldset styling */
  border-inline: 1px solid var(--border);
}

.section-legend {
  font-family: var(--font-d);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--fg);
  padding: 0;
  margin-bottom: 4px;
  float: left; /* keep inside fieldset */
  width: 100%;
  margin-bottom: 16px;
}

.required-mark { color: var(--accent); font-size: 0.9em; }

/* Field groups */
.field-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field-row { display: flex; gap: 16px; }
.two-col > .field-group { flex: 1; }
.three-col > .field-group { flex: 1; }

label, .field-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--fg-mid);
  font-family: var(--font-d);
}

input[type="text"],
input[type="number"],
input[type="tel"],
input[type="email"],
select,
textarea {
  width: 100%;
  padding: 11px 14px;
  background: var(--bg-card2);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-family: var(--font-b);
  font-size: 15px;
  color: var(--fg);
  transition: border-color 0.2s, box-shadow 0.2s;
  appearance: none;
  -webkit-appearance: none;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: var(--focus-ring);
}

input::placeholder, textarea::placeholder {
  color: #bbb;
}

textarea { resize: vertical; min-height: 80px; }

select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23888' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
  cursor: pointer;
}

.field-hint {
  font-size: 13px;
  color: var(--fg-muted);
  line-height: 1.5;
  margin-top: 2px;
}

/* Glass type selector */
.glass-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.glass-option {
  cursor: pointer;
  position: relative;
}

.glass-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.glass-label {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px 8px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card2);
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  text-align: center;
}

.glass-option:hover .glass-label,
.glass-option.selected .glass-label {
  border-color: var(--accent);
  background: var(--accent-lt);
  box-shadow: var(--focus-ring);
}

.glass-icon { font-size: 24px; line-height: 1; }

.glass-name {
  font-family: var(--font-d);
  font-size: 13px;
  font-weight: 600;
  color: var(--fg);
  line-height: 1.3;
}

/* ADAS */
.adas-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

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

.adas-tooltip-btn {
  background: none;
  border: 1px solid var(--accent-bdr);
  border-radius: 100px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
  padding: 3px 12px;
  cursor: pointer;
  font-family: var(--font-d);
  transition: background 0.2s;
}

.adas-tooltip-btn:hover { background: var(--accent-lt); }

.adas-tip {
  background: var(--accent-lt);
  border: 1px solid var(--accent-bdr);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 14px;
  color: #5a4010;
  line-height: 1.55;
}

.radio-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.radio-opt {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 15px;
  color: var(--fg-mid);
}

.radio-opt input[type="radio"] {
  width: 18px;
  height: 18px;
  min-width: 18px;
  accent-color: var(--accent);
  cursor: pointer;
  appearance: auto;
  -webkit-appearance: auto;
  border: none;
  background: none;
  box-shadow: none;
  padding: 0;
}

/* Submit button */
.btn-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 16px 24px;
  background: var(--accent);
  color: #0a0c10;
  border: none;
  border-radius: var(--radius);
  font-family: var(--font-d);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}

.btn-submit:hover {
  background: #d4a039;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(196, 148, 40, 0.3);
}

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

/* ── SIDEBAR ── */
.book-sidebar { position: sticky; top: 74px; }

.trust-card {
  background: var(--bg-dark);
  border-radius: 14px;
  padding: 28px 24px;
  color: #e8e6e1;
}

.trust-badge-row { margin-bottom: 24px; }

.trust-badge {
  display: flex;
  align-items: center;
  gap: 14px;
}

.trust-badge-icon {
  font-size: 28px;
  background: rgba(212,160,57,0.12);
  border-radius: 10px;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.trust-badge-title {
  font-family: var(--font-d);
  font-size: 1rem;
  font-weight: 700;
  color: #d4a039;
}

.trust-badge-sub {
  font-size: 12px;
  color: #8b8a87;
  margin-top: 2px;
}

.trust-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 14px;
  color: #c8c6c2;
  line-height: 1.4;
}

.trust-list .check {
  color: #d4a039;
  font-weight: 700;
  margin-right: 6px;
}

.trust-divider {
  height: 1px;
  background: rgba(255,255,255,0.07);
  margin: 20px 0;
}

.trust-contact p {
  font-size: 13px;
  color: #8b8a87;
  margin-bottom: 6px;
}

.trust-phone {
  display: block;
  font-family: var(--font-d);
  font-size: 1.15rem;
  font-weight: 700;
  color: #d4a039;
  text-decoration: none;
  margin-bottom: 10px;
  transition: opacity 0.2s;
}

.trust-phone:hover { opacity: 0.8; }

.trust-addr {
  font-size: 13px;
  color: #8b8a87;
  line-height: 1.6;
}

/* ── SUCCESS STATE ── */
.success-card {
  max-width: 560px;
  margin: 40px auto 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 48px 40px;
  text-align: center;
}

.success-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(135deg, #c49428, #e8b84a);
  color: #0a0c10;
  font-size: 28px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  box-shadow: 0 8px 24px rgba(196, 148, 40, 0.3);
}

.success-heading {
  font-family: var(--font-d);
  font-size: 1.9rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
  color: var(--fg);
}

.success-body {
  color: var(--fg-muted);
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 28px;
}

.success-details {
  background: var(--bg-card2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 28px;
  text-align: left;
}

.success-detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  font-size: 14px;
  border-bottom: 1px solid var(--border);
}

.success-detail-row:last-child { border-bottom: none; }

.detail-label { color: var(--fg-muted); }
.detail-value { font-weight: 600; color: var(--fg); }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  color: var(--fg-mid);
  text-decoration: none;
  font-family: var(--font-d);
  font-size: 14px;
  font-weight: 600;
  transition: border-color 0.2s, background 0.2s;
}

.btn-secondary:hover {
  border-color: var(--accent);
  background: var(--accent-lt);
  color: var(--accent);
}

/* ── RESPONSIVE ── */
@media (max-width: 820px) {
  .book-layout {
    grid-template-columns: 1fr;
  }

  .book-sidebar {
    position: static;
    /* Show sidebar below form on mobile */
    order: 2;
  }

  .book-form { order: 1; }
}

@media (max-width: 600px) {
  .book-main { padding: 32px 0 60px; }

  .book-heading { font-size: 2rem; }

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

  .field-row.two-col,
  .field-row.three-col { flex-direction: column; gap: 12px; }

  .form-section { padding: 20px 16px; }

  .success-card { padding: 32px 20px; }
}

@media (max-width: 380px) {
  .glass-grid { grid-template-columns: repeat(2, 1fr); }
}
