/* ─── Fonts: Inter, hosted on this site (no Google Fonts), SIL Open Font License ─── */
@font-face { font-family: 'Inter'; font-weight: 400; font-style: normal; font-display: swap; src: url('/fonts/inter-400.woff') format('woff'); }
@font-face { font-family: 'Inter'; font-weight: 500; font-style: normal; font-display: swap; src: url('/fonts/inter-500.woff') format('woff'); }
@font-face { font-family: 'Inter'; font-weight: 600; font-style: normal; font-display: swap; src: url('/fonts/inter-600.woff') format('woff'); }
@font-face { font-family: 'Inter Display'; font-weight: 600; font-style: normal; font-display: swap; src: url('/fonts/inter-display-600.woff') format('woff'); }
@font-face { font-family: 'Inter Display'; font-weight: 700; font-style: normal; font-display: swap; src: url('/fonts/inter-display-700.woff') format('woff'); }

/* ─── Brand colours: change these to restyle the whole site ─── */
:root {
  --brand: #1F5F4A;
  --brand-dark: #163F32;
  --brand-tint: #E7F2EC;
  --brand-tint-border: #BFDACC;
  --accent: #F2B35C;
  --ink: #1C2321;
  --ink-2: #3F4744;
  --muted: #4F5754;
  --ground: #F7F6F2;
  --card: #FFFFFF;
  --line: #E3E1DA;
  --line-2: #ECEAE3;
  --warn-bg: #FFF6E8;
  --warn-border: #F0D5A8;
  --warn-ink: #7A4A08;
  --bad-bg: #FBEAE5;
  --bad-ink: #8F2F17;
  --radius: 14px;
  --font-display: 'Inter Display', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ground); color: var(--ink); font-family: var(--font-body); font-size: 16px; line-height: 1.55; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.15; letter-spacing: -0.01em; margin: 0 0 12px; }
h1 { font-size: clamp(30px, 5vw, 44px); }
h2, .h2 { font-size: clamp(22px, 3vw, 28px); }
h3, .h3 { font-size: 20px; }
.h4 { font-size: 17px; margin: 14px 0 4px; }
p { margin: 0 0 12px; }
a { color: var(--brand); }
a:hover { color: var(--brand-dark); }
ul { margin: 0 0 12px; padding-left: 20px; }
li { margin-bottom: 4px; }

.wrap { max-width: 1080px; margin: 0 auto; padding-left: 20px; padding-right: 20px; }
.narrow { max-width: 640px; }
.pad { padding-top: 40px; padding-bottom: 64px; }
.center { text-align: center; }
.stack { display: flex; flex-direction: column; gap: 24px; }
.grow { flex: 1 1 360px; min-width: 0; }
.mt { margin-top: 16px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.strong { font-weight: 600; }
.optional { font-weight: 400; color: var(--muted); }
.brand-color { color: var(--brand); }
.warn-text { color: var(--warn-ink); }
.lead-dark { font-size: 18px; color: var(--ink-2); }

/* Header */
.demo-banner { background: #2B2B2B; color: #FFF; text-align: center; font-size: 14px; padding: 6px 16px; }
.site-header { background: var(--card); border-bottom: 1px solid var(--line); }
.header-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding-top: 14px; padding-bottom: 14px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-family: var(--font-display); font-weight: 700; font-size: 21px; }
.brand svg { color: var(--brand); }
.nav { display: flex; gap: 20px; font-size: 15px; font-weight: 500; }
.nav a { color: var(--ink-2); text-decoration: none; }
.nav a:hover { color: var(--brand); text-decoration: underline; }
.progress { padding-bottom: 14px; }
.progress-row { font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.progress-bar { height: 6px; background: #E9E7E0; border-radius: 999px; overflow: hidden; }
.progress-bar > div { height: 6px; background: var(--brand); border-radius: 999px; }

/* Hero */
.hero { background: var(--brand); color: #FFF; }
.hero-inner { padding-top: 64px; padding-bottom: 72px; }
.hero h1 { font-size: clamp(36px, 6vw, 62px); line-height: 1.05; letter-spacing: -0.02em; max-width: 780px; margin-bottom: 18px; }
.eyebrow { font-size: 14px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: #CFE5DB; }
.lead { font-size: 19px; max-width: 620px; color: #E4F1EB; }
.hero-note { font-size: 14px; color: #CFE5DB; margin-top: 12px; }
.check-form { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; max-width: 760px; margin-top: 24px; }
.check-form .field { flex: 1 1 160px; }
.check-form .field.grow { flex: 2 1 240px; }
.check-form label { color: #E4F1EB; }
.check-form .optional { color: #CFE5DB; }
.check-form input { border: 0; height: 56px; font-size: 17px; }
.check-form .btn { flex: 0 0 auto; }
.hero .form-error { color: #FFFFFF; background: #8F2F17; display: inline-block; padding: 6px 12px; border-radius: 8px; margin-top: 12px; }

/* Forms */
.field { display: flex; flex-direction: column; gap: 6px; }
label { font-weight: 600; font-size: 15px; }
input[type=text], input[type=email], input[type=tel], input:not([type]), select, textarea {
  width: 100%; height: 48px; padding: 0 14px; border: 1px solid #B9B6AC; border-radius: 8px;
  font: inherit; font-size: 16px; color: var(--ink); background: #FFF;
}
textarea { height: auto; padding: 12px 14px; }
input:focus-visible, select:focus-visible, textarea:focus-visible, .btn:focus-visible, a:focus-visible {
  outline: 3px solid var(--accent); outline-offset: 2px;
}
[aria-invalid=true] { border-color: var(--bad-ink) !important; }
.form-error { color: var(--bad-ink); font-size: 14px; font-weight: 600; margin: 0; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 14px; color: var(--ink-2); }
.consent input { width: 20px; height: 20px; margin: 2px 0 0; flex: 0 0 auto; }
.consent-dark { color: #DADFDC; max-width: 320px; }
.consent-dark a { color: #FFF; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 24px; border-radius: 10px; border: 0; font-family: var(--font-display); font-weight: 700; font-size: 16px; text-decoration: none; cursor: pointer; }
.btn-lg { min-height: 56px; padding: 0 28px; font-size: 17px; }
.btn-primary { background: var(--brand); color: #FFF; }
.btn-primary:hover { background: var(--brand-dark); color: #FFF; }
.btn-accent { background: var(--accent); color: var(--ink); }
.btn-accent:hover { background: #E9A243; color: var(--ink); }
.btn-outline { background: #FFF; color: var(--brand); border: 1px solid var(--brand); }

/* Cards */
.cards { display: flex; flex-wrap: wrap; gap: 20px; }
.cards > .card { flex: 1 1 280px; }
.cards-tight { gap: 14px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card .num { font-family: var(--font-display); font-weight: 700; font-size: 28px; color: var(--brand); margin-bottom: 6px; }
.card-tip { background: var(--warn-bg); border-color: var(--warn-border); }
.check { display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; }
.check-found { border-color: var(--warn-border); background: var(--warn-bg); }
.check-label { font-size: 14px; color: var(--muted); margin: 0; }
.check-value { font-weight: 600; margin: 0; }
.check-names { font-size: 14px; color: var(--ink-2); margin: 4px 0 0; }
.icon { flex: 0 0 auto; margin-top: 2px; }
.icon-ok { color: #1F7A55; }
.icon-warn { color: #A35A00; }
.icon-unknown { color: var(--muted); }

/* Notices */
.notice { display: flex; gap: 14px; align-items: flex-start; border-radius: var(--radius); padding: 20px 24px; border: 1px solid; }
.notice h2, .notice h3 { font-size: 20px; margin-bottom: 4px; }
.notice p:last-child, .notice ul:last-child { margin-bottom: 0; }
.notice-ok { background: var(--brand-tint); border-color: var(--brand-tint-border); }
.notice-warn { background: var(--warn-bg); border-color: var(--warn-border); }

/* Lists and tables */
.h-place { font-size: clamp(26px, 4vw, 38px); margin-bottom: 6px; }
.list-box, .table-box { background: var(--card); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.table-box { overflow-x: auto; }
.list-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; padding: 16px 18px; border-bottom: 1px solid var(--line-2); }
.list-row:last-child { border-bottom: 0; }
.locked { justify-content: flex-start; color: var(--muted); background: #FAF9F6; }
table { width: 100%; min-width: 720px; border-collapse: collapse; font-size: 15px; }
th { text-align: left; background: #F2F1EC; padding: 12px 16px; font-weight: 600; }
td { padding: 12px 16px; border-top: 1px solid var(--line-2); vertical-align: top; }
.badge { display: inline-block; font-weight: 600; font-size: 14px; padding: 2px 10px; border-radius: 999px; white-space: nowrap; }
.badge-approved { background: var(--brand-tint); color: #165C40; }
.badge-refused { background: var(--bad-bg); color: var(--bad-ink); }
.badge-withdrawn, .badge-pending, .badge-referred, .badge-other { background: #EEEDE8; color: #474D4A; }
.rate { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
.rate-bar { width: 80px; height: 8px; background: #E9E7E0; border-radius: 999px; overflow: hidden; display: inline-block; }
.rate-bar > span { display: block; height: 8px; background: var(--brand); }
.costs { margin: 0; }
.costs dt { font-weight: 600; margin-top: 10px; }
.costs dd { margin: 0; color: var(--ink-2); }
.costs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 4px 28px; }

/* Calls to action */
.cta-dark, .cta-brand { border-radius: 16px; padding: 28px; display: flex; flex-wrap: wrap; gap: 24px; align-items: center; justify-content: space-between; }
.cta-dark { background: var(--ink); color: #FFF; }
.cta-dark ul { color: #DADFDC; }
.cta-brand { background: var(--brand); color: #FFF; }
.cta-brand p { color: #E4F1EB; margin: 0; }
.cta-buy { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.price { font-family: var(--font-display); font-size: 40px; font-weight: 700; line-height: 1; margin: 0; }
.cta-buy .small { color: #C2C9C5; margin: 0; }
.report-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 16px; }

/* Long text pages */
.prose h2 { font-size: 22px; margin-top: 28px; }

/* Footer */
.site-footer { background: var(--card); border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.site-footer .wrap { padding-top: 24px; padding-bottom: 24px; }
.site-footer p { margin: 0 0 6px; }

/* Printing / Save as PDF */
@media print {
  .no-print, .site-header nav, .progress, .demo-banner, .site-footer .wrap p:nth-child(2) { display: none !important; }
  body { background: #FFF; font-size: 12pt; }
  .card, .notice, .table-box { break-inside: avoid; }
  table { min-width: 0; }
}
.cards-2 > .card { flex: 1 1 420px; }

/* Homepage trust sections */
.trust-strip { background: var(--brand-dark); color: #E4F1EB; font-size: 14px; }
.trust-row { display: flex; flex-wrap: wrap; gap: 8px 28px; padding-top: 12px; padding-bottom: 12px; }
.trust-row span { display: inline-flex; align-items: center; gap: 8px; }
.trust-row svg { color: var(--accent); flex: 0 0 auto; }
.band { background: #EFEDE6; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.stats > div { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 24px; }
.stats p { margin: 0; }
.stat { font-family: var(--font-display); font-size: 36px; font-weight: 700; color: var(--brand); line-height: 1.1; }
.price-sm { font-family: var(--font-display); font-size: 30px; font-weight: 700; margin: 0 0 12px; }
.ticks { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.ticks li { display: flex; gap: 10px; align-items: flex-start; margin: 0; }
.ticks svg { color: var(--brand); flex: 0 0 auto; margin-top: 4px; }
.card-feature { border: 2px solid var(--brand); }
.sample { position: relative; background: var(--card); border: 1px dashed #A8A498; border-radius: var(--radius); padding: 24px; }
.sample-tag { position: absolute; top: -12px; right: 20px; margin: 0; background: var(--accent); color: var(--ink); font-weight: 700; font-size: 13px; padding: 2px 12px; border-radius: 999px; }
.about { max-width: 760px; }
.about p { font-size: 17px; color: var(--ink-2); }
.faq { display: flex; flex-direction: column; gap: 10px; max-width: 820px; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 0 20px; }
.faq summary { cursor: pointer; font-weight: 600; padding: 16px 0; list-style-position: outside; }
.faq summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.faq details p { margin: 0 0 16px; color: var(--ink-2); }
.pro-grid .card h3 { margin-top: 0; }
@media print { .trust-strip { display: none; } }

/* Ask Plotwise chat */
.chat-launch { position: fixed; right: 20px; bottom: 20px; z-index: 50; display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 18px; border: 0; border-radius: 999px; background: var(--brand); color: #FFF; font-family: var(--font-display); font-weight: 700; font-size: 15px; cursor: pointer; box-shadow: 0 6px 20px rgba(0,0,0,0.18); }
.chat-launch:hover { background: var(--brand-dark); }
.chat-launch:focus-visible, .chat-close:focus-visible, .chat-chip:focus-visible, .chat-send:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.chat-panel { position: fixed; right: 20px; bottom: 80px; z-index: 50; width: min(380px, calc(100vw - 32px)); height: min(560px, calc(100vh - 110px)); display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 12px 40px rgba(0,0,0,0.22); overflow: hidden; }
.chat-panel[hidden] { display: none; }
.chat-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 14px 16px; background: var(--brand); color: #FFF; }
.chat-title { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: 17px; }
.chat-sub { margin: 0; font-size: 12px; color: #CFE5DB; }
.chat-close { background: none; border: 0; color: #FFF; font-size: 26px; line-height: 1; cursor: pointer; width: 36px; height: 36px; border-radius: 8px; }
.chat-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; background: var(--ground); }
.chat-msg { max-width: 88%; padding: 10px 12px; border-radius: 12px; font-size: 15px; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.chat-bot { align-self: flex-start; background: var(--card); border: 1px solid var(--line); }
.chat-user { align-self: flex-end; background: var(--brand-tint); border: 1px solid var(--brand-tint-border); }
.chat-error { align-self: flex-start; background: var(--warn-bg); border: 1px solid var(--warn-border); }
.chat-thinking { color: var(--muted); font-style: italic; }
.chat-chips { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.chat-chip { border: 1px solid var(--brand); background: #FFF; color: var(--brand); border-radius: 999px; padding: 6px 12px; font: inherit; font-size: 14px; cursor: pointer; text-align: left; }
.chat-form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); background: var(--card); }
.chat-form textarea { flex: 1; min-width: 0; height: auto; resize: none; font-size: 15px; padding: 8px 10px; }
.chat-send { min-height: 44px; padding: 0 16px; }
@media print { .chat-launch, .chat-panel { display: none !important; } }
