/* LankaVerse: white and Kandy Lake blue, with flat Kandy touches: cut-out leaves in the hero, the cloud wall across the middle, and small
   stepped diamonds from Dumbara weaving. Patterns are SVG files in web/ (tools/pattern). */
@font-face { font-family: "Bricolage"; src: url(/assets/bricolage.woff2) format("woff2"); font-weight: 500 800; font-display: swap; }
@font-face { font-family: "Inter"; src: url(/assets/inter.woff2) format("woff2"); font-weight: 400 600; font-display: swap; }

:root {
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-2: #fbf8f3;
  --ink: #1a1714;
  --ink-2: #4f4a43;
  --ink-3: #857d72;
  --line: #ebe3d7;
  --accent: #1c64a8;
  --accent-ink: #ffffff;
  --gold: #4aa6a0;
  --teal: #0f4778;
  --shadow: 0 1px 2px rgb(40 30 10 / .05), 0 10px 30px rgb(40 30 10 / .06);
  --radius: 12px;
  --display: "Bricolage", ui-sans-serif, system-ui, sans-serif;
  --body: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.6 var(--body); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: var(--teal); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--display); line-height: 1.08; letter-spacing: -0.02em; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(2.4rem, 7vw, 4.6rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.2rem); font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }

.wrap { width: min(1180px, 100% - 32px); margin-inline: auto; }
.wrap-narrow { width: min(760px, 100% - 32px); margin-inline: auto; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 12px; background: var(--surface); padding: 8px 12px; z-index: 10; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* header */
.top { border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 5; }
.top-in { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font: 800 1.35rem var(--display); letter-spacing: -0.02em; }
.mark { width: 38px; height: 38px; border-radius: 10px; }
.top nav { display: flex; gap: 4px; }
.top nav a { color: var(--ink-2); text-decoration: none; font-weight: 500; padding: 8px 12px; border-radius: 8px; }
.top nav a:hover { background: var(--surface); color: var(--ink); }
.top nav a[aria-current] { color: var(--ink); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }

/* shared bits */
.kicker { font: 600 .78rem/1.2 var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; }
.lede { font-size: 1.2rem; color: var(--ink-2); max-width: 62ch; }
.btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 20px; border-radius: 999px; border: 1px solid var(--accent); background: var(--accent); color: var(--accent-ink); font: 600 .98rem var(--body); text-decoration: none; cursor: pointer; transition: background-color .15s, color .15s, border-color .15s; }
.btn:hover { color: var(--accent-ink); filter: brightness(1.06); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { color: var(--ink); background: var(--surface); filter: none; }
.btn-small { min-height: 36px; padding: 0 14px; font-size: .9rem; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.head-row { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.head-row h1, .head-row h2 { margin-bottom: .4em; }
.block { margin-top: clamp(56px, 9vw, 104px); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px; }
.tags a { font-size: .85rem; padding: 4px 12px; border-radius: 999px; border: 1px solid var(--line); color: var(--ink-2); text-decoration: none; }
.tags a[aria-current], .tags a:hover { border-color: var(--ink); color: var(--ink); }
.draft { font-size: .75rem; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--accent); }

/* home */
.hero { padding-top: clamp(48px, 9vw, 104px); }
.hero h1 { max-width: 14ch; }
.hero-shot { margin-top: clamp(36px, 6vw, 64px); }
.hero-shot img { width: 100%; aspect-ratio: 2 / 1; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); }
.hero-shot figcaption, figcaption { font-size: .86rem; color: var(--ink-3); margin-top: 10px; }
.three { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.point { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.point p { color: var(--ink-2); margin: 0; }
.stand { display: grid; grid-template-columns: 1.1fr 1fr; gap: 20px; align-items: start; }
.stats { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.stats li { background: var(--surface); padding: 22px 24px; }
.stats strong { display: block; font: 800 clamp(1.8rem, 4vw, 2.5rem)/1 var(--display); letter-spacing: -0.03em; margin-bottom: 6px; }
.stats span { color: var(--ink-2); font-size: .92rem; }
.now { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.now ol { margin: 0; padding-left: 1.3em; }
.now li { padding: 4px 0; color: var(--ink-2); }
.now li.done { color: var(--ink-3); text-decoration: line-through; text-decoration-thickness: 1px; }
.strip { display: flex; gap: 12px; overflow-x: auto; padding: 4px 16px 12px; scroll-snap-type: x mandatory; scrollbar-width: thin; }
.strip a { flex: 0 0 auto; scroll-snap-align: start; }
.strip img { height: 200px; width: auto; aspect-ratio: 2 / 1; object-fit: cover; border-radius: 10px; }
@media (min-width: 1212px) { .strip { padding-inline: calc((100% - 1180px) / 2); } }

/* cards */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: border-color .15s, transform .15s; }
.card:hover { border-color: var(--ink-3); transform: translateY(-2px); }
.card-link { display: block; color: inherit; text-decoration: none; height: 100%; }
.card-link:hover { color: inherit; }
.card img, .card-blank { width: 100%; aspect-ratio: 2 / 1; object-fit: cover; background: var(--line); }
.card-text { padding: 18px 20px 20px; }
.card-text p { color: var(--ink-2); font-size: .95rem; margin: 0; }
.card-text .meta { font-size: .82rem; color: var(--ink-3); margin-bottom: 8px; }
.day { color: var(--accent); font-weight: 600; }

/* blog list */
.page-head { padding-top: clamp(40px, 7vw, 80px); padding-bottom: 12px; }
.timeline { margin-top: 32px; }
.tl-day { display: grid; grid-template-columns: 160px 1fr; gap: 24px; padding: 28px 0; border-top: 1px solid var(--line); }
.tl-label span { display: block; font: 800 1.6rem/1 var(--display); letter-spacing: -0.02em; }
.tl-label time { font-size: .88rem; color: var(--ink-3); }
.tl-posts { display: grid; gap: 16px; }
.tl-posts .card-link { display: grid; grid-template-columns: 280px 1fr; }
.tl-posts .card img, .tl-posts .card-blank { height: 100%; min-height: 140px; aspect-ratio: auto; }

/* post */
.post { padding-top: clamp(40px, 7vw, 80px); }
.post-head { margin-bottom: 32px; }
.post-head h1 { font-size: clamp(2.1rem, 5.6vw, 3.4rem); }
.post-head .meta { color: var(--ink-3); }
.prose { font-size: 1.08rem; }
.prose h2 { font-size: 1.6rem; margin-top: 1.8em; }
.prose h3 { margin-top: 1.6em; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.1em; }
.prose li { margin: .3em 0; }
.prose blockquote { margin: 1.4em 0; padding: 4px 0 4px 20px; border-left: 3px solid var(--accent); color: var(--ink-2); }
.prose code { font: .9em ui-monospace, "Cascadia Code", Menlo, monospace; background: var(--surface); border: 1px solid var(--line); padding: 1px 6px; border-radius: 6px; }
.prose pre { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 16px; overflow-x: auto; }
.prose pre code { border: 0; padding: 0; background: none; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.4em 0; }
.prose figure { margin: 1.8em 0; }
.prose > figure { margin-inline: calc(min(1100px, 100vw - 32px) / -2 + 50%); }
.prose figure img { width: 100%; border-radius: 10px; }
.shots { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px 12px; margin: 1.6em calc(min(1100px, 100vw - 32px) / -2 + 50%); }
.shots figure { margin: 0; }
.shots img { aspect-ratio: 2 / 1; object-fit: cover; border-radius: 8px; background: var(--line); }
.shots figcaption { font-size: .78rem; line-height: 1.35; margin-top: 6px; }
.video a { position: relative; display: block; }
.video span { position: absolute; left: 12px; bottom: 12px; background: var(--ink); color: var(--bg); padding: 6px 12px; border-radius: 999px; font-size: .85rem; }
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 64px 0 0; padding-top: 24px; border-top: 1px solid var(--line); }
.post-nav a { text-decoration: none; color: var(--ink); font-weight: 600; }
.post-nav a span { display: block; font-size: .8rem; font-weight: 500; color: var(--ink-3); text-transform: uppercase; letter-spacing: .08em; }
.post-nav .next { text-align: right; }

/* footer */
.foot { margin-top: clamp(72px, 10vw, 128px); border-top: 1px solid var(--line); padding: 28px 0 40px; color: var(--ink-2); font-size: .92rem; }
.foot-in { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.foot p { margin: 0; }
.foot-links { display: flex; gap: 18px; }
.foot a { color: var(--ink-2); }
.foot .quiet { color: var(--ink-3); }

/* write */
.login { display: grid; gap: 10px; max-width: 380px; margin-top: 24px; }
label { font-weight: 600; font-size: .9rem; }
.hint { font-weight: 400; color: var(--ink-3); font-size: .82rem; }
input, textarea { width: 100%; font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
input:focus, textarea:focus { outline: 2px solid var(--teal); outline-offset: 0; border-color: transparent; }
.error { color: var(--accent); margin: 0; }
.list { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.list th, .list td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.list th { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); }
.signout { margin-top: 24px; }
.editor { padding-top: 28px; }
.ed-actions { display: flex; gap: 8px; align-items: center; margin: 0; }
.status { color: var(--ink-3); font-size: .88rem; }
.ed-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin-top: 12px; }
.ed-form { display: grid; gap: 8px; align-content: start; }
.ed-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: end; }
.ed-row > div { display: grid; gap: 8px; }
.check { display: flex !important; grid-template-columns: none; align-items: center; gap: 8px; min-height: 44px; }
.check input { width: 20px; height: 20px; }
.tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 8px; }
textarea { min-height: 60vh; resize: vertical; line-height: 1.55; font-size: .98rem; }
textarea.drop { outline: 2px dashed var(--accent); }
.picker { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; max-height: 320px; overflow: auto; padding: 8px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.picker[hidden] { display: none; }
.picker button { padding: 0; border: 0; background: none; cursor: pointer; border-radius: 6px; overflow: hidden; }
.picker img { aspect-ratio: 2 / 1; object-fit: cover; width: 100%; }
.ed-preview { border-left: 1px solid var(--line); padding-left: 28px; max-height: calc(100vh - 140px); overflow: auto; position: sticky; top: 80px; }
.ed-preview .prose > figure, .ed-preview .shots { margin-inline: 0; }
.ed-preview h1 { font-size: 2rem; }

@media (max-width: 900px) {
  .three, .cards, .stand { grid-template-columns: 1fr; }
  .tl-day { grid-template-columns: 1fr; gap: 12px; }
  .tl-label span { display: inline; margin-right: 10px; }
  .tl-posts .card-link { grid-template-columns: 1fr; }
  .tl-posts .card img { aspect-ratio: 2 / 1; min-height: 0; }
  .ed-grid { grid-template-columns: 1fr; }
  .ed-preview { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); padding-top: 20px; position: static; max-height: none; }
  .shots { grid-template-columns: repeat(2, 1fr); }
  .prose > figure, .shots { margin-inline: 0; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stats li { padding: 16px; }
  .strip img { height: 140px; }
  .ed-row { grid-template-columns: 1fr; }
  .post-nav { grid-template-columns: 1fr; }
  .post-nav .next { text-align: left; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* pictures: open in the viewer, no easy saving */
img { -webkit-user-drag: none; user-select: none; -webkit-touch-callout: none; }
.zoom { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 10px; }
.shots .zoom { border-radius: 8px; }
.zoom img { transition: opacity .15s; }
.zoom:hover img { opacity: .88; }
html.lb-open { overflow: hidden; }
.lb { position: fixed; inset: 0; z-index: 50; background: rgb(10 9 7 / .97); display: grid; grid-template-columns: 64px 1fr 64px; grid-template-rows: 56px 1fr auto; align-items: center; color: #f1ebe0; }
.lb[hidden] { display: none; }
.lb-top { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; padding: 0 12px 0 20px; font-size: .9rem; color: #bdb4a6; }
.lb-stage { grid-column: 2; height: 100%; min-height: 0; background: center / contain no-repeat; -webkit-touch-callout: none; user-select: none; }
.lb-cap { grid-column: 1 / -1; text-align: center; margin: 0; padding: 12px 20px 20px; font-size: .95rem; color: #d9d1c4; min-height: 1.5em; }
.lb-btn { width: 48px; height: 48px; border-radius: 999px; border: 1px solid rgb(255 255 255 / .18); background: rgb(255 255 255 / .06); color: #f1ebe0; font: 400 28px/1 var(--body); cursor: pointer; display: grid; place-items: center; justify-self: center; transition: background-color .15s; }
.lb-btn:hover { background: rgb(255 255 255 / .16); }
.lb-close { font-size: 26px; width: 44px; height: 44px; }
.lb-single .lb-prev, .lb-single .lb-next { visibility: hidden; }
@media (max-width: 640px) {
  .lb { grid-template-columns: 0 1fr 0; }
  .lb-prev, .lb-next { position: absolute; bottom: 64px; }
  .lb-prev { left: calc(50% - 60px); } .lb-next { left: calc(50% + 12px); }
  .lb-cap { padding-bottom: 76px; }
}

/* stats and roadmap */
.stats-4 { grid-template-columns: repeat(4, 1fr); }
.roadmap { list-style: none; padding: 0; margin: 28px 0 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; counter-reset: rm; }
.rm { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 18px 18px; }
.rm::before { content: ""; position: absolute; left: 18px; right: 18px; top: 0; height: 3px; border-radius: 0 0 3px 3px; background: var(--line); }
.rm-done::before { background: var(--teal); }
.rm-now { border-color: var(--accent); }
.rm-now::before { background: var(--accent); }
.rm-state { font: 600 .74rem/1 var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 10px; }
.rm-done .rm-state { color: var(--teal); }
.rm-now .rm-state { color: var(--accent); }
.rm h3 { font-size: 1.08rem; margin-bottom: 10px; }
.rm ul { margin: 0; padding-left: 1.1em; list-style: disc; color: var(--ink-2); font-size: .9rem; }
.rm li { margin: 4px 0; }
.rm-done li { color: var(--ink-3); }
@media (max-width: 1100px) { .roadmap { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 900px) { .stats-4 { grid-template-columns: 1fr 1fr; } .roadmap { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .roadmap { grid-template-columns: 1fr; } }

/* support */
.support-in { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 4vw, 36px); }
.support h2 { margin-bottom: .35em; }
.support p { color: var(--ink-2); margin: 0 0 .6em; max-width: 58ch; }
.support .support-more { color: var(--ink-3); font-size: .95rem; margin: 0; }
.support-actions { display: flex; flex-direction: column; gap: 10px; align-items: stretch; margin: 0 !important; }
.support-actions .btn { justify-content: center; }
.btn-coffee { background: #fff; border-color: #fff; color: var(--teal); gap: 8px; }
.btn-coffee:hover { color: var(--teal); background: #eaf3fb; border-color: #eaf3fb; }
.support-compact { margin-top: 56px; }
.support-compact .support-in { grid-template-columns: 1fr; }
.support-compact h2 { font-size: 1.4rem; margin-top: 0; }
.support-compact .support-actions { flex-direction: row; flex-wrap: wrap; }
.foot-links { flex-wrap: wrap; }
@media (max-width: 760px) { .support-in { grid-template-columns: 1fr; } }

/* ---------- Sri Lankan geometry ---------- */
.top { background: #fff; border-bottom: 0; }
.top nav a:hover, .top nav a[aria-current] { background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); }

.hero h1 { position: relative; }
.kicker { display: inline-flex; align-items: center; gap: 10px; }
.kicker::before { content: ""; width: 10px; height: 10px; flex: none; background: url(/assets/diamond.svg) center / contain no-repeat; }
.hero-shot { position: relative; }
.hero-shot img { box-shadow: var(--shadow); border-radius: var(--radius) var(--radius) 0 0; }
.hero-shot figcaption { margin-top: 12px; }


/* cards and boxes: white, thin warm line, red-gold on hover */
.point, .now, .rm, .card, .support-in, .list, .stats { background: #fff; }
.point { border-top: 3px solid var(--accent); }
.point:nth-child(2) { border-top-color: var(--ink); }
.point:nth-child(3) { border-top-color: var(--gold); }
.card { box-shadow: 0 1px 0 var(--line); }
.card:hover { border-color: var(--gold); transform: translateY(-2px); }
.day { color: var(--accent); }
.stats { border-color: var(--line); background: var(--line); }
.stats li { background: #fff; }
.stats strong { color: var(--ink); }
.stats li:nth-child(4n+1) strong { color: var(--accent); }
.tl-day { border-top: 0; position: relative; padding-top: 36px; }
.tl-label span { color: var(--accent); }

/* roadmap */
.rm { padding-top: 30px; }
.rm-done::before { opacity: .55; }
.rm-now { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.rm-now::before { opacity: 1; }
.rm-done .rm-state { color: var(--gold); }
.rm ul { list-style: none; padding-left: 0; }
.rm li { padding-left: 18px; position: relative; }
.rm li::before { content: ""; position: absolute; left: 0; top: .5em; width: 8px; height: 8px; background: url(/assets/diamond.svg) center / contain no-repeat; }
.rm-done li::before { filter: grayscale(1); opacity: .5; }
.prose ul { list-style: none; padding-left: 0; }
.prose ul > li { padding-left: 20px; position: relative; }
.prose ul > li::before { content: ""; position: absolute; left: 0; top: .62em; width: 9px; height: 9px; background: url(/assets/diamond.svg) center / contain no-repeat; }
.prose blockquote { border-left-color: var(--gold); }

/* support box */
.support-in { position: relative; overflow: hidden; padding-top: calc(clamp(22px, 4vw, 36px) + 18px); }

/* footer */
.foot { border-top: 0; padding-top: 0; background: var(--surface-2); }

/* picture viewer, white like the rest */
.lb { background: rgb(255 255 255 / .98); color: var(--ink); }
.lb-top { color: var(--ink-3); }
.lb-cap { color: var(--ink-2); }
.lb-btn { border-color: var(--line); background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgb(0 0 0 / .08); }
.lb-btn:hover { background: var(--surface-2); }

/* editor */
input, textarea { background: #fff; }
.ed-preview { border-left-color: var(--line); }
html, body { overflow-x: clip; }
.foot { padding-bottom: 96px; }

/* no stripes: plain lines instead */
.top { border-bottom: 1px solid var(--line); }
.hero-shot img { border-radius: var(--radius); }
.tl-day { padding-top: 28px; border-top: 1px solid var(--line); }
.rm { padding-top: 20px; }
.support-in { padding-top: clamp(22px, 4vw, 36px); }
.foot { border-top: 1px solid var(--line); padding-top: 28px; }

/* the cloud wall (Walakulu Bemma) across the middle of the home page */
.cloudwall { height: 44px; margin: clamp(40px, 6vw, 72px) 0 0; background: url(/assets/cloudwall.svg) repeat-x center bottom / 48px 44px; }

/* help build it: logo on a blue gradient, white text */
.support-in { grid-template-columns: auto 1.4fr 1fr; border: 0; color: #fff;
  background: linear-gradient(135deg, #0f4778 0%, #1c64a8 55%, #3a8fc9 100%); }
.support-mark { width: 64px; height: 64px; border-radius: 15px; box-shadow: 0 0 0 2px rgb(255 255 255 / .9), 0 8px 24px rgb(0 0 0 / .18); align-self: start; }
.support h2, .support p, .support .support-more { color: #fff; }
.support .support-more { opacity: .85; }
.support .btn-ghost { background: transparent; border-color: rgb(255 255 255 / .7); color: #fff; }
.support .btn-ghost:hover { background: rgb(255 255 255 / .12); color: #fff; }
.support-compact .support-in { grid-template-columns: auto 1fr; }
.support-compact .support-actions { grid-column: 1 / -1; }
@media (max-width: 760px) { .support-in { grid-template-columns: auto 1fr; } .support-actions { grid-column: 1 / -1; } .support-mark { width: 52px; height: 52px; border-radius: 12px; } }
.foot { padding-bottom: 40px; }

/* hero: full width, cut-out leaves, centred and quiet (fashion-house style) */
.home .hero { position: relative; padding: 0; min-height: min(86vh, 780px); display: grid; place-items: center; text-align: center;
  background: #f8f3e3 url(/assets/leaves.svg) center / cover no-repeat; }
.home .hero-in { padding-block: clamp(72px, 12vw, 120px); display: flex; flex-direction: column; align-items: center; }
.home .hero .kicker { color: var(--ink); letter-spacing: .22em; }
.home .hero h1 { max-width: 13ch; margin-inline: auto; font-size: clamp(2.6rem, 7vw, 5.4rem); line-height: .98; letter-spacing: -.02em; }
.home .hero .lede { max-width: 46ch; margin-inline: auto; color: var(--ink-2); font-size: 1.08rem; }
.home .hero .actions { justify-content: center; gap: 28px; margin-top: 30px; }
.home .hero .actions a { font: 600 .8rem/1 var(--body); letter-spacing: .2em; text-transform: uppercase; color: var(--ink); text-decoration: none;
  padding-bottom: 6px; border-bottom: 1.5px solid currentColor; }
.home .hero .actions a:hover { color: var(--accent); }
.home .top { border-bottom-color: transparent; }
.home .hero-shot { margin-top: clamp(48px, 7vw, 80px); }
@media (max-width: 600px) { .home .hero { min-height: 640px; background-image: url(/assets/leaves-tall.svg); } .home .hero .lede { font-size: 1rem; } }

/* hero with the Unreal timelapse behind it */
.home .hero-video { background: #1a2a33; overflow: hidden; isolation: isolate; }
.hero-video .hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.hero-video::before { content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(ellipse 60% 55% at 50% 50%, rgb(8 18 28 / .5), transparent 75%),
    linear-gradient(180deg, rgb(8 18 28 / .45) 0%, rgb(8 18 28 / .3) 45%, rgb(8 18 28 / .55) 100%); }
.home .hero-video .kicker, .home .hero-video h1, .home .hero-video .lede, .home .hero-video .actions a { color: #fff; }
.hero-video h1, .hero-video .lede, .hero-video .kicker, .hero-video .actions a { text-shadow: 0 1px 3px rgb(0 0 0 / .45), 0 1px 24px rgb(0 0 0 / .4); }
.home .hero-video .lede { color: rgb(255 255 255 / .94); }
.hero-video .kicker::before { filter: brightness(0) invert(1); }
.home .hero-video .actions a:hover { color: #cfe6f7; }
.hero-pause { position: absolute; right: 18px; bottom: 18px; width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid rgb(255 255 255 / .7);
  background: rgb(0 0 0 / .25); cursor: pointer; display: grid; place-items: center; }
.hero-pause:hover { background: rgb(0 0 0 / .45); }
.hero-pause:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.hero-pause span { width: 12px; height: 14px; border-left: 4px solid #fff; border-right: 4px solid #fff; }
.hero-pause.is-paused span { width: 0; height: 0; border: 0; border-left: 13px solid #fff; border-top: 8px solid transparent; border-bottom: 8px solid transparent; margin-left: 4px; }
@media (max-width: 600px) { .home .hero-video { background-image: none; } }

/* header: fashion-house style. Name centred in spaced capitals, quiet links either side.
   On the home page it floats over the video in white and turns solid once you scroll past it. */
.top, .home .top { position: sticky; top: 0; z-index: 20; background: #fff; border-bottom: 1px solid var(--line); transition: background-color .3s ease, border-color .3s ease, color .3s ease; }
.top-in { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; height: 68px; }
.top nav { display: flex; gap: 26px; }
.top .top-r { justify-content: flex-end; }
.top nav a, .top nav a:hover, .top nav a[aria-current] { padding: 6px 0; border-radius: 0; background: none; box-shadow: none;
  font: 600 .74rem/1 var(--body); letter-spacing: .2em; text-transform: uppercase; color: var(--ink); text-decoration: none; border-bottom: 1.5px solid transparent; }
.top nav a:hover, .top nav a[aria-current] { border-bottom-color: currentColor; }
.brand { gap: 12px; font: 700 1.05rem/1 var(--body); letter-spacing: .42em; text-transform: uppercase; margin-right: -.42em; color: var(--ink); }
.mark { width: 34px; height: 34px; border-radius: 9px; }
.mark-w { display: none; }
.top.top-over { position: fixed; left: 0; right: 0; background: transparent; border-bottom-color: transparent; }
.top-over:not(.is-solid) nav a, .top-over:not(.is-solid) .brand { color: #fff; text-shadow: 0 1px 8px rgb(0 0 0 / .35); }
.top-over:not(.is-solid) .mark-c { display: none; }
.top-over:not(.is-solid) .mark-w { display: block; filter: drop-shadow(0 1px 6px rgb(0 0 0 / .3)); }
.top-over.is-solid { background: #fff; border-bottom-color: var(--line); }
.home .hero-in { padding-top: calc(clamp(72px, 12vw, 120px) + 40px); }
@media (max-width: 600px) { .hide-s { display: none; } .top nav { gap: 16px; } .brand { letter-spacing: .3em; margin-right: -.3em; gap: 8px; } .brand span { font-size: .95rem; } }
.top-over:not(.is-solid) { background: linear-gradient(180deg, rgb(8 18 28 / .5), rgb(8 18 28 / 0)); }
/* picture strip: no scrollbar line, it still scrolls by swipe, trackpad or shift + wheel */
.strip { scrollbar-width: none; -ms-overflow-style: none; }
.strip::-webkit-scrollbar { display: none; }
/* boxes with a coloured top line: square top corners so the line runs straight */
.point, .rm { border-radius: 0 0 var(--radius) var(--radius); }
.rm::before { left: 0; right: 0; border-radius: 0; }
/* no line under the header at all */
.top, .home .top, .top.top-over, .top-over.is-solid { border-bottom: 0; box-shadow: none; }

/* visitors, views, thumbs */
.site-stats { color: var(--ink-3); font-size: .95rem; margin-top: 10px; }
.site-stats strong { color: var(--ink); font-weight: 700; font-variant-numeric: tabular-nums; }
.rate { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); }
.rate p { margin: 0 8px 0 0; font-weight: 600; color: var(--ink); }
.rate-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink-2); font: 600 .95rem var(--body); font-variant-numeric: tabular-nums; cursor: pointer; transition: border-color .15s, background-color .15s, color .15s; }
.rate-btn:hover { border-color: var(--ink-3); color: var(--ink); }
.rate-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.rate-btn[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.rate-btn span:empty { display: none; }
.rate-down svg { transform: scaleY(-1); }

/* questions */
.faq { margin-top: 24px; border-top: 1px solid var(--line); max-width: 820px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; padding: 18px 36px 18px 0; position: relative; font: 600 1.08rem/1.4 var(--body); color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 14px; font: 400 1.5rem/1 var(--body); color: var(--accent); }
.faq details[open] summary::after { content: "\2013"; }
.faq summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.faq p { margin: 0 0 18px; color: var(--ink-2); max-width: 68ch; }
#faq { scroll-margin-top: 84px; }

/* ---------- /map: the whole Kandy area, done in green (web/kandy-map.svg from tools/make-map.py) ---------- */
.map-key { display: flex; flex-wrap: wrap; gap: 8px 20px; list-style: none; padding: 0; margin: 18px 0 0; font-size: .92rem; color: var(--ink-2); }
.map-key li { display: flex; align-items: center; gap: 8px; }
.map-key i { width: 14px; height: 14px; border-radius: 3px; display: inline-block; border: 1px solid #0002; }
.k-done { background: #2f8f46; } .k-wip { background: #9fd79a; } .k-other { background: #c9c2b8; } .k-lm { background: #d97a4a; } .k-water { background: #a9d3e6; }
.map-wrap { width: min(1400px, 100% - 32px); margin: 20px auto 0; }
.map-box { position: relative; height: min(78vh, 900px); min-height: 420px; background: #f4f1ea; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.map-box svg { width: 100%; height: 100%; display: block; cursor: grab; touch-action: none; }
.map-box svg.grabbing { cursor: grabbing; }
.map-loading { position: absolute; inset: 0; display: grid; place-items: center; color: var(--ink-3); margin: 0; }
.map-tools { position: absolute; right: 12px; top: 12px; display: flex; flex-direction: column; gap: 6px; z-index: 2; }
.map-tools button { width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--line); background: #fff; color: var(--ink); font: 600 1.2rem/1 var(--body); cursor: pointer; }
.map-tools button:hover { background: var(--surface); }
.map-tools button.wide { font-size: .72rem; }
.map-note { font-size: .86rem; color: var(--ink-3); margin: 10px 0 0; }
#kmap .park { fill: #d5e6c3; } #kmap .water { fill: #a9d3e6; stroke: #7fb4cc; stroke-width: .6; }
#kmap .foot { fill: none; stroke: #b98; stroke-width: 1.2; stroke-dasharray: 3 2; }
#kmap .rd { fill: none; stroke: #fff; stroke-linecap: round; stroke-linejoin: round; }
#kmap .rd.trunk, #kmap .rd.primary { stroke: #f6d98a; } #kmap .rd.secondary, #kmap .rd.tertiary { stroke: #fbeeb8; } #kmap .rd.pedestrian { stroke: #e9dfd0; }
#kmap .rd.done { stroke: #3aa856; } #kmap .rd.wip { stroke: #b4e3ad; }
#kmap .b { fill: #c9c2b8; stroke: #958d82; stroke-width: .35; } #kmap .nm { fill: #b9a58c; stroke: #7d6d58; stroke-width: .4; }
#kmap .lm { fill: #d97a4a; stroke: #8a4322; stroke-width: .5; } #kmap .ho { fill: #8fa7c9; stroke: #4f678a; stroke-width: .4; }
#kmap .b.done, #kmap .nm.done, #kmap .ho.done { fill: #2f8f46; stroke: #1d5e2d; }
#kmap .b.wip, #kmap .nm.wip, #kmap .ho.wip { fill: #9fd79a; stroke: #5e9c58; }
#kmap path:hover { filter: brightness(.85); }
#kmap .sn { fill: #555; paint-order: stroke; stroke: #fffc; stroke-width: 2px; pointer-events: none; }
#kmap .lbl { fill: #5a1e08; font-weight: 600; text-anchor: middle; paint-order: stroke; stroke: #fffd; stroke-width: 2.5px; pointer-events: none; }
#kmap .cut { fill: none; stroke: #c00; stroke-width: 3; pointer-events: none; }
