/*!
 * Copyright (c) 2026 Tax Policy Associates Limited
 * SPDX-License-Identifier: MIT
 * Licensed under the MIT licence. See LICENCE in the repository root.
 */
/* England visitor levy model.
   Uses the LVT modeller's colours and component conventions, with the site's
   light theme. */
:root{
  --blue:#1f4bd8; --blue-deep:#12163a; --blue-soft:#eef2ff;
  --ink:#151a2e; --ink-2:#3a4256; --muted:#6b7488; --faint:#9aa2b5;
  --line:#e6e9f2; --line-2:#eef0f6;
  --bg:#f4f6fb; --bg-2:#ffffff; --card:#ffffff;
  --good:#0f7a52; --good-bg:#e4f5ec; --bad:#c0392b; --bad-bg:#fbeae7;
  --shadow:0 1px 2px rgba(20,30,60,.04), 0 8px 24px rgba(20,30,60,.05);
  --radius:16px;
  /* Map colours run from light to dark using the house blue. */
  --seq-1:#e3e9fb; --seq-2:#bcccf6; --seq-3:#8ea8ee; --seq-4:#5c7fe4;
  --seq-5:#3459db; --seq-6:#1f4bd8; --seq-7:#16349a;
  /* Warm colours for the second and third series, with different lightness
     levels to help distinguish them. */
  --amber:#d97706; --teal:#0f7a72;
  --neutral:#e8eaf0; --map-edge:#ffffff;
}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--bg);color:var(--ink);line-height:1.55;
  font-family:'Poppins',system-ui,-apple-system,Segoe UI,Roboto,sans-serif;
  -webkit-font-smoothing:antialiased;font-feature-settings:"tnum" 1;}
.wrap{max-width:1120px;margin:0 auto;padding:20px 18px 28px;}
a{color:var(--blue);text-decoration:none}
a:hover{text-decoration:underline}
::selection{background:var(--blue);color:#fff}
:where(a,button,summary,input,tr):focus-visible{outline:2px solid var(--blue);outline-offset:2px;border-radius:6px}

.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap}

/* header */
.top{display:flex;align-items:center;gap:12px;margin-bottom:16px;flex-wrap:wrap;}
.logo{height:38px;width:auto;border-radius:6px;display:block;}
.embedded-own .brand{display:none}
.top h1{font-size:1.35rem;font-weight:700;margin:0;letter-spacing:-.015em;}
.top .spacer{flex:1}
.tools{display:flex;gap:8px;flex-wrap:wrap;}
.tool-btn{border:1px solid var(--line);background:var(--card);color:var(--ink-2);border-radius:10px;
  height:38px;padding:0 14px;cursor:pointer;font:inherit;font-size:.84rem;font-weight:600;
  display:inline-flex;align-items:center;gap:7px;white-space:nowrap;}
.tool-btn:hover{color:var(--blue);border-color:var(--blue);background:var(--blue-soft);}
.tool-btn .ic{font-size:1rem;line-height:1;}

.lede{font-size:1.06rem;color:var(--ink-2);max-width:74ch;margin:0 0 22px;}
.lede b{color:var(--ink)}

/* segmented control */
.mode-switch{display:flex;justify-content:center;margin:0 0 20px;}
.seg{display:inline-flex;border:1px solid var(--line);border-radius:11px;overflow:hidden;background:var(--bg-2);max-width:100%;flex-wrap:wrap;}
.seg button{border:0;background:transparent;padding:9px 14px;font:inherit;font-size:.86rem;cursor:pointer;color:var(--muted);font-weight:500}
.seg button + button{border-left:1px solid var(--line)}
.seg button.active{background:var(--blue);color:#fff;font-weight:600}
@media(max-width:560px){.mode-switch .seg{width:100%}.mode-switch .seg button{flex:1}}

/* cards */
.card{background:var(--card);border:1px solid var(--line);border-radius:var(--radius);
  padding:18px 20px;box-shadow:var(--shadow);}
.card > h2, .card-head h2{font-size:.74rem;font-weight:700;letter-spacing:.07em;text-transform:uppercase;
  color:var(--muted);margin:0 0 14px;}
.card > h2 .n, .card-head h2 .n{color:var(--muted);font-weight:500;text-transform:none;letter-spacing:0;font-size:.86rem;}

.hero{display:grid;grid-template-columns:0.72fr 1.28fr;gap:16px;}
@media(max-width:900px){.hero{grid-template-columns:1fr}}

/* the rate control */
.rate-head{display:flex;justify-content:space-between;align-items:baseline;gap:12px;margin-bottom:2px;}
.rate-now{font-size:1.9rem;font-weight:700;letter-spacing:-.02em;line-height:1;color:var(--blue);}
.rate-cap{font-size:.85rem;color:var(--muted);}
input[type=range]{width:100%;accent-color:var(--blue);cursor:pointer;height:22px;margin:0;}
.ticks{position:relative;height:5px;margin-top:1px}
.ticks i{position:absolute;top:0;width:2px;height:6px;border-radius:1px;background:var(--faint);transform:translateX(-50%)}
.refs{font-size:.72rem;color:var(--faint);margin:5px 0 0;line-height:1.5}
.fhelp{font-size:.78rem;color:var(--muted);margin:6px 0 0;line-height:1.45}
.fld{margin-bottom:16px}
.fld:last-child{margin-bottom:0}
.fld-head{display:flex;justify-content:space-between;align-items:baseline;gap:12px;margin-bottom:2px}
.fld-lbl{font-size:.86rem;font-weight:600;color:var(--ink-2);display:inline-flex;align-items:center;gap:6px}
.info{width:16px;height:16px;flex:0 0 16px;border:0;background:none;padding:0;cursor:pointer;
  color:var(--faint);display:inline-flex;align-items:center;justify-content:center;
  border-radius:50%;transition:color .12s ease}
.info svg{display:block}
.info:hover,.info:focus-visible,.info[aria-expanded=true]{color:var(--blue)}
.tip-pop{position:absolute;z-index:9999;background:var(--ink);color:#fff;border-radius:10px;
  padding:11px 13px;font-size:.76rem;line-height:1.5;box-shadow:0 12px 32px rgba(20,26,46,.28);
  max-width:300px;}
.tip-pop[hidden]{display:none}
.fld-val{font-size:.85rem;font-weight:700;color:var(--blue);font-variant-numeric:tabular-nums}

/* headline result */
.result{display:flex;flex-direction:column;}
.outcomes{display:grid;grid-template-columns:1fr 1fr;gap:24px}
@media(max-width:640px){.outcomes{grid-template-columns:1fr;gap:20px}}
.outcome .k{font-size:.8rem;font-weight:600;color:var(--muted);margin-bottom:6px;
  text-transform:uppercase;letter-spacing:.05em}
.outcome .k .scope{text-transform:none;letter-spacing:0;font-weight:400;color:var(--faint)}
.outcome .v{font-size:2.5rem;font-weight:700;line-height:1;letter-spacing:-.03em;
  font-variant-numeric:tabular-nums}
.outcome.raise .v{color:var(--blue)}
.outcome.lose .v{color:var(--bad)}
.outcome .parts{margin-top:12px;padding-top:11px;border-top:1px solid var(--line-2);
  display:flex;flex-direction:column;gap:5px}
.outcome .parts span{display:flex;align-items:baseline;gap:7px;font-size:.8rem;color:var(--muted);
  line-height:1.35}
.outcome .parts b{margin-left:auto;color:var(--ink);font-variant-numeric:tabular-nums;
  font-weight:600;font-size:.85rem;white-space:nowrap}
.sw{width:8px;height:8px;border-radius:2px;flex:0 0 8px;position:relative;top:-1px}
.sw.uk{background:var(--blue)} .sw.fo{background:var(--amber)}
.sw.lost-fo{background:var(--bad)} .sw.lost-uk{background:#d68910}
.nights-line{margin-top:16px;padding-top:13px;border-top:1px solid var(--line-2);
  font-size:.86rem;color:var(--ink-2);line-height:1.5}
.nights-line b{color:var(--ink);font-variant-numeric:tabular-nums}
.bignum{font-size:2.9rem;font-weight:700;line-height:1;letter-spacing:-.02em;
  background:linear-gradient(120deg,var(--blue),#7a3ff0);-webkit-background-clip:text;background-clip:text;color:transparent;}
.result .cap{color:var(--muted);font-size:.95rem;margin-top:4px}
.response{margin-top:14px;font-size:.88rem;color:var(--ink-2);line-height:1.5}
.response b{color:var(--ink);font-variant-numeric:tabular-nums}
.splits{margin-top:auto;padding-top:16px;border-top:1px solid var(--line-2);display:grid;grid-template-columns:1fr 1fr;gap:16px}
.splits .k{font-size:.78rem;color:var(--muted);margin-bottom:2px}
.splits .v{font-size:1.45rem;font-weight:700;letter-spacing:-.01em;line-height:1.15;font-variant-numeric:tabular-nums}
.splits .n{font-size:.75rem;color:var(--faint);margin-top:2px;line-height:1.4}
.splits .uk .v{color:var(--blue)} .splits .fo .v{color:var(--amber)}
.perhead{margin-top:14px;padding-top:12px;border-top:1px solid var(--line-2);font-size:.88rem;color:var(--muted)}
.perhead b{color:var(--ink);font-variant-numeric:tabular-nums}

/* map */
.map-wrap{margin-top:16px}
.map-body{display:grid;grid-template-columns:0.78fr 1.22fr;gap:26px;align-items:start}
/* Grid items default to min-width:auto, so the nowrap region table forces the
   whole column wider than the card on a narrow screen, taking the map and the
   legend with it. Let them shrink; the table scrolls inside .region-scroll. */
.map-body > *{min-width:0}
@media(max-width:900px){.map-body{grid-template-columns:1fr}}
#map{height:440px}
@media(max-width:900px){#map{height:380px}}
.legend{font-size:.75rem;line-height:1.5;margin-top:10px}
.legend .lt{font-weight:700;margin-bottom:5px;color:var(--ink)}
.legend .ramp{display:flex;height:9px;border-radius:3px;overflow:hidden;margin:0}
.legend .ramp i{flex:1}
.legend .ends{display:flex;justify-content:space-between;color:var(--muted);font-size:.7rem;font-variant-numeric:tabular-nums;margin-top:3px}
.legend .ramp i{border-right:1px solid #fff}
.legend .ramp i:last-child{border-right:0}
.legend .row{display:flex;align-items:center;gap:7px;margin:8px 0 0;color:var(--faint);font-size:.7rem}
.legend .row i{width:15px;height:12px;border-radius:3px;display:inline-block;background:var(--line);border:1px solid var(--line-2)}

.region-scroll{overflow-x:auto}
.region-table{width:100%;border-collapse:collapse;font-size:.88rem;font-variant-numeric:tabular-nums}
.region-table th,.region-table td{padding:8px 9px;text-align:right;border-bottom:1px solid var(--line-2);white-space:nowrap}
.region-table th{color:var(--muted);font-weight:600;font-size:.76rem;letter-spacing:.02em;text-transform:uppercase;
  /* The headings carry a <br> so each column is only as wide as its longest
     single word. Middle alignment keeps the one-line and two-line headings on
     the same baseline block. */
  vertical-align:middle;line-height:1.25}
.region-table th.raised{color:var(--good)}
.region-table th.lost{color:var(--bad)}
/* Centre the two-line headings over their columns; right-aligning them left
   the shorter line hanging off the edge of the stack. */
.region-table th.raised,.region-table th.lost{text-align:center}
.region-table td.raised{color:var(--good);font-weight:500}
.region-table td.lost{color:var(--bad);font-weight:500}
.region-table tr.residual td{color:var(--faint)}
.region-table tr.residual td.b{font-weight:500}
.region-table tr.residual td.raised{color:#5b9b7d}
.region-table tr.residual td.lost{color:#c98a80}
.region-table tfoot td{border-bottom:0;border-top:2px solid var(--line);
  padding-top:11px;font-weight:700;font-size:.92rem}
.region-table tfoot td.b{font-weight:700}
.region-table tfoot td.raised{color:var(--good)}
.region-table tfoot td.lost{color:var(--bad)}
.region-table td.b,.region-table th.b{text-align:left;font-weight:600;white-space:normal}
.region-table tbody tr{cursor:pointer}
.region-table tbody tr:hover td{background:var(--bg)}
.region-table tbody tr.on td{background:var(--blue-soft)}
/* Tighten the gutters on a phone so the four columns fit without scrolling. */
@media(max-width:560px){
  .region-table{font-size:.84rem}
  .region-table th,.region-table td{padding:7px 5px}
  .region-table th{font-size:.72rem;letter-spacing:0}
  .region-table tfoot td{font-size:.88rem}
}
@media(max-width:400px){
  .region-table{font-size:.8rem}
  .region-table th,.region-table td{padding:7px 3px}
  .region-table th{font-size:.69rem}
  .region-table tfoot td{font-size:.84rem}
}
@media(max-width:340px){
  .region-table th,.region-table td{padding:7px 2px}
}



.chart{width:100%;height:250px}
.chart-short{height:120px}

.pnote{font-size:.78rem;color:var(--muted);font-style:italic;margin-top:10px}
.verdict{font-size:.95rem;color:var(--ink-2);margin:0 0 12px}
.verdict b{color:var(--ink)}
.pill{display:inline-flex;align-items:center;padding:4px 11px;border-radius:999px;font-size:.9rem;font-weight:700;font-variant-numeric:tabular-nums}
.pill.good{background:var(--good-bg);color:var(--good)} .pill.bad{background:var(--bad-bg);color:var(--bad)}

.assume{margin-top:16px}
.presets{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:2px 0 18px}
.presets-lbl{font-size:.86rem;color:var(--ink-2);font-weight:600}
.presets .seg button{font-size:.8rem;padding:8px 12px}
h3.grp{font-size:.72rem;font-weight:700;letter-spacing:.07em;text-transform:uppercase;color:var(--faint);
  margin:18px 0 10px;padding-top:14px;border-top:1px solid var(--line-2)}
h3.grp:first-of-type{border-top:0;padding-top:0;margin-top:0}
.compare-row.top{border-top:0;padding-top:0;margin:0 0 14px}
.fld.off{opacity:.42;pointer-events:none}
.fld.off .fld-val{color:var(--faint)}
.toggles{display:flex;flex-direction:column;gap:9px}
.opt{display:flex;align-items:flex-start;gap:9px;font-size:.86rem;color:var(--ink-2);cursor:pointer;line-height:1.4}
.opt input{margin:2px 0 0;width:16px;height:16px;accent-color:var(--blue);cursor:pointer;flex:0 0 auto}
.assume-intro{margin:0 0 18px;font-size:.86rem;color:var(--muted);line-height:1.55;max-width:62ch}
.card-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.card-head h2{flex:1;margin-top:2px}
.icon-btn{border:1px solid var(--line);background:var(--card);color:var(--muted);
  width:30px;height:30px;border-radius:9px;cursor:pointer;padding:0;margin-top:-4px;
  display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto}
.icon-btn:hover{color:var(--blue);border-color:var(--blue);background:var(--blue-soft)}
.icon-btn svg{display:block}

/* The comparison sits beside its label, below the sliders. */
.compare-row{display:flex;align-items:center;gap:14px;
  flex-wrap:wrap;margin-top:4px;padding-top:16px;border-top:1px solid var(--line-2)}
.compare-row .seg button{font-size:.82rem;padding:8px 13px}
@media(max-width:560px){.compare-row .seg{width:100%}.compare-row .seg button{flex:1}}
@media(max-width:900px){.grid2{grid-template-columns:1fr}}
.assume-grid{display:grid;grid-template-columns:1fr 1fr;gap:0 30px}
@media(max-width:700px){.assume-grid{grid-template-columns:1fr}}


.foot h3{font-size:.82rem;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--ink);margin:0 0 8px}
.foot ul{margin:0 0 12px;padding-left:18px}
.foot li{margin-bottom:3px}


@media(prefers-reduced-motion:reduce){*{transition-duration:.01ms!important;animation:none!important}}
