/* Repère Salarié — le guide des droits du salarié (indemnite-rupture-conventionnelle.fr) */

/* Charter draws U+00A0 twice as wide as a space: take the no-break space from a font with a normal one */
@font-face {
  font-family: "Nbsp";
  src: local("Georgia"), local("Times New Roman"), local("Arial");
  unicode-range: U+00A0;
}

:root {
  --navy: #12284a;
  --navy-2: #1d3a66;
  --navy-soft: #e8eef7;
  --ink: #18212d;
  --text: #2c3746;
  --muted: #5d6877;
  --line: #dde3ea;
  --soft: #f4f6f9;
  --gold: #c39233;
  --gold-text: #8a6214;
  --gold-soft: #fbf5e8;
  --ok: #1f6f4a;
  --ok-soft: #eaf5ef;
  --warn-soft: #fff6e5;
  --radius: 10px;
  --serif: "Nbsp", Charter, "Bitstream Charter", "Sitka Text", Cambria, Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: #fff;
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: var(--navy-2);
  text-underline-offset: 3px;
}

a:hover {
  color: var(--navy);
}

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

h1,
h2,
h3,
h4 {
  font-family: var(--serif);
  color: var(--ink);
  line-height: 1.2;
  margin: 0 0 0.5em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2rem, 4.2vw, 2.9rem);
  letter-spacing: -0.01em;
}

h2 {
  font-size: clamp(1.45rem, 2.6vw, 1.85rem);
}

h3 {
  font-size: 1.22rem;
}

p {
  margin: 0 0 1em;
}

img,
svg {
  max-width: 100%;
}

.wrap {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.skip {
  position: absolute;
  left: -9999px;
}

.skip:focus {
  left: 12px;
  top: 12px;
  z-index: 100;
  background: #fff;
  padding: 8px 14px;
}

/* Header */

.masthead {
  position: sticky;
  top: 0;
  z-index: 40;
  background: #fff;
  box-shadow: 0 1px 0 var(--line);
}

.masthead-top {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 66px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  color: var(--ink);
  flex: none;
}

.brand-mark {
  width: 38px;
  height: 38px;
  flex: none;
}

.brand-name {
  display: block;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.12rem;
  line-height: 1.1;
  color: var(--navy);
  letter-spacing: -0.005em;
}

.brand-tag {
  display: block;
  font-size: 0.76rem;
  color: var(--muted);
  line-height: 1.25;
  margin-top: 2px;
}

.top-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 16px;
}

.top-link {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--navy);
  text-decoration: none;
}

.top-link:hover,
.top-link[aria-current] {
  color: var(--gold-text);
  text-decoration: underline;
}

.top-note {
  font-size: 0.8rem;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 10px;
}

.btn-sm {
  padding: 9px 16px;
  font-size: 0.9rem;
}

.mainbar {
  background: var(--navy);
}

.menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: space-between;
  position: relative;
}

.has-sub {
  position: relative;
}

.menu > .has-sub {
  position: static;
}

.menu .top {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 14px;
  color: #e3eaf4;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.93rem;
  white-space: nowrap;
}

.menu .top::after {
  content: "";
  width: 6px;
  height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  opacity: 0.7;
}

.menu .has-sub:hover > .top,
.menu .has-sub:focus-within > .top,
.menu .is-current > .top {
  color: #fff;
  background: var(--navy-2);
}

.menu .is-current > .top {
  box-shadow: inset 0 -3px 0 var(--gold);
}

.sub {
  display: block;
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  /* closes quickly, opens after a 0.3 s hover so passing the mouse over the bar does not flash the panels */
  transition: opacity 0.12s ease, visibility 0s linear 0.12s;
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 50;
  width: min(640px, calc(100vw - 48px));
  background: #fff;
  border: 1px solid var(--line);
  border-top: 3px solid var(--gold);
  border-radius: 0 0 10px 10px;
  box-shadow: 0 18px 40px rgba(18, 40, 74, 0.18);
  padding: 8px 0 0;
}

.menu > li:nth-child(3) > .sub,
.menu > li:nth-child(4) > .sub {
  left: 50%;
  transform: translateX(-50%);
}

.menu > li:nth-child(n + 5) > .sub,
.sub-right {
  left: auto;
  right: 0;
}

.sub-cols {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  gap: 4px 12px;
  padding: 8px 10px 4px;
}

.sub-title {
  margin: 4px 12px 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-text);
}

.sub-col-wide ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 12px;
}

.has-sub:hover > .sub {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
  transition: opacity 0.15s ease 0.3s, visibility 0s linear 0.3s;
}

.has-sub:has(:focus-visible) > .sub {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
  transition: none;
}

.sub ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sub li a {
  display: block;
  padding: 8px 12px;
  border-radius: 6px;
  color: var(--ink);
  text-decoration: none;
  font-size: 0.93rem;
  line-height: 1.35;
}

.sub li a:hover,
.sub li a[aria-current] {
  background: var(--navy-soft);
  color: var(--navy);
}

.sub-all {
  display: block;
  margin-top: 6px;
  padding: 10px 20px;
  border-top: 1px solid var(--line);
  background: var(--soft);
  color: var(--navy-2);
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
  border-radius: 0 0 10px 10px;
}

.sub-all:hover {
  text-decoration: underline;
}

.tools .sub {
  width: 300px;
  padding: 8px;
  border-radius: 10px;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  position: static;
}

.nav-toggle > summary {
  list-style: none;
  cursor: pointer;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--navy);
}

.nav-toggle > summary::-webkit-details-marker {
  display: none;
}

.nav-toggle[open] > summary {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
}

.mobile-panel {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  max-height: calc(100vh - 70px);
  overflow-y: auto;
  background: #fff;
  border-top: 3px solid var(--gold);
  box-shadow: 0 20px 40px rgba(18, 40, 74, 0.18);
  padding: 8px 16px 20px;
}

.mobile-panel details {
  border-bottom: 1px solid var(--line);
}

.mobile-panel summary {
  list-style: none;
  cursor: pointer;
  padding: 14px 4px;
  font-weight: 700;
  color: var(--ink);
  display: flex;
  justify-content: space-between;
}

.mobile-panel summary::-webkit-details-marker {
  display: none;
}

.mobile-panel summary::after {
  content: "+";
  color: var(--gold-text);
  font-size: 1.2rem;
  line-height: 1;
}

.mobile-panel details[open] summary::after {
  content: "−";
}

.mobile-panel ul {
  list-style: none;
  margin: 0 0 10px;
  padding: 0;
}

.mobile-panel li a {
  display: block;
  padding: 9px 10px;
  color: var(--text);
  text-decoration: none;
  border-radius: 6px;
}

.mobile-panel li a:hover {
  background: var(--soft);
}

.mobile-panel .sub-all {
  background: none;
  border: 0;
  padding: 9px 10px;
}

.mobile-tools {
  margin-top: 14px;
  background: var(--gold-soft);
  border-radius: 10px;
  padding: 12px 10px 4px;
}

.mobile-tools strong {
  display: block;
  padding: 0 10px 4px;
  color: var(--gold-text);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.mobile-extra {
  margin-top: 10px !important;
}

/* Breadcrumb */

.crumbs {
  font-size: 0.8rem;
  color: var(--muted);
  margin: 0 0 10px;
  line-height: 1.4;
}

.crumbs ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 0;
}

.crumbs li + li::before {
  content: "›";
  margin: 0 8px;
  color: #9aa5b3;
}

.crumbs a {
  color: var(--muted);
}

/* Page header */

.pagehead {
  background: var(--soft);
  border-bottom: 1px solid var(--line);
  padding: 16px 0 20px;
}

.pagehead h1 {
  font-size: clamp(1.6rem, 2.7vw, 2.15rem);
  margin: 0 0 8px;
  max-width: none;
  text-wrap: pretty;
}

.pagehead .lede {
  font-size: 1.06rem;
  line-height: 1.6;
  color: var(--text);
  max-width: none;
  margin: 10px 0 0;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  font-size: 0.8rem;
  color: var(--muted);
  margin: 0;
}

.meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.meta svg {
  width: 15px;
  height: 15px;
}

/* Article layout */

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 56px;
  padding-top: 26px;
  padding-bottom: 64px;
}

.article > :first-child,
.article > .essentiel:first-child,
.article > .note:first-child {
  margin-top: 0;
}

.article {
  min-width: 0;
  max-width: 760px;
}

.article h2 {
  margin-top: 2em;
  padding-top: 0.3em;
  scroll-margin-top: 126px;
}

.article h3 {
  margin-top: 1.6em;
  scroll-margin-top: 126px;
}

.article ul,
.article ol {
  padding-left: 1.3em;
  margin: 0 0 1.1em;
}

.article li {
  margin-bottom: 0.4em;
}

.article blockquote {
  margin: 1.4em 0;
  padding: 14px 20px;
  border-left: 4px solid var(--gold);
  background: var(--gold-soft);
  color: var(--ink);
}

.article blockquote p:last-child {
  margin: 0;
}

.table-wrap {
  overflow-x: auto;
  margin: 1.2em 0 1.6em;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.article table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.article th,
.article td {
  text-align: left;
  vertical-align: top;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
}

.article thead th {
  background: var(--navy);
  color: #fff;
  font-weight: 600;
}

.article tbody tr:nth-child(even) {
  background: var(--soft);
}

.article tbody tr:last-child td {
  border-bottom: 0;
}

.essentiel {
  border: 1px solid #e9d6ad;
  background: var(--gold-soft);
  border-radius: var(--radius);
  padding: 22px 24px 10px;
  margin: 0 0 30px;
}

.essentiel h2 {
  font-size: 1.1rem;
  margin: 0 0 12px;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--gold-text);
  font-family: var(--sans);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.essentiel ul {
  list-style: none;
  padding: 0;
}

.essentiel li {
  position: relative;
  padding-left: 26px;
}

.essentiel li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.62em;
  width: 9px;
  height: 9px;
  border-radius: 2px;
  background: var(--gold);
}

.note {
  border-radius: var(--radius);
  padding: 16px 20px;
  margin: 1.4em 0;
  background: var(--navy-soft);
  color: var(--ink);
  font-size: 0.96rem;
}

/* Sidebar */

.aside {
  position: relative;
}

.aside-inner {
  position: sticky;
  top: 128px;
  display: grid;
  gap: 18px;
}

.toc {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
}

.toc h2 {
  font-family: var(--sans);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin: 0 0 10px;
}

.toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: toc;
  font-size: 0.92rem;
  line-height: 1.4;
}

.toc li {
  counter-increment: toc;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  padding: 6px 0;
  border-top: 1px solid var(--line);
}

.toc li:first-child {
  border-top: 0;
}

.toc li::before {
  content: counter(toc);
  color: var(--gold-text);
  font-weight: 700;
}

.toc a {
  color: var(--text);
  text-decoration: none;
}

.toc a:hover {
  color: var(--navy);
  text-decoration: underline;
}

.promo {
  background: var(--navy);
  color: #fff;
  border-radius: var(--radius);
  padding: 20px;
}

.promo strong {
  display: block;
  font-family: var(--serif);
  font-size: 1.15rem;
  margin-bottom: 6px;
}

.promo p {
  font-size: 0.92rem;
  color: #d6dfec;
  margin: 0 0 14px;
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.97rem;
  text-decoration: none;
  border: 2px solid transparent;
  line-height: 1.2;
}

.btn-gold {
  background: var(--gold);
  color: var(--ink);
}

.btn-gold:hover {
  background: #d6a445;
  color: var(--ink);
}

.btn-navy {
  background: var(--navy);
  color: #fff;
}

.btn-navy:hover {
  background: var(--navy-2);
  color: #fff;
}

.btn-line {
  border-color: var(--navy);
  color: var(--navy);
}

.btn-line:hover {
  background: var(--navy);
  color: #fff;
}

.btns {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

/* FAQ */

.faq {
  margin-top: 2.4em;
}

.faq details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 10px;
  background: #fff;
}

.faq details[open] {
  border-color: #b9c6d8;
}

.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 15px 48px 15px 18px;
  position: relative;
  font-weight: 700;
  color: var(--ink);
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  position: absolute;
  right: 18px;
  top: 12px;
  font-size: 1.3rem;
  color: var(--gold-text);
}

.faq details[open] summary::after {
  content: "−";
}

.faq .answer {
  padding: 0 18px 6px;
}

/* Sources + disclaimer */

.sources {
  margin-top: 2.4em;
  border-top: 3px solid var(--navy);
  padding-top: 18px;
}

.sources h2 {
  font-size: 1.15rem;
  margin: 0 0 10px;
}

.sources ul {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.94rem;
}

.sources li {
  padding: 7px 0;
  border-bottom: 1px solid var(--line);
}

.disclaimer {
  margin-top: 2em;
  font-size: 0.88rem;
  color: var(--muted);
  background: var(--soft);
  border-radius: var(--radius);
  padding: 14px 18px;
}

/* Related + cards */

.related {
  background: var(--soft);
  border-top: 1px solid var(--line);
  padding: 44px 0 52px;
}

.related h2 {
  margin-bottom: 20px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 22px;
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.card:hover {
  border-color: var(--navy-2);
  box-shadow: 0 10px 26px rgba(18, 40, 74, 0.08);
  color: var(--text);
}

.card .kicker {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--gold-text);
  margin-bottom: 8px;
}

.card h3 {
  font-size: 1.12rem;
  margin: 0 0 8px;
  color: var(--navy);
}

.card p {
  font-size: 0.93rem;
  margin: 0;
  color: var(--muted);
}

/* Hub */

.hub-list {
  padding: 26px 0 64px;
}

.hub-intro {
  max-width: 780px;
  margin-bottom: 34px;
}

.hub-section + .hub-section {
  margin-top: 46px;
}

/* Home */

.hero {
  background: linear-gradient(160deg, var(--navy) 0%, #183563 70%, #1f4277 100%);
  color: #fff;
  padding: 56px 0 60px;
}

.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 48px;
  align-items: center;
}

.hero h1 {
  color: #fff;
  font-size: clamp(2.1rem, 4.4vw, 3.1rem);
}

.hero .lede {
  color: #d9e2ef;
  font-size: 1.15rem;
  max-width: 34em;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
  font-size: 0.88rem;
  color: #c8d4e6;
}

.hero-badges li::before {
  content: "✓";
  color: var(--gold);
  font-weight: 700;
  margin-right: 6px;
}

.home-block {
  padding: 56px 0;
}

.home-block.soft {
  background: var(--soft);
}

.section-title {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 22px;
}

.section-title h2 {
  margin: 0;
}

.section-title a {
  font-weight: 600;
  font-size: 0.95rem;
  white-space: nowrap;
}

.feature {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 40px;
  align-items: start;
}

.feature-links {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
}

.feature-links li {
  border-bottom: 1px solid var(--line);
}

.feature-links a {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 2px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
}

.feature-links a:hover {
  color: var(--navy-2);
}

.feature-links a span {
  color: var(--gold-text);
}

/* Calculator */

.calc {
  background: #fff;
  color: var(--text);
  border-radius: 14px;
  padding: 24px;
  box-shadow: 0 18px 50px rgba(5, 16, 33, 0.25);
  border-top: 4px solid var(--gold);
}

.article .calc {
  box-shadow: none;
  border: 1px solid var(--line);
  border-top: 4px solid var(--gold);
  margin: 1.6em 0;
}

.calc h2,
.calc h3 {
  font-size: 1.25rem;
  margin: 0 0 4px;
  padding: 0;
}

.calc .calc-sub {
  font-size: 0.9rem;
  color: var(--muted);
  margin: 0 0 16px;
}

.calc-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.calc label {
  display: grid;
  align-content: end;
  gap: 4px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink);
}

.calc label.wide {
  grid-column: 1 / -1;
}

.calc input {
  width: 100%;
  font: inherit;
  font-size: 1rem;
  padding: 10px 12px;
  border: 1px solid #c5cfdb;
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
}

.calc input:focus {
  border-color: var(--navy-2);
  outline: 2px solid var(--navy-soft);
}

.calc-result {
  margin-top: 16px;
  background: var(--navy-soft);
  border-radius: 10px;
  padding: 14px 16px;
}

.calc-result .amount {
  display: block;
  font-family: var(--serif);
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.2;
}

.calc-result small {
  display: block;
  color: var(--muted);
  font-size: 0.84rem;
  margin-top: 4px;
}

.calc-note {
  font-size: 0.8rem;
  color: var(--muted);
  margin: 12px 0 0;
}

.calc-lines {
  margin: 10px 0 0;
  padding-left: 18px;
  font-size: 0.84rem;
  color: var(--text);
}

.calc-lines li {
  margin: 3px 0;
}

.calc-lines:empty {
  display: none;
}

/* Blog list */

.post-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

/* Footer */

.footer {
  background: var(--navy);
  color: #c7d2e2;
  padding: 48px 0 26px;
  font-size: 0.93rem;
}

.footer a {
  color: #fff;
  text-decoration: none;
}

.footer a:hover {
  text-decoration: underline;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr));
  gap: 32px;
  padding-bottom: 30px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.footer h2 {
  font-family: var(--sans);
  color: #fff;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin: 0 0 12px;
}

.footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 7px;
}

.footer .brand-name {
  color: #fff;
}

.footer p {
  margin: 12px 0 0;
}

.footer-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  padding-top: 18px;
  font-size: 0.84rem;
  color: #9fb0c8;
}

/* Responsive */

@media (max-width: 1100px) {
  .menu .top {
    padding: 12px 10px;
    font-size: 0.88rem;
  }
}

@media (max-width: 960px) {
  .mainbar,
  .top-actions {
    display: none;
  }

  .nav-toggle {
    display: block;
  }
}

@media (max-width: 960px) {
  .layout,
  .hero .wrap,
  .feature {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }

  .aside-inner {
    position: static;
  }

  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  body {
    font-size: 16px;
  }

  .wrap {
    padding: 0 16px;
  }

  .brand-tag {
    display: none;
  }

  .brand-name {
    font-size: 0.98rem;
  }

  .cards,
  .post-list,
  .footer-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .calc-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .calc label:first-child {
    grid-column: 1 / -1;
  }

  .btns .btn {
    width: 100%;
  }

  .section-title {
    flex-direction: column;
    gap: 4px;
  }
}

.hero .calc-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.calc label small {
  font-weight: 400;
  color: var(--muted);
}

.calc select {
  width: 100%;
  font: inherit;
  font-size: 1rem;
  padding: 10px 12px;
  border: 1px solid #c5cfdb;
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
}

.brand {
  min-width: 0;
  flex: 0 1 auto;
}

.nav-toggle {
  flex: none;
}

@media (max-width: 640px) {
  .masthead-top {
    gap: 12px;
    min-height: 60px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
  }

  .brand-name {
    font-size: 0.98rem;
    line-height: 1.15;
  }
}

/* Blog images (Vercel Blob) */

.post-cover {
  margin: 0 0 24px;
}

.post-cover img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius);
  background: var(--soft);
}

.card.has-img {
  padding-top: 0;
  overflow: hidden;
}

.card-img {
  display: block;
  width: calc(100% + 44px);
  max-width: none;
  margin: 0 -22px 16px;
  aspect-ratio: 16 / 9;
  height: auto;
  object-fit: cover;
  background: var(--soft);
}

.card-img-empty {
  display: grid;
  place-items: center;
  background: var(--navy);
}

.card-img-empty svg {
  width: 56px;
  height: 56px;
}
