/* SGD strategy styles. Shared by every strategy page.
   Same design as the proposals (sgd-proposals/public/_shared/proposal.css): tokens, side menu,
   type and cards are copied from there so both read as one brand.
   Screen: the branded web strategy. Print: a plain, black-on-white document
   (see the @media print block at the end). */

:root {
  --sgd-blue: #36AAE3;
  --sgd-blue-hover: #2B93C7;
  --sgd-blue-deep: #1F6E99;
  --sgd-blue-tint: #EAF6FD;
  --navy: #1D2647;
  --sgd-yellow: #FCCA03;
  --sgd-yellow-hover: #E3B503;
  --cream: #F5F4F2;
  --white: #FFFFFF;
  --body-text: #555555;
  --stone: #6B6560;
  --border: #E0DDD9;

  --font-display: 'Bebas Neue', 'Arial Narrow', sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-full: 999px;
  --shadow-md: 0 4px 16px rgba(29, 38, 71, 0.08);
  --shadow-lg: 0 12px 40px rgba(29, 38, 71, 0.12);
  --shadow-accent: 0 8px 24px rgba(252, 202, 3, 0.35);
  --gradient: url('brand-gradient.svg') center / cover no-repeat, var(--navy);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 16px; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--body-text);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--sgd-blue); text-decoration: none; }
a:hover { color: var(--sgd-blue-hover); text-decoration: underline; }
p { margin: 0; text-wrap: pretty; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; }
strong { color: var(--navy); font-weight: 600; }
.dark strong, .card-dark strong { color: #fff; }

.print-only { display: none; }

/* ---------- Layout ---------- */
.layout { display: flex; align-items: flex-start; min-height: 100vh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; width: 240px; flex-shrink: 0;
  background: var(--navy); display: flex; flex-direction: column; gap: 28px;
  padding: 28px 18px; overflow-y: auto; border-right: 1px solid rgba(255,255,255,0.14);
}
.sidebar-logo { padding: 0 10px; }
.sidebar-logo img { height: 52px; width: auto; }
.sidebar-title { display: flex; flex-direction: column; gap: 4px; padding: 0 10px; }
.sidebar-title .eyebrow { font-size: 11px; }
.sidebar-title strong { font-size: 14px; line-height: 1.4; color: #fff; font-weight: 600; }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a {
  display: grid; grid-template-columns: 24px minmax(0,1fr); gap: 8px; align-items: baseline;
  padding: 9px 10px; border-radius: var(--radius-md); font-size: 14px; font-weight: 500;
  color: rgba(255,255,255,0.72); text-decoration: none;
}
.nav a span:first-child { font-size: 11px; font-weight: 600; color: var(--sgd-blue); }
.nav a:hover { background: rgba(255,255,255,0.08); color: #fff; }
.nav a.active { background: rgba(54,170,227,0.18); color: #fff; }
.sidebar-cta { margin-top: auto; }

main { flex: 1; min-width: 0; }
.section { background: var(--white); }
.section.alt { background: var(--cream); }
.section.dark { background: var(--gradient); color: #fff; }
.wrap {
  max-width: 1100px; margin: 0 auto; padding: clamp(56px, 8vw, 96px) 24px;
  display: flex; flex-direction: column; gap: 48px;
}
.section-head { display: flex; flex-direction: column; gap: 16px; max-width: 720px; }
.block, .stack { display: flex; flex-direction: column; gap: 20px; }
.lead { font-size: 17px; }

/* ---------- Type ---------- */
.eyebrow {
  font-size: 12px; letter-spacing: .14em; text-transform: uppercase;
  font-weight: 600; color: var(--sgd-blue-deep);
}
.dark .eyebrow, .card-dark .eyebrow, .sidebar .eyebrow { color: var(--sgd-yellow); }
.tag {
  display: inline-flex; align-items: center; gap: 10px; align-self: flex-start;
  font-size: 12px; letter-spacing: .18em; text-transform: uppercase; font-weight: 600; color: var(--sgd-blue-deep);
}
.tag::before { content: ''; width: 24px; height: 2px; background: var(--sgd-yellow); }
.dark .tag { color: #fff; }
.h1 { font-family: var(--font-display); font-size: clamp(56px, 11vw, 128px); line-height: .9; color: #fff; max-width: 900px; letter-spacing: .01em; }
.h2 { font-family: var(--font-display); font-size: clamp(40px, 6vw, 64px); line-height: .92; color: var(--navy); }
.h3 { font-family: var(--font-display); font-size: clamp(30px, 4vw, 40px); line-height: .95; color: var(--navy); }
.h4 { font-family: var(--font-display); font-size: 26px; line-height: 1; color: var(--navy); }
.card-dark .h3, .card-dark .h4 { color: #fff; }
.label { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; font-weight: 700; color: var(--navy); margin: 0 0 8px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; font: inherit; font-weight: 700; font-size: 15px; text-align: center;
  padding: 13px 20px; border-radius: var(--radius-md); border: 0; cursor: pointer;
  background: var(--sgd-yellow); color: var(--navy); text-decoration: none;
}
.btn:hover { background: var(--sgd-yellow-hover); box-shadow: var(--shadow-accent); color: var(--navy); text-decoration: none; }
.btn-block { display: block; width: 100%; }
.btn-small { padding: 9px 14px; font-size: 14px; }
.btn-ghost { background: transparent; border: 1px solid var(--border); color: var(--navy); font-weight: 600; }
.btn-ghost:hover { background: var(--sgd-blue-tint); box-shadow: none; }
.sidebar .btn-ghost { color: #fff; border-color: rgba(255,255,255,0.35); }
.sidebar .btn-ghost:hover { background: rgba(255,255,255,0.1); color: #fff; }

/* ---------- Cover ---------- */
.cover .wrap { padding-top: clamp(72px, 12vw, 140px); gap: 32px; }
.cover-period { font-size: 20px; color: rgba(255,255,255,0.85); }
.meta {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 24px;
  border-top: 1px solid rgba(255,255,255,0.2); padding-top: 28px; max-width: 900px;
}
.meta div { display: flex; flex-direction: column; gap: 6px; }
.meta span:last-child { color: #fff; }

/* ---------- Cards and lists ---------- */
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 20px; }
.split { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 48px; align-items: start; }
.card { background: var(--white); border: 1px solid var(--border); box-shadow: var(--shadow-md); border-radius: var(--radius-lg); padding: clamp(22px, 3vw, 32px); display: flex; flex-direction: column; gap: 12px; }
.card-dark { background: var(--navy); color: rgba(255,255,255,0.85); border-color: var(--navy); }
.section.alt .card:not(.card-dark) { background: var(--white); }

.numbered { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 0 48px; margin: 0; padding: 0; list-style: none; }
.numbered li { position: relative; padding: 22px 0 22px 64px; border-top: 1px solid var(--border); }
.numbered li > span { position: absolute; left: 0; top: 22px; font-family: var(--font-display); font-size: 36px; line-height: 1; color: var(--sgd-blue); }

.checks, .dots { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; font-size: 15px; }
.checks li, .dots li { position: relative; padding-left: 26px; line-height: 1.6; }
.checks li::before { content: '✓'; position: absolute; left: 0; top: 0; color: var(--sgd-blue); font-weight: 700; }
.dots li::before { content: ''; position: absolute; left: 4px; top: 10px; width: 6px; height: 6px; border-radius: 50%; background: var(--stone); }

/* ---------- Summary ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: 16px; }
.stat { background: var(--gradient); color: #fff; border-radius: var(--radius-lg); padding: 24px; display: flex; flex-direction: column; gap: 10px; }
.stat-value { font-family: var(--font-display); font-size: 64px; line-height: .9; color: var(--sgd-yellow); }
.stat-label { font-size: 14px; line-height: 1.5; color: rgba(255,255,255,0.85); }
.resources { background: var(--sgd-blue-tint); border-radius: var(--radius-lg); padding: clamp(22px, 3vw, 30px); display: flex; flex-direction: column; gap: 14px; }
.resource-links { display: flex; flex-direction: column; gap: 10px; }
.resource { display: flex; flex-direction: column; gap: 2px; background: var(--white); border-radius: var(--radius-md); padding: 14px 16px; border: 1px solid transparent; }
.resource:hover { border-color: var(--sgd-blue); text-decoration: none; }
.resource strong { color: var(--navy); }
.resource span { font-size: 13px; color: var(--stone); }

/* ---------- Review ---------- */
.competitors { display: flex; flex-direction: column; gap: 20px; }
.competitor-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; }
.competitor-head a { font-size: 14px; }
.competitor-body { display: grid; grid-template-columns: minmax(0, 320px) 1fr; gap: 24px; align-items: start; border-top: 1px solid var(--border); padding-top: 16px; }
.competitor-body.no-shot { grid-template-columns: 1fr; }
.competitor-shot { display: block; width: 100%; height: auto; aspect-ratio: 8 / 5; object-fit: cover; object-position: top; border: 1px solid var(--border); border-radius: 8px; background: var(--cream); }
.competitor-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }

.website { border-top: 4px solid var(--sgd-yellow); gap: 18px; }
.website-head { display: flex; flex-direction: column; gap: 4px; }
.website-top { display: grid; grid-template-columns: minmax(0, 440px) 1fr; gap: 28px; align-items: start; border-top: 1px solid var(--border); padding-top: 18px; }
.website-top.no-shot { grid-template-columns: 1fr; }
.website-intro { display: flex; flex-direction: column; gap: 12px; }
.website-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; border-top: 1px solid var(--border); padding-top: 18px; }
.wr-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 16px; font-size: 15px; }
.wr-item { display: grid; grid-template-columns: 24px 1fr; gap: 12px; align-items: start; line-height: 1.6; }
.wr-item strong { display: block; color: var(--navy); }
.wr-icon { width: 24px; height: 24px; margin-top: 1px; }
.wr-icon path { fill: none; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.strength .wr-icon circle { fill: #2E9E6B; }
.strength .wr-icon path { stroke: #fff; }
.opportunity .wr-icon circle { fill: var(--sgd-yellow); }
.opportunity .wr-icon path { stroke: var(--navy); }
.wr-vs { display: inline-block; margin-top: 6px; font-size: 12px; font-weight: 600; color: var(--sgd-blue-deep); background: var(--sgd-blue-tint); border-radius: var(--radius-sm); padding: 2px 8px; }

/* ---------- Plan ---------- */
.themes { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 20px; }
.theme .h3 { font-size: 34px; }
.theme-url { font-size: 13px; color: var(--sgd-blue-deep); word-break: break-all; }
.card-dark .theme-url { color: var(--sgd-blue); }
.theme-added { align-self: flex-start; font-size: 12px; font-weight: 600; background: var(--sgd-yellow); color: var(--navy); border-radius: var(--radius-sm); padding: 2px 8px; }
.recurring li { display: flex; flex-direction: column; padding: 14px 0 14px 30px; border-top: 1px solid var(--border); }
.recurring li:last-child { border-bottom: 1px solid var(--border); }
.recurring li::before { top: 14px; }

/* ---------- Action plan ---------- */
.months { display: flex; flex-direction: column; gap: 20px; }
.month { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 32px; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); padding: clamp(22px, 3vw, 32px); }
.month-side { display: flex; flex-direction: column; gap: 4px; }
.month-num { font-family: var(--font-display); font-size: 88px; line-height: .85; color: var(--navy); }
.month-label { font-size: 14px; font-weight: 600; color: var(--stone); }
.month-body { display: flex; flex-direction: column; gap: 20px; }
.tasks { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; }
.task { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 16px; padding: 16px 0; border-top: 1px solid var(--border); }
.task > div { display: flex; flex-direction: column; gap: 4px; }
.task-num {
  width: 32px; height: 32px; border-radius: 50%; background: var(--sgd-yellow); color: var(--navy);
  display: flex; align-items: center; justify-content: center; font-family: var(--font-display); font-size: 20px;
}
.task p { font-size: 15px; }
.task-tag { align-self: flex-start; font-size: 12px; font-weight: 600; background: var(--sgd-blue-tint); color: var(--sgd-blue-deep); border-radius: var(--radius-sm); padding: 2px 8px; }
.task-target { font-size: 13px; color: var(--stone); }
.task-note { background: var(--cream); border-left: 3px solid var(--sgd-yellow); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; padding: 10px 14px; margin-top: 6px; }

.footer { background: var(--navy); color: rgba(255,255,255,0.72); }
.footer .wrap { padding: 32px 24px; flex-direction: row; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; font-size: 13px; }
.footer img { height: 40px; width: auto; }
.footer a { color: #fff; }

/* ---------- Small screens: the side menu becomes a drop-down from the top bar ---------- */
.mobile-bar { display: none; }
@media (max-width: 900px) {
  html { scroll-padding-top: 72px; }
  .layout { display: block; }
  .mobile-bar {
    display: flex; position: sticky; top: 0; z-index: 20; justify-content: space-between; align-items: center;
    gap: 12px; padding: 10px 16px; background: var(--navy);
  }
  .mobile-bar img { height: 36px; width: auto; }
  .sidebar {
    display: none; position: fixed; top: 56px; left: 0; right: 0; bottom: 0; z-index: 19;
    width: auto; height: auto; padding: 20px 16px; border-right: 0;
  }
  .sidebar-logo { display: none; }
  body.menu-open { overflow: hidden; }
  body.menu-open .sidebar { display: flex; }
  .wrap { padding-left: 16px; padding-right: 16px; gap: 40px; }
  .split, .competitor-cols, .competitor-body, .website-top, .website-cols { grid-template-columns: 1fr; }
  .month { grid-template-columns: 1fr; gap: 16px; }
  .month-side { flex-direction: row; align-items: baseline; gap: 12px; }
  .month-num { font-size: 56px; }
}

/* =====================================================================
   PRINT: minimal, black on white, no colour backgrounds, no navigation.
   One continuous document with sensible page breaks.
   ===================================================================== */
@media print {
  @page { size: A4; margin: 18mm 16mm 20mm; }

  :root { --gradient: none; }
  html, body { background: #fff !important; color: #111 !important; }
  body { font-size: 10.5pt; line-height: 1.5; -webkit-print-color-adjust: economy; }
  * { box-shadow: none !important; text-shadow: none !important; }

  .sidebar, .mobile-bar, .footer { display: none !important; }
  .print-only { display: block !important; }
  .layout { display: block; }

  .section, .section.alt, .section.dark { background: none !important; color: #111 !important; }
  /* Block layout in print: Chrome honours page-break rules far better than in flex/grid */
  .wrap, .section-head, .block, .stack, .split, .month-body, .task > div, .competitors, .months { display: block; max-width: none; }
  .wrap { padding: 0; }
  .wrap > * + *, .section-head > * + *, .block > * + *, .stack > * + *, .split > * + *, .month-body > * + *, .competitors > * + *, .months > * + * { margin-top: 10pt; }
  .task > div > * + * { margin-top: 2pt; }
  .section-head > .tag { display: none; }
  .section { padding: 0 0 18pt; break-inside: auto; }
  .section + .section { border-top: 0.5pt solid #999; padding-top: 14pt; }
  /* Reserve space under each heading so it never sits alone at the foot of a page */
  .block > .h3::after { content: ''; display: block; height: 110pt; margin-bottom: -110pt; }
  /* Section headings: the spacer above splits the card under them, so use break-after instead */
  .section-head { break-after: avoid; }

  .h1, .h2, .h3, .h4, .card-dark .h3, .card-dark .h4 {
    font-family: var(--font-body); color: #111 !important; letter-spacing: 0; line-height: 1.25; font-weight: 700;
  }
  .h1 { font-size: 24pt; }
  .h2 { font-size: 16pt; }
  .h3, .theme .h3 { font-size: 12.5pt; }
  .h4 { font-size: 11pt; }
  h1, h2, h3, h4 { break-after: avoid; page-break-after: avoid; }
  .tag, .eyebrow, .label { color: #555 !important; font-size: 8pt; letter-spacing: .08em; }
  .tag::before { display: none; }
  p, li, span, strong, .lead, .stat-label, .card-dark { color: #111 !important; }
  .lead { font-size: 10.5pt; }
  a { color: #111 !important; text-decoration: underline; }

  /* Cover: a simple title block */
  .cover .wrap { padding: 0; }
  .print-logo { display: block !important; height: 34pt; width: auto; margin-bottom: 6pt; }
  .cover-period { font-size: 11pt; }
  .meta { display: grid; border-top: 0.5pt solid #999; padding-top: 10pt; gap: 10pt; grid-template-columns: repeat(3, 1fr); }
  .meta span:last-child { color: #111 !important; }

  /* Cards, tiles and panels become plain boxed blocks */
  .card, .card-dark, .stat, .resources, .resource, .month {
    background: none !important; color: #111 !important; border: 0.5pt solid #999 !important; border-radius: 0 !important;
  }
  .card, .resources, .month { padding: 10pt; gap: 6pt; break-inside: avoid; }
  /* Chrome ignores break-inside on flex boxes, so plain cards print as blocks and never split. */
  .grid-2 > .card { display: block; }
  .grid-2 > .card > * + * { margin-top: 6pt; }
  .grid-2, .themes, .stats { gap: 8pt; }
  /* Grid cards split across pages in Chrome; stacked blocks don't */
  .grid-2, .themes { display: block; }
  .grid-2 > * + *, .themes > * + * { margin-top: 8pt; }
  .stats { grid-template-columns: repeat(4, 1fr); }
  .stat { padding: 8pt; gap: 2pt; }
  .stat-value { font-family: var(--font-body); font-size: 16pt; font-weight: 700; color: #111 !important; }
  .resource { padding: 4pt 6pt; }
  .numbered li { padding: 6pt 0 6pt 32pt; border-top: 0.5pt solid #ccc; break-inside: avoid; }
  .numbered li > span { top: 6pt; font-family: var(--font-body); font-size: 10.5pt; font-weight: 700; color: #111 !important; }
  .checks li::before { color: #111 !important; }
  .dots li::before { background: #111; }
  .competitor-body { display: grid; grid-template-columns: 150pt 1fr; gap: 12pt; border-color: #ccc; padding-top: 6pt; }
  .competitor-body.no-shot { grid-template-columns: 1fr; }
  .competitor-shot { border-color: #ccc; border-radius: 4pt; }
  .competitor { break-inside: avoid; }
  .website { display: block; border-top: 2pt solid #111 !important; break-inside: auto; }
  .website > * + * { margin-top: 8pt; }
  .website-top { display: grid; grid-template-columns: 190pt 1fr; gap: 12pt; border-color: #ccc; padding-top: 6pt; }
  .website-top.no-shot { grid-template-columns: 1fr; }
  .website-cols { display: grid; gap: 12pt; border-color: #ccc; padding-top: 6pt; }
  .wr-list { gap: 6pt; font-size: 10.5pt; }
  .wr-item { grid-template-columns: 12pt 1fr; gap: 6pt; break-inside: avoid; }
  .wr-icon { width: 12pt; height: 12pt; }
  .wr-icon circle { fill: #fff !important; stroke: #111; stroke-width: 1.5; }
  .wr-icon path { stroke: #111 !important; }
  .wr-vs { background: none; border: 0.5pt solid #999; color: #111 !important; }
  .competitor-cols { gap: 10pt; }
  .theme-added, .task-tag { background: none; border: 0.5pt solid #999; color: #111 !important; }
  .recurring li { padding: 4pt 0 4pt 20pt; border-color: #ccc; break-inside: avoid; }
  .recurring li::before { top: 4pt; }

  /* Action plan: each month starts its own box; long months may break between tasks */
  /* A4 is narrower than 900px, so undo the phone layout from the small-screen rules */
  .month { display: grid; grid-template-columns: 70pt 1fr; gap: 10pt; break-inside: auto; }
  .month-side { flex-direction: column; align-items: flex-start; gap: 2pt; }
  .month-label { font-size: 9pt; }
  .month-num { font-family: var(--font-body); font-size: 20pt; font-weight: 700; color: #111 !important; }
  .task { grid-template-columns: 16pt 1fr; gap: 6pt; padding: 6pt 0; border-color: #ccc; break-inside: avoid; }
  .task p, .checks, .dots { font-size: 10.5pt; }
  .task-num { width: auto; height: auto; background: none; font-family: var(--font-body); font-size: 10.5pt; font-weight: 700; display: block; }
  .task-note { background: none; border-left: 1.5pt solid #111; padding: 3pt 8pt; }
}
