/* Calculus Refined design tokens. Mobile first: fluid values use clamp()
   (min = phone at 390px, max = desktop, reached by ~1040px).
   Layout breakpoint: 720px (see components.css). */

:root {
  /* Color: brand */
  --color-brand: #064963;          /* logo teal. Headings, links, primary buttons, icons, active borders */
  --color-brand-hover: #0a5c7a;    /* primary button hover/active background only */
  --color-link-hover: #0a6a8c;     /* text link hover only */
  --color-focus: #0a6a8c;          /* focus ring only */

  /* Color: ink */
  --color-ink-strong: #1f2a2e;     /* sub-headings, form labels, input text, service intro */
  --color-ink: #33393c;            /* default body color, bullet text */
  --color-ink-body: #3a4144;       /* long-form paragraphs */
  --color-ink-footer: #4a5357;     /* footer copyright */
  --color-ink-muted: #5d6a70;      /* eyebrows, counters, meta, fine print */

  /* Color: surfaces and lines */
  --color-white: #ffffff;
  --color-band: #f5f7f8;           /* alternating section band, TOC panel */
  --color-line: #e3e6e8;           /* header/footer/card borders, hairlines */
  --color-line-subtle: #eef0f1;    /* service card toggle divider */
  --color-rule: #cfd4d7;           /* 72px divider under section titles */
  --color-input-border: #7f8c92;   /* form input border, ~3.5:1 on white */
  --color-card-border: #d5dde1;    /* success card border */
  --color-image-fill: #dfe6ea;     /* background behind images while loading */
  --color-header-bg: rgba(255, 255, 255, 0.97);
  --color-bar-bg: rgba(255, 255, 255, 0.98);
  --color-arrow-bg: rgba(255, 255, 255, 0.92);
  --color-tap: rgba(6, 73, 99, 0.12);

  /* Color: feedback */
  --color-error: #a4231b;          /* field error text and invalid border */
  --color-error-ink: #7d1c15;      /* text inside error alert */
  --color-error-bg: #fdf0ef;
  --color-error-border: #e3b7b3;

  /* Hero */
  --hero-wash-opacity: 0.5;        /* white layer over the hero photo. Do not go below 0.5 (heading contrast) */
  --hero-min-h: clamp(440px, 66svh, 660px);
  --hero-pad-top: clamp(28px, 6vh, 72px);
  --hero-pad-bottom: clamp(20px, 4vh, 40px);
  --hero-logo-w: clamp(84px, 20vw, 170px);
  --hero-body-gap: clamp(22px, 3.5vh, 36px);
  --hero-body-pad: 24px;

  /* Font */
  --font-sans: 'Jost', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --weight-light: 300;
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;

  /* Type scale (size / line-height) */
  --text-hero: clamp(34px, 7.4vw, 72px);         --lh-hero: 1.08;
  --text-h2: clamp(28px, 5vw, 48px);             --lh-h2: 1.15;
  --text-services-h2: clamp(28px, 5vw, 36px);
  --text-h3: clamp(22px, 3vw, 28px);             --lh-h3: 1.25;
  --text-service-title: clamp(20px, 2.4vw, 22px); --lh-service-title: 1.3;
  --text-lead: 17px;         --lh-lead: 1.6;
  --text-body: clamp(17px, 1.6vw, 18px);         --lh-body: 1.7;
  --text-bullet: 16px;       --lh-bullet: 1.55;
  --text-sub: clamp(17px, 1.8vw, 19px);
  --text-hero-email: clamp(16px, 2.2vw, 19px);
  --text-policy-h1: clamp(32px, 5.5vw, 52px);    --lh-policy-h1: 1.1;
  --text-policy-h2: clamp(21px, 2.6vw, 24px);
  --text-policy-body: 17px;
  --text-policy-sub: 14px;
  --text-success: 22px;
  --text-input: 17px;
  --text-label: 15px;
  --text-button: 15px;
  --text-nav: 13px;
  --text-brand: 16px;
  --text-meta: 15px;
  --text-footer: 14px;
  --text-error: 14px;
  --text-eyebrow: 13px;
  --text-fine: 13px;

  /* Letter-spacing */
  --track-button: 0.18em;
  --track-eyebrow: 0.16em;
  --track-nav: 0.12em;
  --track-brand: 0.02em;
  --track-hero: -0.005em;

  /* Spacing scale */
  --space-1: 4px;
  --space-2: 6px;
  --space-3: 8px;
  --space-4: 10px;
  --space-5: 12px;
  --space-6: 14px;
  --space-7: 16px;
  --space-8: 18px;
  --space-9: 20px;
  --space-10: 24px;
  --space-11: 28px;
  --space-12: 32px;
  --space-13: 36px;
  --space-14: 40px;
  --space-15: 48px;

  /* Layout */
  --gutter: 20px;
  --container-wide: 1200px;   /* header */
  --container: 1160px;        /* welcome, service cards */
  --container-text: 720px;    /* policy article, carousel service panel */
  --container-form: 560px;    /* contact, carousel thumbnails */
  --header-h: 56px;
  --header-pad-l: 16px;
  --header-pad-r: 8px;
  --brand-logo: 28px;
  --brand-gap: 8px;
  --nav-gap: 2px;
  --nav-link-pad: 10px;
  --input-h: 52px;
  --submit-h: 56px;
  --tap-min: 44px;

  /* Section rhythm */
  --head-gap: 18px;
  --welcome-pad-top: clamp(20px, 3vw, 36px);
  --welcome-pad-bottom: clamp(56px, 10vw, 120px);
  --welcome-head-mb: clamp(28px, 6vw, 64px);
  --welcome-grid-gap: clamp(28px, 5vw, 72px);
  --welcome-title-mb: 18px;
  --services-pad-top: clamp(56px, 9vw, 64px);
  --services-pad-bottom: clamp(64px, 10vw, 120px);
  --services-pad-x: 16px;
  --services-head-mb: clamp(28px, 5vw, 36px);
  --contact-pad-y: clamp(56px, 10vw, 120px);
  --policy-pad-top: clamp(36px, 8vw, 88px);
  --policy-pad-bottom: clamp(56px, 10vw, 104px);
  --policy-head-gap: 16px;
  --policy-head-mb: clamp(28px, 5vw, 48px);
  --footer-pad: 36px 20px calc(44px + env(safe-area-inset-bottom));
  --footer-gap: 12px;
  --footer-bg: var(--color-band);

  /* Radii */
  --radius-sm: 2px;      /* buttons, inputs, cards, panels */
  --radius-round: 50%;   /* carousel arrows, back-to-top */

  /* Shadows */
  --shadow-arrow: 0 2px 10px rgba(6, 40, 55, 0.18);
  --shadow-bar: 0 -4px 18px rgba(6, 40, 55, 0.08);
  --shadow-fab: 0 4px 14px rgba(6, 40, 55, 0.22);

  /* Focus */
  --focus-ring: 3px solid var(--color-focus);
  --focus-offset: 3px;

  /* Motion */
  --ease-slide: cubic-bezier(0.2, 0.7, 0.2, 1);
  --dur-slide: 520ms;
  --dur-fade: 420ms;
  --dur-bar: 260ms;
  --dur-fast: 200ms;
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --dur-slide: 0ms;
    --dur-fade: 0ms;
    --dur-bar: 0ms;
    --dur-fast: 0ms;
  }
}
