/* Work Diary Mate — design system */

:root {
  /* Brand */
  --brand: #5fae33;            /* refined from logo #75C04F — slightly deeper for type contrast */
  --brand-bright: #75c04f;     /* original logo green for marks/icons */
  --brand-dark: #3d7e1f;
  --brand-deep: #1f4a0d;
  --brand-tint: #ecf7e3;
  --brand-tint-2: #f7fbf2;

  /* Surface */
  --bg: #ffffff;
  --bg-alt: #fafaf7;           /* warm off-white */
  --bg-tint: #f4f6f1;          /* faint green-tinted neutral */
  --ink: #0e1411;              /* near-black, green-tinted */
  --ink-2: #2a312d;
  --ink-3: #5a615d;
  --ink-4: #8a918d;
  --line: #e7e8e3;
  --line-2: #ededea;

  /* Dark surface (for inverted sections) */
  --dark: #0c130f;
  --dark-2: #131c17;
  --dark-3: #1c2620;
  --dark-line: rgba(255,255,255,.10);
  --dark-line-2: rgba(255,255,255,.06);
  --dark-ink: #f6f8f5;
  --dark-ink-2: #b8c0bc;
  --dark-ink-3: #7d847f;

  /* Misc */
  --warn: #d97706;
  --danger: #d23a3a;

  /* Radii */
  --r-sm: 6px;
  --r: 10px;
  --r-lg: 16px;
  --r-xl: 24px;
  --r-2xl: 32px;
  --r-pill: 999px;

  /* Shadow */
  --shadow-sm: 0 1px 2px rgba(15,23,18,.04), 0 1px 1px rgba(15,23,18,.03);
  --shadow: 0 4px 12px rgba(15,23,18,.05), 0 1px 3px rgba(15,23,18,.04);
  --shadow-lg: 0 24px 48px -12px rgba(15,23,18,.12), 0 8px 24px -8px rgba(15,23,18,.08);
  --shadow-brand: 0 12px 32px -8px rgba(95,174,51,.35);

  /* Layout */
  --w-page: 1200px;
  --w-narrow: 760px;
  --nav-h: 80px;

  /* Type */
  --font-display: "Geist", ui-sans-serif, system-ui, sans-serif;
  --font-sans: "Geist", ui-sans-serif, system-ui, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SF Mono", monospace;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "ss01", "cv11";
}

body { min-height: 100vh; }

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

/* Type scale */
.h-eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand-dark);
}
.h-eyebrow.on-dark { color: #a6d77f; }

h1, h2, h3, h4 { margin: 0; letter-spacing: -0.02em; line-height: 1.05; font-weight: 600; }
h1 { font-size: clamp(40px, 7vw, 84px); letter-spacing: -0.035em; line-height: 1.0; font-weight: 600; }
h2 { font-size: clamp(32px, 4.5vw, 56px); letter-spacing: -0.028em; line-height: 1.05; }
h3 { font-size: clamp(22px, 2.6vw, 32px); letter-spacing: -0.02em; line-height: 1.15; }
h4 { font-size: clamp(17px, 1.4vw, 20px); letter-spacing: -0.012em; line-height: 1.2; font-weight: 600; }
p { margin: 0; line-height: 1.55; }

.lede { font-size: clamp(17px, 1.6vw, 22px); color: var(--ink-2); line-height: 1.5; }
.muted { color: var(--ink-3); }
.tabular { font-variant-numeric: tabular-nums; }

/* Layout */
.page-wrap { max-width: var(--w-page); margin: 0 auto; padding: 0 24px; }
.narrow { max-width: var(--w-narrow); margin: 0 auto; }
.section { padding: 96px 0; }
.section-tight { padding: 64px 0; }
@media (max-width: 720px) {
  .section { padding: 64px 0; }
  .section-tight { padding: 44px 0; }
  .page-wrap { padding: 0 20px; }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 18px;
  border-radius: var(--r-pill);
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: -0.005em;
  border: 1px solid transparent;
  transition: background .15s, transform .15s, border-color .15s, color .15s;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--ink);
  color: #fff;
}
.btn-primary:hover { background: #1c2620; }
.btn-brand {
  background: var(--brand);
  color: #fff;
  box-shadow: var(--shadow-brand);
}
.btn-brand:hover { background: var(--brand-dark); }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn-ghost:hover { background: var(--bg-tint); border-color: var(--ink-4); }
.btn-ghost.on-dark { color: var(--dark-ink); border-color: var(--dark-line); }
.btn-ghost.on-dark:hover { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.25); }
.btn-lg { height: 52px; padding: 0 24px; font-size: 15.5px; }
.btn-sm { height: 36px; padding: 0 14px; font-size: 13.5px; }
.btn-link {
  background: transparent;
  border: 0;
  color: var(--brand-dark);
  font-size: 14.5px;
  font-weight: 500;
  display: inline-flex; align-items: center; gap: 6px;
  padding: 0;
  height: auto;
}
.btn-link:hover { color: var(--brand-deep); }

/* Cards */
.card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 28px;
  transition: border-color .15s, transform .15s, box-shadow .2s;
}
.card:hover { border-color: #d6d8d2; }
.card-flat {
  background: var(--bg-tint);
  border-radius: var(--r-lg);
  padding: 28px;
  border: 1px solid transparent;
}

/* Badge / pill */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  font-size: 12.5px;
  font-weight: 500;
  background: var(--bg-tint);
  color: var(--ink-2);
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  letter-spacing: -0.01em;
}
.pill-brand {
  background: var(--brand-tint);
  color: var(--brand-deep);
  border-color: #cfe5b8;
}
.pill-dark {
  background: rgba(255,255,255,.06);
  color: var(--dark-ink-2);
  border-color: var(--dark-line);
}
.pill .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

/* Dot grid background */
.bg-grid {
  background-image: radial-gradient(circle, var(--line) 1px, transparent 1px);
  background-size: 24px 24px;
}
.bg-grid-dark {
  background-image: radial-gradient(circle, rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* Section heading */
.section-h {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 48px;
}
.section-h.center { align-items: center; text-align: center; }

/* Image placeholders */
.placeholder {
  position: relative;
  background:
    repeating-linear-gradient(135deg,
      rgba(0,0,0,.025) 0 1px,
      transparent 1px 12px),
    var(--bg-tint);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-3);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.02em;
  text-align: center;
  padding: 16px;
  overflow: hidden;
}
.placeholder.on-dark {
  background:
    repeating-linear-gradient(135deg,
      rgba(255,255,255,.04) 0 1px,
      transparent 1px 12px),
    rgba(255,255,255,.03);
  border-color: var(--dark-line);
  color: var(--dark-ink-3);
}
.placeholder .ph-tag {
  position: absolute;
  top: 12px; left: 12px;
  font-size: 10.5px;
  font-family: var(--font-mono);
  color: var(--ink-3);
  padding: 3px 8px;
  background: rgba(255,255,255,.8);
  border: 1px solid var(--line);
  border-radius: 999px;
  backdrop-filter: blur(8px);
}
.placeholder.on-dark .ph-tag {
  background: rgba(0,0,0,.4);
  border-color: var(--dark-line);
  color: var(--dark-ink-2);
}

/* Phone frame */
.phone {
  position: relative;
  width: 280px;
  aspect-ratio: 9/19.5;
  background: var(--ink);
  border-radius: 38px;
  padding: 8px;
  box-shadow: var(--shadow-lg);
}
.phone .screen {
  width: 100%;
  height: 100%;
  background: var(--bg-tint);
  border-radius: 30px;
  overflow: hidden;
  position: relative;
}
.phone .notch {
  position: absolute;
  top: 14px; left: 50%; transform: translateX(-50%);
  width: 90px; height: 24px;
  background: var(--ink);
  border-radius: 999px;
  z-index: 2;
}

/* Subtle separators */
.hr {
  height: 1px;
  background: var(--line);
  border: 0;
}
.hr-dark { background: var(--dark-line); }

/* Generic dark surface */
.dark-surface {
  background: var(--dark);
  color: var(--dark-ink);
}
.dark-surface .muted { color: var(--dark-ink-3); }

/* Utilities */
.row { display: flex; }
.col { display: flex; flex-direction: column; }
.gap-8 { gap: 8px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; }
.gap-24 { gap: 24px; } .gap-32 { gap: 32px; } .gap-48 { gap: 48px; }
.center { align-items: center; }
.between { justify-content: space-between; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; }
/* .hidden-mobile is just a marker — element keeps whatever display its other classes set */
.only-mobile { display: none; }
.only-mid { display: none; }
/* Mid widths: slim the header — hide tagline + secondary CTA, shorten log-in label */
@media (max-width: 1280px) {
  .hide-mid { display: none !important; }
  .only-mid { display: inline !important; }
}
@media (max-width: 1100px) {
  .hidden-mobile { display: none !important; }
  .only-mobile { display: inline-flex !important; }
}
@media (max-width: 720px) {
  .hidden-mobile { display: none !important; }
  .only-mobile { display: inline-flex !important; }
}

/* Entry animations disabled — left as no-op classes for compat. */
.rise, .rise-2, .rise-3, .rise-4 { opacity: 1; }

/* Focus */
:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Header nav — never let labels wrap */
header nav a,
header nav button,
header .wdm-aud-toggle button { white-space: nowrap; }

/* Header audience toggle: hide on tight desktops (it's available in the hero + mobile menu) */
@media (max-width: 1100px) {
  .header-aud { display: none !important; }
}

/* Selection */
::selection { background: var(--brand-tint); color: var(--ink); }
