/* ============================================================
   Planify — shared stylesheet (fonts + tokens + base)
   Derived from the customer's mockup (Planify Design System v1.0.0).
   Pages carry their layout inline, exactly as the mockup does;
   this file holds what the mockup shipped in its <helmet>.
   ============================================================ */

/* ---- Self-hosted webfonts: IBM Plex Sans ---- */
@font-face { font-family:'IBM Plex Sans'; font-style:normal; font-weight:300; font-display:swap; src:url("/fonts/ibm-plex-sans-300.woff2") format('woff2'); }
@font-face { font-family:'IBM Plex Sans'; font-style:normal; font-weight:400; font-display:swap; src:url("/fonts/ibm-plex-sans-400.woff2") format('woff2'); }
@font-face { font-family:'IBM Plex Sans'; font-style:normal; font-weight:500; font-display:swap; src:url("/fonts/ibm-plex-sans-500.woff2") format('woff2'); }
@font-face { font-family:'IBM Plex Sans'; font-style:normal; font-weight:600; font-display:swap; src:url("/fonts/ibm-plex-sans-600.woff2") format('woff2'); }
@font-face { font-family:'IBM Plex Sans'; font-style:normal; font-weight:700; font-display:swap; src:url("/fonts/ibm-plex-sans-700.woff2") format('woff2'); }

/* ---- Colors & type tokens ---- */
:root {
  /* Primary (logo blue→cyan gradient) */
  --p700: #1668B5;
  --p600: #1E7FD4;
  --p500: #2C92DD;
  --p400: #5FB1E8;
  --p300: #9BCFF1;
  --cyan: #25B5DD;

  /* Neutral (navy-tinted) */
  --n900: #1A2740;
  --n800: #21304F;
  --n700: #3C4A66;
  --n500: #6B7A99;
  --n400: #8B98B3;
  --n300: #AEB8CC;
  --n200: #D7DEEA;
  --n100: #E9EDF4;
  --n50:  #F4F6FA;
  --white: #FFFFFF;

  /* Semantic (schedule states) */
  --success: #16A34A;
  --warning: #F59E0B;
  --error:   #DC2626;
  --info:    #2493CA;
  --auto:    #7C4AED;
  --teal:    #0E7490;

  /* soft tints for badge / alert backgrounds */
  --success-bg: #E7F6EC;
  --warning-bg: #FEF3E2;
  --error-bg:   #FCEBEB;
  --info-bg:    #E4F1F8;
  --auto-bg:    #F0EAFD;
  --p-bg:       #EEF6FD;

  /* Brand gradient */
  --grad: linear-gradient(100deg, var(--p700), var(--p500) 55%, var(--cyan));
  --grad-soft: linear-gradient(100deg, #EAF3FB, #E6F4FA);

  /* Spacing scale (base 4px) */
  --sp-1: 4px;  --sp-2: 8px;  --sp-3: 12px; --sp-4: 16px;
  --sp-6: 24px; --sp-8: 32px; --sp-10: 40px; --sp-12: 48px; --sp-16: 64px;

  /* Radius */
  --r-xs: 2px; --r-sm: 4px; --r: 8px; --r-md: 12px;
  --r-lg: 16px; --r-xl: 20px; --r-2xl: 24px; --r-full: 999px;

  /* Borders */
  --line: 1px solid var(--n200);
  --line-strong: 1.5px solid var(--n200);

  /* Elevation */
  --sh-1: 0 1px 2px rgba(26, 39, 64, 0.06);
  --sh-2: 0 2px 6px rgba(26, 39, 64, 0.08);
  --sh-3: 0 6px 16px rgba(26, 39, 64, 0.10);
  --sh-pop: 0 12px 32px rgba(26, 39, 64, 0.16);
  --focus-ring: 0 0 0 3px rgba(30, 127, 212, 0.14);

  /* Type */
  --font-sans: 'IBM Plex Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: var(--font-sans);

  --h1-size: 32px;  --h1-lh: 40px;  --h1-wt: 700;
  --h2-size: 24px;  --h2-lh: 32px;  --h2-wt: 600;
  --h3-size: 20px;  --h3-lh: 28px;  --h3-wt: 600;
  --h4-size: 16px;  --h4-lh: 24px;  --h4-wt: 600;
  --body-lg-size: 16px; --body-lg-lh: 24px;
  --body-size: 14px;    --body-lh: 20px;
  --small-size: 12px;   --small-lh: 16px;
  --code-size: 13px;    --code-lh: 20px;  --code-wt: 500;
  --label-size: 10px;   --label-ls: 0.05em;
}

/* ---- Base ---- */
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: #fff;
  font-family: 'IBM Plex Sans', system-ui, sans-serif;
  color: var(--n700);
  font-feature-settings: 'tnum' 1, 'lnum' 1;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
a { color: var(--p600); text-decoration: none; }
a:hover { color: var(--p700); }
h1, h2, h3 { margin: 0; color: var(--n800); letter-spacing: -.015em; }
.tnum, .mono { font-variant-numeric: tabular-nums; }
.wrap { max-width: 1140px; margin: 0 auto; }

/* ---- Nav ---- */
.navlink { font: 500 14.5px/1 'IBM Plex Sans', sans-serif; color: var(--n700); }
.navlink:hover { color: var(--p600); }

/* ---- Buttons (hover states — background lives here so :hover can win) ---- */
.btn-solid { background: var(--p600); color: #fff; }
.btn-solid:hover { background: var(--p700); color: #fff; }
.btn-solid-light { background: var(--p600); color: #fff; }   /* on dark sections */
.btn-solid-light:hover { background: var(--p500); color: #fff; }
.btn-ghost { background: #fff; }
.btn-ghost:hover { background: var(--n50); }

/* ---- Forms (contact) ---- */
.fld { width: 100%; border: 1.5px solid var(--n200); border-radius: 8px; padding: 11px 13px; font: 400 14.5px/1.4 'IBM Plex Sans', sans-serif; color: var(--n800); background: #fff; outline: none; transition: border-color .15s, box-shadow .15s; }
.fld::placeholder { color: var(--n400); }
.fld:focus { border-color: var(--p600); box-shadow: 0 0 0 3px rgba(30, 127, 212, .14); }
.lbl { display: block; font: 600 12.5px/1 'IBM Plex Sans', sans-serif; color: var(--n800); margin-bottom: 7px; }

/* ---- Alternating feature blocks (features + inner pages) ---- */
.feat { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 64px); align-items: center; scroll-margin-top: 88px; }
@media (max-width: 820px) { .feat { grid-template-columns: 1fr; } }

/* ---- Responsive helpers (mockup grids collapse gracefully on mobile) ---- */
.g2 { }
@media (max-width: 820px) {
  .g2 { grid-template-columns: 1fr !important; }
}
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; align-items: start; }
@media (max-width: 820px) { .foot-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .foot-grid { grid-template-columns: 1fr; } }
.shot-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.shot-scroll > * { min-width: 720px; }
.nav-row { display: flex; align-items: center; justify-content: space-between; padding: 16px clamp(20px, 5vw, 44px); gap: 12px; flex-wrap: wrap; }
.nav-links { display: flex; align-items: center; gap: clamp(14px, 3vw, 34px); flex-wrap: wrap; }

/* ---- Mobile nav toggle (hamburger) ----
   The button is injected by /js/nav.js so every page picks it up
   without touching the per-page nav markup. Hidden above 900px. */
.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1.5px solid var(--n200);
  border-radius: 9px;
  background: #fff;
  color: var(--n800);
  cursor: pointer;
  transition: background .15s, border-color .15s;
}
.nav-toggle:hover { background: var(--n50); }
.nav-toggle:focus-visible { border-color: var(--p600); box-shadow: 0 0 0 3px rgba(30, 127, 212, .18); outline: none; }
.nav-toggle svg { display: block; width: 22px; height: 22px; }
.nav-toggle .ico-close { display: none; }
.nav-row[data-open="true"] .nav-toggle .ico-open { display: none; }
.nav-row[data-open="true"] .nav-toggle .ico-close { display: block; }

@media (max-width: 900px) {
  .nav-row { row-gap: 0; }
  .nav-toggle { display: inline-flex; }

  /* Links drop to their own full-width row and stack as a panel. */
  .nav-links {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin-top: 14px;
    padding-bottom: 6px;
    border-top: 1px solid var(--n200);
  }
  .nav-row[data-open="true"] .nav-links { display: flex; }

  .nav-links .navlink {
    padding: 14px 2px;
    font-size: 16px;
    border-bottom: 1px solid var(--n100);
  }
  /* Nav CTA carries inline styles in the page markup, so override hard. */
  .nav-links .btn-solid {
    width: 100%;
    margin-top: 14px;
    justify-content: center !important;
    padding: 14px 20px !important;
    font-size: 15px !important;
  }
}
