/* Collect Earth site styles, matched to the Open Foris look (openforis.org):
   Poppins, slate headings, warm sand sections, satellite hero with a
   translucent rounded box and blue band, green 6px buttons, dark footer. */

:root {
  --of-blue: #4A9CD5;        /* Open Foris accent: hero band, active menu */
  --of-link: #0066CC;        /* links (Open Foris #006EDF, a touch darker for contrast on sand) */
  --of-link-hover: #0089F7;
  --of-green: #587F2E;       /* buttons (Open Foris #679436, darkened for AA contrast) */
  --of-green-dark: #476825;
  --heading: #161922;
  --text: #626262;
  --menu: #73748C;
  --muted: #666666;
  --sand: #EFECE6;
  --sand-dark: #E5DDC8;
  --line: #E2DDD3;
  --footer: #333333;
  --band: #666666;
  --soft: var(--sand);       /* kept for inline styles in the guides */
  --radius: 8px;
  --radius-lg: 16px;
  --max: 1180px;
  --font: "Poppins", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 96px; }
body { margin: 0; font: 400 15px/1.7 var(--font); color: var(--text); background: #fff; -webkit-font-smoothing: antialiased; }
a { color: var(--of-link); text-decoration: none; }
a:hover { color: var(--of-link-hover); text-decoration: underline; }
img { max-width: 100%; height: auto; }
strong { color: #3a3a3a; font-weight: 600; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .86em; background: var(--sand); color: #3a3a3a; padding: 2px 6px; border-radius: 4px; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

h1, h2, h3, h4 { color: var(--heading); font-family: var(--font); margin: 0 0 .45em; }
h1 { font-size: clamp(2.1rem, 4vw, 3.1rem); line-height: 1.2; font-weight: 500; }
h2 { font-size: clamp(1.8rem, 3.2vw, 2.5rem); line-height: 1.25; font-weight: 500; }
h3 { font-size: 1.3rem; line-height: 1.35; font-weight: 500; }
section { padding: 80px 0; }
section.soft { background: var(--sand); }
.lead { font-size: 1.07rem; color: var(--text); max-width: 760px; margin: 0; }

/* ---------- Header ---------- */
header.top { position: sticky; top: 0; z-index: 50; background: #fff; box-shadow: 0 2px 5px rgba(0,0,0,.08); }
header.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 84px; gap: 16px; position: relative; }
header.top .brand img { height: 56px; width: auto; display: block; }
nav { display: flex; align-items: center; }
nav a { padding: 8px 14px; color: var(--menu); font-size: 15px; font-weight: 500; border-radius: 4px; }
nav a:hover { color: var(--of-blue); text-decoration: none; }
nav a[aria-current="page"] { color: var(--of-blue); }
nav .btn { margin-left: 12px; padding: 9px 18px; font-size: 15px; }
nav .btn:hover { color: #fff; }
.menu-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; color: var(--of-blue); }
.menu-toggle svg { display: block; }

@media (max-width: 1040px) {
  .js .menu-toggle { display: block; }
  .js header.top nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; background: #fff; padding: 8px 16px 18px; box-shadow: 0 10px 20px rgba(1,7,39,.08); }
  .js header.top.open nav { display: flex; }
  .js header.top nav a { padding: 12px 10px; border-bottom: 1px solid #F2F2F2; }
  .js header.top nav .btn { margin: 14px 0 0; justify-content: center; border-bottom: 0; }
  html:not(.js) nav { flex-wrap: wrap; justify-content: flex-end; }
}

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 22px; border-radius: 6px; font: 400 16px/1.2 var(--font); text-decoration: none; border: 0; cursor: pointer; transition: background-color .15s, color .15s, box-shadow .15s; }
.btn:hover { text-decoration: none; }
.btn.green, .btn.primary { background: var(--of-green); color: #fff; }
.btn.green:hover, .btn.primary:hover { background: var(--of-green-dark); color: #fff; }
.btn.dark { background: #444; color: #fff; border-radius: 8px; }
.btn.dark:hover { background: #222; color: #fff; }
.btn.ghost { background: transparent; color: var(--heading); box-shadow: inset 0 0 0 1.5px var(--heading); }
.btn.ghost:hover { background: var(--heading); color: #fff; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.arrow-link { font-weight: 500; }

/* ---------- Hero: satellite imagery, translucent box, blue band ---------- */
.hero { background: #23463a url("img/hero.jpg") 22% 45% / cover no-repeat; border-bottom: 8px solid var(--of-blue); padding: 72px 0; min-height: 540px; display: flex; align-items: center; }
.hero .wrap { width: 100%; display: flex; justify-content: flex-end; }
.hero .box { background: rgba(255,255,255,.88); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); border-radius: var(--radius-lg); padding: 36px 40px; max-width: 610px; }
.hero .eyebrow { display: flex; align-items: center; gap: 12px; margin: 0 0 14px; font-size: 1.15rem; font-weight: 500; color: var(--heading); }
.hero .eyebrow img { width: 40px; height: 40px; }
.hero h1 { font-size: clamp(1.8rem, 3vw, 2.25rem); margin: 0 0 .45em; }
.hero p { font-size: 1.05rem; color: #4a4a4a; margin: 0 0 1.5em; }
.hero .meta { font-size: .9rem; color: #555; margin: 18px 0 0; }
@media (max-width: 820px) {
  .hero { min-height: 0; padding: 120px 0 40px; background-position: 26% 30%; }
  .hero .box { padding: 26px 24px; }
}

/* ---------- Intro (emblem beside text, as on the Open Foris product pages) ---------- */
.intro { display: grid; grid-template-columns: 220px 1fr; gap: 56px; align-items: start; }
.intro .emblem { width: 220px; height: auto; }
@media (max-width: 820px) { .intro { grid-template-columns: 1fr; gap: 24px; } .intro .emblem { width: 120px; } }

/* ---------- Grids and cards ---------- */
.grid { display: grid; gap: 24px; }
.g3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.g4 { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.card { background: var(--sand); border-radius: var(--radius); padding: 30px 28px; position: relative; }
section.soft .card { background: #fff; border-radius: 12px; }
.card h3 { font-size: 1.2rem; margin-bottom: .45em; }
.card p { margin: 0; color: var(--text); font-size: .95rem; }
.card .num { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; background: var(--of-blue); color: #fff; font-weight: 600; margin-bottom: 14px; }
.card.featured { box-shadow: inset 0 0 0 2px var(--of-blue); }
.tag { display: inline-block; font-size: .75rem; font-weight: 600; letter-spacing: .02em; padding: 3px 12px; border-radius: 999px; background: var(--of-blue); color: #fff; position: absolute; top: -12px; right: 20px; }

/* Check-circle list, like the Key Features list on openforis.org */
ul.ticks { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px 32px; }
ul.ticks li { padding-left: 36px; position: relative; }
ul.ticks li::before { content: ""; position: absolute; left: 0; top: .1em; width: 24px; height: 24px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23587F2E' d='M10.6 16.6l7.05-7.05-1.4-1.4-5.65 5.65-2.85-2.85-1.4 1.4 4.25 4.25zM12 22a9.74 9.74 0 0 1-3.9-.79 10.1 10.1 0 0 1-3.17-2.13A10.1 10.1 0 0 1 2.79 15.9 9.74 9.74 0 0 1 2 12c0-1.38.26-2.68.79-3.9a10.1 10.1 0 0 1 2.13-3.17A10.1 10.1 0 0 1 8.1 2.79 9.74 9.74 0 0 1 12 2c1.38 0 2.68.26 3.9.79a10.1 10.1 0 0 1 3.17 2.13 10.1 10.1 0 0 1 2.14 3.18c.53 1.22.79 2.52.79 3.9s-.26 2.68-.79 3.9a10.1 10.1 0 0 1-2.13 3.17 10.1 10.1 0 0 1-3.18 2.14A9.74 9.74 0 0 1 12 22z'/%3E%3C/svg%3E") no-repeat center / contain; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; margin-top: 32px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); }
table { border-collapse: collapse; width: 100%; min-width: 760px; font-size: .93rem; }
th, td { text-align: left; padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { background: var(--sand-dark); color: var(--heading); font-weight: 500; }
tbody th { color: var(--heading); font-weight: 500; width: 17%; }
tbody tr:nth-child(even) td, tbody tr:nth-child(even) th { background: #FAF8F5; }
tr:last-child td, tr:last-child th { border-bottom: 0; }

/* ---------- Layout helpers ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; } }
ol.steps { padding-left: 1.3em; margin: 0; }
ol.steps li { margin-bottom: .65em; padding-left: .2em; }
ol.steps li::marker { color: var(--of-blue); font-weight: 600; }

/* Guide cards: name, tagline and an arrow link, like the Open Foris portfolio */
.docs .grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.docs a.card { display: flex; flex-direction: column; text-decoration: none; color: inherit; transition: transform .15s, box-shadow .15s; }
.docs a.card::after { content: "→ Read the guide"; margin-top: auto; padding-top: 16px; color: var(--of-link); font-weight: 500; font-size: .93rem; }
.docs a.card:hover { transform: translateY(-3px); box-shadow: 0 8px 16px rgba(0,0,0,.08); }
.docs a.card:hover h3 { color: var(--of-link); }

/* Closing band, like the Resources band on the Open Foris product pages */
.cta { background: var(--band); color: #fff; text-align: center; }
.cta h2 { color: #fff; }
.cta p { color: #F1F1F1; margin: 0 auto 1.6em; max-width: 640px; }
.cta .actions { justify-content: center; }
.cta .btn.ghost { color: #fff; box-shadow: inset 0 0 0 1.5px #fff; }
.cta .btn.ghost:hover { background: #fff; color: var(--heading); }

/* ---------- Footer ---------- */
footer { background: var(--footer); color: #BABABA; padding: 48px 0 40px; font-size: .93rem; }
footer .wrap { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 32px; align-items: start; }
footer img { height: 60px; width: auto; display: block; margin-bottom: 16px; }
footer p { margin: 0 0 12px; max-width: 360px; }
footer h4 { color: #fff; font-size: 1rem; font-weight: 500; margin: 6px 0 12px; }
footer .links a { display: block; color: #D1D1D1; font-weight: 500; padding: 3px 0; }
footer .links a:hover { color: #fff; }
footer .btn.dark { margin-top: 6px; }
@media (max-width: 820px) { footer .wrap { grid-template-columns: 1fr; } }

/* ---------- Guide pages ---------- */
.page-title { background: #23463a url("img/band.jpg") center / cover no-repeat; border-bottom: 8px solid var(--of-blue); padding: 56px 24px; }
.page-title .box { max-width: 820px; margin: 0 auto; background: rgba(255,255,255,.9); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); border-radius: var(--radius-lg); padding: 30px 36px; }
.page-title h1 { font-size: clamp(1.9rem, 3.6vw, 2.6rem); margin: .15em 0 .35em; }
.page-title .lead { color: #4a4a4a; }
.crumb { font-size: .88rem; color: rgba(22,25,34,.6); margin: 0; }
.crumb a { color: rgba(22,25,34,.6); }
.crumb a:hover { color: var(--of-link); }

.doc { max-width: 820px; margin: 0 auto; padding: 40px 24px 88px; font-size: 15.5px; }
.doc h2 { font-size: 1.75rem; margin: 2em 0 .55em; padding-top: 1em; border-top: 1px solid var(--line); }
.doc h3 { font-size: 1.2rem; margin: 1.7em 0 .45em; }
.doc li { margin-bottom: .35em; }
.doc figure { margin: 28px 0; }
.doc figure img { display: block; width: 100%; border-radius: var(--radius); border: 1px solid var(--line); box-shadow: 0 8px 16px rgba(0,0,0,.07); }
.doc figcaption { font-size: .86rem; color: var(--muted); margin-top: 10px; text-align: center; }
.doc figure.narrow { max-width: 560px; margin-left: auto; margin-right: auto; }
.doc .note { background: var(--sand); border-left: 4px solid var(--of-blue); padding: 16px 20px; border-radius: 0 var(--radius) var(--radius) 0; margin: 22px 0; }
.doc .toc { background: var(--sand); border-radius: var(--radius); padding: 20px 26px; margin: 8px 0 28px; }
.doc .toc strong { color: var(--heading); font-weight: 500; }
.doc .toc ol { margin: 8px 0 0; padding-left: 1.3em; columns: 2; column-gap: 32px; }
.doc .toc li { margin-bottom: .2em; break-inside: avoid; }
@media (max-width: 640px) { .doc .toc ol { columns: 1; } }
.doc table { min-width: 0; }
.doc .table-wrap { margin: 24px 0; }
.doc .table-wrap table { min-width: 560px; }
.doc kbd { font-family: var(--font); font-size: .85em; font-weight: 500; color: var(--heading); background: #fff; border: 1px solid #CFC8BA; border-bottom-width: 2px; border-radius: 4px; padding: 1px 6px; }
.doc .ui { font-weight: 500; color: var(--heading); }
.doc pre { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.doc .next { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 56px; }
.doc .next a { background: var(--sand); border-radius: var(--radius); padding: 18px 22px; font-weight: 500; transition: background-color .15s; }
.doc .next a:last-child { text-align: right; grid-column: 2; }
.doc .next a:hover { background: var(--sand-dark); text-decoration: none; }
@media (max-width: 640px) { .doc .next { grid-template-columns: 1fr; } .doc .next a:last-child { grid-column: 1; } }

/* Screenshots */
figure.shot { margin: 40px 0 0; }
figure.shot img { display: block; width: 100%; border-radius: var(--radius); box-shadow: 0 8px 16px rgba(0,0,0,.10); }
figure.shot figcaption { font-size: .9rem; color: var(--muted); margin-top: 10px; text-align: center; }
.gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 0 28px; margin-top: 24px; }
.gallery figure.shot { margin-top: 28px; }

:focus-visible { outline: 3px solid var(--of-blue); outline-offset: 2px; border-radius: 4px; }

/* ---------- Your data, under your control (home) ---------- */
.data-band { background: #23463a; color: #DCE6E0; }
.data-band h2 { color: #fff; }
.data-band .lead { color: #DCE6E0; }
.pillars { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; margin-top: 40px; }
.pillar { background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.12); border-radius: 12px; padding: 26px 26px 24px; }
.pillar .icon { width: 44px; height: 44px; padding: 10px; border-radius: 50%; background: var(--of-blue); stroke: #fff; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 14px; display: block; }
.pillar h3 { color: #fff; font-size: 1.15rem; margin-bottom: .4em; }
.pillar p { margin: 0; font-size: .95rem; color: #D2DED7; }
.band-link { margin: 32px 0 0; }
.data-band a { color: #BFE0F7; font-weight: 500; }
.data-band a:hover { color: #fff; }

/* ---------- Find your set-up ---------- */
.decide { display: none; background: var(--sand); border-radius: 12px; padding: 30px 32px; margin-top: 32px; max-width: 860px; }
.decide.ready { display: block; }
.decide.ready + .decide-static { display: none; }
.decide-static { margin: 24px 0 0; padding-left: 1.2em; }
.decide-step h3 { font-size: 1.3rem; margin-bottom: .5em; outline: none; }
.decide .hint { margin: -4px 0 16px; font-size: .92rem; color: var(--muted); }
.choices { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 14px; }
.choice { font: 500 15px/1.3 var(--font); color: var(--heading); background: #fff; border: 1.5px solid #CFC8BA; border-radius: 8px; padding: 13px 20px; cursor: pointer; transition: border-color .15s, color .15s, box-shadow .15s; }
.choice:hover { border-color: var(--of-blue); color: var(--of-link); box-shadow: 0 4px 10px rgba(0,0,0,.06); }
.decide-trail { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.decide-trail .chip { font-size: .8rem; font-weight: 500; color: #476825; background: #E3ECD8; border-radius: 999px; padding: 3px 12px; }
.decide .result { background: #fff; border-radius: 10px; border-left: 6px solid var(--of-green); padding: 24px 26px; }
.decide .result h3 { font-size: 1.45rem; margin: 0 0 .4em; }
.decide .result p { margin: 0 0 .8em; }
.result-kicker { font-size: .78rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--of-green); margin: 0 0 4px !important; }
.decide .result .actions { margin-top: 18px; }
.decide .result .btn.ghost { font-size: 15px; }
.where { font-size: .92rem; }
.where strong { color: var(--heading); font-weight: 500; }
.card .where { margin-top: 12px; padding-top: 12px; border-top: 1px solid rgba(0,0,0,.08); color: #555; font-size: .88rem; }
.card .more { display: inline-block; margin-top: 12px; font-weight: 500; font-size: .93rem; }
.doc .decide { margin: 18px 0 8px; }
.doc .decide-static { margin-top: 12px; }

/* ---------- Workflow pages ---------- */
.best { background: #F6F4EF; border-radius: var(--radius); padding: 12px 18px; }
ul.ticks.one { grid-template-columns: 1fr; gap: 14px; margin: 18px 0 8px; }
ol.flow { list-style: none; display: flex; align-items: stretch; gap: 0; padding: 0; margin: 22px 0 24px; }
ol.flow li { flex: 1; background: #fff; border: 1.5px solid #D9D3C7; border-radius: 10px; padding: 14px 16px; font-size: .9rem; line-height: 1.45; position: relative; }
ol.flow li span { display: block; font-weight: 600; color: var(--heading); font-size: .82rem; letter-spacing: .03em; text-transform: uppercase; margin-bottom: 4px; }
ol.flow li.store { border-color: var(--of-blue); background: #F1F7FC; }
ol.flow li + li { margin-left: 34px; }
ol.flow li + li::before { content: "→"; position: absolute; left: -28px; top: 50%; transform: translateY(-50%); color: var(--of-blue); font-size: 1.3rem; font-weight: 600; }
@media (max-width: 640px) {
  ol.flow { flex-direction: column; }
  ol.flow li + li { margin: 30px 0 0; }
  ol.flow li + li::before { content: "↓"; left: 50%; top: -26px; transform: translateX(-50%); }
}
#setups .g4 .card { display: flex; flex-direction: column; }
#setups .g4 .card .where { margin-top: auto; }
#setups .g4 .card > p:not(.where) { margin-bottom: 14px; }

/* ---------- Costs and commands (own-server guide) ---------- */
.cost-box { display: flex; align-items: center; gap: 28px; background: #23463a; color: #DCE6E0; border-radius: 12px; padding: 24px 28px; margin: 24px 0 8px; }
.cost-box p { margin: 0; font-size: .95rem; }
.cost-box code { background: rgba(255,255,255,.12); color: #fff; }
.cost-figure { flex: none; color: #fff; font-size: 2.6rem; font-weight: 600; line-height: 1; text-align: center; }
.cost-figure span, .cost-figure small { display: block; font-size: .8rem; font-weight: 400; color: #BFD3C8; letter-spacing: .04em; }
.cost-figure span { margin-bottom: 6px; text-transform: uppercase; }
.cost-figure small { margin-top: 6px; }
@media (max-width: 640px) { .cost-box { flex-direction: column; align-items: flex-start; } .cost-figure { text-align: left; } }
table.costs.num td:last-child, table.costs.num th:last-child { white-space: nowrap; }
table.costs code { white-space: nowrap; }
table.costs.regions td:first-child { min-width: 210px; }
table.costs tbody td:not(:first-child) { font-variant-numeric: tabular-nums; }
table.costs tr.total td { background: var(--sand) !important; color: var(--heading); }
.th-note { font-size: .78rem; font-weight: 400; color: #5a5a5a; }
.th-note code { font-size: .95em; }
.doc p.small { font-size: .88rem; color: var(--muted); margin-top: 10px; }
details.assumptions { background: #F6F4EF; border-radius: var(--radius); padding: 14px 20px; margin: 24px 0; font-size: .92rem; }
details.assumptions summary { cursor: pointer; font-weight: 500; color: var(--heading); }
details.assumptions p { margin: 12px 0 0; }
.doc pre.cmd { background: #1E2B26; color: #E4EEE8; border-radius: 8px; padding: 14px 18px; margin: 10px 0 14px; overflow-x: auto; font-size: .84rem; line-height: 1.55; }
.doc pre.cmd code { background: none; color: inherit; padding: 0; font-size: 1em; }
.cta-line { margin: 18px 0 22px; }
footer .fineprint { margin: 18px 0 0; font-size: .8rem; color: #9A9A9A; max-width: 380px; }
footer .fineprint a { color: #BABABA; text-decoration: underline; }
