/* =====================================================================
   Calcolo Bollo Auto — shared stylesheet
   Sections: variables → reset → layout → components → utilities → responsive
   Design system is LOCKED. Do not introduce colors/spacing outside the tokens.
   ===================================================================== */

/* ============================ VARIABLES ============================ */
:root {
  /* Brand colors */
  --navy: #10213a;
  --navy-deep: #12213a;
  --hero-a: #0b1a2f;
  --hero-b: #13294b;
  --cream: #efeae0;
  --brass: #b08430;
  --brass-light: #ddbe79;
  --brass-deep: #8a6620;
  --green: #25603e;
  --red: #a03b33;
  --white: #ffffff;
  --muted: #55637a;
  --muted-2: #8a93a3;

  /* Surfaces & ink (derived) */
  --bg: #faf9f6;
  --ink: #1f2c3d;
  --ink-strong: #16233a;
  --panel: #ffffff;
  --panel-cream: #f3f0e8;
  --line: #e8e2d4;
  --line-soft: #efeae0;
  --link: #24558f;

  /* Accent tints used by badges/callouts */
  --tint-blue-bg: #eaf1f8;
  --tint-blue-fg: #2c4a6e;
  --tint-blue-border: #24558f;
  --tint-gold-bg: #fbf3dc;
  --tint-gold-fg: #6b5320;
  --tint-green-bg: #e9f3eb;
  --tint-green-fg: #25603e;
  --tint-red-bg: #fbebe8;
  --tint-red-fg: #8e332c;

  /* Fonts */
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "Hanken Grotesk", "Helvetica Neue", Arial, sans-serif;

  /* Spacing scale — ONLY these values */
  --s4: 4px;
  --s8: 8px;
  --s12: 12px;
  --s16: 16px;
  --s24: 24px;
  --s32: 32px;
  --s48: 48px;
  --s64: 64px;
  --s96: 96px;

  /* Layout */
  --wrap: 1160px;
  --wrap-narrow: 860px;
  --wrap-calc: 920px;
  --radius: 14px;
  --radius-lg: 18px;
}

/* ============================== RESET ============================== */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16.5px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
h1,
h2,
h3,
h4,
h5,
h6,
p,
ul,
ol,
figure {
  margin: 0;
}
ul,
ol {
  padding: 0;
  list-style: none;
}
img {
  max-width: 100%;
  height: auto;
  display: block;
}
a {
  color: var(--link);
  text-decoration: none;
}
a:hover {
  color: var(--brass-deep);
}
button {
  font-family: inherit;
}
table {
  border-collapse: collapse;
}
::selection {
  background: #ebddbc;
}

/* Accessibility */
:focus-visible {
  outline: 3px solid var(--brass);
  outline-offset: 2px;
}
.skip-link {
  position: absolute;
  left: var(--s8);
  top: -60px;
  z-index: 200;
  background: var(--white);
  color: var(--navy);
  padding: var(--s12) var(--s16);
  border-radius: 8px;
  font-weight: 700;
  transition: top 0.15s ease;
}
.skip-link:focus {
  top: var(--s8);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ============================== LAYOUT ============================= */
.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--s24);
}
.wrap-narrow {
  max-width: var(--wrap-narrow);
  margin: 0 auto;
  padding: 0 var(--s24);
}
.section {
  padding: var(--s64) 0;
}
.section--tight {
  padding: var(--s32) 0;
}
.section--cream {
  background: var(--panel-cream);
  border-top: 1px solid #eae5d8;
  border-bottom: 1px solid #eae5d8;
}
.section--white {
  background: var(--white);
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}

/* Section eyebrow + titles */
.eyebrow {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--brass-deep);
  margin-bottom: var(--s12);
}
h1,
h2,
h3 {
  font-family: var(--serif);
  color: var(--navy-deep);
  line-height: 1.15;
}
.h1 {
  font-weight: 600;
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1.08;
  letter-spacing: -0.5px;
}
.h2 {
  font-style: italic;
  font-weight: 600;
  font-size: clamp(28px, 3.6vw, 42px);
  margin-bottom: var(--s16);
}
.h3 {
  font-style: italic;
  font-weight: 600;
  font-size: clamp(22px, 2.6vw, 29px);
  margin: var(--s32) 0 var(--s12);
}
.h4 {
  font-family: var(--sans);
  font-size: 17.5px;
  font-weight: 800;
  color: var(--ink-strong);
  margin: var(--s24) 0 var(--s8);
}
.lead {
  max-width: 820px;
  color: #4a5a70;
  margin-bottom: var(--s32);
}
.prose p {
  margin: 0 0 var(--s16);
  color: #3a4a60;
}
.prose p.tight {
  margin-bottom: var(--s8);
}
.note-fine {
  color: var(--muted-2);
  font-size: 13.5px;
  margin-top: var(--s16);
}

/* ============================ COMPONENTS =========================== */

/* --- Header + nav --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--hero-a);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.site-header .wrap {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s24);
}
.brand {
  display: inline-flex;
  align-items: center;
  flex: none;
  color: var(--white);
}
.brand:hover {
  color: var(--white);
}
.brand__logo {
  display: block;
  height: 52px;
  width: auto;
  max-width: 220px;
}
.main-nav {
  display: flex;
  align-items: center;
  gap: clamp(6px, 1.2vw, 14px);
}
.main-nav > ul {
  display: flex;
  align-items: center;
  gap: clamp(6px, 1.2vw, 14px);
  flex-wrap: wrap;
}
.main-nav a {
  color: #c7d2e1;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
}
/* every top-level nav link is a hover/open "chip": soft light pill background + a centered
   pill-shaped underline that scales in from the middle (not a straight edge-to-edge line) */
.main-nav > ul > li > a {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: var(--s8) var(--s12);
  border-radius: 999px;
  transition:
    background-color 0.18s ease,
    color 0.18s ease;
}
.main-nav > ul > li > a:hover,
.main-nav > ul > li > a:focus-visible {
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
}
.main-nav > ul > li > a::after {
  content: "";
  position: absolute;
  left: var(--s12);
  right: var(--s12);
  bottom: 2px;
  height: 3px;
  background: var(--brass-light);
  border-radius: 999px;
  transform: scaleX(0);
  transform-origin: 50% 50%;
  transition: transform 0.2s ease;
}
.main-nav > ul > li > a:hover::after,
.main-nav > ul > li > a:focus-visible::after {
  transform: scaleX(1);
}
.has-dropdown {
  position: relative;
  display: flex;
  align-items: center;
  gap: 2px;
}
.has-dropdown:hover > a,
.has-dropdown:focus-within > a {
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
}
.has-dropdown:hover > a::after,
.has-dropdown:focus-within > a::after {
  transform: scaleX(1);
}
/* caret: a real SVG chevron (not a text glyph) so it stays crisp and vertically centered
   with the label regardless of font/OS; the toggle button (mobile) has its own copy */
.nav-caret {
  display: inline-block;
  flex: none;
  margin-left: var(--s4);
  color: #8da0b8;
  transition:
    transform 0.2s ease,
    color 0.2s ease;
}
.has-dropdown:hover > a .nav-caret,
.has-dropdown:focus-within > a .nav-caret {
  transform: rotate(180deg);
  color: var(--brass-light);
}
.dropdown-toggle {
  display: none;
  background: none;
  border: none;
  color: #c7d2e1;
  cursor: pointer;
  padding: 0;
}
.dropdown-toggle .nav-caret {
  margin-left: 0;
}
.dropdown {
  position: absolute;
  left: var(--s12);
  top: calc(100% + 10px);
  min-width: 250px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 18px 40px -18px rgba(8, 20, 40, 0.5);
  padding: var(--s8);
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 70vh;
  overflow: auto;
  z-index: 60;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  pointer-events: none;
  transition:
    opacity 0.16s ease,
    transform 0.16s ease,
    visibility 0.16s;
}
/* the last dropdown would overflow the viewport on the right, so anchor it to the right edge */
.main-nav > ul > li:last-child .dropdown {
  left: auto;
  right: var(--s12);
}
/* keep dropdown reachable across the 10px gap while hovering */
.has-dropdown::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  height: 12px;
}
.dropdown a {
  color: var(--ink);
  font-size: 14.5px;
  font-weight: 600;
  padding: var(--s8) var(--s12);
  border-radius: 8px;
}
.dropdown a:hover {
  background: #f6f2e7;
  color: var(--brass-deep);
}
.has-dropdown:hover .dropdown,
.has-dropdown:focus-within .dropdown,
.dropdown.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}
.nav-toggle {
  display: none;
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 8px;
  color: #f5f2ea;
  padding: var(--s8) var(--s12);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  min-height: 44px;
}

/* --- Hero + calculator wrapper --- */
.hero {
  background: linear-gradient(160deg, var(--hero-a) 0%, var(--hero-b) 100%);
  /* the bottom padding seats the calculator card inside the hero; without it
     the card's bottom edge lands exactly on the seam with the next section */
  padding: var(--s64) 0 var(--s64);
}
.hero__inner {
  max-width: var(--wrap-calc);
  margin: 0 auto;
  padding: 0 var(--s24);
  text-align: center;
}
.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--s8);
  padding: var(--s8) var(--s16);
  border: 1px solid rgba(217, 182, 106, 0.35);
  border-radius: 999px;
  color: #e4ce9a;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.hero h1 {
  color: #fbf8f1;
  margin: var(--s24) 0 var(--s16);
}
.hero h1 em {
  font-style: italic;
  color: var(--brass-light);
}
.hero__sub {
  color: #a9b8cc;
  font-size: clamp(16px, 2vw, 19px);
  margin: 0 auto;
  max-width: 560px;
}
.calc-shell {
  max-width: var(--wrap-calc);
  margin: var(--s48) auto 0;
  padding: 0 var(--s16);
}

/* --- Stat cards --- */
.grid-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: var(--s16);
}
.stat {
  background: var(--white);
  border: 1px solid var(--line);
  border-top: 3px solid var(--brass);
  border-radius: var(--radius);
  padding: var(--s24);
  box-shadow: 0 6px 18px -12px rgba(20, 32, 54, 0.18);
}
.stat--red {
  border-top-color: var(--red);
}
.stat--green {
  border-top-color: #2e7d4f;
}
.stat--blue {
  border-top-color: #24558f;
}
.stat__label {
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: #7b8699;
  min-height: 30px;
}
.stat__value {
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(24px, 2.6vw, 30px);
  color: var(--navy-deep);
  margin-top: var(--s8);
  line-height: 1.15;
}
.stat__sub {
  color: var(--muted-2);
  font-size: 13.5px;
  margin-top: var(--s4);
}

/* --- Tables --- */
.table-card {
  background: var(--white);
  border: 1px solid #e5dfd0;
  border-radius: var(--radius);
  overflow: auto;
  box-shadow: 0 8px 24px -16px rgba(20, 32, 54, 0.2);
  max-height: 540px;
}
.table-card table {
  width: 100%;
  min-width: 640px;
  font-size: 15px;
}
.table-card th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--navy);
  color: #b9c6d8;
  text-align: left;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  padding: var(--s12) var(--s16);
}
.table-card td {
  padding: var(--s12) var(--s16);
  border-top: 1px solid var(--line-soft);
  color: #3a4a60;
}
.table-card tbody tr:nth-child(even) {
  background: #fbfaf6;
}
.table-card tbody tr:hover {
  background: #f6f2e7;
}
.td-strong {
  font-weight: 700;
  color: var(--ink-strong);
}
.td-num {
  color: #9aa3b2;
  font-weight: 600;
}
.td-region {
  font-weight: 600;
  color: #24344c;
}
.pill {
  display: inline-block;
  padding: var(--s4) var(--s12);
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 800;
}
.pill--good {
  background: #e3f1e6;
  color: #256b43;
}
.pill--mid {
  background: #eaf0f6;
  color: #44586f;
}
.pill--warn {
  background: #f9f0d8;
  color: var(--brass-deep);
}
.pill--bad {
  background: #f9e5e2;
  color: var(--red);
}

/* --- Author box --- */
.author-box {
  display: flex;
  gap: var(--s16);
  align-items: flex-start;
  margin: var(--s32) 0 0;
  padding: var(--s20) var(--s24);
  background: var(--panel-cream);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.author-box__photo {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  flex: none;
  border: 2px solid var(--white);
  box-shadow: 0 2px 8px rgba(20, 32, 54, 0.15);
}
.author-box__name {
  margin: 0 0 2px;
  font-size: 15px;
  font-weight: 800;
  color: var(--ink-strong);
}
.author-box__role {
  margin: 0 0 var(--s8);
  font-size: 13px;
  color: var(--muted);
}
.author-box__bio {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink);
}
@media (max-width: 520px) {
  .author-box {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

/* --- Callouts --- */
.callout {
  padding: var(--s16) var(--s24);
  border-radius: 0 12px 12px 0;
  margin: 0 0 var(--s16);
}
.callout__title {
  font-weight: 800;
  margin-bottom: var(--s4);
}
.callout p {
  margin: 0;
  font-size: 15px;
}
.callout p + p {
  margin-top: var(--s8);
}
.callout--blue {
  background: var(--tint-blue-bg);
  border-left: 3px solid var(--tint-blue-border);
  color: var(--tint-blue-fg);
}
.callout--blue .callout__title {
  color: #1e3a5c;
}
.callout--gold {
  background: var(--tint-gold-bg);
  border-left: 3px solid var(--brass);
  color: var(--tint-gold-fg);
}
.callout--gold .callout__title {
  color: var(--tint-gold-fg);
}
.callout--green {
  background: var(--tint-green-bg);
  border-left: 3px solid #2e7d4f;
  color: #2e5b42;
}
.callout--green .callout__title {
  color: var(--green);
}
.callout--red {
  background: var(--tint-red-bg);
  border-left: 3px solid #b4443c;
  color: #8e4038;
}
.callout--red .callout__title {
  color: var(--tint-red-fg);
}

/* --- Arrow lists / numbered steps --- */
.arrow-list {
  display: flex;
  flex-direction: column;
  gap: var(--s8);
  margin: 0 0 var(--s16);
}
.arrow-list li {
  display: flex;
  gap: var(--s12);
  align-items: baseline;
  color: var(--ink);
}
.arrow-list li::before {
  content: "→";
  color: var(--brass);
  font-weight: 800;
  flex: none;
}
.step-list {
  display: flex;
  flex-direction: column;
  gap: var(--s12);
  margin: 0 0 var(--s24);
  counter-reset: step;
}
.step-list li {
  display: flex;
  gap: var(--s12);
  align-items: baseline;
}
.step-list li::before {
  counter-increment: step;
  content: counter(step);
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #16335e;
  color: #f2e9d4;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
}
.subhead {
  font-weight: 800;
  color: var(--ink-strong);
  margin: 0 0 var(--s8);
}

/* --- Region cards --- */
.region-group {
  margin-top: var(--s32);
}
.region-group__head {
  display: flex;
  align-items: center;
  gap: var(--s16);
  margin-bottom: var(--s16);
}
.region-group__label {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 2.2px;
  text-transform: uppercase;
  color: #7b8699;
}
.region-group__rule {
  flex: 1;
  height: 1px;
  background: #e3ddce;
}
.grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: var(--s16);
}
.region-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--s24) var(--s24) var(--s16);
  box-shadow: 0 4px 14px -10px rgba(20, 32, 54, 0.15);
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease,
    border-color 0.15s ease;
}
.region-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 26px -12px rgba(20, 32, 54, 0.28);
  border-color: #d9cfb6;
}
.region-card__title {
  font-weight: 800;
  font-size: 16px;
  color: #16335e;
  display: inline-flex;
  align-items: baseline;
  gap: var(--s8);
}
.region-card__title span {
  color: var(--brass);
}
.region-card__title:hover {
  color: var(--brass-deep);
}
.region-card__desc {
  color: #5a6880;
  font-size: 14px;
  margin: var(--s8) 0 0;
  line-height: 1.55;
}

/* --- Guide/post cards (archive grids, e.g. /guides/) --- */
.grid-guides {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--s24);
  margin: var(--s32) 0;
}
.guide-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 4px 14px -10px rgba(20, 32, 54, 0.15);
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease,
    border-color 0.15s ease;
  display: flex;
  flex-direction: column;
}
.guide-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 26px -12px rgba(20, 32, 54, 0.28);
  border-color: #d9cfb6;
}
.guide-card__thumb {
  aspect-ratio: 16/9;
  width: 100%;
  object-fit: cover;
  display: block;
  background: var(--line-soft);
}
.guide-card__body {
  padding: var(--s16) var(--s16) var(--s24);
  display: flex;
  flex-direction: column;
  gap: var(--s8);
}
.guide-card__cat {
  align-self: flex-start;
}
.guide-card__title {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 700;
  color: var(--navy-deep);
  line-height: 1.3;
}
.guide-card__title a {
  color: inherit;
}
.guide-card__title a:hover {
  color: var(--brass-deep);
}
.guide-card__meta {
  font-size: 12.5px;
  color: var(--muted-2);
}
.guide-card__excerpt {
  color: #5a6880;
  font-size: 14px;
  line-height: 1.55;
  margin: 0;
}
.guide-card__more {
  font-size: 13.5px;
  font-weight: 800;
  color: var(--brass-deep);
  align-self: flex-start;
  margin-top: var(--s8);
}
.guide-card__more:hover {
  color: var(--brass);
}
.guide-pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--s8);
  margin: var(--s32) 0;
}
.guide-pagination a,
.guide-pagination span {
  min-width: 40px;
  height: 40px;
  padding: 0 var(--s12);
  border-radius: 10px;
  border: 1px solid var(--line);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
}
.guide-pagination a:hover {
  border-color: var(--brass);
  color: var(--brass-deep);
}
.guide-pagination span[aria-current="page"] {
  background: var(--navy);
  border-color: var(--navy);
  color: #fff;
}
.guide-pagination .dots {
  border: none;
}

/* --- Superbollo highlighted card --- */
.superbollo-card {
  background: linear-gradient(150deg, #fffdf6, #fbf3dc);
  border: 1px solid #e4c97e;
  border-radius: var(--radius-lg);
  padding: var(--s32);
  box-shadow: 0 14px 34px -20px rgba(143, 106, 36, 0.4);
}
.superbollo-card .callout {
  background: rgba(255, 255, 255, 0.7);
  margin-bottom: var(--s16);
}

/* --- Cost cards --- */
.grid-cost {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: var(--s16);
  margin-bottom: var(--s48);
}
.cost-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--s24) var(--s16);
  text-align: center;
  box-shadow: 0 4px 14px -10px rgba(20, 32, 54, 0.15);
}
.cost-card--free {
  background: #f2f8f1;
  border-color: #bfdcc2;
}
.cost-card__name {
  font-weight: 800;
  font-size: 15px;
  color: var(--ink-strong);
  line-height: 1.3;
}
.cost-card__spec {
  color: var(--muted-2);
  font-size: 12.5px;
  margin: var(--s4) 0 var(--s12);
}
.cost-card__price {
  font-family: var(--serif);
  font-weight: 700;
  font-size: 30px;
  color: var(--navy-deep);
  line-height: 1;
}
.cost-card--free .cost-card__price {
  color: #256b43;
}
.cost-card__unit {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: #9aa3b2;
  margin: var(--s8) 0;
}
.cost-card__year {
  border-top: 1px solid var(--line-soft);
  padding-top: var(--s8);
  font-size: 13px;
  color: var(--muted-2);
  font-weight: 500;
}
.cost-card--free .cost-card__year {
  color: #256b43;
  font-weight: 800;
}

/* --- Savings columns --- */
.grid-savings {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--s16);
  margin-bottom: var(--s32);
}
.savings-col {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--s24);
  box-shadow: 0 6px 18px -12px rgba(20, 32, 54, 0.18);
}
.savings-col__title {
  font-weight: 800;
  font-size: 16.5px;
  color: var(--ink-strong);
  margin-bottom: var(--s16);
}
.savings-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s8);
  padding: var(--s8) 0;
  border-top: 1px solid #f0ebe0;
  flex-wrap: wrap;
}
.savings-row .p {
  font-weight: 700;
  color: #3a4a60;
  font-size: 14px;
  white-space: nowrap;
}
.savings-row .v {
  color: var(--muted-2);
  font-size: 13.5px;
}
.savings-row .s {
  color: var(--green);
  font-weight: 800;
  font-size: 14px;
  white-space: nowrap;
}

/* --- Big highlight banner --- */
.banner-dark {
  background: linear-gradient(150deg, var(--hero-a), var(--hero-b));
  border-radius: var(--radius-lg);
  padding: var(--s48);
  text-align: center;
  margin-bottom: var(--s32);
}
.banner-dark__label {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 2.4px;
  text-transform: uppercase;
  color: #9fb2ca;
}
.banner-dark__value {
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(56px, 8vw, 84px);
  line-height: 1.05;
  color: var(--brass-light);
  margin: var(--s8) 0;
}
.banner-dark__sub {
  color: #a9b8cc;
  font-size: 15.5px;
}

/* --- FAQ --- */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: var(--s16);
}
.faq {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--s24);
  box-shadow: 0 4px 14px -10px rgba(20, 32, 54, 0.15);
}
.faq h3 {
  font-family: var(--sans);
  font-weight: 800;
  font-size: 17px;
  color: var(--ink-strong);
  margin: 0 0 var(--s8);
}
.faq p {
  margin: 0 0 var(--s12);
  color: #4a5a70;
  font-size: 15.5px;
}
.faq p:last-child {
  margin: 0;
}

/* --- CTA --- */
.cta {
  max-width: var(--wrap);
  margin: 0 auto;
  background: linear-gradient(150deg, var(--hero-a), var(--hero-b));
  border-radius: 22px;
  padding: var(--s64) var(--s48);
  text-align: center;
}
.cta h2 {
  color: #fbf8f1;
  margin-bottom: var(--s16);
}
.cta p {
  max-width: 520px;
  margin: 0 auto var(--s24);
  color: #a9b8cc;
  font-size: 16.5px;
}

/* --- Buttons --- */
.btn-gold {
  display: inline-block;
  padding: var(--s16) var(--s32);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  background: linear-gradient(135deg, var(--brass-light), var(--brass));
  color: #241a05;
  font-family: var(--sans);
  font-size: 16.5px;
  font-weight: 800;
  letter-spacing: 0.3px;
  box-shadow: 0 14px 30px -12px rgba(221, 190, 121, 0.5);
  min-height: 44px;
}
.btn-gold:hover {
  filter: brightness(1.07);
  color: #241a05;
}

/* --- Pills row (Pagine Importanti) --- */
.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s8);
}
.pill-link {
  display: inline-block;
  padding: var(--s8) var(--s16);
  background: var(--white);
  border: 1px solid #e3dccb;
  border-radius: 999px;
  color: #16335e;
  font-size: 14.5px;
  font-weight: 700;
  min-height: 44px;
  line-height: 26px;
}
.pill-link:hover {
  border-color: var(--brass);
  color: var(--brass-deep);
  background: #fdfbf4;
}

/* --- Author box --- */
.author {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: var(--s24);
  display: flex;
  gap: var(--s16);
  align-items: flex-start;
  flex-wrap: wrap;
  box-shadow: 0 4px 14px -10px rgba(20, 32, 54, 0.15);
}
.author__avatar {
  flex: none;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, #16335e, var(--hero-a));
  color: var(--brass-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 22px;
}
/* When .author__avatar is an <img> (real photo) rather than a text-initials
   placeholder div, fill the same circle instead of centering text in it. */
img.author__avatar {
  object-fit: cover;
}
.author__body {
  flex: 1;
  min-width: 240px;
}
.author__name {
  font-weight: 800;
  font-size: 17px;
  color: var(--ink-strong);
}
.author__bio {
  margin: var(--s8) 0;
  color: #4a5a70;
  font-size: 15px;
}
.author__meta {
  color: var(--muted-2);
  font-size: 13.5px;
}
.author__meta a {
  text-decoration: underline;
}

/* --- Breadcrumb --- */
.breadcrumb {
  padding: var(--s12) 0;
}
.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s8);
  font-size: 13.5px;
  color: var(--muted);
}
.breadcrumb li {
  display: flex;
  gap: var(--s8);
  align-items: center;
}
.breadcrumb li + li::before {
  content: "/";
  color: var(--muted-2);
}

/* --- Footer --- */
.site-footer {
  background: var(--hero-a);
  color: #a9b8cc;
  padding: var(--s64) 0 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--s32) var(--s24);
  padding-bottom: var(--s48);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.footer-brand__row {
  display: flex;
  align-items: center;
  gap: var(--s8);
  margin-bottom: var(--s12);
}
.footer-brand__mark {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: linear-gradient(135deg, var(--brass), var(--brass-light));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--hero-a);
  font-weight: 800;
  font-size: 13px;
}
.footer-brand__name {
  font-weight: 800;
  font-size: 16px;
  color: #f5f2ea;
}
.footer-brand p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.65;
  color: #8da0b8;
}
.footer-col__title {
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #6e82a0;
  margin-bottom: var(--s12);
}
.footer-col ul {
  display: flex;
  flex-direction: column;
  gap: var(--s8);
  font-size: 14.5px;
}
.footer-col a {
  color: #b9c6d8;
}
.footer-col a:hover {
  color: var(--white);
}
.footer-social {
  display: flex;
  gap: var(--s12);
  margin-top: var(--s12);
}
.footer-social a {
  color: #b9c6d8;
  display: inline-flex;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
}
.footer-social a:hover {
  color: var(--white);
}
.footer-bottom {
  text-align: center;
  padding: var(--s24) 0;
  font-size: 13.5px;
  color: #6e82a0;
}

/* --- Calculator widget (cba26) --- */
.cba26 {
  background: var(--white);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  box-shadow: 0 24px 60px -20px rgba(8, 20, 40, 0.45);
  overflow: hidden;
}
.cba26 * {
  box-sizing: border-box;
}
.cba26-tr {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}
.cba26-ts {
  display: flex;
  border-bottom: 1px solid #e9e4d8;
  background: #f6f3eb;
}
.cba26-tl {
  flex: 1;
  padding: var(--s16) var(--s12);
  text-align: center;
  font-weight: 700;
  font-size: 15.5px;
  color: #7b8699;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  margin-bottom: -1px;
  line-height: 1.3;
  transition: all 0.2s;
  display: block;
  user-select: none;
  min-height: 44px;
}
.cba26-tl:hover {
  color: var(--navy-deep);
  background: #f1ede2;
}
#cba26-r1:checked ~ .cba26-ts .cba26-t1,
#cba26-r3:checked ~ .cba26-ts .cba26-t3 {
  color: var(--navy-deep);
  border-bottom-color: var(--brass);
  background: var(--white);
}
.cba26-bd {
  padding: var(--s32);
  background: var(--white);
}
.cba26-pn {
  display: none;
}
#cba26-r1:checked ~ .cba26-bd .cba26-p1,
#cba26-r3:checked ~ .cba26-bd .cba26-p3 {
  display: block;
}
.cba26-gr {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--s24);
}
.cba26-fw {
  grid-column: 1/-1;
}
.cba26-lb {
  font-size: 12px;
  font-weight: 800;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  display: block;
  margin-bottom: var(--s8);
}
.cba26-lb em {
  color: var(--red);
  font-style: normal;
}
.cba26-in {
  width: 100%;
  padding: var(--s12);
  border: 1.5px solid #dcd6c8;
  border-radius: 10px;
  font-size: 15.5px;
  font-family: var(--sans);
  background: #fdfcf9;
  color: var(--ink);
  appearance: none;
  -webkit-appearance: none;
  transition:
    border-color 0.2s,
    box-shadow 0.2s,
    background 0.2s;
}
.cba26-in:focus {
  outline: none;
  border-color: var(--brass);
  box-shadow: 0 0 0 3px rgba(176, 132, 48, 0.15);
  background: var(--white);
}
.cba26-in.err {
  border-color: var(--red) !important;
  background: #fff1f2 !important;
  box-shadow: 0 0 0 3px rgba(160, 59, 51, 0.12) !important;
}
.cba26-rds {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s8);
}
.cba26-rl {
  display: flex;
  align-items: center;
  gap: var(--s8);
  padding: var(--s12);
  border: 1.5px solid #dcd6c8;
  border-radius: 10px;
  cursor: pointer;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--muted);
  transition: all 0.2s;
  min-height: 44px;
}
.cba26-rl:has(input:checked) {
  border-color: var(--brass);
  background: #fbf5e6;
  color: var(--tint-gold-fg);
}
.cba26-rl input {
  accent-color: var(--brass);
  flex-shrink: 0;
  width: 16px;
  height: 16px;
}
.cba26-btn {
  grid-column: 1/-1;
  width: 100%;
  margin-top: var(--s4);
  padding: var(--s16) var(--s24);
  background: linear-gradient(135deg, var(--brass), #8f6a24);
  color: #fff9ec;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 0.3px;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  box-shadow: 0 10px 24px -10px rgba(143, 106, 36, 0.55);
  transition: filter 0.2s;
  min-height: 44px;
}
.cba26-btn:hover {
  filter: brightness(1.06);
}
.cba26-errmsg {
  grid-column: 1/-1;
  background: var(--tint-red-bg);
  border: 1px solid #ebc5c0;
  border-radius: 10px;
  padding: var(--s12) var(--s16);
  font-size: 14.5px;
  color: var(--red);
  font-weight: 600;
  display: none;
}
.cba26-errmsg.show {
  display: block;
}
.cba26-rs {
  grid-column: 1/-1;
  display: none;
  margin-top: var(--s4);
  border-radius: var(--radius);
  overflow: hidden;
  background: linear-gradient(160deg, var(--hero-a), var(--hero-b));
  animation: cba26fade 0.3s ease;
}
@keyframes cba26fade {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.cba26-rh {
  padding: var(--s24);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--s12);
}
.cba26-rh .cba26-rt {
  color: #d9be7c;
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin: 0;
}
.cba26-ra {
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(32px, 5vw, 44px);
  color: var(--white);
  line-height: 1;
}
.cba26-rb {
  background: rgba(255, 255, 255, 0.04);
  padding: var(--s24);
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}
.cba26-rr {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--s8) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 14.5px;
  gap: var(--s8);
}
.cba26-rr:last-child {
  border: none;
}
.cba26-rk {
  color: #a9b8cc;
  font-weight: 500;
}
.cba26-rv {
  color: #f2e9d4;
  font-weight: 700;
  text-align: right;
}
.cba26-rv strong,
.cba26-rk strong {
  color: #fff;
}
.cba26-rn {
  font-size: 12.5px;
  color: #8da0b8;
  margin-top: var(--s12);
  line-height: 1.6;
}
.calc-how {
  background: var(--white);
  border-top: 1px solid var(--line-soft);
  padding: var(--s24) var(--s32);
}
.calc-how h2 {
  font-family: var(--sans);
  font-style: normal;
  font-weight: 800;
  font-size: 16px;
  color: var(--ink-strong);
  margin: 0 0 var(--s4);
}
.calc-how p {
  font-size: 15.5px;
  color: var(--muted);
  margin: 0;
}

@media (max-width: 768px) {
  .cba26-bd {
    padding: var(--s16);
  }
  .cba26-gr {
    grid-template-columns: 1fr;
  }
  .cba26-tl {
    font-size: 14px;
  }
  .calc-how {
    padding: var(--s16);
  }
}

/* --- Region article (shared by all region/post pages) --- */
.region-article {
  max-width: var(--wrap-narrow);
  margin: 0 auto;
  padding: var(--s48) var(--s24);
}
.region-article h2 {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(26px, 3.4vw, 38px);
  color: var(--navy-deep);
  margin: var(--s48) 0 var(--s16);
  line-height: 1.18;
}
.region-article h3 {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(21px, 2.6vw, 28px);
  color: var(--navy-deep);
  margin: var(--s32) 0 var(--s12);
  line-height: 1.2;
}
.region-article h4 {
  font-family: var(--sans);
  font-weight: 800;
  font-size: 18px;
  color: var(--ink-strong);
  margin: var(--s24) 0 var(--s8);
}
.region-article p {
  margin: 0 0 var(--s16);
  color: #3a4a60;
}
.region-article ul,
.region-article ol {
  margin: 0 0 var(--s16) var(--s24);
  display: flex;
  flex-direction: column;
  gap: var(--s8);
}
.region-article ul li {
  list-style: disc;
}
.region-article ol li {
  list-style: decimal;
}
.region-article li {
  color: #3a4a60;
}
.region-article li::marker {
  color: var(--brass);
}
.region-article a {
  color: var(--link);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.region-article a:hover {
  color: var(--brass-deep);
}
.region-article strong {
  color: var(--ink-strong);
}
.region-article figure {
  margin: var(--s24) 0;
}
.region-article img {
  border-radius: var(--radius);
  border: 1px solid var(--line);
}
.region-article .table-card {
  margin: var(--s24) 0;
}
.region-article .table-card table {
  min-width: 520px;
}
.region-article .table-card td {
  border-top: 1px solid var(--line-soft);
  vertical-align: top;
}
.region-article .table-card tr:first-child td {
  background: var(--navy);
  color: #eaf0f8;
  font-weight: 700;
}
.region-article .table-card tr:first-child td strong {
  color: #fff;
}

/* --- Region calculator widget (bollo-widget) --- */
.bollo-widget {
  max-width: 600px;
  margin: 0 auto;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 60px -20px rgba(8, 20, 40, 0.45);
  overflow: hidden;
}
.bollo-header {
  background: linear-gradient(135deg, var(--hero-a), var(--hero-b));
  color: #fff;
  padding: var(--s32) var(--s32) var(--s24);
  text-align: center;
}
.bollo-header .region-badge {
  display: inline-block;
  background: rgba(217, 182, 106, 0.18);
  border: 1px solid rgba(217, 182, 106, 0.35);
  color: var(--brass-light);
  border-radius: 999px;
  padding: var(--s4) var(--s16);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: var(--s8);
}
.bollo-header h2 {
  font-family: var(--serif);
  color: #fff;
  font-size: 24px;
  font-weight: 700;
  margin: 0 0 var(--s4);
}
.bollo-header p {
  font-size: 14px;
  color: #a9b8cc;
  margin: 0;
}
.bollo-body {
  padding: var(--s32);
}
.form-group {
  margin-bottom: var(--s16);
}
.form-group label {
  display: block;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: var(--s8);
}
.form-group input[type="number"],
.form-group input[type="text"],
.form-group select {
  width: 100%;
  padding: var(--s12) var(--s16);
  border: 1.5px solid #dcd6c8;
  border-radius: 10px;
  font-size: 15.5px;
  font-family: var(--sans);
  color: var(--ink);
  background: #fdfcf9;
  transition:
    border-color 0.2s,
    box-shadow 0.2s,
    background 0.2s;
  outline: none;
  box-sizing: border-box;
}
.form-group input.targa-input {
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 700;
  text-align: center;
}
.form-group select.err,
.form-group input.err {
  border-color: var(--red) !important;
  background: #fdf1f0 !important;
  box-shadow: 0 0 0 3px rgba(160, 59, 51, 0.12) !important;
}
.notfound-body {
  padding-top: var(--s48);
  padding-bottom: var(--s96);
}
.cbtg-errmsg {
  display: none;
  background: var(--tint-blue-bg, #fef2f2);
  border: 1.5px solid var(--red);
  border-radius: 10px;
  padding: var(--s12) var(--s16);
  margin-top: var(--s12);
  font-size: 13px;
  color: var(--red);
  font-weight: 600;
}
.cbtg-errmsg.show {
  display: block;
}
.form-group input:focus,
.form-group select:focus {
  border-color: var(--brass);
  box-shadow: 0 0 0 3px rgba(176, 132, 48, 0.15);
  background: #fff;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s16);
}
.btn-calcola {
  width: 100%;
  padding: var(--s16);
  background: linear-gradient(135deg, var(--brass), #8f6a24);
  color: #fff9ec;
  border: none;
  border-radius: 12px;
  font-size: 16.5px;
  font-weight: 800;
  letter-spacing: 0.3px;
  cursor: pointer;
  margin-top: var(--s8);
  box-shadow: 0 10px 24px -10px rgba(143, 106, 36, 0.55);
  transition: filter 0.2s;
  min-height: 44px;
  text-align: center;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--s8);
  box-sizing: border-box;
}
.btn-calcola:hover {
  filter: brightness(1.06);
}
.btn-reset {
  display: none;
  width: 100%;
  padding: var(--s12);
  background: #f6f3eb;
  color: var(--muted);
  border: 1.5px solid #e5dfd0;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  margin-top: var(--s8);
  min-height: 44px;
}
.btn-reset:hover {
  background: #efe9dc;
}
.result-box {
  display: none;
  margin-top: var(--s24);
  background: linear-gradient(160deg, var(--hero-a), var(--hero-b));
  border-radius: var(--radius);
  padding: var(--s24);
  text-align: center;
  color: #eaf0f8;
}
.result-box .result-label {
  font-size: 12px;
  color: var(--brass-light);
  font-weight: 800;
  margin-bottom: var(--s8);
  text-transform: uppercase;
  letter-spacing: 1.5px;
}
.result-box .result-amount {
  font-family: var(--serif);
  font-size: clamp(34px, 5vw, 42px);
  font-weight: 700;
  color: #fff;
  margin-bottom: var(--s4);
}
.result-box .result-detail {
  font-size: 13px;
  color: #a9b8cc;
  margin-top: var(--s8);
  line-height: 1.6;
}
.superbollo-box {
  display: none;
  margin-top: var(--s12);
  background: var(--tint-gold-bg);
  border: 1px solid #e4c97e;
  border-radius: 10px;
  padding: var(--s12) var(--s16);
  text-align: center;
}
.superbollo-box .sb-label {
  font-size: 13px;
  color: var(--brass-deep);
  font-weight: 800;
  margin-bottom: var(--s4);
}
.superbollo-box .sb-amount {
  font-size: 26px;
  font-weight: 800;
  color: #8f6a24;
}
.superbollo-box .sb-detail {
  font-size: 12px;
  color: #6b5320;
  margin-top: var(--s4);
}
.esenzione-box {
  display: none;
  margin-top: var(--s12);
  background: var(--tint-green-bg);
  border: 1px solid #7cc79a;
  border-radius: 10px;
  padding: var(--s12) var(--s16);
  text-align: center;
  font-size: 14px;
  color: var(--green);
  font-weight: 600;
}
.info-note {
  font-size: 12px;
  color: var(--muted-2);
  margin-top: var(--s16);
  text-align: center;
  line-height: 1.5;
}
.sepa-badge {
  display: inline-block;
  background: var(--tint-green-bg);
  border: 1px solid #7cc79a;
  color: var(--green);
  border-radius: 8px;
  padding: var(--s8) var(--s12);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: var(--s16);
}
.fvg-note,
.lazio-note,
.marche-note,
.no-ibridi {
  display: block;
  background: var(--tint-blue-bg);
  border: 1px solid var(--tint-blue-border);
  color: var(--tint-blue-fg);
  border-radius: 8px;
  padding: var(--s8) var(--s12);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: var(--s16);
  line-height: 1.45;
}
@media (max-width: 520px) {
  .bollo-body {
    padding: var(--s24) var(--s16);
  }
  .form-row {
    grid-template-columns: 1fr;
  }
}

/* --- Region calculator widget, alt generation (calculator-wrapper) — Lombardia --- */
.calculator-wrapper {
  max-width: 600px;
  margin: 0 auto;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 60px -20px rgba(8, 20, 40, 0.45);
  overflow: hidden;
}
.calc-header {
  background: linear-gradient(135deg, var(--hero-a), var(--hero-b));
  color: #fff;
  padding: var(--s32) var(--s32) var(--s24);
  text-align: center;
}
.calc-header h2 {
  font-family: var(--serif);
  color: #fff;
  font-size: 24px;
  font-weight: 700;
  margin: 0 0 var(--s4);
}
.calc-header p {
  font-size: 14px;
  color: #a9b8cc;
  margin: 0;
}
.calc-body {
  padding: var(--s32);
}
.discount-banner {
  background: var(--tint-green-bg);
  border: 1px solid #7cc79a;
  color: var(--green);
  border-radius: 8px;
  padding: var(--s8) var(--s12);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: var(--s16);
}
.discount-banner .tag-icon {
  margin-right: var(--s4);
}
.field-group {
  margin-bottom: var(--s16);
}
.field-label {
  display: block;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: var(--s8);
}
.field-input,
.field-select {
  width: 100%;
  padding: var(--s12) var(--s16);
  border: 1.5px solid #dcd6c8;
  border-radius: 10px;
  font-size: 15.5px;
  font-family: var(--sans);
  color: var(--ink);
  background: #fdfcf9;
  transition:
    border-color 0.2s,
    box-shadow 0.2s,
    background 0.2s;
  outline: none;
}
.field-input:focus,
.field-select:focus {
  border-color: var(--brass);
  box-shadow: 0 0 0 3px rgba(176, 132, 48, 0.15);
  background: #fff;
}
.select-wrap {
  position: relative;
}
.fields-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s16);
}
.error-msg {
  display: none;
  background: var(--tint-red-bg);
  border: 1px solid var(--red);
  color: var(--red);
  border-radius: 8px;
  padding: var(--s8) var(--s12);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: var(--s16);
}
.error-msg.visible {
  display: block;
}
.calc-btn {
  width: 100%;
  padding: var(--s16);
  background: linear-gradient(135deg, var(--brass), #8f6a24);
  color: #fff9ec;
  border: none;
  border-radius: 12px;
  font-size: 16.5px;
  font-weight: 800;
  letter-spacing: 0.3px;
  cursor: pointer;
  margin-top: var(--s8);
  box-shadow: 0 10px 24px -10px rgba(143, 106, 36, 0.55);
  transition: filter 0.2s;
  min-height: 44px;
}
.calc-btn:hover {
  filter: brightness(1.06);
}
.reset-btn {
  display: none;
  width: 100%;
  padding: var(--s12);
  background: #f6f3eb;
  color: var(--muted);
  border: 1.5px solid #e5dfd0;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  margin-top: var(--s8);
  min-height: 44px;
}
.reset-btn.visible {
  display: block;
}
.reset-btn:hover {
  background: #efe9dc;
}
.calculator-wrapper .result-box {
  display: none;
  margin-top: var(--s24);
  background: linear-gradient(160deg, var(--hero-a), var(--hero-b));
  border-radius: var(--radius);
  padding: var(--s24);
  text-align: center;
  color: #eaf0f8;
}
.calculator-wrapper .result-box.visible {
  display: block;
}
.calculator-wrapper .result-box .result-label {
  font-size: 12px;
  color: var(--brass-light);
  font-weight: 800;
  margin-bottom: var(--s8);
  text-transform: uppercase;
  letter-spacing: 1.5px;
}
.calculator-wrapper .result-box .result-amount {
  font-family: var(--serif);
  font-size: clamp(34px, 5vw, 42px);
  font-weight: 700;
  color: #fff;
  margin-bottom: var(--s4);
}
.calculator-wrapper .result-box .result-sub {
  font-size: 13px;
  color: #a9b8cc;
  margin-top: var(--s8);
}
.result-breakdown {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--s4) var(--s12);
  margin-top: var(--s16);
  padding-top: var(--s16);
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  text-align: left;
}
.result-breakdown .bd-label {
  font-size: 12.5px;
  color: #a9b8cc;
}
.result-breakdown .bd-val {
  font-size: 12.5px;
  color: #eaf0f8;
  font-weight: 700;
  text-align: right;
}
.calc-footer {
  padding: var(--s16) var(--s32);
  background: #f6f3eb;
  display: flex;
  flex-direction: column;
  gap: var(--s4);
  font-size: 12px;
  color: var(--muted-2);
  text-align: center;
}
.calc-footer a {
  color: var(--brass-deep);
  font-weight: 600;
}
@media (max-width: 520px) {
  .calc-body {
    padding: var(--s24) var(--s16);
  }
  .fields-row {
    grid-template-columns: 1fr;
  }
}

/* ============================ UTILITIES =========================== */
.mt-32 {
  margin-top: var(--s32);
}
.mb-0 {
  margin-bottom: 0;
}
.center {
  text-align: center;
}
strong {
  color: var(--ink-strong);
}
.section .lead strong,
.callout strong,
.arrow-list strong,
.faq strong {
  color: inherit;
}

/* ============================ RESPONSIVE ========================== */
@media (max-width: 768px) {
  body {
    font-size: 16px;
  }
  .section {
    padding: var(--s48) 0;
  }
  .cta {
    padding: var(--s48) var(--s24);
  }
  .banner-dark {
    padding: var(--s32);
  }
  .superbollo-card {
    padding: var(--s24);
  }

  .nav-toggle {
    display: inline-flex;
    align-items: center;
  }
  .main-nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 76px;
    background: var(--hero-a);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: var(--s12) var(--s24) var(--s24);
    max-height: 80vh;
    overflow: auto;
  }
  .main-nav.open {
    display: flex;
  }
  .main-nav > ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }
  .main-nav > ul > li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }
  .main-nav a {
    display: flex;
    width: 100%;
    padding: var(--s12) 0;
    min-height: 44px;
  }
  /* mobile: no hover — the caret button toggles the submenu; underline pill swaps for a left accent bar */
  .main-nav > ul > li > a {
    border-radius: 0;
    padding-left: 0;
    padding-right: 0;
  }
  .main-nav > ul > li > a:hover,
  .main-nav > ul > li > a:focus-visible {
    background: transparent;
    color: var(--white);
  }
  .main-nav > ul > li > a::after {
    display: none;
  }
  .main-nav > ul > li {
    position: relative;
    padding-left: 0;
    transition:
      padding-left 0.15s ease,
      border-color 0.15s ease;
  }
  .main-nav > ul > li:has(.dropdown.open) {
    padding-left: var(--s12);
    border-color: rgba(221, 190, 121, 0.35);
  }
  .main-nav > ul > li:has(.dropdown.open)::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--brass-light);
    border-radius: 2px;
  }
  .has-dropdown {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
  }
  .has-dropdown > a {
    flex: 1;
  }
  /* the anchor's own caret is desktop-only; mobile shows the toggle button's caret instead */
  .has-dropdown > a .nav-caret {
    display: none;
  }
  .has-dropdown::after {
    display: none;
  }
  .dropdown-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
    color: #c7d2e1;
  }
  .dropdown-toggle .nav-caret {
    transition:
      transform 0.2s ease,
      color 0.2s ease;
  }
  .dropdown-toggle[aria-expanded="true"] .nav-caret {
    color: var(--brass-light);
    transform: rotate(180deg);
  }
  .dropdown {
    position: static;
    box-shadow: none;
    border: none;
    background: transparent;
    padding: 0 0 var(--s8) var(--s16);
    min-width: 0;
    max-height: none;
    flex-basis: 100%;
    /* Mobile show/hide is driven purely by `display`. The desktop rule keeps the
       panel in flow (opacity/visibility only) so it can transition; in the static
       mobile stack that leaves a closed submenu occupying hundreds of px of blank
       space, so neutralise those and collapse it outright. */
    display: none;
    opacity: 1;
    visibility: visible;
    transform: none;
    pointer-events: auto;
  }
  .dropdown a {
    color: #b9c6d8;
    padding: var(--s8) 0;
  }
  .dropdown a:hover {
    background: transparent;
    color: var(--white);
  }
  /* Desktop opens on hover/focus-within; on mobile only an explicit tap (.open)
     may open. Exclude .open here — tapping the toggle focuses it, so a bare
     :focus-within rule would out-specify `.dropdown.open` and slam the panel
     shut the instant it was opened. */
  .has-dropdown:hover .dropdown:not(.open),
  .has-dropdown:focus-within .dropdown:not(.open) {
    display: none;
  }
  .dropdown.open {
    display: flex;
  }
}

/* scadenza tool result */
.scad-res {
  margin-top: var(--s16);
}
.scad-res__lead {
  font-size: 14px;
  color: var(--muted);
  margin: 0 0 var(--s8);
}
.scad-res__main {
  font-family: var(--serif);
  font-size: clamp(20px, 3.4vw, 26px);
  line-height: 1.3;
  margin: 0 0 var(--s12);
}
.scad-res__note {
  font-size: 14px;
  line-height: 1.6;
  margin: 0;
}

/* sticky jump-back-to-calculator button */
.calc-jump {
  position: fixed;
  right: var(--s16);
  bottom: var(--s16);
  z-index: 70;
  background: var(--brass-deep, #8a6d2f);
  color: #fff;
  font-weight: 700;
  font-size: 14.5px;
  padding: var(--s12) var(--s16);
  border-radius: 999px;
  box-shadow: 0 12px 28px -10px rgba(8, 20, 40, 0.55);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  pointer-events: none;
  transition:
    opacity 0.18s ease,
    transform 0.18s ease,
    visibility 0.18s;
}
.calc-jump.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}
.calc-jump:hover {
  color: #fff;
  filter: brightness(1.08);
}
@media (prefers-reduced-motion: reduce) {
  .calc-jump {
    transition: none;
  }
}

/* hero freshness line */
.hero__meta {
  margin-top: var(--s12);
  font-size: 13.5px;
  color: #9fb0c6;
}
.hero__meta a {
  color: inherit;
  text-decoration: underline;
}
.hero__meta a:hover {
  color: var(--brass-light);
}

/* consent banner (only rendered when a deferred script needs consent) */
.consent {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 90;
  background: var(--white);
  border-top: 1px solid var(--line);
  box-shadow: 0 -14px 40px -20px rgba(8, 20, 40, 0.45);
}
.consent__inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: var(--s16);
  display: flex;
  gap: var(--s16);
  align-items: center;
  flex-wrap: wrap;
}
.consent__body {
  flex: 1 1 320px;
  min-width: 0;
}
.consent__title {
  font-weight: 800;
  margin: 0 0 4px;
  font-size: 15px;
}
.consent__text {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--muted);
}
.consent__actions {
  display: flex;
  gap: var(--s8);
  flex-wrap: wrap;
}
.consent__btn {
  border: 1px solid var(--brass-deep);
  background: var(--brass-deep);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  padding: var(--s12) var(--s24);
  border-radius: 999px;
  cursor: pointer;
}
.consent__btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.consent__btn:hover {
  filter: brightness(1.08);
}
@media (max-width: 640px) {
  .consent__actions {
    width: 100%;
  }
  .consent__btn {
    flex: 1;
  }
}

/* ---------------------------------------------------------------------------
   Themed <select> pickers.

   A native option list is rendered by the operating system, not the page, so
   CSS cannot reach it — that is why the default popup looks like a square,
   system-blue Windows menu regardless of how the closed control is styled.
   `appearance: base-select` pulls the picker into the page so it can inherit
   the site's own look. Everything lives inside @supports: browsers without it
   keep the plain native picker and lose nothing.

   Colours below intentionally mirror the site nav's .dropdown, so both menus
   on the page look like the same component.
   --------------------------------------------------------------------------- */
@supports (appearance: base-select) {
  .cba26-in,
  .field-select {
    appearance: base-select;
  }

  /* the arrow the browser supplies once the control is opted in */
  .cba26-in::picker-icon,
  .field-select::picker-icon {
    color: var(--brass-deep);
    transition: transform 0.18s ease;
  }
  .cba26-in:open::picker-icon,
  .field-select:open::picker-icon {
    transform: rotate(180deg);
  }

  /* the popup itself */
  ::picker(select) {
    appearance: base-select;
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 18px 40px -18px rgba(8, 20, 40, 0.5);
    padding: var(--s8);
    margin-top: 6px;
    max-height: 320px;
    overflow-y: auto;
    /* match the closed control instead of inheriting the OS popup font */
    font-family: var(--sans);
    font-size: 14.5px;
  }

  .cba26-in option,
  .field-select option {
    padding: var(--s8) var(--s12);
    border-radius: 8px;
    color: var(--ink);
    background: transparent;
    cursor: pointer;
    transition:
      background 0.12s ease,
      color 0.12s ease;
  }

  /* brass hover/keyboard highlight instead of the system blue */
  .cba26-in option:hover,
  .cba26-in option:focus,
  .cba26-in option:active,
  .field-select option:hover,
  .field-select option:focus,
  .field-select option:active {
    background: #f6f2e7;
    color: var(--brass-deep);
    outline: none;
  }

  .cba26-in option:checked,
  .field-select option:checked {
    background: var(--brass-deep);
    color: var(--white);
    font-weight: 700;
  }

  /* the selected-item tick is redundant next to the filled highlight */
  .cba26-in option::checkmark,
  .field-select option::checkmark {
    display: none;
  }

  /* the placeholder row reads as helper text, not a real choice */
  .cba26-in option[value=""],
  .field-select option[value=""] {
    color: var(--muted);
  }
}
