@font-face { font-family: "Barlow"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/barlow-400.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-style: italic; font-weight: 400; font-display: swap; src: url("fonts/barlow-400-italic.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/barlow-500.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/barlow-600.woff2") format("woff2"); }
@font-face { font-family: "Barlow"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/barlow-700.woff2") format("woff2"); }

:root {
  --grana: #A51C46;
  --grana-dunkel: #C42A56;
  --accent: #EC6A8B;
  --link: #93B8F2;
  --link-line: rgba(147, 184, 242, 0.4);
  --heading: #E6EDF7;

  --senyera-groc: #FCDD09;
  --senyera-vermell: #DA121A;
  --senyera: linear-gradient(to bottom,
    var(--senyera-groc) 0 11.111%, var(--senyera-vermell) 11.111% 22.222%,
    var(--senyera-groc) 22.222% 33.333%, var(--senyera-vermell) 33.333% 44.444%,
    var(--senyera-groc) 44.444% 55.555%, var(--senyera-vermell) 55.555% 66.666%,
    var(--senyera-groc) 66.666% 77.777%, var(--senyera-vermell) 77.777% 88.888%,
    var(--senyera-groc) 88.888% 100%);

  --text: #CFD9E8;
  --muted: #96A7C2;

  --line: #24375B;
  --bg: #0B1730;
  --bg-alt: #101F3D;
  --bg-rgb: 11, 23, 48;
  --footer-bg: #060F22;
  --on-dark: #E6EDF7;
  --on-dark-muted: #96A7C2;
  --focus: #FCDD09;
  --font: "Barlow", system-ui, sans-serif;
  --header-h: 64px;

  --side: 240px;
  --gap: 64px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; height: auto; display: block; }
address { font-style: normal; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: 16px; top: -100px; z-index: 100;
  background: var(--grana); color: var(--on-dark); border: 0;
  padding: 10px 16px; border-radius: 4px; font-weight: 600;
}
.skip-link:focus { top: 12px; color: var(--on-dark); }

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

a { color: var(--link); text-decoration: none; border-bottom: 1px solid var(--link-line); }
a:hover { color: var(--accent); border-bottom-color: currentColor; }

h1, h2, h3 { line-height: 1.15; margin: 0 0 0.6em; color: var(--heading); }
h1 { font-size: clamp(2rem, 4.8vw, 3.25rem); letter-spacing: -0.025em; }
h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); letter-spacing: -0.02em; }
h3 { font-size: 1.15rem; margin-top: 2.2em; }
p, ul, ol, dl, table { margin: 0 0 1em; }

p, li, dd, address {
  text-align: justify;
  -webkit-hyphens: auto;
  hyphens: auto;
  hyphenate-limit-chars: 6 3 3;
  overflow-wrap: break-word;
}

.eyebrow, .hero-actions, .copy, .fee-label {
  text-align: left;
  -webkit-hyphens: manual;
  hyphens: manual;
}

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

.grid { display: grid; grid-template-columns: var(--side) minmax(0, 1fr); gap: var(--gap); }
.grid-main { max-width: 680px; }
.section .grid-side { position: sticky; top: calc(var(--header-h) + 32px); align-self: start; }
.section .grid-side h2 { font-size: 1.5rem; line-height: 1.25; letter-spacing: -0.015em; }

.intro { font-size: 1.3rem; line-height: 1.45; color: var(--heading); font-weight: 500; letter-spacing: -0.01em; margin-bottom: 1.4em; }

.code { font-variant-numeric: tabular-nums; white-space: nowrap; }

.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px;
  font: inherit; font-size: 1rem; font-weight: 600; line-height: 1.25;
  padding: 11px 21px;
  border: 1px solid var(--grana); border-radius: 4px;
  background: var(--grana); color: var(--on-dark);
  white-space: nowrap; cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}
.button:hover { background: var(--grana-dunkel); border-color: var(--grana-dunkel); color: var(--on-dark); }
.button-small { min-height: 36px; font-size: 0.9rem; padding: 6px 14px; }

.link-more {
  display: inline-flex; align-items: center; min-height: 44px;
  font-weight: 600; font-size: 1.1rem;
  color: var(--accent); border: 0;
}
.link-more::after { content: "›" / ""; margin-left: 0.3em; font-size: 1.3em; line-height: 1; transition: transform 0.15s; }
.link-more:hover { color: var(--heading); }
.link-more:hover::after { transform: translateX(3px); }

.senyera-flag {
  display: inline-block; flex: none; width: 1.5em; height: 1em; vertical-align: -0.15em;
  background: var(--senyera);
  margin-right: 0.6em;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.08);
}

.site-header {
  position: sticky; top: 0; z-index: 10;
  height: var(--header-h);
  background: rgba(var(--bg-rgb), 0.97);
  border-bottom: 1px solid var(--line);
}
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { display: flex; flex: none; align-items: center; gap: 12px; border: 0; color: var(--heading); font-weight: 700; white-space: nowrap; }
.brand:hover { color: var(--heading); }
.brand img { width: 44px; }
.nav { display: flex; align-items: center; gap: 18px; }
.nav a:not(.button) { border: 0; color: var(--muted); font-size: 0.95rem; font-weight: 500; padding: 8px 0; white-space: nowrap; }
.nav a:not(.button):hover, .nav a[aria-current="true"] { color: var(--accent); }
.nav a[aria-current="true"] { box-shadow: inset 0 -2px 0 currentColor; }

.lang { position: relative; display: flex; align-items: center; }
.globe { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.lang-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; margin: 0 -10px 0 -6px;
  list-style: none; border-radius: 50%;
  color: var(--muted); cursor: pointer;
  transition: color 0.15s, background-color 0.15s;
}
.lang-toggle::-webkit-details-marker { display: none; }
.lang-toggle::marker { content: ""; }
.lang-toggle:hover, .lang[open] .lang-toggle { color: var(--heading); background: var(--bg-alt); }
.lang-heading { display: none; }
.lang-list {
  list-style: none; margin: 0; padding: 8px 0;
  position: absolute; top: calc(100% + 8px); right: 0; min-width: 160px;
  background: var(--bg-alt); border: 1px solid var(--line); border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  animation: lang-in 0.15s ease;
}
@keyframes lang-in { from { opacity: 0; transform: translateY(-4px); } }
.lang-list li { margin: 0; }
.nav .lang-list a { display: block; padding: 8px 16px; border: 0; color: var(--text); font-size: 0.95rem; font-weight: 500; }
.lang-list a:hover { color: var(--accent); }
.lang-list a[aria-current="page"] { color: var(--accent); }

.link-row { display: flex; flex-wrap: wrap; gap: 4px 32px; margin: 0.4em 0 1em; }

.nav-toggle {
  display: none;
  width: 44px; height: 44px; margin-right: -10px;
  align-items: center; justify-content: center;
  background: none; border: 0; border-radius: 4px;
  color: var(--heading); cursor: pointer;
}
.nav-toggle svg { width: 24px; height: 24px; overflow: visible; }
.nav-toggle line {
  stroke: currentColor; stroke-width: 2; stroke-linecap: round;
  transform-box: fill-box; transform-origin: center;
  transition: transform 0.2s ease, opacity 0.15s ease;
}
.nav-toggle[aria-expanded="true"] .l1 { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .l2 { opacity: 0; }
.nav-toggle[aria-expanded="true"] .l3 { transform: translateY(-5px) rotate(-45deg); }

.hero { padding: 96px 0 88px; }
.hero .grid { align-items: center; }
.eyebrow { display: flex; align-items: center; font-size: 1.05rem; font-weight: 500; color: var(--muted); margin-bottom: 0.6em; }
.lead { font-size: 1.2rem; color: var(--muted); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 8px 32px; margin-top: 1.2em; }

.hero-logo { width: 100%; overflow: visible; }
.hero-logo .tri-red  { animation: in-left  1.8s cubic-bezier(0.33, 1, 0.68, 1) 0.2s backwards; }
.hero-logo .tri-blue { animation: in-right 1.8s cubic-bezier(0.33, 1, 0.68, 1) 0.5s backwards; }
.hero-logo .tri-top  { animation: in-top   1.8s cubic-bezier(0.33, 1, 0.68, 1) 0.9s backwards; }
.hero-logo .tri-shadow { animation: fade-in 0.8s ease 2.5s backwards; }

.hero-logo { transition: transform 0.6s cubic-bezier(0.33, 1, 0.68, 1); }
.hero-logo:hover { transform: translateY(-4px) scale(1.03); }
@keyframes in-left  { from { transform: translate(-40px, 0); opacity: 0; } }
@keyframes in-right { from { transform: translate(40px, 0);  opacity: 0; } }
@keyframes in-top   { from { transform: translate(0, -40px); opacity: 0; } }
@keyframes fade-in  { from { opacity: 0; } }

.section { padding: 88px 0; }
.section-alt { background: var(--bg-alt); }

ul, ol { padding-left: 1.2em; }
li { margin-bottom: 0.5em; }

.tri { list-style: none; padding-left: 0; }
.tri li { position: relative; padding-left: 1.6em; }
.tri li::before {
  content: "";
  position: absolute; left: 0; top: 0.5em;
  width: 0.8em; height: 0.66em;
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  background: var(--accent);
}

.steps { counter-reset: step; list-style: none; padding: 0; }
.steps li { counter-increment: step; position: relative; padding-left: 2.6em; margin-bottom: 1em; }
.steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: 0.05em;
  width: 1.75em; height: 1.75em; border-radius: 50%;
  background: var(--accent); color: var(--bg);
  font-size: 0.85rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}

.fees { list-style: none; padding: 0; margin: 0 0 1em; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 40px; }
.fees li { margin: 0; display: flex; flex-direction: column; gap: 4px; }
.fee-amount { font-size: clamp(1.9rem, 3.6vw, 2.4rem); font-weight: 700; line-height: 1; letter-spacing: -0.03em; color: var(--accent); font-variant-numeric: tabular-nums; }
.fee-label { color: var(--muted); font-size: 0.98rem; }

.scoreboard { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin: 0 0 1.6em; }
.scoreboard dt { color: var(--muted); font-size: 0.95rem; }
.scoreboard dd { margin: 0; font-size: 1.15rem; font-weight: 600; line-height: 1.3; color: var(--heading); }

.prices { width: 100%; border-collapse: collapse; margin-top: 1.4em; }
.prices caption { text-align: left; font-weight: 600; color: var(--muted); font-size: 0.9rem; padding-bottom: 0.5em; }
.prices th, .prices td { text-align: left; padding: 10px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.prices thead th { font-size: 0.85rem; color: var(--muted); font-weight: 600; }
.prices tbody th { font-weight: 400; }
.prices .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; padding-left: 16px; }
.prices thead th.num { white-space: normal; }
.prices tbody td.num { font-weight: 600; color: var(--heading); }
.fn { border: 0; color: inherit; padding: 0 0.3em; }
.note { font-size: 0.9rem; color: var(--muted); }

.facts div { display: grid; grid-template-columns: 9em 1fr; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.facts div:first-child { border-top: 1px solid var(--line); }
.facts dt { color: var(--muted); font-size: 0.95rem; }
.facts dd { margin: 0; }


.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px; margin: 0 0 1em; }
.card h3 { margin-top: 0; font-size: 1.4rem; }
.venue { margin: 0 0 1em; }
.venue h3 { margin-top: 0; font-size: 1.4rem; }
.address { font-weight: 600; color: var(--heading); margin-bottom: 1em; }
.map-link { display: inline-block; padding: 6px 0; font-size: 0.95rem; font-weight: 500; }

.site-footer { background: var(--footer-bg); color: var(--on-dark); padding: 64px 0 40px; font-size: 0.95rem; }
.footer-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 40px; }

.site-footer h2 { color: var(--on-dark); font-size: 1.5rem; margin: 0; }
.site-footer h3 { color: var(--on-dark); font-size: 1rem; font-weight: 600; margin: 0 0 0.5em; }
.imprint { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 48px; }
.privacy { margin-top: 48px; padding-top: 40px; border-top: 1px solid var(--line); }
.privacy h2 { margin-bottom: 24px; }
.privacy-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 48px; }
.privacy-grid p { margin: 0; }
.copy { margin-top: 2.5em; padding-top: 1.5em; border-top: 1px solid var(--line); font-size: 0.85rem; color: var(--on-dark-muted); }

.to-top {
  position: fixed; right: 24px; bottom: 24px; z-index: 9;
  width: 48px; height: 48px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-alt); color: var(--heading);
  border: 1px solid var(--line);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
  visibility: hidden; opacity: 0; transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease, color 0.15s, visibility 0s linear 0.2s;
}
.to-top.visible {
  visibility: visible; opacity: 1; transform: none;
  transition: opacity 0.2s ease, transform 0.2s ease, color 0.15s, visibility 0s;
}
.to-top:hover { color: var(--accent); border-color: var(--line); }
.to-top svg { width: 20px; height: 20px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .hero-logo:hover { transform: none; }
}

@media (max-width: 960px) {
  :root { --side: 200px; --gap: 40px; }
  .section .grid-side h2 { font-size: 1.3rem; }
  .imprint, .privacy-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 1140px) {
  .nav-toggle { display: inline-flex; }
  .nav {
    position: absolute; top: var(--header-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 8px 20px 20px;
    max-height: calc(100vh - var(--header-h)); overflow-y: auto;

    visibility: hidden; opacity: 0; transform: translateY(-8px);
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0.18s;
  }
  .nav.open {
    visibility: visible; opacity: 1; transform: none;
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s;
  }
  .nav a:not(.button) { padding: 12px 0; font-size: 1rem; }
  .nav .button { order: 2; margin-top: 12px; min-height: 44px; font-size: 1rem; padding: 11px 21px; }

  .lang { order: 3; gap: 16px; margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); }
  .lang-toggle { display: none; }
  .lang-heading { display: inline-flex; float: left; margin: 10px 20px 0 0; color: var(--muted); }
  .lang-list {
    position: static; display: flex; flex-wrap: wrap; gap: 4px 20px;
    padding: 0; border: 0; background: none; box-shadow: none; animation: none;
  }
  .nav .lang-list a { padding: 10px 0; }
}

@media (max-width: 860px) {
  .grid { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .section .grid-side { position: static; }
  .section .grid-side h2 { font-size: 1.75rem; }
  .hero { padding: 48px 0 56px; }
  .hero .grid { gap: 32px; }
  .hero-logo { width: 180px; }
  .section { padding: 64px 0; }
  .cards, .imprint, .privacy-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 600px) {
  .scoreboard { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .intro { font-size: 1.15rem; }
}

@media (max-width: 480px) {
  body { font-size: 1rem; }

  p, li, dd, address { hyphenate-limit-chars: 5 2 2; }
  .brand span { font-size: 0.9rem; }
  .facts div { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .fees { gap: 24px 20px; }
  .grid-main .button { white-space: normal; text-align: center; }
  .to-top { right: 16px; bottom: 16px; }
  .copy { padding-right: 64px; }
}

.site-footer-small { padding: 40px 0 32px; }
.site-footer-small .copy { margin-top: 1em; }
.footer-links .link-more { font-size: 1rem; }
.imprint p, .privacy-grid p { text-align: left; }
