/* ============================================================
   CARREA 2.0 — Design System
   Red profesional (LinkedIn) × aprendizaje gamificado (Duolingo)
   Público: 19–23 años · Mobile-first · Light / Dark
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,600;12..96,700;12..96,800&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
    /* ---- Superficies (tono cálido estilo LinkedIn) ---- */
    --bg: #F3F2EF;
    --surface: #FFFFFF;
    --surface-2: #F7F6F3;
    --surface-3: #EFEDE8;
    --line: #E6E3DD;
    --line-strong: #D6D2CA;
    --overlay: rgba(14, 17, 22, 0.55);

    /* ---- Texto ---- */
    --ink: #0E1116;
    --text: #2A2E35;
    --muted: #666B74;
    --faint: #9A9FA8;
    --on-tone: #FFFFFF;

    /* ---- Tonos (juego) ---- */
    --green: #22C55E;  --green-deep: #179C49;  --green-soft: #DCFCE7;  --green-ink: #15803D;
    --blue: #3B82F6;   --blue-deep: #1D5FD8;   --blue-soft: #DBEAFE;   --blue-ink: #1D4ED8;
    --purple: #8B5CF6; --purple-deep: #6D28D9; --purple-soft: #EDE9FE; --purple-ink: #6D28D9;
    --orange: #F97316; --orange-deep: #C2410C; --orange-soft: #FFEDD5; --orange-ink: #C2410C;
    --gold: #FBBF24;   --gold-deep: #D48806;   --gold-soft: #FEF3C7;   --gold-ink: #A16207;
    --red: #EF4444;    --red-deep: #B91C1C;    --red-soft: #FEE2E2;    --red-ink: #B91C1C;
    --pink: #EC4899;   --pink-deep: #BE185D;   --pink-soft: #FCE7F3;   --pink-ink: #BE185D;
    --lime: #BEF264;

    /* ---- Profesional (acciones tipo LinkedIn) ---- */
    --pro: #0A66C2;
    --pro-deep: #08519B;
    --pro-soft: #E8F1FB;

    /* ---- Sistema ---- */
    --font: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --display: 'Bricolage Grotesque', 'Plus Jakarta Sans', system-ui, sans-serif;
    --r-sm: 10px;
    --r: 14px;
    --r-lg: 20px;
    --r-xl: 28px;
    --pill: 999px;
    --shadow-1: 0 1px 2px rgba(16, 20, 26, 0.05), 0 0 0 1px rgba(16, 20, 26, 0.02);
    --shadow-2: 0 6px 24px -8px rgba(16, 20, 26, 0.18);
    --shadow-3: 0 24px 60px -12px rgba(16, 20, 26, 0.35);
    --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
    --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
    --top-h: 60px;
    --nav-h: 68px;
    --main-w: 600px;

    color-scheme: light;
}

/* ---- Modo oscuro (auto o forzado) ---- */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --bg: #0B0D10; --surface: #15181D; --surface-2: #1B1F25; --surface-3: #232831;
        --line: #252A32; --line-strong: #323844; --overlay: rgba(0, 0, 0, 0.7);
        --ink: #F3F5F8; --text: #D7DBE1; --muted: #98A0AB; --faint: #6B7380;
        --green-soft: rgba(34, 197, 94, 0.15); --green-ink: #4ADE80;
        --blue-soft: rgba(59, 130, 246, 0.16); --blue-ink: #7AA7FF;
        --purple-soft: rgba(139, 92, 246, 0.18); --purple-ink: #B39BFF;
        --orange-soft: rgba(249, 115, 22, 0.16); --orange-ink: #FB9A55;
        --gold-soft: rgba(251, 191, 36, 0.15); --gold-ink: #FCD34D;
        --red-soft: rgba(239, 68, 68, 0.16); --red-ink: #F87171;
        --pink-soft: rgba(236, 72, 153, 0.16); --pink-ink: #F472B6;
        --pro: #3B8FE6; --pro-deep: #2563B8; --pro-soft: rgba(59, 143, 230, 0.15);
        --shadow-1: 0 0 0 1px rgba(255, 255, 255, 0.02);
        --shadow-2: 0 8px 28px -10px rgba(0, 0, 0, 0.6);
        color-scheme: dark;
    }
}
:root[data-theme="dark"] {
    --bg: #0B0D10; --surface: #15181D; --surface-2: #1B1F25; --surface-3: #232831;
    --line: #252A32; --line-strong: #323844; --overlay: rgba(0, 0, 0, 0.7);
    --ink: #F3F5F8; --text: #D7DBE1; --muted: #98A0AB; --faint: #6B7380;
    --green-soft: rgba(34, 197, 94, 0.15); --green-ink: #4ADE80;
    --blue-soft: rgba(59, 130, 246, 0.16); --blue-ink: #7AA7FF;
    --purple-soft: rgba(139, 92, 246, 0.18); --purple-ink: #B39BFF;
    --orange-soft: rgba(249, 115, 22, 0.16); --orange-ink: #FB9A55;
    --gold-soft: rgba(251, 191, 36, 0.15); --gold-ink: #FCD34D;
    --red-soft: rgba(239, 68, 68, 0.16); --red-ink: #F87171;
    --pink-soft: rgba(236, 72, 153, 0.16); --pink-ink: #F472B6;
    --pro: #3B8FE6; --pro-deep: #2563B8; --pro-soft: rgba(59, 143, 230, 0.15);
    --shadow-1: 0 0 0 1px rgba(255, 255, 255, 0.02);
    --shadow-2: 0 8px 28px -10px rgba(0, 0, 0, 0.6);
    color-scheme: dark;
}

/* ---- Tonos: cualquier componente usa var(--tone*) ---- */
.tone-green  { --tone: var(--green);  --tone-deep: var(--green-deep);  --tone-soft: var(--green-soft);  --tone-ink: var(--green-ink); }
.tone-blue   { --tone: var(--blue);   --tone-deep: var(--blue-deep);   --tone-soft: var(--blue-soft);   --tone-ink: var(--blue-ink); }
.tone-purple { --tone: var(--purple); --tone-deep: var(--purple-deep); --tone-soft: var(--purple-soft); --tone-ink: var(--purple-ink); }
.tone-orange { --tone: var(--orange); --tone-deep: var(--orange-deep); --tone-soft: var(--orange-soft); --tone-ink: var(--orange-ink); }
.tone-gold   { --tone: var(--gold);   --tone-deep: var(--gold-deep);   --tone-soft: var(--gold-soft);   --tone-ink: var(--gold-ink); }
.tone-red    { --tone: var(--red);    --tone-deep: var(--red-deep);    --tone-soft: var(--red-soft);    --tone-ink: var(--red-ink); }
.tone-pink   { --tone: var(--pink);   --tone-deep: var(--pink-deep);   --tone-soft: var(--pink-soft);   --tone-ink: var(--pink-ink); }

/* ============================================================
   BASE
   ============================================================ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html { font-size: 16px; scroll-behavior: smooth; }

body {
    font-family: var(--font);
    color: var(--text);
    background: var(--bg);
    line-height: 1.5;
    font-weight: 500;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overscroll-behavior-y: none;
    min-height: 100vh;
    transition: background-color 0.3s ease;
}

h1, h2, h3, h4 { color: var(--ink); font-family: var(--display); font-weight: 700; line-height: 1.15; letter-spacing: -0.02em; }
h1 { font-size: 1.85rem; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.1rem; }
h4 { font-size: 0.98rem; }

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
button { font-family: inherit; color: inherit; cursor: pointer; border: none; background: none; font-size: inherit; }
input, textarea, select { font-family: inherit; }
:focus-visible { outline: 2.5px solid var(--pro); outline-offset: 2px; border-radius: 8px; }
::selection { background: var(--green-soft); color: var(--ink); }

.ico { width: 1.25em; height: 1.25em; flex-shrink: 0; display: inline-block; vertical-align: middle; }
.ico.fill { fill: currentColor; stroke: none; }
.num { font-family: var(--display); font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }

/* ============================================================
   TOPBAR
   ============================================================ */
.topbar {
    position: sticky;
    top: 0;
    z-index: 40;
    height: var(--top-h);
    background: color-mix(in srgb, var(--surface) 86%, transparent);
    backdrop-filter: saturate(1.6) blur(16px);
    -webkit-backdrop-filter: saturate(1.6) blur(16px);
    border-bottom: 1px solid var(--line);
}
.topbar-inner {
    height: 100%;
    max-width: 1128px;
    margin: 0 auto;
    padding: 0 16px;
    display: flex;
    align-items: center;
    gap: 14px;
}

.brand { display: flex; align-items: center; gap: 9px; font-family: var(--display); font-weight: 800; font-size: 1.32rem; color: var(--ink); letter-spacing: -0.04em; }
.brand-mark { width: 32px; height: 32px; flex-shrink: 0; filter: drop-shadow(0 2px 0 var(--green-deep)); }
.brand .brand-dot { color: var(--green); }

.top-nav { display: none; }

.topbar-stats { margin-left: auto; display: flex; align-items: center; gap: 8px; }

.stat-group {
    display: flex;
    align-items: center;
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: var(--pill);
    padding: 3px;
}
.stat-chip {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 9px;
    border-radius: var(--pill);
    font-family: var(--display);
    font-weight: 700;
    font-size: 0.92rem;
    color: var(--ink);
    transition: background 0.2s;
}
.stat-chip .ico { width: 18px; height: 18px; }
.stat-chip.streak .ico { color: var(--orange); }
.stat-chip.streak.off .ico { color: var(--faint); }
.stat-chip.gems .ico { color: var(--blue); }
.stat-chip.hearts .ico { color: var(--red); }
.stat-chip.bump { animation: bump 0.5s var(--spring); }
@keyframes bump { 40% { transform: scale(1.25); } }

.icon-btn {
    width: 38px; height: 38px;
    display: grid; place-items: center;
    border-radius: 50%;
    color: var(--muted);
    transition: background 0.2s, color 0.2s, transform 0.15s;
}
.icon-btn:hover { background: var(--surface-3); color: var(--ink); }
.icon-btn:active { transform: scale(0.92); }
.icon-btn .ico { width: 20px; height: 20px; }

.me-btn { position: relative; border-radius: 50%; transition: transform 0.15s; }
.me-btn:active { transform: scale(0.92); }
.me-btn .sync-dot {
    position: absolute; right: -1px; bottom: -1px;
    width: 12px; height: 12px; border-radius: 50%;
    border: 2px solid var(--surface);
    background: var(--faint);
}
.me-btn .sync-dot.synced { background: var(--green); }
.me-btn .sync-dot.saving { background: var(--gold); animation: pulse 1s ease-in-out infinite; }
.me-btn .sync-dot.offline { background: var(--red); }
@keyframes pulse { 50% { opacity: 0.35; } }

.theme-btn { display: none; }

/* ============================================================
   LAYOUT
   ============================================================ */
.layout {
    max-width: var(--main-w);
    margin: 0 auto;
    padding: 14px 12px calc(var(--nav-h) + 28px + env(safe-area-inset-bottom));
}
.side { display: none; }
.main { min-width: 0; }

.screen { display: none; }
.screen.active { display: block; animation: screenIn 0.42s var(--ease); }
@keyframes screenIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.stagger > * { animation: rise 0.5s var(--ease) both; }
.stagger > *:nth-child(1) { animation-delay: 0.02s; }
.stagger > *:nth-child(2) { animation-delay: 0.06s; }
.stagger > *:nth-child(3) { animation-delay: 0.10s; }
.stagger > *:nth-child(4) { animation-delay: 0.14s; }
.stagger > *:nth-child(5) { animation-delay: 0.18s; }
.stagger > *:nth-child(6) { animation-delay: 0.22s; }
.stagger > *:nth-child(n+7) { animation-delay: 0.26s; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

.page-head { padding: 6px 4px 14px; }
.page-head h1 { font-size: 1.7rem; }
.page-head p { color: var(--muted); font-size: 0.92rem; margin-top: 4px; max-width: 46ch; }
.eyebrow { font-size: 0.72rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--green-ink); }

/* ============================================================
   NAVEGACIÓN
   ============================================================ */
.bottom-nav {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 50;
    height: calc(var(--nav-h) + env(safe-area-inset-bottom));
    padding: 6px 6px env(safe-area-inset-bottom);
    background: color-mix(in srgb, var(--surface) 90%, transparent);
    backdrop-filter: saturate(1.6) blur(18px);
    -webkit-backdrop-filter: saturate(1.6) blur(18px);
    border-top: 1px solid var(--line);
    display: flex;
    justify-content: center;
}
.bottom-nav .nav-inner { width: 100%; max-width: var(--main-w); display: flex; }

.nav-item {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    color: var(--muted);
    font-size: 0.68rem;
    font-weight: 700;
    white-space: nowrap;
    transition: color 0.2s;
    position: relative;
}
.nav-item .nav-ico {
    width: 54px; height: 30px;
    display: grid; place-items: center;
    border-radius: var(--pill);
    transition: background 0.3s var(--ease), transform 0.3s var(--spring);
}
.nav-item .nav-ico .ico { width: 22px; height: 22px; transition: transform 0.3s var(--spring); }
.nav-item:active .nav-ico { transform: scale(0.9); }
.nav-item.active { color: var(--ink); }
.nav-item.active .nav-ico { background: var(--green-soft); color: var(--green-ink); }
.nav-item.active .nav-ico .ico { transform: translateY(-1px); stroke-width: 2.4; }
.nav-item .nav-label { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }

/* ============================================================
   BOTONES — píldora con profundidad 3D sutil
   ============================================================ */
.btn {
    --b: var(--green); --b-deep: var(--green-deep); --b-ink: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 800;
    font-size: 0.94rem;
    letter-spacing: -0.005em;
    padding: 12px 22px;
    border-radius: var(--pill);
    color: var(--b-ink);
    background: var(--b);
    box-shadow: 0 3px 0 var(--b-deep);
    transition: transform 0.08s ease, box-shadow 0.08s ease, filter 0.2s, background 0.2s;
    user-select: none;
    white-space: nowrap;
    position: relative;
    top: 0;
}
.btn .ico { width: 18px; height: 18px; }
.btn:hover { filter: brightness(1.06); }
.btn:active { transform: translateY(3px); box-shadow: 0 0 0 var(--b-deep); }

.btn.full { width: 100%; }
.btn.sm { padding: 8px 15px; font-size: 0.84rem; box-shadow: 0 2px 0 var(--b-deep); }
.btn.sm:active { transform: translateY(2px); }
.btn.lg { padding: 15px 26px; font-size: 1.02rem; }

.btn.pro { --b: var(--pro); --b-deep: var(--pro-deep); }
.btn.red { --b: var(--red); --b-deep: var(--red-deep); }
.btn.gold { --b: var(--gold); --b-deep: var(--gold-deep); --b-ink: #3A2A00; }
.btn.dark { --b: var(--ink); --b-deep: #000; --b-ink: var(--surface); }
.btn.white { --b: #fff; --b-deep: rgba(0, 0, 0, 0.18); --b-ink: #0E1116; }

/* Outline estilo LinkedIn */
.btn.outline {
    background: transparent;
    color: var(--pro);
    box-shadow: inset 0 0 0 1.5px var(--pro);
}
.btn.outline:hover { background: var(--pro-soft); filter: none; }
.btn.outline:active { transform: scale(0.97); box-shadow: inset 0 0 0 2px var(--pro); }

.btn.ghost {
    background: var(--surface);
    color: var(--text);
    box-shadow: inset 0 0 0 1.5px var(--line-strong), 0 2px 0 var(--line);
}
.btn.ghost:hover { background: var(--surface-2); filter: none; }
.btn.ghost:active { transform: translateY(2px); box-shadow: inset 0 0 0 1.5px var(--line-strong); }
.btn.ghost.danger { color: var(--red-ink); }

.btn.soft { background: var(--surface-3); color: var(--ink); box-shadow: none; }
.btn.soft:hover { filter: none; background: var(--line); }
.btn.soft:active { transform: scale(0.97); }

.btn:disabled, .btn.disabled {
    background: var(--surface-3);
    color: var(--faint);
    box-shadow: none;
    cursor: not-allowed;
    pointer-events: none;
    filter: none;
}
.btn.done { background: var(--green-soft); color: var(--green-ink); box-shadow: none; pointer-events: none; }

.text-btn { color: var(--pro); font-weight: 700; font-size: 0.86rem; display: inline-flex; align-items: center; gap: 4px; padding: 6px 8px; border-radius: 8px; transition: background 0.2s; }
.text-btn:hover { background: var(--pro-soft); }
.text-btn .ico { width: 16px; height: 16px; }

/* ============================================================
   CARDS
   ============================================================ */
.card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    padding: 16px;
    margin-bottom: 10px;
    box-shadow: var(--shadow-1);
}
.card.flush { padding: 0; overflow: hidden; }
.card.dashed { border-style: dashed; border-width: 1.5px; background: transparent; box-shadow: none; }
@media (hover: hover) {
    .card.lift { transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s; }
    .card.lift:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); border-color: var(--line-strong); }
}

.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.card-head h3 { font-size: 1.12rem; }
.card-head .sub { color: var(--muted); font-size: 0.8rem; font-weight: 600; }

.section-title { display: flex; align-items: baseline; justify-content: space-between; margin: 22px 4px 10px; }
.section-title h3 { font-size: 1.12rem; }

/* ---- Pills ---- */
.pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: var(--pill);
    font-size: 0.76rem;
    font-weight: 700;
    background: var(--surface-3);
    color: var(--muted);
    white-space: nowrap;
}
.pill .ico { width: 14px; height: 14px; }
.pill[class*="tone-"] { background: var(--tone-soft); color: var(--tone-ink); }
.pill.pro { background: var(--pro-soft); color: var(--pro); }
.pill.solid[class*="tone-"] { background: var(--tone); color: #fff; }

/* ---- Avatares ---- */
.avatar {
    border-radius: 50%;
    background: var(--tone-soft);
    color: var(--tone-ink);
    display: grid;
    place-items: center;
    font-family: var(--display);
    font-weight: 700;
    flex-shrink: 0;
    overflow: hidden;
    letter-spacing: -0.02em;
    position: relative;
}
.avatar.emoji { background: linear-gradient(145deg, var(--tone-soft), color-mix(in srgb, var(--tone) 28%, var(--surface))); }
.avatar.xs { width: 32px; height: 32px; font-size: 0.78rem; }
.avatar.xs.emoji { font-size: 1.05rem; }
.avatar.sm { width: 40px; height: 40px; font-size: 0.95rem; }
.avatar.sm.emoji { font-size: 1.25rem; }
.avatar.md { width: 52px; height: 52px; font-size: 1.15rem; }
.avatar.md.emoji { font-size: 1.6rem; }
.avatar.lg { width: 120px; height: 120px; font-size: 2.6rem; }
.avatar.lg.emoji { font-size: 3.6rem; }
.avatar.ring { box-shadow: 0 0 0 4px var(--surface); }

/* ---- Barras de progreso ---- */
.progress {
    height: 10px;
    background: var(--surface-3);
    border-radius: var(--pill);
    overflow: hidden;
}
.progress .bar {
    height: 100%;
    border-radius: var(--pill);
    background: var(--tone, var(--green));
    transform-origin: left center;
    animation: growX 0.9s var(--ease) both;
    position: relative;
}
.progress .bar::after {
    content: "";
    position: absolute;
    top: 2px; left: 6px; right: 6px;
    height: 3px;
    background: rgba(255, 255, 255, 0.35);
    border-radius: var(--pill);
}
.progress.thin { height: 6px; }
.progress.thin .bar::after { display: none; }
.progress.lg { height: 14px; }
@keyframes growX { from { transform: scaleX(0); } }

/* ---- Anillo de progreso (SVG) ---- */
.ring { position: relative; display: grid; place-items: center; flex-shrink: 0; }
.ring svg { transform: rotate(-90deg); }
.ring .ring-track { stroke: var(--ring-track, var(--surface-3)); }
.ring .ring-val { stroke: var(--ring-color, var(--green)); stroke-linecap: round; animation: ringIn 1.1s var(--ease) both; }
.ring .ring-label { position: absolute; text-align: center; line-height: 1.05; }
@keyframes ringIn { from { stroke-dashoffset: var(--circ); } }

/* ============================================================
   APRENDE
   ============================================================ */
.hero {
    position: relative;
    overflow: hidden;
    border-radius: var(--r-xl);
    padding: 20px;
    margin-bottom: 12px;
    color: #fff;
    background:
        radial-gradient(120% 90% at 100% 0%, rgba(190, 242, 100, 0.38), transparent 55%),
        radial-gradient(80% 80% at 0% 100%, rgba(34, 197, 94, 0.45), transparent 60%),
        linear-gradient(140deg, #0C2E22 0%, #11402D 45%, #15803D 100%);
    box-shadow: 0 16px 40px -18px rgba(21, 128, 61, 0.7);
}
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.09) 1px, transparent 1px);
    background-size: 14px 14px;
    mask-image: linear-gradient(120deg, transparent 30%, #000 100%);
    -webkit-mask-image: linear-gradient(120deg, transparent 30%, #000 100%);
    pointer-events: none;
}
.hero > * { position: relative; }
.hero h1, .hero h2 { color: #fff; }
.hero .hero-top { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.hero .greet { font-size: 0.86rem; font-weight: 600; opacity: 0.85; }
.hero .title { font-family: var(--display); font-size: 1.55rem; font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; margin-top: 2px; }
.hero .chips { display: flex; gap: 6px; margin-top: 12px; flex-wrap: wrap; }
.hero .hchip { display: inline-flex; align-items: center; gap: 5px; padding: 5px 11px; border-radius: var(--pill); background: rgba(255, 255, 255, 0.12); border: 1px solid rgba(255, 255, 255, 0.16); font-size: 0.78rem; font-weight: 700; backdrop-filter: blur(6px); }
.hero .hchip .ico { width: 15px; height: 15px; }
.hero .hchip.lime { background: var(--lime); color: #1A2E05; border-color: transparent; }
.hero .hero-foot { margin-top: 14px; font-size: 0.86rem; font-weight: 600; opacity: 0.92; display: flex; align-items: center; gap: 8px; }
.hero .ring { --ring-track: rgba(255, 255, 255, 0.16); --ring-color: var(--lime); }
.hero .ring .big { font-family: var(--display); font-weight: 800; font-size: 1.45rem; }
.hero .ring .small { font-size: 0.66rem; font-weight: 700; opacity: 0.8; }

.coach {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 4px 4px 8px;
    margin-bottom: 6px;
}
.coach .coach-face {
    width: 46px; height: 46px; border-radius: 16px;
    display: grid; place-items: center;
    font-size: 1.75rem;
    background: var(--orange-soft);
    flex-shrink: 0;
    animation: wiggle 4s ease-in-out infinite;
}
@keyframes wiggle { 0%, 88%, 100% { transform: rotate(0); } 92% { transform: rotate(-8deg); } 96% { transform: rotate(6deg); } }
.coach .bubble {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 4px 16px 16px 16px;
    padding: 10px 14px;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text);
    box-shadow: var(--shadow-1);
}
.coach .bubble b { color: var(--ink); display: block; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--orange-ink); margin-bottom: 1px; }

.course { margin-top: 18px; }
.course-head {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    padding: 14px;
    box-shadow: var(--shadow-1);
}
.course-ico {
    width: 52px; height: 52px; border-radius: 16px;
    display: grid; place-items: center;
    font-size: 1.6rem;
    background: var(--tone-soft);
    flex-shrink: 0;
}
.course-head h3 { font-size: 1.06rem; }
.course-head .sub { font-size: 0.8rem; color: var(--muted); font-weight: 600; margin: 1px 0 8px; line-height: 1.35; }
.course-head .meta { display: flex; align-items: center; gap: 10px; }
.course-head .meta .progress { flex: 1; }
.course-head .meta span { font-size: 0.76rem; font-weight: 800; color: var(--tone-ink); font-variant-numeric: tabular-nums; }

.unit-banner {
    margin: 18px 0 4px;
    border-radius: var(--r-lg);
    padding: 14px 16px;
    color: #fff;
    background: linear-gradient(120deg, var(--tone), var(--tone-deep));
    box-shadow: 0 4px 0 var(--tone-deep);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.unit-banner .u-kicker { font-size: 0.7rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.85; }
.unit-banner .u-title { font-family: var(--display); font-weight: 700; font-size: 1.08rem; letter-spacing: -0.02em; }
.unit-banner .u-count { font-size: 0.78rem; font-weight: 800; background: rgba(255, 255, 255, 0.2); padding: 4px 10px; border-radius: var(--pill); white-space: nowrap; }

.path { display: flex; flex-direction: column; align-items: center; gap: 18px; padding: 26px 0 14px; }
.path-node:first-child:has(.start-tip) { margin-top: 34px; }
.path-node:not(:first-child):has(.start-tip) { margin-top: 26px; }
.path-node { display: flex; flex-direction: column; align-items: center; gap: 8px; position: relative; }

.lesson-bubble {
    width: 72px; height: 66px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 1.6rem;
    background: var(--tone);
    box-shadow: 0 6px 0 var(--tone-deep), inset 0 -3px 0 rgba(0, 0, 0, 0.06);
    transition: transform 0.1s ease, box-shadow 0.1s ease;
    position: relative;
}
.lesson-bubble::before {
    content: "";
    position: absolute;
    top: 9px; left: 15px;
    width: 18px; height: 9px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.35);
    transform: rotate(-24deg);
}
.lesson-bubble .ico { width: 30px; height: 30px; stroke-width: 3; }
.lesson-bubble:not(:disabled):hover { filter: brightness(1.05); }
.lesson-bubble:not(:disabled):active { transform: translateY(5px); box-shadow: 0 1px 0 var(--tone-deep); }
.lesson-bubble.done { background: var(--gold); box-shadow: 0 6px 0 var(--gold-deep); }
.lesson-bubble.locked { background: var(--surface-3); box-shadow: 0 6px 0 var(--line-strong); color: var(--faint); cursor: not-allowed; }
.lesson-bubble.locked::before { display: none; }
.lesson-bubble.locked .ico { width: 24px; height: 24px; stroke-width: 2.4; }
.lesson-bubble.current { animation: nodeBob 2.2s ease-in-out infinite; }
.lesson-bubble.current::after {
    content: "";
    position: absolute;
    inset: -9px;
    border-radius: 50%;
    border: 4px solid var(--tone-soft);
    border-bottom-width: 6px;
}
@keyframes nodeBob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -5px; } }

.start-tip {
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    translate: -50% 0;
    background: var(--surface);
    color: var(--tone-ink);
    border: 1.5px solid var(--line);
    font-weight: 800;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 7px 12px;
    border-radius: 12px;
    white-space: nowrap;
    box-shadow: 0 3px 0 var(--line);
    animation: tipBob 1.6s ease-in-out infinite;
    pointer-events: none;
}
.start-tip::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    width: 10px; height: 10px;
    background: var(--surface);
    border-right: 1.5px solid var(--line);
    border-bottom: 1.5px solid var(--line);
    transform: translate(-50%, -5px) rotate(45deg);
}
@keyframes tipBob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }

.lesson-label { text-align: center; font-size: 0.78rem; font-weight: 700; color: var(--muted); max-width: 130px; line-height: 1.25; }
.lesson-label .xp { display: block; font-size: 0.7rem; color: var(--faint); font-weight: 700; margin-top: 2px; }
.lesson-label.cur { color: var(--ink); }
.lesson-label.cur .xp { color: var(--gold-ink); }

/* ---- Quiz ---- */
.quiz-top { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.quiz-top .progress { flex: 1; height: 14px; }
.quiz-top .hearts { display: flex; align-items: center; gap: 4px; font-family: var(--display); font-weight: 800; color: var(--red); }
.quiz-top .hearts .ico { width: 22px; height: 22px; }
.quiz-q { font-size: 1.45rem; margin: 10px 0 22px; line-height: 1.2; }
.quiz-opts { display: flex; flex-direction: column; gap: 10px; }
.quiz-opt {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    text-align: left;
    padding: 13px 14px;
    border: 2px solid var(--line);
    border-bottom-width: 4px;
    border-radius: 16px;
    background: var(--surface);
    font-weight: 700;
    color: var(--ink);
    font-size: 0.98rem;
    transition: background 0.15s, border-color 0.15s, transform 0.08s;
}
.quiz-opt .key {
    width: 30px; height: 30px; border-radius: 9px;
    display: grid; place-items: center;
    border: 2px solid var(--line);
    font-size: 0.8rem; font-weight: 800; color: var(--muted);
    flex-shrink: 0;
    transition: inherit;
}
.quiz-opt:hover { background: var(--surface-2); }
.quiz-opt:active { transform: translateY(2px); border-bottom-width: 2px; margin-top: 2px; }
.quiz-opt.sel { border-color: var(--blue); background: var(--blue-soft); color: var(--blue-ink); }
.quiz-opt.sel .key { border-color: var(--blue); color: var(--blue-ink); }
.quiz-opt.ok { border-color: var(--green); background: var(--green-soft); color: var(--green-ink); animation: pop 0.4s var(--spring); }
.quiz-opt.ok .key { border-color: var(--green); background: var(--green); color: #fff; }
.quiz-opt.bad { border-color: var(--red); background: var(--red-soft); color: var(--red-ink); animation: shake 0.4s ease; }
.quiz-opt.bad .key { border-color: var(--red); background: var(--red); color: #fff; }
.quiz-opt:disabled { cursor: default; }
.quiz-opt:disabled:active { transform: none; border-bottom-width: 4px; margin-top: 0; }
@keyframes pop { 50% { transform: scale(1.03); } }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }

.quiz-foot { margin-top: 22px; }
.feedback {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 16px;
    font-weight: 700;
    margin-bottom: 12px;
    animation: rise 0.3s var(--ease);
}
.feedback .f-ico { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; color: #fff; }
.feedback .f-ico .ico { width: 22px; height: 22px; stroke-width: 3; }
.feedback .f-title { font-family: var(--display); font-weight: 800; font-size: 1.08rem; }
.feedback .f-sub { font-size: 0.85rem; font-weight: 600; }
.feedback.ok { background: var(--green-soft); color: var(--green-ink); }
.feedback.ok .f-ico { background: var(--green); }
.feedback.bad { background: var(--red-soft); color: var(--red-ink); }
.feedback.bad .f-ico { background: var(--red); }

.result { text-align: center; padding: 8px 0 4px; }
.result .trophy { font-size: 4.2rem; animation: trophyIn 0.7s var(--spring) both; display: inline-block; }
@keyframes trophyIn { from { transform: scale(0.2) rotate(-20deg); opacity: 0; } }
.result h1 { margin: 6px 0 4px; }
.reward-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 20px 0; }
.reward {
    border-radius: 16px;
    border: 2px solid var(--tone);
    overflow: hidden;
    text-align: center;
    animation: rise 0.5s var(--ease) both;
}
.reward:nth-child(2) { animation-delay: 0.1s; }
.reward:nth-child(3) { animation-delay: 0.2s; }
.reward .r-lbl { background: var(--tone); color: #fff; font-size: 0.66rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; padding: 5px 4px; }
.reward .r-val { padding: 10px 4px; font-family: var(--display); font-weight: 800; font-size: 1.3rem; color: var(--tone-ink); display: flex; align-items: center; justify-content: center; gap: 4px; }
.reward .r-val .ico { width: 20px; height: 20px; }

/* Confetti */
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 300; overflow: hidden; }
.confetti i {
    position: absolute;
    top: -14px;
    width: 9px; height: 14px;
    border-radius: 2px;
    animation: fall linear forwards;
}
@keyframes fall { to { transform: translate3d(var(--dx), 110vh, 0) rotate(var(--rot)); opacity: 0.9; } }

/* ============================================================
   COMUNIDAD
   ============================================================ */
.composer { display: flex; align-items: center; gap: 10px; }
.composer-trigger {
    flex: 1;
    text-align: left;
    border: 1.5px solid var(--line-strong);
    border-radius: var(--pill);
    padding: 12px 18px;
    color: var(--muted);
    font-weight: 600;
    font-size: 0.92rem;
    transition: background 0.2s;
}
.composer-trigger:hover { background: var(--surface-2); }
.composer-actions { display: flex; justify-content: space-around; margin-top: 10px; }
.composer-act {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 9px 10px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.84rem;
    color: var(--muted);
    transition: background 0.2s;
}
.composer-act:hover { background: var(--surface-2); }
.composer-act .ico { width: 20px; height: 20px; }

.people-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding: 2px 2px 8px;
    margin: 0 -2px;
    scrollbar-width: none;
}
.people-scroll::-webkit-scrollbar { display: none; }
.person-card {
    flex: 0 0 168px;
    scroll-snap-align: start;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    overflow: hidden;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-bottom: 14px;
    box-shadow: var(--shadow-1);
}
.person-card .p-cover { width: 100%; height: 52px; background: linear-gradient(120deg, var(--tone-deep), var(--tone) 60%, var(--lime)); }
.person-card .avatar { margin-top: -28px; box-shadow: 0 0 0 3px var(--surface); }
.person-card .p-name { font-weight: 800; color: var(--ink); font-size: 0.9rem; margin-top: 8px; padding: 0 10px; }
.person-card .p-role { font-size: 0.76rem; color: var(--muted); padding: 0 10px; line-height: 1.3; min-height: 2em; }
.person-card .p-mutual { font-size: 0.72rem; color: var(--faint); margin: 6px 0 10px; display: flex; align-items: center; gap: 4px; }
.person-card .p-mutual .ico { width: 13px; height: 13px; }

.post { padding: 0; }
.post-head { display: flex; gap: 10px; padding: 14px 16px 0; align-items: flex-start; }
.post-head .who { flex: 1; min-width: 0; }
.post-head .name { font-weight: 800; color: var(--ink); font-size: 0.95rem; display: flex; align-items: center; gap: 6px; }
.post-head .role { font-size: 0.78rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.post-head .time { font-size: 0.74rem; color: var(--faint); display: flex; align-items: center; gap: 4px; }
.post-head .time .ico { width: 12px; height: 12px; }
.post-text { padding: 10px 16px 12px; color: var(--text); line-height: 1.55; white-space: pre-wrap; font-size: 0.94rem; }

.achievement {
    margin: 0 16px 12px;
    border-radius: 16px;
    padding: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    background:
        radial-gradient(100% 140% at 100% 0%, color-mix(in srgb, var(--gold) 35%, transparent), transparent 60%),
        var(--gold-soft);
    border: 1px solid color-mix(in srgb, var(--gold) 45%, transparent);
}
.achievement .a-ico {
    width: 48px; height: 48px; border-radius: 14px;
    display: grid; place-items: center;
    font-size: 1.6rem;
    background: var(--surface);
    box-shadow: 0 3px 0 color-mix(in srgb, var(--gold-deep) 50%, transparent);
    flex-shrink: 0;
}
.achievement .a-kicker { font-size: 0.68rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--gold-ink); }
.achievement .a-label { font-family: var(--display); font-weight: 700; color: var(--ink); font-size: 1rem; line-height: 1.2; }

.post-stats button { font-size: inherit; color: inherit; }
.post-stats button:hover { color: var(--pro); text-decoration: underline; }
.post-stats { display: flex; justify-content: space-between; align-items: center; padding: 0 16px 8px; font-size: 0.78rem; color: var(--muted); }
.reacts { display: flex; align-items: center; gap: 6px; }
.reacts .stack { display: flex; }
.reacts .stack span {
    width: 18px; height: 18px; border-radius: 50%;
    display: grid; place-items: center;
    font-size: 0.6rem;
    border: 1.5px solid var(--surface);
    margin-left: -4px;
}
.reacts .stack span:first-child { margin-left: 0; }
.reacts .stack .r1 { background: var(--pro); color: #fff; }
.reacts .stack .r2 { background: var(--red); color: #fff; }
.reacts .stack .r3 { background: var(--gold); }
.reacts .stack .ico { width: 10px; height: 10px; }

.post-actions { display: flex; border-top: 1px solid var(--line); padding: 4px 6px; }
.post-act {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 4px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.84rem;
    color: var(--muted);
    transition: background 0.2s, color 0.2s;
}
.post-act:hover { background: var(--surface-2); }
.post-act .ico { width: 19px; height: 19px; transition: transform 0.3s var(--spring); }
.post-act.liked { color: var(--pro); }
.post-act.liked .ico { fill: currentColor; fill-opacity: 0.18; }
.post-act.liked.pop .ico { animation: likePop 0.5s var(--spring); }
@keyframes likePop { 0% { transform: scale(1); } 35% { transform: scale(1.45) rotate(-14deg); } 100% { transform: scale(1); } }

.comment { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 12px; }
.comment .c-body { background: var(--surface-2); border-radius: 4px 14px 14px 14px; padding: 9px 12px; flex: 1; }
.comment .c-name { font-weight: 800; color: var(--ink); font-size: 0.84rem; }
.comment .c-text { font-size: 0.88rem; }

/* ============================================================
   PRÁCTICAS
   ============================================================ */
.kpis { display: grid; grid-template-columns: repeat(3, 1fr); padding: 0; }
.kpi { padding: 14px 8px; text-align: center; }
.kpi + .kpi { border-left: 1px solid var(--line); }
.kpi .k-val { font-family: var(--display); font-weight: 800; font-size: 1.6rem; color: var(--tone-ink); line-height: 1.1; }
.kpi .k-lbl { font-size: 0.74rem; color: var(--muted); font-weight: 700; }

.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px 0 4px; margin-bottom: 8px; }
.chips::-webkit-scrollbar { display: none; }
.chip {
    padding: 7px 14px;
    border-radius: var(--pill);
    border: 1.5px solid var(--line-strong);
    background: var(--surface);
    font-weight: 700;
    font-size: 0.84rem;
    color: var(--text);
    white-space: nowrap;
    transition: all 0.2s var(--ease);
}
.chip:hover { border-color: var(--ink); }
.chip.active { background: var(--ink); border-color: var(--ink); color: var(--surface); }

.logo-tile {
    width: 52px; height: 52px; border-radius: 14px;
    display: grid; place-items: center;
    font-size: 1.6rem;
    background: var(--tone-soft);
    border: 1px solid color-mix(in srgb, var(--tone) 22%, transparent);
    flex-shrink: 0;
}
.logo-tile .ico { width: 22px; height: 22px; }
.logo-tile.sm { width: 44px; height: 44px; font-size: 1.35rem; border-radius: 12px; }
.logo-tile.lg { width: 68px; height: 68px; font-size: 2rem; border-radius: 18px; }

.job { cursor: pointer; }
.job-top { display: flex; gap: 12px; align-items: flex-start; }
.job-top .info { flex: 1; min-width: 0; }
.job-role { font-weight: 800; color: var(--ink); font-size: 1rem; line-height: 1.25; }
.job:hover .job-role { color: var(--pro); }
.job-company { font-size: 0.86rem; color: var(--text); font-weight: 600; }
.job-loc { font-size: 0.8rem; color: var(--muted); display: flex; align-items: center; gap: 4px; margin-top: 1px; }
.job-loc .ico { width: 13px; height: 13px; }
.job-meta { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; }
.job-foot { display: flex; align-items: center; gap: 8px; }
.job-foot .stipend { font-weight: 800; color: var(--ink); font-size: 0.9rem; }
.job-foot .stipend small { color: var(--muted); font-weight: 600; }

.match {
    display: flex; flex-direction: column; align-items: center;
    flex-shrink: 0;
}
.match .ring .val { font-family: var(--display); font-weight: 800; font-size: 0.86rem; color: var(--ink); }
.match .m-lbl { font-size: 0.64rem; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; margin-top: 2px; }

.tracker { display: flex; align-items: center; margin: 14px 2px 6px; }
.tracker .dot { width: 12px; height: 12px; border-radius: 50%; background: var(--surface-3); flex-shrink: 0; box-shadow: 0 0 0 3px var(--surface); }
.tracker .dot.on { background: var(--green); }
.tracker .dot.now { background: var(--green); box-shadow: 0 0 0 3px var(--surface), 0 0 0 6px var(--green-soft); animation: pulse 1.6s ease-in-out infinite; }
.tracker .line { flex: 1; height: 3px; background: var(--surface-3); }
.tracker .line.on { background: var(--green); }
.tracker-lbl { display: flex; justify-content: space-between; font-size: 0.72rem; font-weight: 700; color: var(--muted); }
.tracker-lbl span:nth-child(-n+2) { color: var(--green-ink); }

.req-list { display: flex; flex-direction: column; gap: 10px; }
.req-list li { display: flex; gap: 10px; align-items: flex-start; font-size: 0.92rem; }
.req-list .tick { width: 22px; height: 22px; border-radius: 50%; background: var(--green-soft); color: var(--green-ink); display: grid; place-items: center; flex-shrink: 0; }
.req-list .tick .ico { width: 13px; height: 13px; stroke-width: 3; }

.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 16px 0; }
.detail-cell { background: var(--surface-2); border-radius: 14px; padding: 10px 12px; }
.detail-cell .d-lbl { font-size: 0.7rem; font-weight: 700; color: var(--muted); display: flex; align-items: center; gap: 5px; }
.detail-cell .d-lbl .ico { width: 13px; height: 13px; }
.detail-cell .d-val { font-weight: 800; color: var(--ink); font-size: 0.9rem; }

/* ============================================================
   LIGA
   ============================================================ */
.league-hero {
    position: relative;
    overflow: hidden;
    border-radius: var(--r-xl);
    padding: 20px;
    color: #fff;
    margin-bottom: 12px;
    background:
        radial-gradient(90% 90% at 100% 0%, rgba(110, 231, 183, 0.45), transparent 55%),
        linear-gradient(145deg, #062F2A 0%, #065F46 50%, #0D9488 100%);
    box-shadow: 0 16px 40px -18px rgba(13, 148, 136, 0.7);
}
.league-hero .gem { position: absolute; right: -16px; top: -14px; width: 104px; opacity: 0.95; filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.3)); animation: float 5s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-8px) rotate(4deg); } }
.league-hero .l-kicker { font-size: 0.72rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.8; }
.league-hero h2 { color: #fff; font-size: 1.6rem; margin: 2px 0 4px; }
.league-hero .l-sub { font-size: 0.86rem; opacity: 0.9; font-weight: 600; max-width: 24ch; }
.league-hero .l-stats { display: flex; gap: 8px; margin-top: 16px; }
.league-hero .l-stat { flex: 1; background: rgba(255, 255, 255, 0.1); border: 1px solid rgba(255, 255, 255, 0.14); border-radius: 14px; padding: 9px 10px; }
.league-hero .l-stat .v { font-family: var(--display); font-weight: 800; font-size: 1.25rem; line-height: 1.1; }
.league-hero .l-stat .k { font-size: 0.68rem; font-weight: 700; opacity: 0.8; }

.podium { display: grid; grid-template-columns: 1fr 1fr 1fr; align-items: end; gap: 8px; padding: 12px 6px 0; }
.pod { display: flex; flex-direction: column; align-items: center; text-align: center; min-width: 0; }
.pod .crown { font-size: 1.3rem; margin-bottom: -4px; animation: tipBob 2s ease-in-out infinite; }
.pod .avatar { box-shadow: 0 0 0 3px var(--surface), 0 0 0 5px var(--medal); }
.pod .p-name { font-weight: 800; color: var(--ink); font-size: 0.82rem; margin-top: 8px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pod .p-xp { font-size: 0.74rem; color: var(--muted); font-weight: 700; margin-bottom: 8px; }
.pod .block {
    width: 100%;
    border-radius: 14px 14px 0 0;
    background: linear-gradient(180deg, color-mix(in srgb, var(--medal) 30%, var(--surface)), var(--surface-2));
    border: 1px solid var(--line);
    border-bottom: none;
    display: grid;
    place-items: start center;
    padding-top: 8px;
    font-family: var(--display);
    font-weight: 800;
    font-size: 1.5rem;
    color: var(--ink);
    animation: podUp 0.7s var(--ease) both;
    transform-origin: bottom;
}
.pod.p1 { --medal: #F5B300; }
.pod.p2 { --medal: #A8B3C2; }
.pod.p3 { --medal: #D08A4E; }
.pod.p1 .block { height: 96px; animation-delay: 0.15s; }
.pod.p2 .block { height: 70px; }
.pod.p3 .block { height: 52px; animation-delay: 0.08s; }
.pod.me .p-name { color: var(--green-ink); }
@keyframes podUp { from { transform: scaleY(0); } }

.board { padding: 6px; }
.board-row { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 14px; transition: background 0.2s; }
.board-row:hover { background: var(--surface-2); }
.board-row .rank { width: 26px; text-align: center; font-family: var(--display); font-weight: 800; color: var(--muted); flex-shrink: 0; }
.board-row .b-name { flex: 1; min-width: 0; font-weight: 700; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.board-row .b-xp { font-family: var(--display); font-weight: 700; color: var(--text); font-size: 0.92rem; }
.board-row.me { background: var(--green-soft); box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--green) 50%, transparent); }
.board-row.me .b-name, .board-row.me .rank { color: var(--green-ink); }
.board-row.demote .rank { color: var(--red-ink); }
.zone-label { display: flex; align-items: center; gap: 8px; font-size: 0.7rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; padding: 10px 10px 6px; }
.zone-label::after { content: ""; flex: 1; height: 1.5px; background: repeating-linear-gradient(90deg, currentColor 0 6px, transparent 6px 11px); opacity: 0.5; }
.zone-label.up { color: var(--green-ink); }
.zone-label.down { color: var(--red-ink); }
.zone-label .ico { width: 14px; height: 14px; }

/* ============================================================
   PERFIL (estilo LinkedIn)
   ============================================================ */
.profile-card { padding: 0; overflow: hidden; }
.cover {
    height: 112px;
    position: relative;
    background:
        radial-gradient(70% 120% at 85% 10%, color-mix(in srgb, var(--lime) 70%, transparent), transparent 60%),
        linear-gradient(120deg, var(--tone-deep), var(--tone) 70%);
}
.cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.16) 1.2px, transparent 1.2px);
    background-size: 16px 16px;
    mask-image: linear-gradient(90deg, transparent, #000);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000);
}
.cover .cover-edit {
    position: absolute; top: 12px; right: 12px; z-index: 1;
    width: 36px; height: 36px; border-radius: 50%;
    background: var(--surface); color: var(--pro);
    display: grid; place-items: center;
    box-shadow: var(--shadow-2);
    transition: transform 0.2s var(--spring);
}
.cover .cover-edit:hover { transform: scale(1.08); }
.cover .cover-edit .ico { width: 18px; height: 18px; }
.profile-body { padding: 0 18px 18px; }
.profile-body .avatar.lg { margin-top: -62px; box-shadow: 0 0 0 4px var(--surface); }
.lvl-badge {
    position: absolute;
    bottom: 4px; right: 2px;
    min-width: 34px; height: 34px;
    padding: 0 6px;
    border-radius: var(--pill);
    background: var(--gold);
    color: #3A2A00;
    font-family: var(--display);
    font-weight: 800;
    font-size: 0.95rem;
    display: grid; place-items: center;
    box-shadow: 0 0 0 3px var(--surface), 0 3px 0 3px var(--gold-deep);
}
.avatar-wrap { position: relative; display: inline-block; }
.profile-name { font-size: 1.5rem; margin-top: 10px; }
.profile-headline { color: var(--text); font-size: 0.95rem; margin-top: 2px; }
.profile-meta { color: var(--muted); font-size: 0.82rem; margin-top: 6px; display: flex; flex-wrap: wrap; gap: 4px 12px; }
.profile-meta span { display: inline-flex; align-items: center; gap: 4px; }
.profile-meta .ico { width: 14px; height: 14px; }
.profile-meta a { color: var(--pro); font-weight: 700; }
.lvl-line { display: flex; align-items: center; gap: 10px; margin-top: 14px; }
.lvl-line .progress { flex: 1; }
.lvl-line .lv { font-size: 0.76rem; font-weight: 800; color: var(--gold-ink); white-space: nowrap; }
.profile-actions { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap; }

.strength { display: flex; align-items: center; gap: 14px; }
.strength .s-txt { flex: 1; min-width: 0; }
.strength .s-title { font-weight: 800; color: var(--ink); }
.strength .s-sub { font-size: 0.8rem; color: var(--muted); }
.missing { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }

.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.stat-box {
    background: var(--surface-2);
    border-radius: 16px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.stat-box .s-ico { width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; background: var(--tone-soft); color: var(--tone-ink); }
.stat-box .s-ico .ico { width: 17px; height: 17px; }
.stat-box .s-num { font-family: var(--display); font-weight: 800; font-size: 1.3rem; color: var(--ink); line-height: 1; }
.stat-box .s-lbl { font-size: 0.7rem; font-weight: 700; color: var(--muted); }

.add-btn {
    width: 36px; height: 36px; border-radius: 50%;
    display: grid; place-items: center;
    color: var(--muted);
    transition: background 0.2s, color 0.2s;
}
.add-btn:hover { background: var(--surface-3); color: var(--ink); }
.add-btn .ico { width: 20px; height: 20px; }

.item { display: flex; gap: 12px; padding: 12px 0; align-items: flex-start; }
.item + .item { border-top: 1px solid var(--line); }
.item .i-body { flex: 1; min-width: 0; }
.item .i-title { font-weight: 800; color: var(--ink); font-size: 0.94rem; line-height: 1.3; }
.item .i-sub { font-size: 0.84rem; color: var(--text); }
.item .i-meta { font-size: 0.78rem; color: var(--muted); margin-top: 2px; }
.item .i-desc { font-size: 0.84rem; color: var(--text); margin-top: 6px; }
.item-x {
    width: 32px; height: 32px; border-radius: 50%;
    display: grid; place-items: center;
    color: var(--faint);
    flex-shrink: 0;
    transition: background 0.2s, color 0.2s;
}
.item-x:hover { background: var(--red-soft); color: var(--red-ink); }
.item-x .ico { width: 16px; height: 16px; }

.empty { text-align: center; padding: 14px 10px 6px; }
.empty .e-ico { font-size: 1.4rem; width: 48px; height: 48px; border-radius: 16px; margin: 0 auto 8px; display: grid; place-items: center; background: var(--surface-2); color: var(--muted); }
.empty .e-ico .ico { width: 22px; height: 22px; }
.empty .e-title { font-weight: 800; color: var(--ink); font-size: 0.92rem; }
.empty .e-sub { font-size: 0.8rem; color: var(--muted); margin-bottom: 12px; }

.skill-wrap { display: flex; flex-wrap: wrap; gap: 8px; }
.skill-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 6px 6px 13px;
    border-radius: var(--pill);
    font-weight: 700;
    font-size: 0.86rem;
    background: var(--surface-2);
    border: 1px solid var(--line);
    color: var(--ink);
}
.skill-tag .dots { display: flex; gap: 3px; }
.skill-tag .dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--line-strong); }
.skill-tag .dots i.on { background: var(--green); }
.skill-tag .skill-del { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: var(--faint); transition: background 0.2s, color 0.2s; }
.skill-tag .skill-del:hover { background: var(--red-soft); color: var(--red-ink); }
.skill-tag .skill-del .ico { width: 13px; height: 13px; }

.badge-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.badge-cell { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 8px 2px; border-radius: 14px; transition: background 0.2s, transform 0.2s var(--spring); }
.badge-cell:hover { background: var(--surface-2); transform: translateY(-2px); }
.badge-ico {
    width: 56px; height: 56px;
    border-radius: 18px;
    display: grid; place-items: center;
    font-size: 1.6rem;
    background: linear-gradient(150deg, color-mix(in srgb, var(--tone) 30%, var(--surface)), var(--tone-soft));
    box-shadow: 0 3px 0 color-mix(in srgb, var(--tone) 55%, transparent), inset 0 0 0 1.5px color-mix(in srgb, var(--tone) 35%, transparent);
    transform: rotate(-4deg);
}
.badge-cell.locked .badge-ico { background: var(--surface-2); box-shadow: inset 0 0 0 1.5px var(--line); color: var(--faint); transform: none; }
.badge-cell.locked .badge-ico .ico { width: 20px; height: 20px; }
.badge-name { font-size: 0.68rem; font-weight: 700; color: var(--text); text-align: center; line-height: 1.15; }
.badge-cell.locked .badge-name { color: var(--faint); }

.reco { padding: 12px 0; }
.reco + .reco { border-top: 1px solid var(--line); }
.reco .quote { margin-top: 8px; font-size: 0.9rem; color: var(--text); position: relative; padding-left: 14px; border-left: 3px solid var(--green); }

.account { display: flex; align-items: center; gap: 12px; }
.account .a-ico { width: 42px; height: 42px; border-radius: 14px; display: grid; place-items: center; background: var(--green-soft); color: var(--green-ink); flex-shrink: 0; }
.account .a-ico .ico { width: 22px; height: 22px; }

.login-cta {
    position: relative;
    overflow: hidden;
    border: none;
    color: #fff;
    background:
        radial-gradient(90% 120% at 100% 0%, rgba(125, 211, 252, 0.45), transparent 60%),
        linear-gradient(135deg, #0A3D7A, #0A66C2);
}
.login-cta h3 { color: #fff; }
.login-cta p { font-size: 0.86rem; opacity: 0.88; margin: 2px 0 12px; }

.setting-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; }
.setting-row + .setting-row { border-top: 1px solid var(--line); }
.setting-row .s-ico { width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-2); color: var(--text); flex-shrink: 0; }
.setting-row .s-ico .ico { width: 18px; height: 18px; }
.setting-row .s-label { flex: 1; font-weight: 700; color: var(--ink); font-size: 0.92rem; }

/* ---- Onboarding ---- */
.onb { display: flex; flex-direction: column; min-height: calc(100vh - var(--top-h) - var(--nav-h) - 60px); }
.onb-hero { text-align: center; padding: 18px 8px 22px; }
.onb-hero .fox { width: 92px; height: 92px; border-radius: 30px; margin: 0 auto 14px; display: grid; place-items: center; font-size: 3.4rem; background: var(--orange-soft); animation: trophyIn 0.7s var(--spring) both; }
.onb-hero h1 { font-size: 1.9rem; }
.onb-hero p { color: var(--muted); margin-top: 6px; }
.goal-opt {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 14px;
    border: 2px solid var(--line);
    border-bottom-width: 4px;
    border-radius: 18px;
    background: var(--surface);
    font-weight: 700;
    color: var(--ink);
    text-align: left;
    transition: all 0.15s;
}
.goal-opt:hover { background: var(--surface-2); }
.goal-opt .g-ico { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; font-size: 1.5rem; background: var(--surface-2); flex-shrink: 0; transition: transform 0.3s var(--spring); }
.goal-opt .g-check { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line-strong); display: grid; place-items: center; color: transparent; flex-shrink: 0; transition: all 0.2s; }
.goal-opt .g-check .ico { width: 14px; height: 14px; stroke-width: 3.2; }
.goal-opt.sel { border-color: var(--green); background: var(--green-soft); }
.goal-opt.sel .g-ico { transform: scale(1.1) rotate(-6deg); background: var(--surface); }
.goal-opt.sel .g-check { background: var(--green); border-color: var(--green); color: #fff; }

/* ============================================================
   SIDEBARS (escritorio)
   ============================================================ */
.mini-profile { padding: 0; overflow: hidden; text-align: center; }
.mini-profile .cover { height: 58px; }
.mini-profile .avatar { margin: -34px auto 0; box-shadow: 0 0 0 3px var(--surface); }
.mini-profile .mp-name { font-family: var(--display); font-weight: 700; color: var(--ink); font-size: 1.05rem; margin-top: 8px; padding: 0 12px; }
.mini-profile .mp-head { font-size: 0.78rem; color: var(--muted); padding: 0 14px; line-height: 1.35; }
.mini-profile .mp-rows { border-top: 1px solid var(--line); margin-top: 14px; padding: 8px 0; text-align: left; }
.mp-row { width: 100%; display: flex; align-items: center; justify-content: space-between; padding: 6px 14px; font-size: 0.8rem; font-weight: 600; color: var(--muted); transition: background 0.2s; }
.mp-row:hover { background: var(--surface-2); }
.mp-row b { color: var(--pro); font-weight: 800; }
.mini-profile .mp-lvl { padding: 0 14px 14px; text-align: left; }
.mini-profile .mp-lvl .lbl { display: flex; justify-content: space-between; font-size: 0.72rem; font-weight: 700; color: var(--muted); margin-bottom: 5px; }

.side-card h4 { font-size: 0.98rem; margin-bottom: 10px; display: flex; align-items: center; justify-content: space-between; }
.side-list { display: flex; flex-direction: column; gap: 2px; }
.side-item { display: flex; align-items: center; gap: 10px; padding: 7px 6px; border-radius: 12px; transition: background 0.2s; text-align: left; width: 100%; }
.side-item:hover { background: var(--surface-2); }
.side-item .si-body { flex: 1; min-width: 0; }
.side-item .si-title { font-size: 0.84rem; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-item .si-sub { font-size: 0.74rem; color: var(--muted); }
.side-item.me { background: var(--green-soft); }
.daily { display: flex; align-items: center; gap: 14px; }
.daily .ring .val { font-family: var(--display); font-weight: 800; font-size: 1.05rem; color: var(--ink); }
.footer-links { font-size: 0.72rem; color: var(--faint); text-align: center; padding: 8px 10px; line-height: 1.8; }

/* ============================================================
   SHEET / MODAL
   ============================================================ */
.overlay {
    position: fixed;
    inset: 0;
    background: var(--overlay);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    z-index: 100;
    display: none;
    align-items: flex-end;
    justify-content: center;
    animation: fadeIn 0.25s ease;
}
.overlay.open { display: flex; }
.overlay.closing { animation: fadeOut 0.22s ease forwards; }
.overlay.closing .sheet { animation: sheetOut 0.22s ease forwards; }
@keyframes fadeIn { from { opacity: 0; } }
@keyframes fadeOut { to { opacity: 0; } }

.sheet {
    width: 100%;
    max-width: var(--main-w);
    background: var(--surface);
    border-radius: var(--r-xl) var(--r-xl) 0 0;
    padding: 10px 18px calc(22px + env(safe-area-inset-bottom));
    max-height: 92vh;
    overflow-y: auto;
    overscroll-behavior: contain;
    animation: sheetIn 0.45s var(--ease);
    box-shadow: var(--shadow-3);
}
.sheet.full { min-height: 92vh; }
@keyframes sheetIn { from { transform: translateY(100%); } }
@keyframes sheetOut { to { transform: translateY(100%); } }

.sheet-handle { width: 40px; height: 5px; border-radius: 99px; background: var(--line-strong); margin: 0 auto 14px; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 16px; }
.sheet-head h3 { font-size: 1.2rem; }
.sheet-x { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: var(--muted); transition: background 0.2s; flex-shrink: 0; }
.sheet-x:hover { background: var(--surface-3); color: var(--ink); }
.sheet-x .ico { width: 20px; height: 20px; }

/* ============================================================
   TOAST
   ============================================================ */
#toast-host {
    position: fixed;
    top: calc(var(--top-h) + 10px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 200;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: calc(100% - 32px);
    max-width: 420px;
    pointer-events: none;
}
.toast {
    background: var(--ink);
    color: var(--surface);
    padding: 10px 16px 10px 10px;
    border-radius: var(--pill);
    font-weight: 700;
    font-size: 0.88rem;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: var(--shadow-3);
    animation: toastIn 0.45s var(--spring);
    max-width: 100%;
}
.toast .toast-ico { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, 0.14); font-size: 1rem; flex-shrink: 0; }
.toast.green .toast-ico { background: var(--green); }
.toast.gold .toast-ico { background: var(--gold); }
.toast.blue .toast-ico { background: var(--pro); }
.toast.red .toast-ico { background: var(--red); }
.toast.out { animation: toastOut 0.3s ease forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-18px) scale(0.92); } }
@keyframes toastOut { to { opacity: 0; transform: translateY(-12px) scale(0.96); } }

/* ============================================================
   FORM
   ============================================================ */
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 0.8rem; font-weight: 700; color: var(--muted); margin-bottom: 6px; }
.input, .textarea {
    width: 100%;
    font-weight: 600;
    font-size: 0.98rem;
    color: var(--ink);
    background: var(--surface-2);
    border: 1.5px solid var(--line);
    border-radius: var(--r);
    padding: 12px 14px;
    transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
.input::placeholder, .textarea::placeholder { color: var(--faint); font-weight: 500; }
.input:focus, .textarea:focus { outline: none; border-color: var(--pro); background: var(--surface); box-shadow: 0 0 0 4px var(--pro-soft); }
.textarea { resize: vertical; min-height: 110px; line-height: 1.5; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.seg { display: flex; gap: 4px; background: var(--surface-2); padding: 4px; border-radius: var(--pill); border: 1px solid var(--line); }
.seg-opt { flex: 1; padding: 9px 6px; border-radius: var(--pill); font-weight: 700; font-size: 0.84rem; color: var(--muted); transition: all 0.2s var(--ease); }
.seg-opt.active { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-2); }

.check-row { display: flex; align-items: center; gap: 10px; font-weight: 600; color: var(--ink); font-size: 0.9rem; margin: 2px 0 6px; cursor: pointer; }
.check-row input { width: 20px; height: 20px; accent-color: var(--green); }

.avatar-pick { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.avatar-opt { aspect-ratio: 1; border: 2px solid var(--line); border-radius: 16px; font-size: 1.6rem; background: var(--surface); transition: all 0.2s var(--spring); }
.avatar-opt:hover { transform: scale(1.06); }
.avatar-opt.sel { border-color: var(--green); background: var(--green-soft); transform: scale(1.06); }
.color-pick { display: flex; gap: 10px; flex-wrap: wrap; }
.color-opt { width: 36px; height: 36px; border-radius: 50%; background: var(--tone); box-shadow: inset 0 -3px 0 rgba(0, 0, 0, 0.15); transition: transform 0.2s var(--spring); position: relative; }
.color-opt.sel { box-shadow: 0 0 0 3px var(--surface), 0 0 0 5px var(--tone); transform: scale(1.06); }

.auth-divider { display: flex; align-items: center; gap: 12px; color: var(--faint); font-size: 0.76rem; font-weight: 700; margin: 6px 0 16px; }
.auth-divider::before, .auth-divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.link-btn { color: var(--pro); font-weight: 800; padding: 0 2px; }
.link-btn:hover { text-decoration: underline; }

/* ============================================================
   UTILIDADES
   ============================================================ */
.row { display: flex; align-items: center; gap: 12px; }
.row.between { justify-content: space-between; }
.row.top { align-items: flex-start; }
.col { display: flex; flex-direction: column; }
.gap-sm { gap: 8px; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.center { text-align: center; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.ink { color: var(--ink); }
.tiny { font-size: 0.76rem; }
.small { font-size: 0.86rem; }
.bold { font-weight: 800; }
.mt { margin-top: 12px; }
.mt-lg { margin-top: 20px; }
.mb { margin-bottom: 12px; }
.hidden { display: none !important; }
.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.sheet::-webkit-scrollbar { width: 6px; }
.sheet::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 99px; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (min-width: 640px) {
    .layout { padding-left: 16px; padding-right: 16px; }
    .overlay { align-items: center; padding: 24px; }
    .sheet { border-radius: var(--r-xl); max-width: 520px; max-height: 88vh; padding: 18px 22px 24px; animation: modalIn 0.4s var(--spring); }
    .sheet.full { min-height: 0; max-width: 580px; }
    .sheet-handle { display: none; }
    .overlay.closing .sheet { animation: modalOut 0.2s ease forwards; }
    @keyframes modalIn { from { opacity: 0; transform: translateY(16px) scale(0.96); } }
    @keyframes modalOut { to { opacity: 0; transform: scale(0.97); } }
    .hero, .league-hero { padding: 24px; }
}

/* Escritorio: navegación arriba (LinkedIn) + 3 columnas */
@media (min-width: 1024px) {
    :root { --top-h: 64px; }
    .bottom-nav { display: none; }
    .theme-btn { display: grid; }

    .top-nav { display: flex; align-items: stretch; height: 100%; margin-left: 18px; gap: 2px; }
    .top-nav .nav-item {
        flex: 0 0 auto;
        width: 84px;
        gap: 2px;
        font-size: 0.72rem;
        font-weight: 600;
    }
    .top-nav .nav-item .nav-ico { width: auto; height: auto; background: none !important; }
    .top-nav .nav-item .nav-ico .ico { width: 24px; height: 24px; }
    .top-nav .nav-item::after {
        content: "";
        position: absolute;
        left: 10px; right: 10px; bottom: -1px;
        height: 2.5px;
        border-radius: 2px 2px 0 0;
        background: var(--ink);
        transform: scaleX(0);
        transition: transform 0.3s var(--ease);
    }
    .top-nav .nav-item:hover { color: var(--ink); }
    .top-nav .nav-item.active { color: var(--ink); font-weight: 700; }
    .top-nav .nav-item.active .nav-ico { color: var(--ink); }
    .top-nav .nav-item.active::after { transform: scaleX(1); }

    .layout {
        max-width: 1128px;
        display: grid;
        grid-template-columns: 228px minmax(0, 1fr) 300px;
        gap: 22px;
        align-items: start;
        padding: 22px 24px 48px;
    }
    .side { display: block; position: sticky; top: calc(var(--top-h) + 22px); }
    .side .card { margin-bottom: 10px; }
    .main { max-width: 600px; width: 100%; justify-self: center; }
    #toast-host { top: calc(var(--top-h) + 14px); }
}

@media (min-width: 1024px) and (max-width: 1180px) {
    .layout { grid-template-columns: 210px minmax(0, 1fr) 270px; gap: 18px; }
}

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