/* Valdore design system (owner, PRODUCT-DIRECTION §0.17). Change values in the tokens, not in the components. */

/* ---- 0. Fonts: served from this site, so customers' browsers never contact a font service. SIL Open Font License; see /fonts. ---- */
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-latin-600-normal.woff2) format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-latin-ext-600-normal.woff2) format('woff2'); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-cyrillic-600-normal.woff2) format('woff2'); unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-cyrillic-ext-600-normal.woff2) format('woff2'); unicode-range: U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F; }
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-vietnamese-600-normal.woff2) format('woff2'); unicode-range: U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB; }
@font-face { font-family: 'Cormorant Garamond'; font-style: italic; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-latin-600-italic.woff2) format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Cormorant Garamond'; font-style: italic; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-latin-ext-600-italic.woff2) format('woff2'); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Cormorant Garamond'; font-style: italic; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-cyrillic-600-italic.woff2) format('woff2'); unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family: 'Cormorant Garamond'; font-style: italic; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-cyrillic-ext-600-italic.woff2) format('woff2'); unicode-range: U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F; }
@font-face { font-family: 'Cormorant Garamond'; font-style: italic; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-vietnamese-600-italic.woff2) format('woff2'); unicode-range: U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB; }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 200 800; font-display: swap; src: url(/fonts/manrope-latin-wght-normal.woff2) format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 200 800; font-display: swap; src: url(/fonts/manrope-latin-ext-wght-normal.woff2) format('woff2'); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 200 800; font-display: swap; src: url(/fonts/manrope-cyrillic-wght-normal.woff2) format('woff2'); unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 200 800; font-display: swap; src: url(/fonts/manrope-cyrillic-ext-wght-normal.woff2) format('woff2'); unicode-range: U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F; }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 200 800; font-display: swap; src: url(/fonts/manrope-vietnamese-wght-normal.woff2) format('woff2'); unicode-range: U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB; }

/* ---- 1. Tokens ---- */
:root {
  color-scheme: dark;

  /* Surfaces */
  --bg: #120404;              /* page */
  --surface: #240909;         /* main container, header */
  --surface-inset: #2B0A0A;   /* cards, inputs */
  --surface-result: #3E0E0E;  /* the result moment; used sparingly */
  --highlight: #6F2A2A;       /* quiet separators on burgundy */

  /* Brand */
  --gold: #C9A24B;
  --gold-light: #D9B45A;
  --on-gold: #120404;

  /* Text */
  --text: #F9F6ED;
  --muted: #C4B5AF;

  /* Lines. Input borders are stronger than the website's decorative lines: they must be seen. */
  --line: #4A2A22;
  --line-input: #A08A5F;

  /* Meaning */
  --danger-text: #F6B8AE;
  --danger-bg: #4A1414;
  --ok: #9AD6A6;

  /* Type */
  --font-head: "Cormorant Garamond", "Noto Serif", Georgia, serif;
  --font-ui: "Manrope", system-ui, -apple-system, "Segoe UI", "Noto Sans", "Noto Sans Arabic", sans-serif;
  --h1: 38px; --h2: 32px; --h3: 16px; --body: 16px; --small: 14px; --tiny: 13px;

  /* Shape and rhythm */
  --radius-card: 10px;
  --radius-control: 4px;
  --control-h: 48px;
  --gap: 16px;

  /* Names the mock-only pages already use */
  --card: var(--surface-inset); --ink: var(--text); --gold-soft: var(--surface-result); --warn: var(--danger-text); --focus: var(--gold-light);
}

/* ---- 2. Base and type ---- */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 var(--body)/1.55 var(--font-ui); overflow-wrap: anywhere; }
h1, h2 { font-family: var(--font-head); font-weight: 600; line-height: 1.15; color: var(--text); margin: 0 0 8px; }
h1 { font-size: var(--h1); }
h2 { font-size: var(--h2); }
/* Italic only where the script has one. Other scripts stay upright. */
:is(html[lang=en], html[lang=fr], html[lang=es], html[lang=pt], html[lang=tl], html[lang=vi]) :is(h1, .result-title) { font-style: italic; }
h3 { font: 600 var(--h3)/1.35 var(--font-ui); }
a { color: var(--gold-light); }
img { max-width: 100%; }
.sub { color: var(--muted); margin: 0 0 var(--gap); }
.help { font-size: var(--tiny); color: var(--muted); margin: 6px 0 0; }
.ref { font-size: var(--small); color: var(--muted); margin: 0 0 12px; font-variant-numeric: tabular-nums; }
.eyebrow { font-size: var(--tiny); font-weight: 600; letter-spacing: .04em; color: var(--gold); }
.error { color: var(--danger-text); font-size: var(--small); font-weight: 500; margin: 10px 0 0; }

/* ---- 3. Header ---- */
.top { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 24px; background: var(--surface); border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; min-width: 0; }
.brand img { display: block; height: 44px; width: auto; }
.owner-brand { gap: 12px; font-weight: 600; }
.owner-brand img { height: 32px; }
.lang-pick { display: flex; align-items: center; gap: 8px; font-size: var(--small); color: var(--muted); margin-inline-start: auto; }
.lang-pick select { width: auto; max-width: 52vw; min-height: 44px; padding-block: 6px; }
.top-actions { display: flex; align-items: center; gap: 14px; }
.mock { margin: 0; padding: 6px 16px; font-size: var(--tiny); background: var(--surface-result); color: var(--text); text-align: center; }

/* ---- 4. Layout ---- */
main { max-width: 720px; margin: 24px auto 48px; padding: 28px; background: var(--surface); border-radius: var(--radius-card); }
.card { background: var(--surface-inset); border: 1px solid var(--line); border-radius: var(--radius-card); padding: var(--gap); margin: 0 0 var(--gap); }
.card h3 { margin: 0 0 12px; display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.full { grid-column: 1 / -1; }
.field { min-width: 0; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: var(--gap); }
.actions button { flex: 0 1 auto; }
.privacy { margin-top: 20px; }
form .field { margin-bottom: 14px; }

/* ---- 5. Progress ---- */
.progress { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; }
.progress-bar { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; max-width: 200px; }
.progress-bar i { height: 3px; border-radius: 2px; background: var(--line); }
.progress-bar i.on { background: var(--gold); }

/* ---- 6. Buttons ---- */
button { font: 600 15px/1.3 var(--font-ui); cursor: pointer; min-height: var(--control-h); padding: 10px 18px; border-radius: var(--radius-control); border: 1px solid var(--gold); background: transparent; color: var(--text); text-align: center; }
button:hover { background: var(--surface-result); border-color: var(--gold-light); }
button:active { background: var(--highlight); }
button:disabled { cursor: not-allowed; color: var(--muted); border-color: var(--line); background: transparent; opacity: .7; }
/* Primary: one obvious next action. */
.gold, .primary { background: var(--gold); border-color: var(--gold); color: var(--on-gold); font-weight: 700; }
.gold:hover, .primary:hover { background: var(--gold-light); border-color: var(--gold-light); }
.gold:active, .primary:active { background: #B18D3E; border-color: #B18D3E; }
.gold:disabled, .primary:disabled { background: var(--line); border-color: var(--line); color: var(--muted); }
/* Text action. */
.link { min-height: 44px; border: none; background: none; color: var(--gold-light); padding: 6px 0; text-decoration: underline; text-underline-offset: 3px; font-weight: 500; text-align: start; }
.link:hover { background: none; color: var(--text); }
.link:active { background: none; color: var(--gold); }

/* Keyboard focus: same everywhere, and visible on every surface. */
:is(button, select, input, textarea, a):focus-visible { outline: 3px solid var(--gold-light); outline-offset: 2px; }

/* ---- 7. Forms ---- */
select, input, textarea { font: 500 16px/1.35 var(--font-ui); color: var(--text); }
select, input[type=text], input[type=tel], input[type=number], input[type=password], input:not([type]), textarea { width: 100%; min-height: var(--control-h); padding: 10px 12px; background: var(--surface-inset); border: 1px solid var(--line-input); border-radius: var(--radius-control); font-variant-numeric: tabular-nums; }
.card :is(select, input, textarea) { background: var(--surface); }
:is(select, input, textarea):hover { border-color: var(--gold); }
:is(select, input, textarea):focus-visible { border-color: var(--gold-light); }
:is(select, input, textarea):disabled { color: var(--muted); border-color: var(--line); cursor: not-allowed; }
select option { background: var(--surface); color: var(--text); }
::placeholder { color: var(--muted); opacity: 1; }
.field label, .q-title { display: block; font-size: var(--small); font-weight: 500; color: var(--muted); margin-bottom: 6px; }
.q-strong { font-size: var(--body); font-weight: 600; color: var(--text); }
.checks { display: flex; flex-wrap: wrap; gap: 4px 18px; margin-top: 8px; font-size: var(--small); color: var(--muted); }
.checks label { display: inline-flex; align-items: center; min-height: 40px; margin: 0; }
.checks input { width: 20px; height: 20px; min-height: 0; margin-inline-end: 8px; accent-color: var(--gold); flex: none; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button { min-height: 44px; padding: 8px 14px; font-size: var(--small); font-weight: 500; border-color: var(--line-input); }
.chips button[aria-pressed=true] { background: var(--gold); border-color: var(--gold); color: var(--on-gold); font-weight: 700; }
.q-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 0; border-top: 1px solid var(--line); flex-wrap: wrap; }
.q-row:first-of-type { border-top: none; }
.langs { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.langs button { min-height: 54px; font-size: 16px; font-weight: 500; border-color: var(--line-input); }

/* ---- 8. Messages and the result ---- */
.message { white-space: pre-wrap; background: var(--surface-inset); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 18px; margin: 0 0 12px; unicode-bidi: plaintext; }
.message.result { background: var(--surface-result); border-color: var(--highlight); }
.message.en { color: var(--muted); }
/* Must not set a direction here: splitting the run would reorder "$327 – $338 CAD" in Arabic and Persian. */
.amount { color: var(--gold-light); font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.message { font-variant-numeric: tabular-nums; }

/* ---- 9. Phones: a first-class layout ---- */
@media (max-width: 560px) {
  :root { --h1: 30px; --h2: 27px; }
  .top { padding: 10px 16px; }
  .brand img { height: 40px; }
  .lang-pick > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  main { margin: 0; padding: 20px 16px 32px; border-radius: 0; }
  .card { padding: 14px; }
  .grid { grid-template-columns: 1fr; }
  .actions button { flex: 1 1 100%; }
  .langs { grid-template-columns: 1fr 1fr; }
  /* Keep the booking action on screen while reading the estimate. */
  .sticky-actions { position: sticky; bottom: 0; background: var(--surface); padding: 10px 0 calc(12px + env(safe-area-inset-bottom)); margin-top: 16px; border-top: 1px solid var(--line); }
  /* The bar never hides anything for good: a focused link is kept clear of it, and the page ends below the message. */
  html { scroll-padding-bottom: 130px; }
  .sticky-actions button { flex: 1 1 140px; }
}
