/* Dvarc — estilos del sitio público
 * Paleta tomada del logo: carbón, óxido, vino, verde y azul profundo.
 */

:root {
  color-scheme: dark;

  --bg: #0b0d10;
  --bg-soft: #0f1318;
  --surface: #141920;
  --surface-raised: #1a212a;
  --surface-hover: #202833;
  --line: #28313c;
  --line-soft: #1e252e;

  --text: #eef1f5;
  --text-soft: #c3ccd8;
  --muted: #8d99a8;

  --accent: #e0703a;
  --accent-bright: #f58a4f;
  --accent-deep: #b04a1f;
  --wine: #a83e63;
  --green: #4c8a63;
  --navy: #3a5f92;
  --purple: #756090;

  --danger: #f26d6d;
  --ok: #5fd08a;

  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;

  --shadow: 0 24px 60px -30px rgb(0 0 0 / 0.9);
  --shadow-soft: 0 14px 40px -24px rgb(0 0 0 / 0.8);

  --font-sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "Cascadia Code", "SFMono-Regular", Consolas, "Liberation Mono", monospace;

  --max-width: 1120px;
  --header-height: 72px;
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(60rem 40rem at 12% -10%, rgb(224 112 58 / 0.10), transparent 60%),
    radial-gradient(50rem 38rem at 88% 0%, rgb(168 62 99 / 0.10), transparent 62%),
    radial-gradient(44rem 34rem at 50% 110%, rgb(58 95 146 / 0.08), transparent 60%),
    var(--bg);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.35;
  background-image:
    linear-gradient(to right, rgb(255 255 255 / 0.028) 1px, transparent 1px),
    linear-gradient(to bottom, rgb(255 255 255 / 0.028) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(circle at 50% 30%, #000 0%, transparent 78%);
}

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

a {
  color: var(--accent-bright);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: #ffb184;
}

h1,
h2,
h3,
h4 {
  margin: 0 0 0.5em;
  line-height: 1.12;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.4rem, 6vw, 4.25rem);
  font-weight: 760;
}

h2 {
  font-size: clamp(1.7rem, 3.4vw, 2.5rem);
  font-weight: 720;
}

h3 {
  font-size: 1.18rem;
  font-weight: 660;
}

p {
  margin: 0 0 1em;
}

code,
pre {
  font-family: var(--font-mono);
}

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

::selection {
  background: rgb(224 112 58 / 0.35);
  color: #fff;
}

.container {
  width: min(100% - 2.5rem, var(--max-width));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  padding: 0.65rem 1rem;
  background: var(--accent);
  color: #160a04;
  font-weight: 700;
  border-radius: var(--radius-sm);
  transition: top 150ms ease;
}

.skip-link:focus {
  top: 1rem;
  color: #160a04;
}

/* ---------------------------------------------------------------- header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--header-height);
  display: flex;
  align-items: center;
  border-bottom: 1px solid transparent;
  background: rgb(11 13 16 / 0.74);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  transition: border-color 180ms ease, background 180ms ease;
}

.site-header.is-scrolled {
  border-bottom-color: var(--line-soft);
  background: rgb(11 13 16 / 0.92);
}

.site-header .container {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 720;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.brand:hover {
  color: var(--text);
}

.brand img {
  width: 34px;
  height: 34px;
  filter: drop-shadow(0 4px 12px rgb(224 112 58 / 0.25));
}

.brand span {
  font-size: 1.03rem;
}

.brand small {
  display: block;
  margin-top: -3px;
  color: var(--muted);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin-left: auto;
}

.site-nav a {
  padding: 0.5rem 0.8rem;
  border-radius: 8px;
  color: var(--text-soft);
  font-size: 0.92rem;
  font-weight: 560;
  text-decoration: none;
  transition: color 140ms ease, background 140ms ease;
}

.site-nav a:hover {
  background: var(--surface);
  color: var(--text);
}

.site-nav a[aria-current="page"] {
  color: var(--accent-bright);
}

.site-nav .nav-cta {
  margin-left: 0.4rem;
  padding-inline: 1rem;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
}

.site-nav .nav-cta:hover {
  border-color: var(--accent-deep);
  background: var(--surface-raised);
  color: #fff;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
}

.nav-toggle span,
.nav-toggle::before,
.nav-toggle::after {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 2px;
  background: currentColor;
  content: "";
  transition: transform 160ms ease, opacity 160ms ease;
}

.nav-toggle[aria-expanded="true"] span {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"]::before {
  transform: translateY(6px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"]::after {
  transform: translateY(-6px) rotate(-45deg);
}

[data-auth="in"],
[data-auth="out"] {
  display: none !important;
}

body.has-token [data-auth="in"] {
  display: inline-flex !important;
}

body:not(.has-token) [data-auth="out"] {
  display: inline-flex !important;
}

/* ------------------------------------------------------------------ hero */

.hero {
  position: relative;
  padding: clamp(3.5rem, 8vw, 7rem) 0 clamp(3rem, 6vw, 5rem);
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.35rem;
  padding: 0.36rem 0.8rem 0.36rem 0.45rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgb(20 25 32 / 0.8);
  color: var(--text-soft);
  font-size: 0.8rem;
  font-weight: 560;
}

.pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--muted);
  box-shadow: 0 0 0 4px rgb(141 153 168 / 0.12);
}

.pill-dot[data-state="ok"] {
  background: var(--ok);
  box-shadow: 0 0 0 4px rgb(95 208 138 / 0.14);
}

.pill-dot[data-state="down"] {
  background: var(--danger);
  box-shadow: 0 0 0 4px rgb(242 109 109 / 0.14);
}

.hero h1 em {
  font-style: normal;
  background: linear-gradient(105deg, var(--accent-bright) 0%, #e4a06a 38%, var(--wine) 74%, var(--purple) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-lead {
  max-width: 34rem;
  margin-bottom: 2rem;
  color: var(--text-soft);
  font-size: clamp(1.02rem, 1.5vw, 1.16rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-bottom: 1.8rem;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.4rem;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
  font-size: 0.87rem;
}

.hero-meta li {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.hero-meta svg {
  width: 15px;
  height: 15px;
  color: var(--accent);
}

/* Logo + órbitas */

.hero-art {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 360px;
  isolation: isolate;
}

.hero-art::before {
  content: "";
  position: absolute;
  width: min(90%, 460px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgb(224 112 58 / 0.16), transparent 66%);
  filter: blur(8px);
  z-index: -1;
}

.hero-logo {
  width: min(80%, 360px);
  filter: drop-shadow(0 30px 50px rgb(0 0 0 / 0.55));
  animation: float 9s ease-in-out infinite;
}

.hero-ring {
  position: absolute;
  width: min(92%, 430px);
  aspect-ratio: 1;
  border: 1px dashed rgb(255 255 255 / 0.13);
  border-radius: 50%;
  animation: spin 60s linear infinite;
}

.hero-ring::after {
  content: "";
  position: absolute;
  inset: 11%;
  border: 1px solid rgb(255 255 255 / 0.07);
  border-radius: 50%;
}

.hero-tag {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgb(20 25 32 / 0.88);
  box-shadow: var(--shadow-soft);
  color: var(--text-soft);
  font-size: 0.75rem;
  font-weight: 620;
  letter-spacing: 0.01em;
  backdrop-filter: blur(6px);
}

.hero-tag::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.hero-tag.tag-a {
  top: 12%;
  left: 2%;
  color: var(--accent-bright);
}

.hero-tag.tag-b {
  top: 42%;
  right: -1%;
  color: #d97d9a;
}

.hero-tag.tag-c {
  bottom: 12%;
  left: 9%;
  color: #7fc096;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(-6px);
  }
  50% {
    transform: translateY(8px);
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* --------------------------------------------------------------- sections */

.section {
  padding: clamp(3rem, 6vw, 5rem) 0;
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2.2rem;
}

.section-head p {
  max-width: 34rem;
  margin: 0;
  color: var(--muted);
}

.eyebrow {
  margin-bottom: 0.7rem;
  color: var(--accent);
  font-size: 0.76rem;
  font-weight: 720;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}

.card {
  position: relative;
  padding: 1.5rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: linear-gradient(160deg, var(--surface) 0%, var(--bg-soft) 100%);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: 0.7;
}

.card--wine::before {
  background: linear-gradient(90deg, var(--wine), transparent);
}

.card--green::before {
  background: linear-gradient(90deg, var(--green), transparent);
}

.card--navy::before {
  background: linear-gradient(90deg, var(--navy), transparent);
}

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

.card-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  margin-bottom: 1rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-raised);
  color: var(--accent-bright);
}

.card--wine .card-icon {
  color: #d97d9a;
}

.card--green .card-icon {
  color: #7fc096;
}

.card--navy .card-icon {
  color: #85a9d8;
}

.card-icon svg {
  width: 21px;
  height: 21px;
}

/* Pasos */

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.step {
  position: relative;
  padding: 1.4rem 1.4rem 1.4rem 1.5rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--bg-soft);
}

.step::before {
  counter-increment: step;
  content: "0" counter(step);
  display: block;
  margin-bottom: 0.8rem;
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
}

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

/* Banda CTA */

.cta-band {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: clamp(1.6rem, 4vw, 2.6rem);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(120deg, rgb(224 112 58 / 0.13), transparent 46%),
    linear-gradient(300deg, rgb(168 62 99 / 0.12), transparent 48%),
    var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.cta-band h2 {
  margin-bottom: 0.25rem;
  font-size: clamp(1.4rem, 2.6vw, 2rem);
}

.cta-band p {
  margin: 0;
  color: var(--muted);
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

/* --------------------------------------------------------------- buttons */

.btn {
  --btn-bg: var(--surface-raised);
  --btn-fg: var(--text);
  --btn-border: var(--line);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 46px;
  padding: 0.65rem 1.15rem;
  border: 1px solid var(--btn-border);
  border-radius: 10px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: inherit;
  font-size: 0.94rem;
  font-weight: 640;
  text-decoration: none;
  cursor: pointer;
  transition: transform 120ms ease, background 140ms ease, border-color 140ms ease, box-shadow 140ms ease;
}

.btn:hover {
  background: var(--surface-hover);
  color: var(--text);
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn svg {
  width: 17px;
  height: 17px;
}

.btn-primary {
  --btn-bg: linear-gradient(180deg, var(--accent-bright), var(--accent-deep));
  --btn-fg: #1b0c04;
  --btn-border: transparent;
  box-shadow: 0 10px 30px -12px rgb(224 112 58 / 0.55);
}

.btn-primary:hover {
  background: linear-gradient(180deg, #ffa269, #c65626);
  color: #1b0c04;
  box-shadow: 0 14px 34px -12px rgb(224 112 58 / 0.7);
}

.btn-ghost {
  --btn-bg: transparent;
}

.btn-sm {
  min-height: 38px;
  padding: 0.4rem 0.8rem;
  font-size: 0.85rem;
}

.btn[disabled],
.btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

/* ----------------------------------------------------------------- forms */

.field {
  display: grid;
  gap: 0.45rem;
  margin-bottom: 1.05rem;
}

.field label {
  color: var(--text-soft);
  font-size: 0.88rem;
  font-weight: 620;
}

.input {
  width: 100%;
  min-height: 46px;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg-soft);
  color: var(--text);
  font: inherit;
  font-size: 0.94rem;
  transition: border-color 140ms ease, box-shadow 140ms ease;
}

.input::placeholder {
  color: #6c7786;
}

.input:focus {
  border-color: var(--accent-deep);
  outline: none;
  box-shadow: 0 0 0 3px rgb(224 112 58 / 0.18);
}

.input[readonly] {
  color: var(--text-soft);
}

.input-mono {
  font-family: var(--font-mono);
  font-size: 0.86rem;
  letter-spacing: 0.02em;
}

.input-row {
  display: flex;
  gap: 0.55rem;
}

.input-row .input {
  flex: 1;
}

.hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
}

.checkbox {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-soft);
  font-size: 0.88rem;
  cursor: pointer;
  user-select: none;
}

.checkbox input {
  width: 17px;
  height: 17px;
  accent-color: var(--accent);
}

/* ------------------------------------------------------------ auth layout */

.auth-wrap {
  display: grid;
  place-items: center;
  min-height: calc(100vh - var(--header-height));
  padding: clamp(2rem, 6vw, 4.5rem) 0;
}

.auth-card {
  width: min(100%, 470px);
  padding: clamp(1.5rem, 4vw, 2.4rem);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: linear-gradient(170deg, var(--surface) 0%, var(--bg-soft) 100%);
  box-shadow: var(--shadow);
}

.auth-logo {
  width: 64px;
  height: 64px;
  margin-bottom: 1.2rem;
  filter: drop-shadow(0 8px 20px rgb(224 112 58 / 0.25));
}

.auth-card h1 {
  margin-bottom: 0.35rem;
  font-size: clamp(1.6rem, 4vw, 2rem);
}

.auth-card .hero-lead {
  margin-bottom: 1.6rem;
  font-size: 0.95rem;
}

.auth-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 1.4rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--line-soft);
  font-size: 0.86rem;
}

.auth-links a {
  color: var(--text-soft);
  text-decoration: none;
}

.auth-links a:hover {
  color: var(--accent-bright);
}

/* --------------------------------------------------------------- alerts */

.alert {
  display: flex;
  gap: 0.65rem;
  margin: 0 0 1.1rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-raised);
  color: var(--text-soft);
  font-size: 0.88rem;
}

.alert[hidden] {
  display: none;
}

.alert svg {
  flex: none;
  width: 18px;
  height: 18px;
  margin-top: 2px;
}

.alert-error {
  border-color: rgb(242 109 109 / 0.35);
  background: rgb(242 109 109 / 0.08);
  color: #ffc2c2;
}

.alert-error svg {
  color: var(--danger);
}

.alert-info {
  border-color: rgb(224 112 58 / 0.3);
  background: rgb(224 112 58 / 0.07);
}

.alert-info svg {
  color: var(--accent-bright);
}

.alert-ok {
  border-color: rgb(95 208 138 / 0.3);
  background: rgb(95 208 138 / 0.07);
}

.alert-ok svg {
  color: var(--ok);
}

/* ------------------------------------------------------------- dashboard */

.dashboard {
  padding: clamp(2rem, 5vw, 3.5rem) 0 clamp(3rem, 6vw, 5rem);
}

.dash-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2rem;
}

.dash-head h1 {
  margin-bottom: 0.25rem;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
}

.dash-head p {
  margin: 0;
  color: var(--muted);
}

.user-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.45rem 0.8rem 0.45rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-soft);
  font-size: 0.86rem;
  font-weight: 600;
}

.user-chip .avatar {
  display: grid;
  place-items: center;
  width: 27px;
  height: 27px;
  border-radius: 50%;
  background: linear-gradient(140deg, var(--accent), var(--wine));
  color: #1b0c04;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.token-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
  margin-bottom: 2.4rem;
  padding: 1rem 1.15rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--bg-soft);
}

.token-bar .token-label {
  margin: 0 0 0.25rem;
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.token-bar code {
  display: block;
  overflow: hidden;
  color: var(--text-soft);
  font-size: 0.86rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.token-bar .token-actions {
  display: flex;
  gap: 0.5rem;
}

.panel-section {
  margin-bottom: clamp(2.4rem, 5vw, 3.6rem);
}

.panel-section .section-head {
  margin-bottom: 1.3rem;
}

.panel-section .section-head h2 {
  margin: 0;
  font-size: clamp(1.35rem, 2.4vw, 1.75rem);
}

.filters {
  display: inline-flex;
  gap: 0.25rem;
  padding: 0.25rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg-soft);
}

.filters button {
  padding: 0.35rem 0.7rem;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}

.filters button[aria-pressed="true"] {
  background: var(--surface-raised);
  color: var(--text);
}

/* Tarjetas de evento */

.event-list {
  display: grid;
  gap: 0.8rem;
}

.event-card {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) auto;
  gap: 1.15rem;
  align-items: center;
  padding: 1.1rem 1.2rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: linear-gradient(140deg, var(--surface) 0%, var(--bg-soft) 100%);
  transition: border-color 160ms ease, transform 160ms ease;
}

.event-card:hover {
  border-color: var(--line);
  transform: translateY(-1px);
}

.event-date {
  display: grid;
  place-items: center;
  padding: 0.55rem 0.3rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  text-align: center;
}

.event-date .month {
  color: var(--accent);
  font-size: 0.68rem;
  font-weight: 750;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.event-date .day {
  color: var(--text);
  font-size: 1.5rem;
  font-weight: 720;
  line-height: 1.1;
}

.event-body {
  min-width: 0;
}

.event-body h3 {
  margin-bottom: 0.18rem;
}

.event-body p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}

.event-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.9rem;
  margin-top: 0.4rem;
  color: var(--text-soft);
  font-size: 0.8rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.12rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-raised);
  color: var(--text-soft);
  font-size: 0.72rem;
  font-weight: 650;
}

.badge-soon {
  border-color: rgb(224 112 58 / 0.35);
  background: rgb(224 112 58 / 0.1);
  color: var(--accent-bright);
}

.badge-past {
  color: var(--muted);
}

/* Tarjetas de versión */

.version-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.version-card {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  padding: 1.2rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: linear-gradient(150deg, var(--surface) 0%, var(--bg-soft) 100%);
}

.version-head {
  display: flex;
  gap: 0.9rem;
  align-items: center;
}

.version-icon {
  display: grid;
  flex: none;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--bg);
  color: var(--accent-bright);
  font-weight: 800;
  text-transform: uppercase;
}

.version-icon img {
  width: 100%;
  height: 100%;
  border-radius: 10px;
  object-fit: cover;
}

.version-head h3 {
  margin: 0;
  font-size: 1.02rem;
}

.version-head p {
  margin: 0;
  color: var(--muted);
  font-size: 0.8rem;
}

.version-card > p {
  flex: 1;
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.version-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.version-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding-top: 0.8rem;
  border-top: 1px solid var(--line-soft);
  color: var(--muted);
  font-size: 0.78rem;
}

.version-foot .hint {
  font-size: 0.76rem;
}

/* Esqueletos y estados */

.skeleton {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: linear-gradient(100deg, var(--surface) 30%, var(--surface-raised) 50%, var(--surface) 70%);
  background-size: 200% 100%;
  animation: shimmer 1.3s linear infinite;
}

.skeleton-event {
  height: 104px;
}

.skeleton-version {
  height: 200px;
}

@keyframes shimmer {
  to {
    background-position: -200% 0;
  }
}

.empty {
  display: grid;
  place-items: center;
  gap: 0.35rem;
  padding: 2.4rem 1.5rem;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  background: var(--bg-soft);
  color: var(--muted);
  text-align: center;
}

.empty strong {
  color: var(--text-soft);
  font-weight: 650;
}

.empty p {
  margin: 0;
  font-size: 0.9rem;
}

.error-box {
  padding: 1.2rem;
  border: 1px solid rgb(242 109 109 / 0.3);
  border-radius: var(--radius);
  background: rgb(242 109 109 / 0.06);
  color: #ffc2c2;
}

.error-box p {
  margin: 0 0 0.7rem;
}

/* ------------------------------------------------------------- descargas */

.page-head {
  padding: clamp(2.5rem, 6vw, 4.5rem) 0 1rem;
}

.page-head h1 {
  margin-bottom: 0.4rem;
  font-size: clamp(2rem, 5vw, 3.2rem);
}

.page-head .hero-lead {
  margin-bottom: 0;
}

.os-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 2rem 0 1.2rem;
}

.os-tab {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.5rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
}

.os-tab svg {
  width: 16px;
  height: 16px;
}

.os-tab:hover {
  background: var(--surface);
  color: var(--text);
}

.os-tab[aria-selected="true"] {
  border-color: var(--accent-deep);
  background: var(--surface-raised);
  color: var(--text);
}

.download-card {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 1.5rem;
  padding: clamp(1.3rem, 3vw, 2rem);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(125deg, rgb(224 112 58 / 0.10), transparent 50%),
    var(--surface);
  box-shadow: var(--shadow);
}

.download-card h2 {
  margin-bottom: 0.3rem;
  font-size: 1.4rem;
}

.download-meta {
  display: grid;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.85rem;
}

.download-meta li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--line-soft);
  color: var(--muted);
}

.download-meta strong {
  color: var(--text-soft);
  font-weight: 620;
  text-align: right;
  overflow-wrap: anywhere;
}

.download-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: 1.2rem;
}

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

.asset-list li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--line-soft);
  font-size: 0.86rem;
}

.asset-list li:last-child {
  border-bottom: 0;
}

.asset-list a {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  overflow-wrap: anywhere;
}

details.assets {
  margin-top: 1.2rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--bg-soft);
}

details.assets summary {
  padding: 0.8rem 1rem;
  color: var(--text-soft);
  font-size: 0.88rem;
  font-weight: 620;
  cursor: pointer;
}

details.assets > div {
  padding: 0 1rem 0.4rem;
}

.note-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  margin-top: 1.2rem;
}

.note {
  padding: 1.1rem 1.2rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--bg-soft);
}

.note h3 {
  margin-bottom: 0.35rem;
  font-size: 0.96rem;
}

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

/* --------------------------------------------------------------- footer */

.site-footer {
  margin-top: 2rem;
  padding: 2.5rem 0 2rem;
  border-top: 1px solid var(--line-soft);
  background: rgb(11 13 16 / 0.6);
}

.footer-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 2rem;
}

.footer-brand {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  max-width: 22rem;
}

.footer-brand img {
  width: 40px;
  height: 40px;
}

.footer-brand p {
  margin: 0.2rem 0 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 2.5rem;
}

.footer-links div {
  display: grid;
  align-content: start;
  gap: 0.4rem;
}

.footer-links h2 {
  margin: 0 0 0.2rem;
  color: var(--text-soft);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.footer-links a {
  color: var(--muted);
  font-size: 0.86rem;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--accent-bright);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: 2.2rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--line-soft);
  color: var(--muted);
  font-size: 0.78rem;
}

/* ------------------------------------------------------------- utilities */

.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;
}

[hidden] {
  display: none !important;
}

.text-accent {
  color: var(--accent-bright);
}

.text-muted {
  color: var(--muted);
}

.mono {
  font-family: var(--font-mono);
}

/* ----------------------------------------------------------- responsive */

@media (max-width: 860px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .hero-art {
    order: -1;
    min-height: 300px;
  }

  .hero-logo {
    width: min(64%, 280px);
  }

  .hero-ring {
    width: min(76%, 330px);
  }

  .download-card {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  :root {
    --header-height: 64px;
  }

  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0.15rem;
    padding: 0.75rem 1.25rem 1rem;
    border-bottom: 1px solid var(--line);
    background: rgb(11 13 16 / 0.98);
    box-shadow: var(--shadow);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 0.65rem 0.7rem;
  }

  .site-nav .nav-cta {
    margin: 0.4rem 0 0;
    text-align: center;
  }

  .event-card {
    grid-template-columns: 62px minmax(0, 1fr);
    gap: 0.9rem;
  }

  .event-card > .btn {
    grid-column: 1 / -1;
    width: 100%;
  }

  .token-bar {
    grid-template-columns: 1fr;
  }

  .token-bar .token-actions {
    flex-wrap: wrap;
  }

  .token-bar .token-actions .btn {
    flex: 1;
  }

  .dash-head {
    align-items: flex-start;
  }
}

@media (max-width: 420px) {
  .container {
    width: min(100% - 1.6rem, var(--max-width));
  }

  .hero-actions .btn {
    width: 100%;
  }

  .hero-tag.tag-b {
    right: 0;
  }
}
