:root {
    --ink: #0b2239;
    --ink-2: #153852;
    --ink-soft: #eaf0f4;

    --coral: #ef3654;
    --coral-dark: #d82645;
    --coral-soft: #fff0f3;

    --gold: #f4b740;
    --gold-soft: #fff6df;

    --green: #32a66c;
    --green-soft: #eaf8f1;

    --cream: #faf7f1;
    --cream-2: #f4efe6;
    --white: #ffffff;

    --text: #12283a;
    --muted: #6f7d87;
    --line: #e4e5e2;

    --shadow:
        0 18px 55px rgba(11, 34, 57, .10);

    --shadow-soft:
        0 8px 25px rgba(11, 34, 57, .07);

    --radius: 20px;
    --radius-lg: 30px;

    --container: 1180px;
}

/* RESET */

* {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    font-family:
        Inter,
        ui-sans-serif,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
    color: var(--text);
    background: var(--cream);
    line-height: 1.5;
}

button,
input {
    font: inherit;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

/* CONTAINER */

.container {
    width: min(
        calc(100% - 36px),
        var(--container)
    );
    margin-inline: auto;
}

/* BRAND */

.brand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    color: var(--ink);
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    color: white;
    background: var(--ink);
    box-shadow: var(--shadow-soft);
}

.brand-name {
    display: block;
    font-size: 1.08rem;
    font-weight: 900;
    line-height: 1;
    letter-spacing: -.035em;
}

.brand-place {
    display: block;
    margin-top: 5px;
    color: var(--coral);
    font-size: .59rem;
    font-weight: 900;
    letter-spacing: .17em;
}

/* TOPBAR */

.site-header {
    padding: 20px 0;
}

.site-header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.header-action {
    color: var(--muted);
    font-size: .88rem;
}

.header-action strong {
    margin-left: 5px;
    color: var(--coral);
}

/* BUTTONS */

.btn {
    min-height: 52px;
    padding: 13px 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    border: 0;
    border-radius: 14px;

    font-weight: 850;
    cursor: pointer;

    transition:
        transform .16s ease,
        box-shadow .16s ease,
        background .16s ease;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    color: white;
    background: var(--coral);
    box-shadow:
        0 10px 25px rgba(239, 54, 84, .20);
}

.btn-primary:hover {
    background: var(--coral-dark);
}

.btn-secondary {
    color: white;
    background: var(--ink);
}

.btn-light {
    color: var(--ink);
    background: white;
    box-shadow: var(--shadow-soft);
}

.btn-block {
    width: 100%;
}

/* LANDING */

.landing-page {
    min-height: 100vh;
    overflow-x: hidden;
    background:
        radial-gradient(
            circle at 8% 10%,
            rgba(244, 183, 64, .14),
            transparent 28%
        ),
        radial-gradient(
            circle at 92% 28%,
            rgba(239, 54, 84, .08),
            transparent 25%
        ),
        var(--cream);
}

.hero {
    padding: 50px 0 72px;
}

.hero-grid {
    display: grid;
    grid-template-columns:
        minmax(0, 1.05fr)
        minmax(380px, .75fr);
    gap: 70px;
    align-items: center;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;

    margin-bottom: 16px;

    color: var(--coral);
    font-size: .75rem;
    font-weight: 900;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.hero-title {
    max-width: 680px;
    margin: 0;

    color: var(--ink);
    font-size: clamp(3.2rem, 6vw, 5.8rem);
    line-height: .94;
    letter-spacing: -.065em;
}

.hero-title span {
    color: var(--coral);
}

.hero-lead {
    max-width: 610px;
    margin: 24px 0 0;

    color: var(--muted);
    font-size: 1.12rem;
    line-height: 1.7;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 30px;
}

/* HOW */

.how-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 36px;
}

.how-card {
    padding: 18px;

    border: 1px solid rgba(11,34,57,.06);
    border-radius: 18px;

    background: rgba(255,255,255,.70);
}

.how-icon {
    font-size: 25px;
}

.how-title {
    display: block;
    margin-top: 8px;

    color: var(--ink);
    font-weight: 850;
}

.how-text {
    display: block;
    margin-top: 3px;

    color: var(--muted);
    font-size: .77rem;
}

/* COMMUNITY PREVIEW */

.community-card {
    position: relative;
    padding: 28px;
    overflow: hidden;

    border-radius: var(--radius-lg);

    color: white;

    background:
        linear-gradient(
            145deg,
            #102d45,
            #071a2b
        );

    box-shadow: var(--shadow);
}

.community-card::before {
    content: "🍿";
    position: absolute;
    right: -15px;
    top: -35px;

    font-size: 150px;
    opacity: .07;
    transform: rotate(15deg);
}

.community-kicker {
    color: var(--gold);
    font-size: .72rem;
    font-weight: 900;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.community-title {
    max-width: 340px;
    margin: 10px 0 0;

    font-size: 2rem;
    line-height: 1.06;
    letter-spacing: -.045em;
}

.community-text {
    max-width: 370px;
    margin-top: 12px;

    color: rgba(255,255,255,.72);
    font-size: .9rem;
}

.community-preview {
    margin-top: 26px;
    display: grid;
    gap: 10px;
}

.preview-row {
    padding: 13px 14px;
    display: flex;
    align-items: center;
    gap: 12px;

    border-radius: 14px;

    background: rgba(255,255,255,.08);
    backdrop-filter: blur(10px);
}

.preview-icon {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;

    border-radius: 12px;
    background: rgba(255,255,255,.10);
}

.preview-copy strong {
    display: block;
    font-size: .86rem;
}

.preview-copy span {
    color: rgba(255,255,255,.60);
    font-size: .72rem;
}

/* AUTH */

.auth-page {
    min-height: 100vh;

    background:
        radial-gradient(
            circle at 15% 10%,
            rgba(244,183,64,.13),
            transparent 28%
        ),
        var(--cream);
}

.auth-shell {
    padding: 28px 0 60px;
}

.auth-grid {
    display: grid;
    grid-template-columns:
        minmax(0, .8fr)
        minmax(420px, .62fr);
    gap: 70px;
    align-items: start;
}

.auth-intro {
    padding-top: 65px;
}

.auth-intro-title {
    max-width: 560px;
    margin: 0;

    color: var(--ink);
    font-size: clamp(2.8rem, 5vw, 4.7rem);
    line-height: .96;
    letter-spacing: -.06em;
}

.auth-intro-text {
    max-width: 520px;
    margin-top: 20px;

    color: var(--muted);
    font-size: 1.02rem;
    line-height: 1.7;
}

.auth-benefits {
    display: grid;
    gap: 12px;
    margin-top: 30px;
}

.auth-benefit {
    display: flex;
    align-items: center;
    gap: 12px;

    color: var(--ink);
    font-size: .92rem;
    font-weight: 700;
}

.auth-benefit-icon {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;

    border-radius: 13px;
    background: white;

    box-shadow: var(--shadow-soft);
}

.auth-card {
    padding: 30px;

    border: 1px solid rgba(11,34,57,.07);
    border-radius: 26px;

    background: rgba(255,255,255,.92);
    box-shadow: var(--shadow);
}

.auth-card-title {
    margin: 0;

    color: var(--ink);
    font-size: 1.65rem;
    letter-spacing: -.035em;
}

.auth-card-text {
    margin: 7px 0 24px;

    color: var(--muted);
    font-size: .88rem;
}

/* FORMS */

.form-group {
    margin-bottom: 16px;
}

.form-label {
    display: block;
    margin-bottom: 7px;

    color: var(--ink);
    font-size: .83rem;
    font-weight: 800;
}

.form-control {
    width: 100%;
    min-height: 50px;
    padding: 12px 14px;

    outline: none;

    border: 1px solid #dfe3e5;
    border-radius: 13px;

    background: white;
    color: var(--text);

    transition:
        border .16s ease,
        box-shadow .16s ease;
}

.form-control:focus {
    border-color: var(--ink-2);
    box-shadow:
        0 0 0 4px rgba(21,56,82,.08);
}

.form-control::placeholder {
    color: #a7afb5;
}

.form-help {
    display: block;
    margin-top: 6px;

    color: var(--muted);
    font-size: .72rem;
}

.checkbox-card {
    display: flex;
    gap: 11px;

    padding: 13px;

    border: 1px solid var(--line);
    border-radius: 13px;

    color: var(--muted);
    background: #fbfbfa;

    font-size: .78rem;
    cursor: pointer;
}

.checkbox-card input {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
    margin-top: 1px;

    accent-color: var(--coral);
}

.auth-footer {
    margin-top: 20px;

    text-align: center;
    color: var(--muted);
    font-size: .82rem;
}

.auth-footer a {
    color: var(--coral);
    font-weight: 850;
}

/* ALERTS */

.alert {
    margin-bottom: 18px;
    padding: 13px 15px;

    border-radius: 13px;

    font-size: .82rem;
}

.alert-error {
    color: #9e1e34;
    background: var(--coral-soft);
}

.alert-success {
    color: #24764e;
    background: var(--green-soft);
}

.alert ul {
    margin: 6px 0 0;
    padding-left: 20px;
}

/* MOBILE */

@media (max-width: 850px) {

    .site-header {
        padding: 16px 0;
    }

    .header-action span {
        display: none;
    }

    .hero {
        padding: 34px 0 50px;
    }

    .hero-grid,
    .auth-grid {
        grid-template-columns: 1fr;
        gap: 34px;
    }

    .hero-title {
        font-size: clamp(3rem, 14vw, 4.6rem);
    }

    .community-card {
        padding: 23px;
    }

    .how-grid {
        grid-template-columns: 1fr;
    }

    .how-card {
        display: flex;
        gap: 14px;
        align-items: center;
    }

    .how-title {
        margin-top: 0;
    }

    .auth-intro {
        padding-top: 20px;
    }

    .auth-intro-title {
        font-size: clamp(2.6rem, 12vw, 4rem);
    }

    .auth-benefits {
        display: none;
    }

    .auth-card {
        padding: 22px;
    }
}

@media (max-width: 480px) {

    .container {
        width: min(calc(100% - 28px), var(--container));
    }

    .brand-name {
        font-size: .98rem;
    }

    .hero-actions {
        display: grid;
    }

    .hero-actions .btn {
        width: 100%;
    }

    .auth-intro {
        display: none;
    }

    .auth-shell {
        padding-top: 18px;
    }

    .auth-card {
        padding: 20px;
        border-radius: 21px;
    }
}

/* =========================================================
   APP AUTENTICADA
   ========================================================= */

.app-page {
    min-height: 100vh;
    padding-bottom: 100px;
    background:
        radial-gradient(
            circle at 85% 5%,
            rgba(239,54,84,.06),
            transparent 25%
        ),
        #f7f5f0;
}

.app-container {
    width: min(
        calc(100% - 36px),
        1120px
    );
    margin-inline: auto;
}

/* TOPBAR */

.app-topbar {
    position: sticky;
    z-index: 100;
    top: 0;

    border-bottom: 1px solid rgba(11,34,57,.08);

    background: var(--cream);

    box-shadow:
        0 4px 18px rgba(11,34,57,.045);
}

.app-topbar-inner {
    min-height: 78px;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.app-user {
    display: flex;
    align-items: center;
    gap: 11px;
}

.app-user-copy {
    text-align: right;
}

.app-user-copy strong {
    display: block;

    color: var(--ink);
    font-size: .82rem;
}

.app-user-copy span {
    display: block;
    margin-top: 2px;

    color: var(--muted);
    font-size: .7rem;
}

.app-avatar {
    width: 43px;
    height: 43px;

    display: grid;
    place-items: center;

    border-radius: 50%;

    color: white;
    background:
        linear-gradient(
            145deg,
            var(--coral),
            #b52661
        );

    font-size: .9rem;
    font-weight: 900;

    box-shadow:
        0 7px 18px rgba(239,54,84,.18);
}

/* CONTENT */

.app-content {
    position: relative;
    z-index: 1;

    padding-top: 34px;
    padding-bottom: 40px;
}

/* WELCOME */

.dashboard-welcome {
    margin-bottom: 22px;
}

.dashboard-kicker {
    color: var(--coral);

    font-size: .72rem;
    font-weight: 900;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.dashboard-title {
    margin: 5px 0 0;

    color: var(--ink);

    font-size: clamp(2rem, 5vw, 3rem);
    line-height: 1;
    letter-spacing: -.05em;
}

.dashboard-subtitle {
    margin: 8px 0 0;

    color: var(--muted);
    font-size: .92rem;
}

/* DASHBOARD GRID */

.dashboard-grid {
    display: grid;

    grid-template-columns:
        minmax(0, 1.15fr)
        minmax(310px, .75fr);

    gap: 18px;
    align-items: start;
}

.dashboard-column {
    display: grid;
    gap: 16px;
}

/* GENERIC PANEL */

.panel {
    border: 1px solid rgba(11,34,57,.055);
    border-radius: 22px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.panel-body {
    padding: 20px;
}

/* LEVEL */

.level-panel {
    overflow: hidden;

    background:
        linear-gradient(
            135deg,
            #fff5dc,
            #fffaf0
        );
}

.level-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.level-identity {
    display: flex;
    align-items: center;
    gap: 13px;
}

.level-icon {
    width: 50px;
    height: 50px;

    display: grid;
    place-items: center;

    border-radius: 16px;

    background: rgba(244,183,64,.20);

    font-size: 25px;
}

.level-copy span {
    display: block;

    color: var(--muted);

    font-size: .67rem;
    font-weight: 850;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.level-copy strong {
    display: block;
    margin-top: 2px;

    color: var(--ink);

    font-size: 1.05rem;
}

.level-score {
    text-align: right;
}

.level-score strong {
    display: block;

    color: var(--ink);
    font-size: .92rem;
}

.level-score span {
    color: var(--muted);
    font-size: .68rem;
}

.level-progress {
    height: 8px;
    margin-top: 17px;

    overflow: hidden;

    border-radius: 99px;

    background: rgba(11,34,57,.09);
}

.level-progress-bar {
    height: 100%;

    border-radius: inherit;

    background:
        linear-gradient(
            90deg,
            var(--gold),
            #ef8e3c
        );
}

.level-next {
    margin-top: 7px;

    display: flex;
    justify-content: space-between;

    color: var(--muted);
    font-size: .68rem;
}

/* BALANCE */

.balance-panel {
    position: relative;

    padding: 27px;

    overflow: hidden;

    text-align: center;

    color: white;

    background:
        linear-gradient(
            145deg,
            #12334e,
            #081d30
        );
}

.balance-panel::after {
    content: "🎟️";

    position: absolute;
    right: -20px;
    bottom: -48px;

    font-size: 145px;

    opacity: .055;

    transform: rotate(-15deg);
}

.balance-label {
    position: relative;
    z-index: 2;

    color: rgba(255,255,255,.65);

    font-size: .72rem;
    font-weight: 850;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.balance-value {
    position: relative;
    z-index: 2;

    margin: 7px 0 -3px;

    font-size: 4.5rem;
    font-weight: 950;
    line-height: .95;
    letter-spacing: -.07em;
}

.balance-unit {
    position: relative;
    z-index: 2;

    font-weight: 850;
}

.balance-message {
    position: relative;
    z-index: 2;

    max-width: 350px;

    margin: 13px auto 0;

    color: rgba(255,255,255,.62);

    font-size: .76rem;
}

/* MAIN ACTIONS */

.dashboard-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.dashboard-action {
    min-height: 116px;

    padding: 17px;

    display: flex;
    align-items: center;
    gap: 14px;

    border-radius: 19px;

    color: white;

    box-shadow: var(--shadow-soft);

    transition:
        transform .16s ease,
        box-shadow .16s ease;
}

.dashboard-action:hover {
    transform: translateY(-2px);

    box-shadow: var(--shadow);
}

.dashboard-action-icon {
    width: 50px;
    height: 50px;

    display: grid;
    place-items: center;

    flex: 0 0 auto;

    border-radius: 15px;

    background: rgba(255,255,255,.14);

    font-size: 25px;
}

.dashboard-action-copy strong {
    display: block;

    font-size: .94rem;
    font-weight: 900;
}

.dashboard-action-copy span {
    display: block;
    margin-top: 3px;

    font-size: .7rem;
    opacity: .72;
}

.dashboard-action-share {
    background:
        linear-gradient(
            145deg,
            #143d5b,
            var(--ink)
        );
}

.dashboard-action-request {
    background:
        linear-gradient(
            145deg,
            #f33b59,
            #d62548
        );
}

/* STATS */

.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.dashboard-stat {
    padding: 16px 10px;

    text-align: center;

    border: 1px solid rgba(11,34,57,.05);
    border-radius: 17px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.dashboard-stat-icon {
    font-size: 20px;
}

.dashboard-stat-value {
    display: block;
    margin-top: 3px;

    color: var(--ink);

    font-size: 1.05rem;
    font-weight: 900;
}

.dashboard-stat-label {
    display: block;
    margin-top: 1px;

    color: var(--muted);

    font-size: .64rem;
}

/* CHALLENGE */

.challenge-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.challenge-heading span {
    color: var(--coral);

    font-size: .68rem;
    font-weight: 900;
    letter-spacing: .09em;
    text-transform: uppercase;
}

.challenge-heading strong {
    color: var(--muted);
    font-size: .68rem;
}

.challenge-content {
    margin-top: 13px;

    display: flex;
    gap: 13px;
    align-items: center;
}

.challenge-icon {
    width: 48px;
    height: 48px;

    display: grid;
    place-items: center;

    flex: 0 0 auto;

    border-radius: 15px;

    background: var(--coral-soft);

    font-size: 23px;
}

.challenge-copy strong {
    display: block;

    color: var(--ink);

    font-size: .9rem;
}

.challenge-copy span {
    display: block;
    margin-top: 2px;

    color: var(--muted);

    font-size: .7rem;
}

.challenge-progress {
    height: 7px;
    margin-top: 15px;

    overflow: hidden;

    border-radius: 99px;

    background: #ececea;
}

.challenge-progress-bar {
    height: 100%;

    border-radius: inherit;

    background: var(--coral);
}

/* COMMUNITY EMPTY STATE */

.community-mini-title {
    color: var(--ink);

    font-size: .95rem;
    font-weight: 900;
}

.community-mini-text {
    margin-top: 5px;

    color: var(--muted);

    font-size: .75rem;
    line-height: 1.55;
}

.community-empty {
    margin-top: 16px;
    padding: 19px;

    text-align: center;

    border-radius: 17px;

    background: var(--cream);
}

.community-empty-icon {
    font-size: 31px;
}

.community-empty strong {
    display: block;
    margin-top: 7px;

    color: var(--ink);

    font-size: .84rem;
}

.community-empty span {
    display: block;

    max-width: 260px;
    margin: 4px auto 0;

    color: var(--muted);

    font-size: .69rem;
}

/* BOTTOM NAV */

.bottom-nav {
    position: fixed;

    z-index: 60;

    left: 50%;
    bottom: 17px;

    width: min(
        calc(100% - 32px),
        610px
    );

    min-height: 70px;

    display: grid;
    grid-template-columns: repeat(5, 1fr);

    transform: translateX(-50%);

    overflow: hidden;

    border: 1px solid rgba(11,34,57,.08);
    border-radius: 22px;

    background: rgba(255,255,255,.96);

    box-shadow:
        0 15px 45px rgba(11,34,57,.16);

    backdrop-filter: blur(15px);
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;

    color: #8a949b;

    font-size: .62rem;
    font-weight: 750;
}

.bottom-nav-item:hover {
    color: var(--ink);
}

.bottom-nav-icon {
    font-size: 19px;
    line-height: 1;
}

.bottom-nav-item.active {
    color: var(--coral);
}

/* MOBILE APP */

@media (max-width: 780px) {

    .app-container {
        width: min(
            calc(100% - 28px),
            1120px
        );
    }

    .app-topbar-inner {
        min-height: 66px;
    }

    .app-user-copy {
        display: none;
    }

    .app-avatar {
        width: 39px;
        height: 39px;
    }

    .app-content {
        padding-top: 23px;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-actions {
        grid-template-columns: 1fr;
    }

    .dashboard-action {
        min-height: 92px;
    }

    .balance-panel {
        padding: 24px 18px;
    }

    .balance-value {
        font-size: 4rem;
    }

    .bottom-nav {
        left: 0;
        right: 0;
        bottom: 0;

        width: 100%;
        min-height: 68px;

        transform: none;

        border-right: 0;
        border-bottom: 0;
        border-left: 0;
        border-radius: 0;

        padding-bottom:
            env(safe-area-inset-bottom);
    }

    .app-page {
        padding-bottom: 82px;
    }
}

@media (max-width: 430px) {

    .dashboard-title {
        font-size: 2rem;
    }

    .stats-row {
        gap: 7px;
    }

    .dashboard-stat {
        padding: 13px 5px;
    }

    .level-score {
        display: none;
    }

    .brand-place {
        display: none;
    }
}

/* =========================================================
   COMPARTIR CÓDIGO / FORM PAGES
   ========================================================= */

.page-heading {
    max-width: 720px;
    margin-bottom: 24px;
}

.page-back {
    display: inline-flex;
    margin-bottom: 22px;

    color: var(--muted);

    font-size: .78rem;
    font-weight: 750;
}

.page-back:hover {
    color: var(--coral);
}

.page-heading-icon {
    width: 54px;
    height: 54px;

    display: grid;
    place-items: center;

    margin-bottom: 15px;

    border-radius: 17px;

    background: var(--gold-soft);

    font-size: 27px;
}

.page-title {
    margin: 5px 0 0;

    color: var(--ink);

    font-size: clamp(2.1rem, 5vw, 3.2rem);
    line-height: 1;
    letter-spacing: -.05em;
}

.page-description {
    max-width: 590px;

    margin: 10px 0 0;

    color: var(--muted);

    font-size: .92rem;
    line-height: 1.6;
}

.form-page-grid {
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        minmax(280px, .52fr);

    gap: 18px;
    align-items: start;
}

.form-panel .panel-body {
    padding: 25px;
}

.code-input {
    text-transform: uppercase;

    color: var(--ink);

    font-size: 1.25rem;
    font-weight: 900;

    letter-spacing: .09em;
}

.community-promise {
    margin: 22px 0 16px;
    padding: 15px;

    display: flex;
    gap: 12px;

    border-radius: 15px;

    background: var(--gold-soft);
}

.community-promise-icon {
    width: 39px;
    height: 39px;

    display: grid;
    place-items: center;

    flex: 0 0 auto;

    border-radius: 12px;

    background: white;
}

.community-promise strong {
    display: block;

    color: var(--ink);

    font-size: .82rem;
}

.community-promise p {
    margin: 3px 0 0;

    color: var(--muted);

    font-size: .71rem;
    line-height: 1.5;
}

.share-side-card {
    position: relative;

    padding: 25px;

    overflow: hidden;

    border-radius: 22px;

    color: white;

    background:
        linear-gradient(
            145deg,
            #143d5b,
            #081d30
        );

    box-shadow: var(--shadow-soft);
}

.share-side-card::after {
    content: "🍿";

    position: absolute;
    right: -25px;
    top: -35px;

    font-size: 115px;

    opacity: .05;
}

.share-side-icon {
    width: 48px;
    height: 48px;

    display: grid;
    place-items: center;

    border-radius: 15px;

    background: rgba(255,255,255,.10);

    font-size: 24px;
}

.share-side-card h2 {
    position: relative;
    z-index: 2;

    margin: 16px 0 0;

    font-size: 1.35rem;
    letter-spacing: -.035em;
}

.share-side-card > p {
    position: relative;
    z-index: 2;

    margin: 8px 0 22px;

    color: rgba(255,255,255,.65);

    font-size: .77rem;
    line-height: 1.55;
}

.share-benefit {
    position: relative;
    z-index: 2;

    display: flex;
    gap: 11px;

    padding: 12px 0;

    border-top: 1px solid rgba(255,255,255,.09);
}

.share-benefit > span {
    font-size: 19px;
}

.share-benefit strong {
    display: block;

    font-size: .78rem;
}

.share-benefit small {
    display: block;
    margin-top: 2px;

    color: rgba(255,255,255,.55);

    font-size: .66rem;
}

/* FORM PAGE MOBILE */

@media (max-width: 760px) {

    .form-page-grid {
        grid-template-columns: 1fr;
    }

    .share-side-card {
        order: -1;
    }

    .share-side-card > p,
    .share-benefit {
        display: none;
    }

    .share-side-card {
        padding: 17px;

        display: flex;
        align-items: center;
        gap: 13px;
    }

    .share-side-card h2 {
        margin: 0;

        font-size: 1rem;
    }

    .share-side-icon {
        width: 42px;
        height: 42px;

        flex: 0 0 auto;
    }

    .form-panel .panel-body {
        padding: 19px;
    }

    .page-heading {
        margin-bottom: 18px;
    }
}

/* SUCCESS */

.success-screen {
    max-width: 620px;

    margin: 45px auto;

    text-align: center;
}

.success-confetti {
    margin-bottom: 5px;

    font-size: 24px;
    letter-spacing: 10px;
}

.success-icon {
    width: 78px;
    height: 78px;

    display: grid;
    place-items: center;

    margin: 12px auto 20px;

    border-radius: 50%;

    color: white;
    background: var(--green);

    font-size: 37px;
    font-weight: 900;

    box-shadow:
        0 12px 30px rgba(50,166,108,.22);
}

.success-title {
    margin: 5px 0 0;

    color: var(--ink);

    font-size: clamp(2.4rem, 7vw, 4rem);
    line-height: 1;
    letter-spacing: -.055em;
}

.success-text {
    max-width: 490px;

    margin: 16px auto 0;

    color: var(--muted);

    font-size: .94rem;
    line-height: 1.65;
}

.success-text strong {
    color: var(--ink);
}

.success-rewards {
    max-width: 440px;

    margin: 28px auto 0;

    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 11px;
}

.success-reward {
    padding: 18px;

    border-radius: 18px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.success-reward span {
    display: block;

    font-size: 24px;
}

.success-reward strong {
    display: block;
    margin-top: 4px;

    color: var(--ink);

    font-size: 1.05rem;
}

.success-reward small {
    display: block;
    margin-top: 2px;

    color: var(--muted);

    font-size: .65rem;
}

.success-note {
    max-width: 500px;

    margin: 18px auto 0;
    padding: 14px 16px;

    border-radius: 14px;

    color: #8a6520;
    background: var(--gold-soft);

    font-size: .73rem;
}

.success-actions {
    margin-top: 25px;

    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

/* =========================================================
   NAVEGACIÓN DESKTOP
   ========================================================= */

.desktop-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;

    margin-left: auto;
    margin-right: 28px;
}

.desktop-nav-item {
    position: relative;

    padding: 10px 13px;

    border-radius: 11px;

    color: var(--muted);

    font-size: .78rem;
    font-weight: 800;

    transition:
        color .16s ease,
        background .16s ease;
}

.desktop-nav-item:hover {
    color: var(--ink);
    background: rgba(11,34,57,.045);
}

.desktop-nav-item.active {
    color: var(--coral);
    background: var(--coral-soft);
}

/*
 * En escritorio la navegación está arriba,
 * por lo que eliminamos la barra inferior.
 */
@media (min-width: 781px) {

    .bottom-nav {
        display: none;
    }

    .app-page {
        padding-bottom: 30px;
    }
}

/*
 * En móvil hacemos exactamente lo contrario:
 * menú inferior sí, navegación superior no.
 */
@media (max-width: 780px) {

    .desktop-nav {
        display: none;
    }
}

/* =========================================================
   PEDIR CÓDIGOS
   ========================================================= */

.request-heading-icon {
    background: var(--coral-soft);
}

.request-grid {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        minmax(280px, .52fr);
    gap: 18px;
    align-items: start;
}

.request-main-card .panel-body {
    padding: 30px;
}

.request-question {
    color: var(--ink);
    text-align: center;
    font-size: 1.25rem;
    font-weight: 900;
    letter-spacing: -.025em;
}

.request-help {
    margin: 5px 0 24px;
    color: var(--muted);
    text-align: center;
    font-size: .78rem;
}

.quantity-picker {
    max-width: 370px;
    min-height: 100px;
    margin: 0 auto 22px;

    display: grid;
    grid-template-columns: 90px 1fr 90px;

    overflow: hidden;

    border: 1px solid var(--line);
    border-radius: 20px;

    background: var(--cream);
}

.quantity-button {
    border: 0;
    cursor: pointer;

    color: var(--ink);
    background: rgba(11,34,57,.045);

    font-size: 2rem;
    font-weight: 400;
}

.quantity-button:hover:not(:disabled) {
    background: rgba(11,34,57,.08);
}

.quantity-button:disabled {
    cursor: default;
    opacity: .25;
}

.quantity-picker input {
    width: 100%;

    border: 0;
    outline: 0;

    text-align: center;

    color: var(--ink);
    background: white;

    font-size: 2.5rem;
    font-weight: 950;

    -moz-appearance: textfield;
}

.quantity-picker input::-webkit-inner-spin-button,
.quantity-picker input::-webkit-outer-spin-button {
    margin: 0;
    -webkit-appearance: none;
}

.request-availability {
    margin-bottom: 20px;
    padding: 14px 16px;

    border-radius: 15px;

    background: var(--green-soft);
}

.request-availability > div {
    display: flex;
    align-items: center;
    gap: 11px;
}

.request-availability > div > span {
    font-size: 22px;
}

.request-availability strong {
    display: block;
    color: #24764e;
    font-size: .78rem;
}

.request-availability small {
    display: block;
    margin-top: 1px;
    color: #57816b;
    font-size: .65rem;
}

.request-info-card {
    padding: 25px;

    border-radius: 22px;

    color: white;

    background:
        linear-gradient(
            145deg,
            #143d5b,
            #081d30
        );

    box-shadow: var(--shadow-soft);
}

.request-info-icon {
    width: 48px;
    height: 48px;

    display: grid;
    place-items: center;

    border-radius: 15px;

    background: rgba(255,255,255,.10);

    font-size: 23px;
}

.request-info-card h2 {
    margin: 15px 0 0;
    font-size: 1.25rem;
    letter-spacing: -.03em;
}

.request-info-card > p {
    margin: 7px 0 21px;

    color: rgba(255,255,255,.62);

    font-size: .75rem;
    line-height: 1.55;
}

.request-rule {
    display: flex;
    gap: 11px;
    align-items: center;

    padding: 12px 0;

    border-top: 1px solid rgba(255,255,255,.09);
}

.request-rule > span {
    width: 31px;
    height: 31px;

    display: grid;
    place-items: center;

    flex: 0 0 auto;

    border-radius: 10px;

    color: var(--gold);
    background: rgba(255,255,255,.09);

    font-size: .72rem;
    font-weight: 900;
}

.request-rule strong {
    display: block;
    font-size: .75rem;
}

.request-rule small {
    display: block;
    margin-top: 2px;

    color: rgba(255,255,255,.52);
    font-size: .63rem;
}

/* PENDIENTES */

.pending-validation-card,
.no-credit-card {
    max-width: 650px;

    margin: 10px auto 0;
    padding: 30px;

    text-align: center;

    border: 1px solid rgba(11,34,57,.06);
    border-radius: 24px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.pending-validation-icon,
.no-credit-icon {
    width: 65px;
    height: 65px;

    display: grid;
    place-items: center;

    margin: 0 auto 16px;

    border-radius: 20px;

    background: var(--coral-soft);

    font-size: 31px;
}

.no-credit-icon {
    background: var(--gold-soft);
}

.pending-validation-card h2,
.no-credit-card h2 {
    margin: 7px 0 0;

    color: var(--ink);

    font-size: 1.6rem;
    letter-spacing: -.035em;
}

.pending-validation-card > p,
.no-credit-card > p {
    max-width: 500px;

    margin: 9px auto 20px;

    color: var(--muted);

    font-size: .82rem;
    line-height: 1.6;
}

.pending-code-list {
    display: grid;
    gap: 8px;

    margin: 20px 0;
}

.pending-code-row {
    padding: 12px 14px;

    display: flex;
    align-items: center;
    gap: 11px;

    text-align: left;

    border-radius: 14px;

    background: var(--cream);
}

.pending-code-ticket {
    width: 39px;
    height: 39px;

    display: grid;
    place-items: center;

    flex: 0 0 auto;

    border-radius: 12px;

    background: white;
}

.pending-code-row strong {
    display: block;

    color: var(--ink);

    font-size: .84rem;
    letter-spacing: .04em;
}

.pending-code-row div span {
    display: block;

    color: var(--muted);

    font-size: .65rem;
}

.pending-validation-message {
    margin: 16px 0;
    padding: 12px;

    border-radius: 13px;

    color: #8a6520;
    background: var(--gold-soft);

    font-size: .7rem;
}

/* =========================================================
   CÓDIGOS RECIBIDOS
   ========================================================= */

.received-screen {
    max-width: 720px;

    margin: 35px auto;

    text-align: center;
}

.received-title {
    margin: 7px 0 0;

    color: var(--ink);

    font-size: clamp(2.5rem, 7vw, 4.2rem);
    line-height: .98;
    letter-spacing: -.06em;
}

.received-lead {
    max-width: 530px;

    margin: 14px auto 0;

    color: var(--muted);

    font-size: .88rem;
}

.received-list {
    display: grid;
    gap: 11px;

    margin: 28px 0 18px;
}

.received-ticket {
    padding: 18px;

    display: flex;
    align-items: center;
    gap: 14px;

    text-align: left;

    border: 1px solid rgba(11,34,57,.06);
    border-radius: 19px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.received-ticket-icon {
    width: 50px;
    height: 50px;

    display: grid;
    place-items: center;

    flex: 0 0 auto;

    border-radius: 15px;

    background: var(--coral-soft);

    font-size: 24px;
}

.received-ticket-content {
    min-width: 0;
    flex: 1;
}

.received-ticket-label {
    display: block;

    color: var(--muted);

    font-size: .62rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.received-code {
    display: block;
    margin-top: 2px;

    color: var(--ink);

    font-size: 1.35rem;
    font-weight: 950;
    letter-spacing: .08em;
}

.received-expiry {
    display: block;
    margin-top: 2px;

    color: var(--muted);

    font-size: .67rem;
}

.copy-code-button {
    padding: 10px 12px;

    border: 0;
    border-radius: 11px;

    cursor: pointer;

    color: var(--ink);
    background: var(--cream);

    font-size: .7rem;
    font-weight: 800;
}

.received-reminder {
    margin: 0 0 22px;
    padding: 14px 16px;

    border-radius: 14px;

    color: #8a6520;
    background: var(--gold-soft);

    font-size: .72rem;
    line-height: 1.5;
}

/* RESPONSIVE REQUEST */

@media (max-width: 760px) {

    .request-grid {
        grid-template-columns: 1fr;
    }

    .request-info-card {
        order: -1;
        padding: 17px;
    }

    .request-info-card > p,
    .request-rule {
        display: none;
    }

    .request-info-card {
        display: flex;
        align-items: center;
        gap: 13px;
    }

    .request-info-card h2 {
        margin: 0;
        font-size: .95rem;
    }

    .request-info-icon {
        width: 42px;
        height: 42px;
        flex: 0 0 auto;
    }

    .request-main-card .panel-body {
        padding: 20px;
    }

    .quantity-picker {
        grid-template-columns: 72px 1fr 72px;
    }

    .pending-validation-card,
    .no-credit-card {
        padding: 22px;
    }
}

@media (max-width: 480px) {

    .received-ticket {
        align-items: flex-start;
    }

    .copy-code-button {
        align-self: center;
    }

    .received-ticket-icon {
        display: none;
    }
}

/* =========================================================
   MENÚ DE USUARIO
   ========================================================= */

.user-menu {
    position: relative;
}

.user-menu-trigger {
    padding: 4px 5px 4px 10px;

    display: flex;
    align-items: center;
    gap: 10px;

    border: 0;
    border-radius: 16px;

    cursor: pointer;

    color: inherit;
    background: transparent;

    transition: background .16s ease;
}

.user-menu-trigger:hover {
    background: rgba(11,34,57,.045);
}

.user-menu-chevron {
    margin-right: 3px;

    color: var(--muted);

    font-size: .72rem;

    transition: transform .16s ease;
}

.user-menu-trigger[aria-expanded="true"]
.user-menu-chevron {
    transform: rotate(180deg);
}

.user-menu-dropdown {
    position: absolute;

    z-index: 200;

    top: calc(100% + 10px);
    right: 0;

    width: 225px;

    padding: 8px;

    border: 1px solid rgba(11,34,57,.08);
    border-radius: 17px;

    background: white;

    box-shadow:
        0 18px 45px rgba(11,34,57,.16);
}

.user-menu-dropdown[hidden] {
    display: none;
}

.user-menu-header {
    padding: 10px 11px;
}

.user-menu-header strong {
    display: block;

    color: var(--ink);

    font-size: .82rem;
}

.user-menu-header span {
    display: block;
    margin-top: 2px;

    color: var(--muted);

    font-size: .67rem;
}

.user-menu-divider {
    height: 1px;

    margin: 5px 3px;

    background: var(--line);
}

.user-menu-item {
    width: 100%;

    padding: 10px 11px;

    display: flex;
    align-items: center;
    gap: 8px;

    border: 0;
    border-radius: 10px;

    cursor: pointer;

    color: var(--text);
    background: transparent;

    text-align: left;

    font-size: .75rem;
    font-weight: 750;
}

.user-menu-item:hover {
    background: var(--cream);
}

.user-menu-logout {
    color: var(--coral);
}

.user-menu-logout:hover {
    background: var(--coral-soft);
}

/* =========================================================
   VALIDACIÓN DE CÓDIGOS
   ========================================================= */

.validation-heading {
    max-width: 700px;
    margin-bottom: 25px;
}

.validation-list {
    display: grid;
    gap: 14px;
}

.validation-card {
    padding: 22px;

    border: 1px solid rgba(11,34,57,.06);
    border-radius: 21px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.validation-code-header {
    display: flex;
    align-items: center;
    gap: 13px;
}

.validation-ticket-icon {
    width: 50px;
    height: 50px;

    display: grid;
    place-items: center;

    flex: 0 0 auto;

    border-radius: 15px;

    background: var(--coral-soft);

    font-size: 23px;
}

.validation-code-header span {
    display: block;

    color: var(--muted);

    font-size: .62rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.validation-code-header strong {
    display: block;
    margin-top: 2px;

    color: var(--ink);

    font-size: 1.25rem;
    font-weight: 950;
    letter-spacing: .07em;
}

.validation-code-header small {
    display: block;
    margin-top: 1px;

    color: var(--muted);

    font-size: .65rem;
}

.validation-question {
    margin-top: 20px;

    color: var(--ink);

    font-size: .9rem;
    font-weight: 850;
}

.validation-actions {
    margin-top: 11px;

    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.validation-actions form {
    display: contents;
}

.validation-button {
    min-height: 58px;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;

    border: 0;
    border-radius: 14px;

    cursor: pointer;

    font-size: .76rem;

    transition:
        transform .15s ease,
        background .15s ease;
}

.validation-button:hover {
    transform: translateY(-1px);
}

.validation-button > span {
    width: 25px;
    height: 25px;

    display: grid;
    place-items: center;

    border-radius: 50%;

    color: white;

    font-size: 15px;
    font-weight: 900;
}

.validation-yes {
    color: #24764e;
    background: var(--green-soft);
}

.validation-yes > span {
    background: var(--green);
}

.validation-no {
    color: #a1283d;
    background: var(--coral-soft);
}

.validation-no > span {
    background: var(--coral);
}

.failure-panel {
    margin-top: 15px;
    padding: 18px;

    border-radius: 16px;

    background: var(--cream);
}

.failure-panel[hidden] {
    display: none;
}

.failure-title {
    color: var(--ink);

    font-size: .88rem;
    font-weight: 900;
}

.failure-panel > p {
    margin: 4px 0 14px;

    color: var(--muted);

    font-size: .68rem;
}

.failure-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;

    margin-bottom: 14px;
}

.failure-option {
    cursor: pointer;
}

.failure-option input {
    position: absolute;

    opacity: 0;
    pointer-events: none;
}

.failure-option span {
    min-height: 47px;
    padding: 10px 12px;

    display: flex;
    align-items: center;

    border: 1px solid var(--line);
    border-radius: 12px;

    color: var(--text);
    background: white;

    font-size: .68rem;
    font-weight: 750;
}

.failure-option input:checked + span {
    border-color: var(--coral);

    color: var(--coral);

    background: var(--coral-soft);
}

.validation-empty {
    max-width: 550px;

    margin: 30px auto;

    padding: 30px;

    text-align: center;

    border-radius: 22px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.validation-empty-icon {
    font-size: 38px;
}

.validation-empty h2 {
    margin: 10px 0 0;

    color: var(--ink);
}

.validation-empty p {
    margin: 5px 0 20px;

    color: var(--muted);

    font-size: .78rem;
}

@media (max-width: 560px) {

    .validation-actions,
    .failure-options {
        grid-template-columns: 1fr;
    }

    .validation-card {
        padding: 18px;
    }
}

/* Evita que las pantallas centradas queden demasiado pegadas
   a la cabecera sticky */

.success-screen,
.received-screen {
    padding-top: 24px;
}

@media (max-width: 780px) {
    .success-screen,
    .received-screen {
        margin-top: 10px;
        padding-top: 12px;
    }
}

/* =========================================================
   COMUNIDAD / RANKINGS
   ========================================================= */

.community-heading {
    max-width: 720px;
    margin-bottom: 25px;
}

.community-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 11px;
    margin-bottom: 18px;
}

.community-stat-card {
    padding: 18px;

    border: 1px solid rgba(11,34,57,.05);
    border-radius: 18px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.community-stat-icon {
    display: block;
    font-size: 21px;
}

.community-stat-card strong {
    display: block;
    margin-top: 6px;

    color: var(--ink);

    font-size: 1.45rem;
    font-weight: 950;
    letter-spacing: -.035em;
}

.community-stat-card small {
    display: block;
    margin-top: 1px;

    color: var(--muted);

    font-size: .66rem;
}

.community-layout {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        minmax(270px, .38fr);

    gap: 18px;
    align-items: start;
}

.community-main,
.community-sidebar {
    display: grid;
    gap: 18px;
}

.ranking-panel {
    padding: 22px;

    border: 1px solid rgba(11,34,57,.055);
    border-radius: 22px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.ranking-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 15px;
}

.ranking-kicker {
    color: var(--coral);

    font-size: .66rem;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.ranking-header h2 {
    margin: 4px 0 0;

    color: var(--ink);

    font-size: 1.15rem;
    letter-spacing: -.025em;
}

.ranking-period {
    padding: 6px 9px;

    border-radius: 9px;

    color: var(--muted);
    background: var(--cream);

    font-size: .62rem;
    font-weight: 750;

    text-transform: capitalize;
}

.ranking-description {
    max-width: 550px;

    margin: 6px 0 18px;

    color: var(--muted);

    font-size: .7rem;
}

.ranking-list {
    display: grid;
    gap: 7px;
}

.ranking-row {
    min-height: 64px;

    padding: 9px 11px;

    display: grid;
    grid-template-columns:
        35px
        42px
        minmax(0, 1fr)
        auto;

    align-items: center;
    gap: 10px;

    border-radius: 14px;

    background: #faf9f6;
}

.ranking-row.is-me {
    border: 1px solid rgba(239,54,84,.16);
    background: var(--coral-soft);
}

.ranking-position {
    display: grid;
    place-items: center;

    color: var(--muted);

    font-size: .72rem;
    font-weight: 900;
}

.ranking-position.position-1,
.ranking-position.position-2,
.ranking-position.position-3 {
    font-size: 19px;
}

.ranking-avatar {
    width: 40px;
    height: 40px;

    display: grid;
    place-items: center;

    border-radius: 50%;

    color: white;

    background:
        linear-gradient(
            145deg,
            #214c69,
            var(--ink)
        );

    font-size: .75rem;
    font-weight: 900;
}

.ranking-user {
    min-width: 0;
}

.ranking-user strong {
    display: flex;
    align-items: center;
    gap: 6px;

    overflow: hidden;

    color: var(--ink);

    font-size: .76rem;

    text-overflow: ellipsis;
    white-space: nowrap;
}

.ranking-user strong span {
    padding: 2px 5px;

    border-radius: 6px;

    color: var(--coral);
    background: white;

    font-size: .52rem;
    text-transform: uppercase;
}

.ranking-user small {
    display: block;
    margin-top: 2px;

    color: var(--muted);

    font-size: .59rem;
}

.ranking-score {
    text-align: right;
}

.ranking-score strong {
    display: block;

    color: var(--ink);

    font-size: .9rem;
    font-weight: 950;
}

.ranking-score small {
    display: block;

    color: var(--muted);

    font-size: .55rem;
}

.ranking-empty {
    padding: 28px 18px;

    text-align: center;

    border-radius: 16px;

    background: var(--cream);
}

.ranking-empty span {
    display: block;

    font-size: 29px;
}

.ranking-empty strong {
    display: block;
    margin-top: 6px;

    color: var(--ink);

    font-size: .8rem;
}

.ranking-empty small {
    display: block;

    max-width: 320px;

    margin: 3px auto 0;

    color: var(--muted);

    font-size: .64rem;
}

.ranking-empty.small {
    padding: 18px;
}

/* TU POSICIÓN */

.community-me-card {
    padding: 24px;

    overflow: hidden;

    border-radius: 22px;

    color: white;

    background:
        linear-gradient(
            145deg,
            #143d5b,
            #081d30
        );

    box-shadow: var(--shadow-soft);
}

.community-me-kicker {
    color: var(--gold);

    font-size: .65rem;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.community-me-position {
    margin-top: 10px;

    color: white;

    font-size: 3rem;
    font-weight: 950;
    line-height: 1;
    letter-spacing: -.06em;
}

.community-me-card > strong {
    display: block;
    margin-top: 5px;

    font-size: .8rem;
}

.community-me-card > p {
    margin: 8px 0 18px;

    color: rgba(255,255,255,.60);

    font-size: .67rem;
    line-height: 1.5;
}

/* HISTÓRICO */

.historical-panel {
    padding: 19px;
}

.historical-list {
    display: grid;
    gap: 4px;

    margin-top: 13px;
}

.historical-row {
    min-height: 38px;

    display: grid;
    grid-template-columns:
        28px
        minmax(0, 1fr)
        auto;

    align-items: center;
    gap: 7px;

    border-bottom: 1px solid #f0efec;
}

.historical-row:last-child {
    border-bottom: 0;
}

.historical-row > span {
    color: var(--muted);

    font-size: .68rem;
    text-align: center;
}

.historical-row strong {
    overflow: hidden;

    color: var(--ink);

    font-size: .67rem;

    text-overflow: ellipsis;
    white-space: nowrap;
}

.historical-row b {
    color: var(--coral);

    font-size: .68rem;
}

/* COMMUNITY RESPONSIVE */

@media (max-width: 850px) {

    .community-stats {
        grid-template-columns: 1fr 1fr;
    }

    .community-layout {
        grid-template-columns: 1fr;
    }

    .community-sidebar {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 580px) {

    .community-sidebar {
        grid-template-columns: 1fr;
    }

    .community-stat-card {
        padding: 14px;
    }

    .ranking-panel {
        padding: 17px;
    }

    .ranking-period {
        display: none;
    }

    .ranking-row {
        grid-template-columns:
            28px
            38px
            minmax(0, 1fr)
            auto;

        gap: 7px;
        padding: 8px;
    }

    .ranking-avatar {
        width: 36px;
        height: 36px;
    }
}

/* =========================================================
   PERFIL / GAMIFICACIÓN
   ========================================================= */

.profile-hero {
    margin-bottom: 18px;
    padding: 25px;

    display: flex;
    align-items: center;
    gap: 17px;

    border-radius: 24px;

    color: white;

    background:
        linear-gradient(
            145deg,
            #143d5b,
            #081d30
        );

    box-shadow: var(--shadow-soft);
}

.profile-avatar {
    width: 72px;
    height: 72px;

    display: grid;
    place-items: center;

    flex: 0 0 auto;

    border-radius: 50%;

    color: white;

    background:
        linear-gradient(
            145deg,
            var(--coral),
            #b52661
        );

    font-size: 1.4rem;
    font-weight: 950;
}

.profile-identity {
    min-width: 0;
    flex: 1;
}

.profile-identity .dashboard-kicker {
    color: var(--gold);
}

.profile-identity h1 {
    margin: 3px 0 0;

    font-size: 1.8rem;
    letter-spacing: -.04em;
}

.profile-identity p {
    margin: 2px 0 0;

    color: rgba(255,255,255,.55);

    font-size: .72rem;
}

.profile-points {
    text-align: right;
}

.profile-points strong {
    display: block;

    font-size: 1.15rem;
}

.profile-points span {
    color: rgba(255,255,255,.55);

    font-size: .62rem;
}

.profile-grid {
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        minmax(280px, .38fr);

    gap: 18px;
    align-items: start;
}

.profile-main,
.profile-sidebar {
    display: grid;
    gap: 16px;
}

.profile-level-card,
.profile-section {
    padding: 21px;

    border: 1px solid rgba(11,34,57,.055);
    border-radius: 21px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.profile-level-card {
    background:
        linear-gradient(
            135deg,
            #fff5dc,
            #fffaf0
        );
}

.profile-level-top {
    display: flex;
    align-items: center;
    gap: 12px;
}

.profile-level-icon {
    width: 48px;
    height: 48px;

    display: grid;
    place-items: center;

    border-radius: 15px;

    background: rgba(244,183,64,.18);

    font-size: 24px;
}

.profile-level-top span {
    display: block;

    color: var(--muted);

    font-size: .62rem;
    font-weight: 850;
    text-transform: uppercase;
}

.profile-level-top strong {
    display: block;
    margin-top: 2px;

    color: var(--ink);

    font-size: .95rem;
}

.profile-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 9px;
}

.profile-stat {
    padding: 15px 8px;

    text-align: center;

    border-radius: 16px;

    background: white;

    box-shadow: var(--shadow-soft);
}

.profile-stat > span {
    font-size: 19px;
}

.profile-stat strong {
    display: block;
    margin-top: 3px;

    color: var(--ink);

    font-size: 1rem;
    font-weight: 950;
}

.profile-stat small {
    display: block;

    color: var(--muted);

    font-size: .58rem;
}

/* SECTIONS */

.profile-section-heading {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
}

.profile-section-heading span {
    color: var(--coral);

    font-size: .62rem;
    font-weight: 900;
    letter-spacing: .07em;
    text-transform: uppercase;
}

.profile-section-heading h2 {
    margin: 3px 0 0;

    color: var(--ink);

    font-size: 1rem;
}

.profile-section-heading > strong {
    color: var(--muted);

    font-size: .67rem;
}

/* BADGES */

.badge-grid {
    display: grid;
    grid-template-columns:
        repeat(3, 1fr);

    gap: 9px;

    margin-top: 16px;
}

.badge-card {
    min-height: 160px;

    padding: 15px;

    border-radius: 16px;

    text-align: center;
}

.badge-card.unlocked {
    border: 1px solid rgba(244,183,64,.22);

    background: var(--gold-soft);
}

.badge-card.locked {
    border: 1px solid var(--line);

    background: #f8f8f6;

    opacity: .72;
}

.badge-icon {
    width: 43px;
    height: 43px;

    display: grid;
    place-items: center;

    margin: auto;

    border-radius: 14px;

    background: white;

    font-size: 21px;
}

.badge-card strong {
    display: block;
    margin-top: 8px;

    color: var(--ink);

    font-size: .72rem;
}

.badge-card p {
    min-height: 31px;

    margin: 3px 0 8px;

    color: var(--muted);

    font-size: .59rem;
}

.badge-progress {
    height: 5px;

    overflow: hidden;

    border-radius: 99px;

    background: #e6e6e3;
}

.badge-progress div {
    height: 100%;

    background: var(--coral);
}

.badge-card small {
    display: block;
    margin-top: 5px;

    color: var(--muted);

    font-size: .55rem;
}

.badge-earned {
    color: #24764e !important;
    font-weight: 850;
}

/* TRUST */

.profile-trust-card {
    padding: 23px;

    border-radius: 21px;

    color: white;

    background:
        linear-gradient(
            145deg,
            #143d5b,
            #081d30
        );

    box-shadow: var(--shadow-soft);
}

.profile-card-kicker {
    color: var(--gold);

    font-size: .62rem;
    font-weight: 900;
    letter-spacing: .07em;
    text-transform: uppercase;
}

.profile-trust-icon {
    margin-top: 15px;

    font-size: 34px;
}

.profile-trust-card h2 {
    margin: 7px 0 0;

    font-size: 1.15rem;
}

.profile-trust-card > p {
    margin: 6px 0 17px;

    color: rgba(255,255,255,.57);

    font-size: .67rem;
    line-height: 1.5;
}

.trust-numbers {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.trust-numbers > div {
    padding: 11px;

    border-radius: 12px;

    background: rgba(255,255,255,.08);
}

.trust-numbers strong {
    display: block;

    font-size: .9rem;
}

.trust-numbers span {
    color: rgba(255,255,255,.48);

    font-size: .55rem;
}

/* ACTIVITY */

.profile-activity {
    display: grid;
    gap: 5px;

    margin-top: 14px;
}

.activity-row {
    min-height: 48px;

    padding: 7px 0;

    display: grid;
    grid-template-columns:
        34px
        minmax(0, 1fr)
        24px;

    align-items: center;
    gap: 8px;

    border-bottom: 1px solid #f0efec;
}

.activity-row:last-child {
    border-bottom: 0;
}

.activity-icon {
    width: 32px;
    height: 32px;

    display: grid;
    place-items: center;

    border-radius: 10px;

    background: var(--cream);

    font-size: 15px;
}

.activity-row strong {
    display: block;

    overflow: hidden;

    color: var(--ink);

    font-size: .64rem;

    text-overflow: ellipsis;
    white-space: nowrap;
}

.activity-row small {
    display: block;

    color: var(--muted);

    font-size: .55rem;
}

.activity-status {
    width: 22px;
    height: 22px;

    display: grid;
    place-items: center;

    border-radius: 50%;

    color: var(--muted);
    background: var(--cream);

    font-size: .62rem;
    font-weight: 900;
}

.status-confirmed {
    color: #24764e;
    background: var(--green-soft);
}

.status-reported {
    color: var(--coral);
    background: var(--coral-soft);
}

.profile-empty {
    padding: 20px;

    text-align: center;

    color: var(--muted);

    font-size: 20px;
}

.profile-empty strong {
    display: block;
    margin-top: 5px;

    font-size: .7rem;
}

/* PROFILE RESPONSIVE */

@media (max-width: 850px) {

    .profile-grid {
        grid-template-columns: 1fr;
    }

    .profile-sidebar {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 620px) {

    .profile-hero {
        padding: 18px;
    }

    .profile-avatar {
        width: 55px;
        height: 55px;
    }

    .profile-points {
        display: none;
    }

    .profile-stats {
        grid-template-columns: 1fr 1fr;
    }

    .badge-grid {
        grid-template-columns: 1fr 1fr;
    }

    .profile-sidebar {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 390px) {

    .badge-grid {
        grid-template-columns: 1fr;
    }
}