@import url('https://fonts.googleapis.com/css2?family=Heebo:wght@300;400;500;600;700;800;900&display=swap');

/* =========================================
   KickOps Spec Document — Stylesheet
   Light Foundation + Teal Gradients
   Reference: ~/Projects/kickops-proposals/drafts/fundops-page.html
   Sample implementation: ~/Projects/jsc-spec-interim/

   Usage:
     1. Copy this file to spec project as `shared.css`
     2. <link rel="stylesheet" href="shared.css">
     3. Use classes: .exec-summary, .section, .meeting-card,
        .learning-box, .dogri-section, .agreements-section,
        .callout, .blocker, .source.meeting, .next-step, .board-card

   Rules:
     - NO blue/green/purple/orange/red as primary colors
     - Amber/red ONLY for semantic indicators (blocker, traffic light)
     - h1 ALWAYS has letter-spacing: -0.025em (KO typographic DNA)
     - Hero header gradient: #0F766E → #134E4A + radial glows
     - For Make.com in diagrams: use #134E4A (NOT purple #7C3AED)
   ========================================= */

:root {
  /* Teal DNA */
  --primary:        #14B8A6;
  --primary-light:  #2DD4BF;
  --primary-dark:   #0F766E;
  --primary-darker: #134E4A;

  /* Light Foundation */
  --bg:        #FAFAF9;
  --surface:   #FFFFFF;
  --surface-2: #F5F5F4;

  /* Slate Text */
  --ink:        #0F172A;
  --ink-2:      #334155;
  --gray:       #64748B;
  --gray-light: #94A3B8;
  --border:     #E2E8F0;

  /* Legacy aliases for existing markup — all redirect to teal/slate */
  --teal:        var(--primary-dark);
  --teal-dark:   var(--primary-darker);
  --teal-bg:     #CCFBF1;
  --teal-soft:   #F0FDFA;
  --text:        var(--ink);
  --green:       var(--primary-dark);
  --green-bg:    #F0FDFA;
  --orange:      var(--gray);
  --orange-bg:   var(--surface-2);
  --red:         var(--ink);
  --red-bg:      var(--surface-2);
  --purple:      var(--gray);
  --purple-bg:   var(--surface-2);
  --gray-border: var(--border);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Heebo', system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

.container { max-width: 980px; margin: 0 auto; padding: 32px 24px 80px; }

a { color: var(--primary-dark); text-decoration: none; }
a:hover { color: var(--primary); }

strong { color: var(--ink); font-weight: 700; }

/* ====== Top navigation (subtle, sticky-feeling) ====== */
.topnav {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px 16px;
  margin-bottom: 24px;
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  font-size: 14px;
}
.topnav a {
  color: var(--ink-2);
  padding: 8px 16px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 500;
  transition: all 0.15s;
}
.topnav a:hover { background: var(--surface-2); color: var(--primary-darker); }
.topnav a.active {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-darker) 100%);
  color: white;
  font-weight: 600;
}

/* ====== Hero header — full KO treatment ====== */
.header {
  background: linear-gradient(180deg, #0F766E 0%, #134E4A 100%);
  color: white;
  padding: 64px 48px 56px;
  border-radius: 20px;
  margin-bottom: 32px;
  position: relative;
  overflow: hidden;
}
.header::before {
  content: '';
  position: absolute;
  top: -150px;
  right: -150px;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(45, 212, 191, 0.18) 0%, transparent 70%);
  pointer-events: none;
}
.header::after {
  content: '';
  position: absolute;
  bottom: -100px;
  left: -100px;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(45, 212, 191, 0.10) 0%, transparent 70%);
  pointer-events: none;
}
.header h1 {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  margin-bottom: 14px;
  letter-spacing: -0.025em;
  line-height: 1.15;
  position: relative;
  max-width: 760px;
}
.header .subtitle {
  font-size: 17px;
  font-weight: 300;
  color: #D1D5DB;
  position: relative;
  max-width: 720px;
  line-height: 1.6;
}
.header .meta {
  margin-top: 28px;
  display: flex;
  gap: 28px;
  font-size: 13px;
  flex-wrap: wrap;
  position: relative;
  color: rgba(255,255,255,0.75);
}
.header .meta span { display: flex; align-items: center; gap: 6px; }

/* ====== Sections — calm, generous, white ====== */
.section,
.dogri-section,
.agreements-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 40px 44px;
  margin-bottom: 24px;
}

/* Section heading pattern: small eyebrow color + large title */
.section h2,
.dogri-section h2,
.agreements-section h2 {
  font-size: clamp(22px, 2.6vw, 28px);
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 22px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.section h3,
.dogri-section h3,
.agreements-section h3 {
  font-size: 19px;
  font-weight: 700;
  color: var(--ink);
  margin: 28px 0 14px;
  letter-spacing: -0.01em;
}
.section h4,
.dogri-section h4,
.agreements-section h4 {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  margin: 16px 0 10px;
}
.section p,
.dogri-section p,
.agreements-section p {
  margin-bottom: 12px;
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1.75;
}
.section ul, .section ol,
.dogri-section ul, .dogri-section ol,
.agreements-section ul, .agreements-section ol {
  padding-right: 22px;
  margin: 10px 0;
  color: var(--ink-2);
}
.section li,
.dogri-section li,
.agreements-section li {
  margin-bottom: 8px;
  line-height: 1.75;
}

/* ====== Exec summary — primary pullquote, calm teal wash ====== */
.exec-summary {
  background: var(--surface);
  border: 1px solid var(--border);
  border-right: 4px solid var(--primary);
  border-radius: 16px;
  padding: 36px 44px;
  margin-bottom: 28px;
  position: relative;
}
.exec-summary::before {
  content: 'תקציר מנהלים';
  position: absolute;
  top: 20px;
  left: 28px;
  font-size: 11px;
  font-weight: 700;
  color: var(--primary-dark);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 5px 12px;
  background: rgba(20, 184, 166, 0.1);
  border-radius: 100px;
}
.exec-summary h2 {
  font-size: clamp(22px, 2.4vw, 26px);
  color: var(--ink);
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 18px;
  letter-spacing: -0.02em;
  font-weight: 800;
  max-width: 620px;
}
.exec-summary p {
  font-size: 17px;
  line-height: 1.8;
  margin-bottom: 14px;
  color: var(--ink-2);
}
.exec-summary p:last-child { margin-bottom: 0; }
.exec-summary strong { color: var(--ink); }

/* ====== Source tags — small, calm, slate ====== */
.source {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--surface-2);
  color: var(--gray);
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 100px;
  font-weight: 500;
  margin-right: 4px;
  white-space: nowrap;
  border: 1px solid var(--border);
}
.source.meeting { background: rgba(20, 184, 166, 0.08); color: var(--primary-dark); border-color: rgba(20, 184, 166, 0.25); }
.source.timeless { background: rgba(20, 184, 166, 0.05); color: var(--primary-dark); border-color: var(--border); }
.source.doc { background: var(--surface-2); color: var(--gray); }
.source.meeting::before { content: '🎤'; font-size: 10px; }
.source.timeless::before { content: '🤖'; font-size: 10px; }
.source.doc::before { content: '📄'; font-size: 10px; }

/* ====== Meeting card — clean, subtle accent ====== */
.meeting-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-right: 3px solid var(--primary);
  border-radius: 12px;
  padding: 28px 32px;
  margin-bottom: 20px;
  transition: all 0.2s;
}
.meeting-card:hover {
  border-color: var(--primary-light);
  border-right-color: var(--primary);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
}
.meeting-card.pending { opacity: 0.6; border-right-color: var(--border); }
.meeting-card .card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  flex-wrap: wrap;
  gap: 10px;
}
.meeting-card .card-title {
  font-size: 19px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.meeting-card .badge {
  font-size: 11px;
  padding: 4px 12px;
  border-radius: 100px;
  font-weight: 600;
  letter-spacing: 0.04em;
}
.badge.done { background: rgba(20, 184, 166, 0.1); color: var(--primary-dark); }
.badge.pending { background: var(--surface-2); color: var(--gray); }
.badge.blocked { background: var(--surface-2); color: var(--ink); }
.meeting-meta {
  display: flex;
  gap: 18px;
  font-size: 13px;
  color: var(--gray);
  margin-bottom: 14px;
  flex-wrap: wrap;
}

/* ====== Learning box — calm cream/teal wash ====== */
.learning-box {
  background: var(--surface-2);
  border-radius: 12px;
  padding: 22px 26px;
  margin-top: 16px;
}
.learning-box .learning-title {
  font-weight: 700;
  font-size: 12px;
  color: var(--primary-dark);
  margin-bottom: 12px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}
.learning-box .learning-title::before { content: '◆ '; color: var(--primary); }
.learning-box ul { padding-right: 18px; margin: 0; }
.learning-box li {
  margin-bottom: 10px;
  font-size: 15px;
  color: var(--ink-2);
  line-height: 1.75;
}

/* ====== Tables — minimal, slate ====== */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 14px;
}
th {
  background: var(--surface-2);
  color: var(--ink);
  padding: 12px 14px;
  text-align: right;
  font-weight: 600;
  font-size: 13px;
  border-bottom: 2px solid var(--border);
}
td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
  color: var(--ink-2);
  font-size: 14px;
}
tr:hover td { background: rgba(20, 184, 166, 0.03); }
.agreements-section table th { background: rgba(20, 184, 166, 0.08); color: var(--primary-darker); }

/* ====== Dogri (challenges) — restyled as calm narrative cards ======
   Removed loud red treatment. Subtle slate accent, no alarm.        */
.dogri-section {
  border-right: 3px solid var(--ink);
}
.dogri-section h2 { color: var(--ink); }
.dogri-item {
  background: var(--surface-2);
  border-radius: 12px;
  padding: 18px 22px;
  margin-bottom: 12px;
  border-right: 3px solid var(--gray-light);
}
.dogri-item .item-title {
  font-weight: 700;
  font-size: 15px;
  color: var(--ink);
  margin-bottom: 6px;
}
.dogri-item p {
  font-size: 14px;
  margin: 0;
  color: var(--ink-2);
  line-height: 1.7;
}

/* Override any custom inline border-right on dogri-items */
.dogri-item[style*="border-right"] {
  border-right: 3px solid var(--primary) !important;
}

/* Lists in dogri */
.unclear-list, .risk-list { list-style: none; padding: 0; }
.unclear-list li, .risk-list li {
  padding: 12px 16px;
  border-right: 3px solid var(--border);
  margin-bottom: 8px;
  font-size: 14px;
  background: var(--surface-2);
  border-radius: 0 8px 8px 0;
  color: var(--ink-2);
  line-height: 1.7;
}

/* ====== Agreements — calm teal accent ====== */
.agreements-section {
  border-right: 3px solid var(--primary);
}
.agreements-section h2 { color: var(--primary-darker); }

/* ====== Open question groups — small subtle badges ====== */
.question-group { margin-bottom: 22px; }
.question-group h4 {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 100px;
  display: inline-block;
  margin-bottom: 12px;
  background: var(--surface-2);
  color: var(--ink);
}
.question-group h4.critical { background: var(--ink); color: white; }
.question-group h4.important { background: rgba(20, 184, 166, 0.1); color: var(--primary-dark); }
.question-group h4.nice { background: var(--surface-2); color: var(--gray); }
.question-list { list-style: none; padding: 0; }
.question-list li {
  padding: 12px 16px;
  border-right: 2px solid var(--border);
  margin-bottom: 8px;
  font-size: 14.5px;
  background: var(--surface);
  border-radius: 0 8px 8px 0;
  color: var(--ink-2);
  line-height: 1.65;
}
.question-list li.critical { border-right-color: var(--ink); background: var(--surface-2); }
.question-list li.important { border-right-color: var(--primary); }

/* ====== Blocker — calm dark card ====== */
.blocker {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-right: 3px solid var(--ink);
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 12px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 14.5px;
  color: var(--ink-2);
  line-height: 1.7;
}
.blocker::before { content: '◼'; color: var(--ink); font-size: 14px; flex-shrink: 0; line-height: 1.7; }
.blocker strong { color: var(--ink); }

/* ====== Architecture SVG wrap ====== */
.arch-svg-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px;
  margin: 16px 0;
  overflow-x: auto;
}
.arch-svg-wrap svg {
  display: block;
  width: 100%;
  height: auto;
  max-width: 920px;
  margin: 0 auto;
}
.arch-diagram {
  background: var(--surface-2);
  border-radius: 10px;
  padding: 22px;
  font-family: 'Menlo', 'Courier New', monospace;
  font-size: 12px;
  line-height: 1.5;
  direction: ltr;
  text-align: left;
  overflow-x: auto;
  white-space: pre;
  color: var(--primary-darker);
}

/* ====== Next steps — clean checklist ====== */
.next-step {
  display: flex;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  align-items: flex-start;
}
.next-step:last-child { border-bottom: none; }
.step-priority {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 12px;
  flex-shrink: 0;
  color: white;
  background: var(--ink);
}
.step-priority.high { background: var(--primary-darker); }
.step-priority.med { background: var(--primary-dark); }
.step-priority.low { background: var(--gray); }
.step-content { flex: 1; color: var(--ink); font-size: 15px; line-height: 1.55; }
.step-owner { font-size: 12.5px; color: var(--gray); margin-top: 4px; }

/* ====== Board card (boards-list page) ====== */
.board-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 26px 30px;
  margin-bottom: 18px;
  border-right: 3px solid var(--primary);
  transition: all 0.2s;
}
.board-card:hover {
  border-color: var(--primary-light);
  border-right-color: var(--primary);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
  transform: translateY(-2px);
}
.board-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}
.board-num {
  background: var(--primary-dark);
  color: white;
  font-weight: 700;
  font-size: 12px;
  padding: 4px 12px;
  border-radius: 100px;
  letter-spacing: 0.05em;
}
.board-card h3 {
  color: var(--ink);
  font-size: 20px;
  margin: 0;
  letter-spacing: -0.015em;
  font-weight: 700;
}
.board-card .meta-line {
  display: flex;
  gap: 16px;
  font-size: 12.5px;
  color: var(--gray);
  margin: 6px 0 14px;
  flex-wrap: wrap;
}
.board-card .field {
  margin: 10px 0;
  font-size: 14.5px;
  color: var(--ink-2);
  line-height: 1.7;
}
.board-card .field strong {
  color: var(--ink);
  display: inline-block;
  min-width: 110px;
}
.board-card.draft {
  border-right-color: var(--gray-light);
  background: var(--surface-2);
}
.board-card.draft .board-num { background: var(--gray); }

/* ====== Workspace section ====== */
.workspace-section { margin-bottom: 32px; }
.workspace-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 28px 0 16px;
  font-size: 18px;
  font-weight: 700;
  color: var(--primary-darker);
  padding: 12px 18px;
  background: rgba(20, 184, 166, 0.08);
  border-radius: 10px;
  letter-spacing: -0.01em;
}

/* ====== Status pills ====== */
.status-pill {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
}
.status-pill.draft { background: var(--surface-2); color: var(--gray); }
.status-pill.ready { background: rgba(20, 184, 166, 0.1); color: var(--primary-dark); }
.status-pill.preliminary { background: var(--surface-2); color: var(--gray); }

/* ====== Callout ====== */
.callout {
  background: var(--surface-2);
  border-right: 3px solid var(--primary);
  padding: 16px 20px;
  margin: 16px 0;
  border-radius: 0 10px 10px 0;
  font-size: 14.5px;
  color: var(--ink-2);
  line-height: 1.7;
}
.callout.preliminary { border-right-color: var(--gray-light); }

/* ====== Footer ====== */
.footer {
  text-align: center;
  padding: 40px 20px;
  font-size: 13px;
  color: var(--gray);
  line-height: 1.7;
}
.footer strong { color: var(--ink); }
.ko-mark {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  color: var(--primary-darker);
  letter-spacing: 0.05em;
}

/* ====== Cleanup: kill loud inline styles via overrides ======
   Existing markup has style="background: #fef9c3..." banners — neutralize them */
[style*="#fef9c3"], [style*="#FEF3C7"] {
  background: var(--surface-2) !important;
  border-right-color: var(--primary) !important;
}
[style*="#D97706"] {
  border-right-color: var(--primary) !important;
}
[style*="background: #fffbeb"], [style*="background:#fffbeb"], [style*="background: #FFFBEB"] {
  background: rgba(20, 184, 166, 0.04) !important;
}
[style*="#f0fdfa"], [style*="#F0FDFA"] {
  background: var(--surface-2) !important;
}

@media print {
  body { background: white; font-size: 12px; }
  .container { max-width: 100%; padding: 16px; }
  .topnav { display: none; }
  .section, .dogri-section, .agreements-section, .exec-summary, .meeting-card, .board-card {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #E2E8F0;
  }
  .header::before, .header::after { display: none; }
}
