:root {
  --bg: #f6f7f9;
  --surface: #ffffff;
  --surface-2: #eef2f4;
  --text: #172126;
  --muted: #5d6a71;
  --line: #dce3e7;
  --brand: #0d6658;
  --brand-strong: #084c43;
  --brand-soft: #e8f4f1;
  --danger: #a33a31;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 12px 35px rgba(17, 35, 43, .08);
  --max: 1160px;
  --header: 72px;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--text); background: var(--bg); font-family: var(--font); line-height: 1.55; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
img, svg { max-width: 100%; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
.container { width: min(calc(100% - 32px), var(--max)); margin-inline: auto; }
.skip-link { position: fixed; left: 12px; top: -60px; z-index: 1000; padding: 10px 14px; background: var(--text); color: #fff; border-radius: 8px; }
.skip-link:focus { top: 12px; }
.site-header { position: sticky; top: 0; z-index: 50; height: var(--header); background: rgba(246,247,249,.92); backdrop-filter: blur(12px); border-bottom: 1px solid rgba(220,227,231,.9); }
.header-inner { min-height: var(--header); display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; letter-spacing: -.03em; }
.brand-mark { width: 34px; height: 34px; flex: 0 0 34px; }
.nav { display: flex; align-items: center; gap: 6px; }
.nav a { text-decoration: none; color: var(--muted); font-weight: 650; font-size: .94rem; padding: 9px 11px; border-radius: 10px; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); background: var(--surface); }
.menu-button { display: none; width: 44px; height: 44px; border: 1px solid var(--line); background: var(--surface); border-radius: 12px; align-items: center; justify-content: center; }
.menu-button span, .menu-button span::before, .menu-button span::after { display:block; width:20px; height:2px; background:var(--text); content:""; position:relative; }
.menu-button span::before { position:absolute; top:-6px; }
.menu-button span::after { position:absolute; top:6px; }
.hero { padding: 76px 0 54px; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 38px; align-items: center; }
.eyebrow { display: inline-flex; gap: 8px; align-items: center; color: var(--brand-strong); background: var(--brand-soft); border-radius: 999px; padding: 7px 11px; font-size: .83rem; font-weight: 800; margin-bottom: 18px; }
h1, h2, h3 { line-height: 1.08; letter-spacing: -.035em; margin-top: 0; }
h1 { font-size: clamp(2.4rem, 6vw, 5.2rem); margin-bottom: 20px; max-width: 820px; }
h2 { font-size: clamp(1.75rem, 3.6vw, 3rem); margin-bottom: 14px; }
h3 { font-size: 1.2rem; margin-bottom: 9px; }
.lead { color: var(--muted); font-size: clamp(1.05rem, 2vw, 1.25rem); max-width: 680px; margin: 0 0 28px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 17px; border: 1px solid transparent; border-radius: 12px; background: var(--brand); color: #fff; font-weight: 800; text-decoration: none; }
.button:hover { background: var(--brand-strong); }
.button.secondary { background: var(--surface); color: var(--text); border-color: var(--line); }
.button.secondary:hover { background: var(--surface-2); }
.button.ghost { background: transparent; color: var(--text); border-color: var(--line); }
.hero-card, .card, .calculator, .result-card, .legal-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.hero-card { padding: 26px; }
.hero-card .micro { margin-top: 16px; }
.mini-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 12px; margin-top: 18px; }
.mini-stat { padding: 16px; background: var(--bg); border-radius: var(--radius-sm); }
.mini-stat strong { display:block; font-size:1.25rem; letter-spacing:-.02em; }
.mini-stat span { color:var(--muted); font-size:.84rem; }
.section { padding: 54px 0; }
.section-head { display:flex; justify-content:space-between; gap:20px; align-items:end; margin-bottom:24px; }
.section-head p { color: var(--muted); margin:0; max-width:620px; }
.cards { display:grid; grid-template-columns:repeat(3,1fr); gap:16px; }
.card { padding:24px; box-shadow:none; transition: transform .18s ease, box-shadow .18s ease; }
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.card p { color:var(--muted); margin:0 0 18px; }
.card-link { color:var(--brand-strong); font-weight:800; text-decoration:none; }
.notice { padding: 15px 17px; border-radius: var(--radius-sm); background: #fff8e8; border: 1px solid #ead8a6; color: #5c4b1e; font-size: .92rem; }
.trust-strip { display:grid; grid-template-columns:repeat(3,1fr); gap:12px; }
.trust-item { padding:18px; border-top:1px solid var(--line); color:var(--muted); }
.trust-item strong { color:var(--text); display:block; margin-bottom:4px; }
.page-hero { padding: 58px 0 26px; }
.page-hero h1 { font-size: clamp(2.3rem,5vw,4rem); margin-bottom:14px; }
.breadcrumb { color:var(--muted); font-size:.86rem; margin-bottom:14px; }
.breadcrumb a { text-decoration:none; }
.tool-layout { display:grid; grid-template-columns:minmax(0,1fr) 360px; gap:24px; align-items:start; }
.calculator { padding:24px; box-shadow:none; }
.form-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
.field { display:flex; flex-direction:column; gap:7px; }
.field.full { grid-column:1/-1; }
label { font-weight:750; font-size:.91rem; }
.help { color:var(--muted); font-size:.8rem; }
input, select, textarea { width:100%; min-height:48px; border:1px solid var(--line); background:#fff; color:var(--text); border-radius:11px; padding:10px 12px; outline:none; }
textarea { min-height:94px; resize:vertical; }
input:focus, select:focus, textarea:focus { border-color:var(--brand); box-shadow:0 0 0 3px rgba(13,102,88,.12); }
.error { min-height:1.4em; color:var(--danger); font-size:.9rem; margin-top:10px; }
.result-card { padding:24px; position:sticky; top:calc(var(--header) + 18px); box-shadow:none; }
.result-main { font-size:2.15rem; font-weight:850; letter-spacing:-.04em; margin:8px 0 18px; }
.result-list { display:grid; gap:12px; }
.result-row { display:flex; justify-content:space-between; gap:14px; padding-top:12px; border-top:1px solid var(--line); color:var(--muted); }
.result-row strong { color:var(--text); text-align:right; }
.micro { color:var(--muted); font-size:.8rem; }
.content-grid { display:grid; grid-template-columns:minmax(0,720px) 1fr; gap:32px; }
.prose { background:var(--surface); border:1px solid var(--line); border-radius:var(--radius); padding:clamp(22px,4vw,38px); }
.prose p, .prose li { color:#3f4d54; }
.prose h2 { font-size:1.65rem; margin-top:32px; }
.prose h3 { margin-top:24px; }
.prose a { color:var(--brand-strong); }
.side-nav { position:sticky; top:calc(var(--header) + 18px); }
.side-nav a { display:block; padding:9px 0; color:var(--muted); text-decoration:none; border-bottom:1px solid var(--line); }
.table-wrap { overflow:auto; background:var(--surface); border:1px solid var(--line); border-radius:var(--radius); }
table { width:100%; border-collapse:collapse; min-width:820px; }
th, td { padding:14px; text-align:left; border-bottom:1px solid var(--line); vertical-align:top; }
th { font-size:.82rem; color:var(--muted); background:#fafbfb; position:sticky; top:0; }
.empty-cell { text-align:center; color:var(--muted); padding:28px; }
.table-action { border:0; background:none; color:var(--danger); font-weight:750; padding:0; }
.pending-data { color:var(--danger); font-weight:750; }
.news-empty { padding:34px; border:1px dashed #b8c5cb; border-radius:var(--radius); color:var(--muted); background:rgba(255,255,255,.45); }
.site-footer { margin-top:58px; padding:34px 0 40px; border-top:1px solid var(--line); background:#f0f3f5; }
.footer-grid { display:grid; grid-template-columns:1.2fr 1fr 1fr; gap:24px; }
.footer-grid h3 { font-size:.95rem; margin-bottom:11px; }
.footer-grid p, .footer-grid a { color:var(--muted); font-size:.88rem; }
.footer-grid a { display:block; text-decoration:none; margin:7px 0; }
.footer-bottom { margin-top:26px; padding-top:18px; border-top:1px solid var(--line); color:var(--muted); font-size:.8rem; }
.cookie-banner { position:fixed; z-index:100; left:16px; right:16px; bottom:16px; max-width:980px; margin:auto; background:#fff; border:1px solid var(--line); border-radius:16px; box-shadow:0 20px 55px rgba(0,0,0,.18); padding:18px; }
.cookie-banner[hidden], .cookie-panel[hidden] { display:none; }
.cookie-row { display:flex; align-items:flex-end; justify-content:space-between; gap:22px; }
.cookie-copy { max-width:600px; }
.cookie-copy strong { display:block; margin-bottom:4px; }
.cookie-copy p { margin:0; color:var(--muted); font-size:.88rem; }
.cookie-actions { display:flex; gap:8px; flex-wrap:wrap; }
.cookie-actions .button { min-height:42px; padding:0 13px; }
.cookie-panel { position:fixed; inset:0; z-index:110; background:rgba(10,18,22,.48); display:grid; place-items:center; padding:18px; }
.cookie-dialog { width:min(100%,560px); max-height:calc(100vh - 36px); overflow:auto; background:#fff; border-radius:18px; padding:24px; box-shadow:0 25px 75px rgba(0,0,0,.25); }
.cookie-option { display:flex; justify-content:space-between; gap:18px; padding:16px 0; border-top:1px solid var(--line); }
.cookie-option p { margin:4px 0 0; color:var(--muted); font-size:.84rem; }
.cookie-option input { width:22px; min-height:22px; accent-color:var(--brand); }
.only-desktop { display:initial; }
@media (max-width: 900px) {
  :root { --header:64px; }
  .container { width:min(calc(100% - 24px), var(--max)); }
  .menu-button { display:flex; }
  .nav { display:none; position:absolute; left:12px; right:12px; top:calc(var(--header) - 2px); background:#fff; border:1px solid var(--line); border-radius:14px; padding:8px; box-shadow:var(--shadow); flex-direction:column; align-items:stretch; }
  .nav.is-open { display:flex; }
  .nav a { padding:12px; }
  .hero { padding:48px 0 34px; }
  .hero-grid, .tool-layout, .content-grid { grid-template-columns:1fr; }
  .hero-card { order:-1; }
  .cards { grid-template-columns:1fr; }
  .trust-strip { grid-template-columns:1fr; }
  .result-card, .side-nav { position:static; }
  .footer-grid { grid-template-columns:1fr 1fr; }
}
@media (max-width: 620px) {
  h1 { font-size:2.45rem; }
  .brand span { max-width:190px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
  .form-grid, .mini-grid { grid-template-columns:1fr; }
  .actions > *, .cookie-actions > * { width:100%; }
  .section { padding:38px 0; }
  .section-head { display:block; }
  .section-head p { margin-top:8px; }
  .calculator, .result-card, .hero-card { padding:19px; }
  .cookie-row { align-items:stretch; flex-direction:column; gap:14px; }
  .footer-grid { grid-template-columns:1fr; }
  .only-desktop { display:none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior:auto !important; transition:none !important; }
}

/* V2: quick calculator + footer refinement */
[hidden] { display: none !important; }
.footer-network-brand { display:inline-flex; align-items:center; gap:10px; text-decoration:none; margin-bottom:10px; }
.footer-expertos-word { font-size:1.18rem; font-weight:900; letter-spacing:-.045em; color:var(--text); line-height:1; }
.footer-expertos-word span { font-size:.68em; font-weight:750; letter-spacing:-.02em; color:var(--muted); }
.footer-brand-block p { max-width:430px; margin-top:8px; }
.quick-rate-result { margin:13px 0 0; text-align:center; }
.quick-rate-result strong { color:var(--text); }

@media (max-width: 620px) {
  .hero-copy { text-align:center; }
  .hero-copy .lead { margin-left:auto; margin-right:auto; }
  .hero-copy .actions { justify-content:center; }
  .hero-card { text-align:center; }
  .hero-card .field { align-items:center; }
  .hero-card input, .hero-card select { text-align:center; }
  .hero-card .help { text-align:center; }
  .hero-card .quick-submit { margin-inline:auto; min-width:210px; }
  .site-footer, .footer-grid, .footer-bottom { text-align:center; }
  .footer-network-brand { justify-content:center; }
  .footer-brand-block p { margin-left:auto; margin-right:auto; }
  .footer-grid a { margin-left:auto; margin-right:auto; width:fit-content; }
}


/* V3 centered layout */

.hero-copy,
.page-hero .container,
.section-head,
.trust-item,
.card,
.news-empty,
.calculator,
.result-card,
.legal-card,
.side-nav,
.site-footer,
.footer-grid,
.footer-bottom {
  text-align: center;
}

.hero-copy .eyebrow,
.page-hero .eyebrow,
.section-head .eyebrow,
.result-card .eyebrow {
  margin-inline: auto;
}

.hero-copy .lead,
.page-hero .lead,
.section-head p,
.footer-brand-block p,
.prose > p,
.prose > .notice,
.prose > .news-empty {
  margin-left: auto;
  margin-right: auto;
}

.hero-copy .actions,
.section-head,
.page-hero .container,
.footer-network-brand,
.footer-grid a,
.calculator .button,
.quick-submit {
  justify-content: center;
}

.hero-copy { text-align: center; }
.hero-copy .actions { justify-content: center; }
.hero-card,
.hero-card .micro,
.hero-card .help,
.hero-card h2,
.hero-card label,
.hero-card .error,
.quick-rate-result { text-align: center; }
.hero-card input,
.hero-card select,
.calculator input,
.calculator select,
.calculator textarea { text-align: center; }

.section-head {
  display: block;
}
.section-head > div {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.section-head p {
  margin-top: 10px;
}
.cards,
.trust-strip {
  align-items: stretch;
}
.card,
.trust-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.card-link { display: inline-flex; justify-content: center; }

.page-hero .container {
  max-width: 900px;
}
.page-hero .breadcrumb {
  text-align: center;
}
.page-hero h1,
.page-hero h2,
.page-hero p,
.page-hero .breadcrumb {
  margin-left: auto;
  margin-right: auto;
}

.tool-layout {
  width: min(100%, 980px);
  margin-inline: auto;
  grid-template-columns: minmax(0, 1fr) 340px;
  justify-content: center;
}
.content-grid {
  width: min(100%, 1020px);
  margin-inline: auto;
  justify-content: center;
  grid-template-columns: minmax(0, 700px) 240px;
}
.prose {
  text-align: center;
}
.prose ul,
.prose ol {
  display: inline-block;
  text-align: left;
  margin-left: auto;
  margin-right: auto;
}
.prose table {
  text-align: left;
}
.side-nav a {
  padding-left: 0;
  padding-right: 0;
}

.result-row {
  display: grid;
  gap: 4px;
  justify-items: center;
  text-align: center;
}
.result-row strong {
  text-align: center;
}

.footer-grid {
  max-width: 980px;
  margin-inline: auto;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: start;
}
.footer-grid > div {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.footer-network-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}
.footer-expertos-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: block;
  object-fit: contain;
  flex: 0 0 42px;
}
.footer-grid a {
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}
.footer-brand-block p {
  max-width: 460px;
}

@media (max-width: 900px) {
  .tool-layout,
  .content-grid,
  .footer-grid {
    width: 100%;
  }
  .tool-layout,
  .content-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .hero-copy,
  .page-hero .container,
  .section-head,
  .card,
  .trust-item,
  .prose,
  .calculator,
  .result-card,
  .site-footer,
  .footer-grid,
  .footer-bottom {
    text-align: center;
  }
  .footer-grid > div {
    align-items: center;
  }
  .footer-expertos-icon {
    width: 40px;
    height: 40px;
  }
}


.footer-network-brand {
  background: #0b0f10;
  padding: 8px 14px;
  border-radius: 999px;
  box-shadow: 0 10px 24px rgba(0,0,0,.12);
}
.footer-network-brand:hover {
  transform: translateY(-1px);
}
.footer-expertos-word {
  color: #ffffff;
}
.footer-expertos-word span {
  color: #d4a619;
}


/* V4 alignment + branding fix */
.brand {
  justify-content: center;
}
.brand-mark--expertos {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 10px;
  object-fit: contain;
  box-shadow: 0 6px 14px rgba(0,0,0,.08);
}

.page-hero .container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 920px;
}
.page-hero .breadcrumb,
.page-hero h1,
.page-hero p,
.page-hero .eyebrow {
  margin-left: auto;
  margin-right: auto;
}
.page-hero .eyebrow,
.section-head .eyebrow,
.result-card .eyebrow,
.feature-visual-copy .eyebrow {
  width: fit-content;
}

.section-head {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.section-head > div {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.section-head p {
  margin-top: 10px;
  margin-left: auto;
  margin-right: auto;
}

.tool-layout {
  width: min(100%, 860px);
  margin: 0 auto;
  grid-template-columns: 1fr;
  gap: 18px;
}
.calculator,
.result-card {
  width: 100%;
  text-align: center;
}
.calculator form {
  max-width: 760px;
  margin: 0 auto;
}
.calculator label,
.calculator .help,
.calculator .error,
.calculator h2,
.calculator p,
.result-card,
.result-card p,
.result-card .micro {
  text-align: center;
}
.calculator input,
.calculator select,
.calculator textarea,
.hero-card input,
.hero-card select {
  text-align: center;
}
.calculator .button,
.quick-submit,
.actions {
  justify-content: center;
}
.calculator .button,
.quick-submit {
  margin-left: auto;
  margin-right: auto;
}
.result-card {
  position: static;
}
.result-list {
  max-width: 520px;
  margin: 0 auto;
}
.result-row {
  grid-template-columns: 1fr;
  justify-items: center;
  text-align: center;
}
.result-row strong {
  text-align: center;
}

.content-grid {
  width: min(100%, 960px);
  margin: 0 auto;
  grid-template-columns: 1fr;
  gap: 20px;
}
.side-nav {
  position: static;
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}
.side-nav a {
  text-align: center;
}
.prose {
  max-width: 800px;
  margin: 0 auto;
}
.prose h2,
.prose h3 {
  text-align: center;
}

.footer-grid {
  grid-template-columns: 1fr 1fr 1fr;
  max-width: 980px;
  margin: 0 auto;
  align-items: start;
  text-align: center;
}
.footer-grid > div {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.footer-main-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  text-decoration: none;
  margin-bottom: 10px;
}
.footer-brand-logo {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  object-fit: contain;
  flex: 0 0 42px;
}
.footer-brand-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  line-height: 1.05;
}
.footer-brand-text strong {
  font-size: 1.12rem;
  letter-spacing: -.03em;
  color: var(--text);
}
.footer-brand-text span {
  font-size: .85rem;
  color: var(--muted);
}
.footer-brand-block p {
  max-width: 470px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}
.footer-grid a {
  margin-left: auto;
  margin-right: auto;
  width: fit-content;
}
.footer-bottom {
  text-align: center;
}

.feature-visual {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}
.feature-visual-copy {
  text-align: center;
}
.feature-visual-copy .lead {
  margin-left: auto;
  margin-right: auto;
  max-width: 520px;
}
.feature-visual-image {
  width: 100%;
  display: block;
  border-radius: 18px;
  border: 1px solid var(--line);
}

@media (max-width: 900px) {
  .feature-visual,
  .footer-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 620px) {
  .brand {
    justify-content: flex-start;
  }
  .footer-main-brand {
    flex-direction: row;
  }
  .footer-brand-text {
    align-items: flex-start;
    text-align: left;
  }
}


/* V5 integrated realistic images */
.feature-visual {
  max-width: 1080px;
  margin: 0 auto;
}
.feature-visual--page {
  grid-template-columns: 1fr 1fr;
}
.feature-visual-copy h2,
.feature-visual-copy p,
.feature-visual-copy .eyebrow {
  margin-left: auto;
  margin-right: auto;
}
.feature-visual-image {
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: #fff;
}
@media (max-width: 900px) {
  .feature-visual--page {
    grid-template-columns: 1fr;
  }
}


/* V6 visual polish and integrated media */
.brand-badges {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.brand-mark--mortgage {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
}
.brand {
  gap: 12px;
}
.footer-brand-text span {
  display: block;
  margin-top: 8px;
}
.feature-visual-copy {
  max-width: 520px;
  margin: 0 auto;
}
.feature-visual--page {
  max-width: 1080px;
  margin: 0 auto;
}
@media (max-width: 620px) {
  .brand-badges {
    gap: 6px;
  }
  .brand-mark--mortgage {
    width: 30px;
    height: 30px;
    flex-basis: 30px;
  }
}


/* FINAL: mobile navigation centered + back to top */
@media (max-width: 900px) {
  .nav {
    align-items: center;
    text-align: center;
  }
  .nav a {
    width: 100%;
    text-align: center;
    justify-content: center;
  }
}

.back-to-top {
  position: fixed;
  right: max(18px, env(safe-area-inset-right));
  bottom: max(18px, env(safe-area-inset-bottom));
  z-index: 80;
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(23,33,38,.12);
  border-radius: 999px;
  background: rgba(255,255,255,.94);
  color: var(--brand-strong);
  box-shadow: 0 12px 30px rgba(17,35,43,.16);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(10px) scale(.96);
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease, background .18s ease, box-shadow .18s ease;
}
.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}
.back-to-top:hover {
  background: var(--surface);
  box-shadow: 0 16px 36px rgba(17,35,43,.2);
  transform: translateY(-2px) scale(1);
}
.back-to-top:focus-visible {
  outline: 3px solid rgba(13,102,88,.22);
  outline-offset: 3px;
}
.back-to-top svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.35;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media (max-width: 620px) {
  .nav {
    left: 14px;
    right: 14px;
    padding: 10px;
  }
  .nav a {
    min-height: 44px;
    display: flex;
    align-items: center;
  }
  .back-to-top {
    width: 48px;
    height: 48px;
    right: max(14px, env(safe-area-inset-right));
    bottom: max(14px, env(safe-area-inset-bottom));
  }
}
