/* Upazila flood report — calm, editorial layout */
body.page { background: var(--bg); min-height: 100vh; }
.topbar { position: sticky; top: 0; z-index: 10; height: 56px; gap: 14px; }
.back { font-weight: 600; text-decoration: none; color: var(--text); white-space: nowrap; }
.back:hover { color: var(--brand); }
.small-brand { gap: 8px; margin-right: auto; }
.small-brand .mark { width: 26px; height: 26px; }
.small-brand b { font-size: 15px; }
.icon-round { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); cursor: pointer; font-size: 16px; }

.report { max-width: 1040px; margin: 0 auto; padding: 28px 18px 48px; display: flex; flex-direction: column; gap: 18px; }
.hero { display: flex; justify-content: space-between; gap: 24px; align-items: flex-start; flex-wrap: wrap; }
.hero > div:first-child { flex: 1 1 520px; }
.crumb { margin: 0; color: var(--muted); font-size: 14px; }
.hero h1 { font-size: 38px; font-weight: 800; letter-spacing: -.025em; margin: 2px 0 10px; line-height: 1.1; }
.lead { font-size: 18px; line-height: 1.6; margin: 0; color: var(--text); max-width: 640px; }
.lead b { color: var(--high); }
.now { border-radius: 14px; padding: 14px 16px; min-width: 230px; background: var(--low-bg); }
.now.medium { background: var(--med-bg); } .now.high { background: var(--high-bg); }
.now small { display: block; color: var(--muted); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.now b { display: block; font-size: 22px; margin: 2px 0; }
.now span { color: var(--muted); font-size: 13px; }

.tiles3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; }
.tile .k { font-size: 13px; color: var(--muted); }
.tile .v { font-size: 28px; font-weight: 800; letter-spacing: -.02em; margin: 2px 0; line-height: 1.15; }
.tile .v small { font-size: 15px; font-weight: 600; color: var(--muted); }
.tile .d { font-size: 13px; color: var(--muted); }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 20px 22px; }
.card h2 { font-size: 18px; font-weight: 700; margin: 0 0 4px; }
.card .sub { color: var(--muted); font-size: 14px; margin: 0 0 14px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }

/* flood calendar */
.cal-wrap { overflow-x: auto; }
.cal { border-collapse: separate; border-spacing: 5px; width: 100%; min-width: 560px; }
.cal th { font-size: 12px; font-weight: 600; color: var(--muted); text-align: center; padding: 0 2px; }
.cal th.yr { text-align: right; padding-right: 8px; font-size: 13px; color: var(--text); }
.cal th.mon { font-size: 12.5px; color: var(--text); }
.cal td { height: 34px; border-radius: 7px; text-align: center; font-size: 12px; font-weight: 700; color: rgba(0,0,0,.65);
  cursor: default; transition: transform .1s; background: var(--surface-2); }
.cal td:hover { transform: scale(1.08); box-shadow: 0 2px 8px rgba(0,0,0,.2); }
.cal td.flood { color: #fff; outline: 2px solid rgba(0,0,0,.15); outline-offset: -2px; }
.cal td.none { color: var(--muted); font-weight: 500; }
.cal-legend { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.cal-legend i { width: 22px; height: 12px; border-radius: 3px; display: inline-block; }

/* rain story */
.cmp { display: flex; flex-direction: column; gap: 12px; margin: 14px 0; }
.cmp .row { display: grid; grid-template-columns: 140px 1fr; gap: 10px; align-items: center; font-size: 13px; }
.cmp .bar { height: 26px; border-radius: 6px; display: flex; align-items: center; padding: 0 10px; color: #fff; font-weight: 700;
  font-size: 13px; min-width: 60px; white-space: nowrap; }
.story { font-size: 15px; line-height: 1.65; margin: 0; }

/* yearly bars */
.ybars { display: flex; flex-direction: column; gap: 6px; }
.ybars .row { display: grid; grid-template-columns: 44px 1fr 84px; gap: 8px; align-items: center; font-size: 13px; }
.ybars .track { background: var(--surface-2); border-radius: 5px; height: 16px; overflow: hidden; }
.ybars .fill { height: 100%; border-radius: 5px; background: linear-gradient(90deg, #5aaee3, #1f6fb5); }
.ybars .v { text-align: right; color: var(--muted); font-variant-numeric: tabular-nums; }

/* cyclones */
.cyc-list { list-style: none; padding: 0; margin: 12px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.cyc-list li { border: 1px solid var(--line); border-left: 4px solid var(--c); border-radius: 10px; padding: 10px 12px; }
.cyc-list b { display: block; font-size: 15px; }
.cyc-list span { color: var(--muted); font-size: 13px; }

.foot details { margin-bottom: 8px; }
.foot summary { cursor: pointer; font-weight: 600; color: var(--text); }
.foot details p { max-width: 720px; line-height: 1.6; }
.credits { margin: 4px 0; }
.tip { position: fixed; z-index: 50; pointer-events: none; background: #1c242e; color: #eef3f7; border-radius: 8px; padding: 8px 10px;
  font-size: 12.5px; line-height: 1.5; box-shadow: 0 6px 18px rgba(0,0,0,.35); max-width: 260px; }

@media (max-width: 820px) {
  .tiles3, .grid2, .cyc-list { grid-template-columns: 1fr; }
  .hero h1 { font-size: 30px; }
  .lead { font-size: 16px; }
  .small-brand b { display: none; }
  .cmp .row { grid-template-columns: 110px 1fr; }
}
@media print {
  .topbar, #print, .foot details { display: none; }
  body.page { background: #fff; }
  .card, .tile { break-inside: avoid; }
}

/* v3: nav, mini map, icons, motion */
.secnav { display: flex; gap: 4px; margin-left: 8px; }
.secnav a { text-decoration: none; color: var(--muted); font-weight: 600; font-size: 13.5px; padding: 6px 10px; border-radius: 999px; }
.secnav a:hover { color: var(--text); background: var(--surface-2); }
.secnav a.on { color: #fff; background: var(--brand); }
.print-btn { background: var(--brand); border-color: var(--brand); color: #fff; }
.print-btn:hover { background: var(--brand-600); }
.small-brand { margin-right: 0; }
.top-actions { margin-left: auto; }
.hero { display: grid; grid-template-columns: 1.4fr 1fr; align-items: center; gap: 24px; scroll-margin-top: 70px; }
.hero-text #now { margin-top: 16px; display: inline-block; }
.mini-map-wrap { border-radius: 18px; overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); height: 240px; }
#mini-map { height: 100%; background: #cfe0ec; }
.tile { position: relative; overflow: hidden; }
.tile .ti { position: absolute; right: 14px; top: 12px; font-size: 26px; opacity: .9; }
.card, .grid2 { scroll-margin-top: 70px; }
.card-head .btn { flex-shrink: 0; }
.cal-legend { margin: 0 0 8px; }
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
.cal td { animation: pop .35s ease both; }
@keyframes pop { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: none; } }
.cmp .bar { animation: grow .9s cubic-bezier(.2,.8,.2,1) both; transform-origin: left; }
.ybars .fill { animation: grow 1s cubic-bezier(.2,.8,.2,1) both; transform-origin: left; }
@keyframes grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.about .about-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.about .card .ico { font-size: 28px; margin-bottom: 6px; }
.about .card p { margin: 6px 0 0; color: var(--muted); line-height: 1.6; font-size: 14.5px; }
.warn-strip { display: flex; gap: 12px; align-items: flex-start; background: var(--med-bg); border-radius: 14px; padding: 14px 16px; }
.warn-strip span { font-size: 22px; }
.warn-strip p { margin: 0; line-height: 1.6; }
.limits { margin: 8px 0 0; padding-left: 20px; line-height: 1.9; color: var(--muted); }
@media (prefers-reduced-motion: reduce) { .reveal, .cal td, .cmp .bar, .ybars .fill { animation: none; transition: none; opacity: 1; transform: none; } }
@media (max-width: 980px) { .secnav { display: none; } }
@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; }
  .mini-map-wrap { height: 190px; }
  .about .about-grid { grid-template-columns: 1fr; }
  .top-actions .btn.ghost:not(#lang) { display: none; }
}
@media print {
  .secnav, .top-actions, .mini-map-wrap { display: none; }
  .reveal { opacity: 1; transform: none; }
}
.not-official { margin: 4px 0 0; text-align: center; color: var(--muted); font-size: 12.5px; }
