:root {
    --bg: #eef3f8;
    --card: #ffffff;
    --text: #213648;
    --muted: #6f8294;
    --primary: #1070d4;
    --primary-dark: #0b56a2;
    --secondary: #1d8b7a;
    --danger: #d14f4f;
    --border: #d6e2ec;
    --shadow: 0 16px 28px rgba(23, 52, 77, 0.08);
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    font-family: 'Inter', sans-serif;
    color: var(--text);
    background: var(--bg);
}

a {
    color: inherit;
}

.page-section {
    display: grid;
    gap: 1rem;
}

.card,
.table-wrapper,
.filters-card,
.auth-card,
.card-stat {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: var(--shadow);
}

.card {
    padding: 1rem;
}

.card h2,
.card h3 {
    margin: 0 0 0.7rem;
}

.page-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.head-actions {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.btn {
    border: 0;
    border-radius: 10px;
    padding: 0.62rem 0.88rem;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    transition: 0.2s ease;
}

.btn-sm {
    padding: 0.4rem 0.62rem;
    font-size: 0.86rem;
}

.btn-primary {
    background: var(--primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--primary-dark);
}

.btn-secondary {
    background: var(--secondary);
    color: #fff;
}

.btn-secondary:hover {
    filter: brightness(0.92);
}

.btn-danger {
    background: var(--danger);
    color: #fff;
}

.btn-outline {
    background: #fff;
    border: 1px solid #c8d9e8;
    color: #1f3d58;
}

.btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.filters-card {
    padding: 0.85rem;
    display: flex;
    align-items: flex-end;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.filter-item {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    min-width: 160px;
}

.filter-item label {
    font-size: 0.85rem;
    color: var(--muted);
}

.filters-card input,
.filters-card select {
    border: 1px solid #c8d9e8;
    border-radius: 10px;
    padding: 0.62rem 0.7rem;
    font-size: 0.92rem;
    font-family: inherit;
    background: #fdfefe;
    color: #1f3d58;
    min-height: 42px;
}

.filters-card input:focus,
.filters-card select:focus {
    outline: none;
    border-color: #7ab3e9;
    box-shadow: 0 0 0 3px rgba(16, 112, 212, 0.14);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(180px, 1fr));
    gap: 0.8rem;
}

.card-stat {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.card-stat span {
    color: var(--muted);
    font-size: 0.9rem;
}

.card-stat strong {
    font-size: 1.7rem;
}

.card-stat small {
    color: var(--muted);
}

.charts-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 0.8rem;
}

.chart-card {
    min-height: unset;
}

.chart-canvas-wrap {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.chart-canvas-wrap-lg {
    height: 360px;
}

.chart-canvas-wrap-sm {
    height: 360px;
}

.chart-canvas-wrap canvas {
    display: block;
    width: 100% !important;
    height: 100% !important;
    max-height: 100%;
}

.table-wrapper {
    overflow-x: auto;
}

.table {
    width: 100%;
    border-collapse: collapse;
    min-width: 760px;
}

.table th,
.table td {
    border-bottom: 1px solid #e5edf4;
    padding: 0.72rem;
    text-align: left;
    vertical-align: top;
}

.table th {
    color: #47627a;
    font-size: 0.86rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

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

.inline {
    display: inline;
}

.inline-filter {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.form-grid {
    display: grid;
    gap: 0.8rem;
}

.two-columns {
    grid-template-columns: repeat(2, minmax(200px, 1fr));
}

.form-grid label {
    display: flex;
    flex-direction: column;
    gap: 0.28rem;
    color: #47607a;
    font-size: 0.9rem;
}

.form-grid input,
.form-grid select,
.form-grid textarea {
    border: 1px solid #c8d9e8;
    border-radius: 10px;
    padding: 0.62rem 0.7rem;
    font-size: 0.95rem;
    font-family: inherit;
    background: #fdfefe;
}

.form-grid input:focus,
.form-grid select:focus,
.form-grid textarea:focus {
    outline: none;
    border-color: #7ab3e9;
    box-shadow: 0 0 0 3px rgba(16, 112, 212, 0.14);
}

.full-width {
    grid-column: 1 / -1;
}

.form-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    justify-content: flex-end;
}

.form-actions.between {
    justify-content: space-between;
    flex-wrap: wrap;
}

.alerts-stack {
    display: grid;
    gap: 0.52rem;
}

.alert {
    border-radius: 10px;
    padding: 0.7rem 0.8rem;
    border: 1px solid transparent;
}

.alert-success {
    background: #e6f7ef;
    border-color: #8fddbc;
    color: #0f6b45;
}

.alert-error,
.alert-danger {
    background: #fde8e8;
    border-color: #f0b0b0;
    color: #a53333;
}

.alert-info {
    background: #e8f3fd;
    border-color: #add1f3;
    color: #1a5f98;
}

.modal {
    position: fixed;
    inset: 0;
    background: rgba(9, 22, 34, 0.45);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    z-index: 40;
}

.modal.open {
    display: flex;
}

.modal-content {
    background: #fff;
    width: min(680px, 100%);
    border-radius: 16px;
    border: 1px solid #d6e2ec;
    box-shadow: 0 24px 40px rgba(12, 35, 57, 0.22);
    padding: 1rem;
}

.confirm-overlay {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(8, 18, 30, 0.5);
    z-index: 70;
}

.confirm-overlay.open {
    display: flex;
}

.confirm-modal {
    width: min(430px, 92vw);
    background: #fff;
    border-radius: 14px;
    border: 1px solid #d9e5ef;
    padding: 1rem;
}

.confirm-modal h3 {
    margin-top: 0;
}

.confirm-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
}

.perfil-grid {
    grid-template-columns: 2fr 1fr;
}

.profile-card .profile-head {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.avatar-large {
    width: 88px;
    height: 88px;
    font-size: 2rem;
}

.gea-form textarea {
    min-height: 92px;
}

.ai-helper-card {
    border: 1px dashed #b5cde3;
    border-radius: 12px;
    padding: 0.75rem;
    background: #f6fbff;
    display: grid;
    gap: 0.6rem;
}

.ai-helper-card label {
    margin: 0;
}

.ai-helper-card textarea {
    min-height: 84px;
}

.ai-helper-actions {
    display: flex;
    gap: 0.65rem;
    align-items: center;
    flex-wrap: wrap;
}

.ai-helper-status {
    font-size: 0.85rem;
    color: var(--muted);
}

.ai-helper-status.is-info {
    color: #2e6ba9;
}

.ai-helper-status.is-success {
    color: #16825f;
}

.ai-helper-status.is-error {
    color: #b33838;
}

.gea-view-grid {
    grid-template-columns: 290px 1fr;
    align-items: start;
}

.gea-list {
    display: grid;
    gap: 0.45rem;
}

.gea-item {
    border: 1px solid #d8e5ef;
    border-radius: 12px;
    padding: 0.65rem;
    text-decoration: none;
    display: grid;
    gap: 0.2rem;
    background: #fbfdff;
}

.gea-item.active {
    border-color: #71ace4;
    background: #edf5fd;
}

.gea-content pre {
    white-space: pre-wrap;
    word-break: break-word;
    margin: 0 0 0.9rem;
    padding: 0.7rem;
    border-radius: 10px;
    background: #f8fbfe;
    border: 1px solid #dfeaf4;
    font-family: inherit;
}

.public-body {
    min-height: 100vh;
    background: radial-gradient(circle at 15% 15%, #1c8a8c 0%, #1467a7 45%, #0b2a45 100%);
}

.public-wrapper {
    min-height: 100vh;
    width: min(1180px, 94vw);
    margin: 0 auto;
    padding: 2rem 0 2.6rem;
    display: grid;
    gap: 1rem;
}

.public-hero {
    display: grid;
    gap: 1rem;
    grid-template-columns: 1.1fr 1fr;
}

.public-brand {
    background: rgba(255, 255, 255, 0.98);
    border-radius: 20px;
    padding: 1.4rem;
    box-shadow: 0 18px 28px rgba(8, 25, 40, 0.22);
}

.brand-badge {
    display: inline-flex;
    border-radius: 999px;
    padding: 0.3rem 0.7rem;
    background: #e6f2fc;
    color: #0f5ca7;
    font-weight: 700;
    font-size: 0.84rem;
}

.public-brand h1 {
    margin-bottom: 0.55rem;
}

.public-brand p {
    color: #4c6378;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.hero-cards {
    display: grid;
    gap: 0.8rem;
}

.feature-card {
    border-radius: 18px;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 18px 30px rgba(8, 25, 40, 0.22);
}

.feature-card i {
    font-size: 1.4rem;
    color: #0f69b7;
}

.auth-card {
    margin: 0 auto;
    width: min(680px, 100%);
    padding: 1rem;
    background: rgba(255, 255, 255, 0.97);
}

.auth-card-lg {
    width: min(930px, 100%);
}

.public-alerts {
    width: min(930px, 100%);
    margin: 0 auto;
}

@media (max-width: 1100px) {
    .cards-grid {
        grid-template-columns: repeat(2, minmax(200px, 1fr));
    }

    .charts-grid,
    .perfil-grid,
    .gea-view-grid,
    .public-hero {
        grid-template-columns: 1fr;
    }

    .chart-canvas-wrap-lg,
    .chart-canvas-wrap-sm {
        height: 320px;
    }
}

@media (max-width: 760px) {
    .table {
        min-width: 640px;
    }

    .two-columns {
        grid-template-columns: 1fr;
    }

    .filters-card,
    .inline-filter {
        width: 100%;
    }

    .inline-filter {
        display: grid;
        grid-template-columns: 1fr;
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    .chart-canvas-wrap-lg,
    .chart-canvas-wrap-sm {
        height: 280px;
    }

    .hero-actions,
    .form-actions {
        width: 100%;
        justify-content: stretch;
    }

    .form-actions .btn,
    .hero-actions .btn {
        flex: 1;
        justify-content: center;
    }
}




.checkbox-inline-wrap {
    display: flex;
    align-items: center;
}

.checkbox-inline {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.92rem;
    color: #2e4860;
}

.checkbox-inline input[type='checkbox'] {
    width: 16px;
    height: 16px;
}

.ai-json-preview-wrap {
    border: 1px solid #d7e6f2;
    border-radius: 12px;
    background: #fbfdff;
    padding: 0.75rem;
    display: grid;
    gap: 0.55rem;
}

.ai-json-preview {
    margin: 0;
    padding: 0.7rem;
    border-radius: 10px;
    background: #f3f8fc;
    border: 1px solid #d5e5f2;
    max-height: 260px;
    overflow: auto;
    white-space: pre-wrap;
    font-size: 0.83rem;
    line-height: 1.35;
}

.inline-actions-wrap {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
}

/* GEA workspace */
.page-subtitle {
    margin: 0.2rem 0 0;
    color: var(--muted);
    font-size: 0.9rem;
}

.gea-form-layout {
    display: grid;
}

.gea-workspace {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 350px;
    gap: 0.9rem;
    align-items: start;
}

.gea-main {
    display: grid;
    gap: 0.9rem;
    min-width: 0;
}

.gea-side {
    position: sticky;
    top: 84px;
    align-self: start;
}

.gea-side-card {
    display: grid;
    gap: 0.75rem;
}

.gea-section-card {
    padding: 1rem;
    display: grid;
    gap: 0.8rem;
}

.gea-section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.gea-section-head h3 {
    margin: 0;
    color: #17354d;
    font-size: 1.03rem;
}

.gea-section-head span {
    color: var(--muted);
    font-size: 0.82rem;
}

.gea-grid {
    gap: 0.76rem;
}

.gea-note {
    margin-top: 0.28rem;
    color: var(--muted);
    font-size: 0.82rem;
}

.gea-descritores-select {
    min-height: 155px;
}

.gea-side-actions {
    display: grid;
    gap: 0.55rem;
}

.gea-side-actions .btn {
    width: 100%;
    justify-content: center;
}

.gea-side-status {
    min-height: 1rem;
}

.gea-submit-actions {
    padding: 0.1rem 0 0.1rem;
}

@media (max-width: 1280px) {
    .gea-workspace {
        grid-template-columns: 1fr;
    }

    .gea-side {
        position: static;
    }

    .gea-side-actions .btn {
        width: auto;
    }
}

@media (max-width: 760px) {
    .gea-section-head {
        align-items: flex-start;
        flex-direction: column;
    }
}

/* Modern UI overrides */
:root {
    --bg: #eef4fb;
    --card: rgba(255, 255, 255, 0.9);
    --text: #13263a;
    --muted: #62748a;
    --primary: #1666c5;
    --primary-dark: #0f4f9d;
    --secondary: #0f9a86;
    --danger: #d94d67;
    --border: rgba(129, 156, 186, 0.24);
    --shadow: 0 24px 56px rgba(11, 33, 56, 0.12);
    --heading: #0c2036;
    --surface-muted: #f4f8fc;
    --success: #159570;
    --warning: #ee9a32;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    color: var(--text);
}

body.app-body {
    background:
        radial-gradient(circle at top left, rgba(22, 102, 197, 0.1), transparent 34%),
        radial-gradient(circle at bottom right, rgba(15, 154, 134, 0.08), transparent 26%),
        linear-gradient(180deg, #f3f7fc 0%, #f8fbff 38%, #eef5fb 100%);
}

body.public-body {
    background:
        radial-gradient(circle at top left, rgba(28, 113, 202, 0.25), transparent 30%),
        radial-gradient(circle at 85% 12%, rgba(19, 174, 149, 0.22), transparent 26%),
        linear-gradient(140deg, #071521 0%, #0c2741 45%, #0b3658 100%);
}

h1,
h2,
h3,
h4 {
    font-family: 'Sora', sans-serif;
    color: var(--heading);
    line-height: 1.16;
}

p {
    color: var(--muted);
}

.page-section {
    position: relative;
    z-index: 1;
    gap: 1.2rem;
}

.card,
.table-wrapper,
.filters-card,
.auth-card,
.card-stat {
    border-radius: 28px;
    background: var(--card);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

.card {
    padding: 1.45rem;
}

.table-wrapper {
    overflow: auto;
}

.page-head {
    align-items: flex-end;
    gap: 1rem;
}

.page-head h2 {
    margin: 0;
    font-size: clamp(1.45rem, 2vw, 1.85rem);
}

.head-actions {
    gap: 0.7rem;
}

.section-tag,
.brand-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    width: fit-content;
    padding: 0.48rem 0.84rem;
    border-radius: 999px;
    background: rgba(22, 102, 197, 0.08);
    border: 1px solid rgba(22, 102, 197, 0.14);
    color: var(--primary-dark);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.section-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.section-heading p {
    margin: 0;
    max-width: 36rem;
}

.section-heading-centered {
    align-items: center;
    flex-direction: column;
    text-align: center;
}

.section-heading-centered p {
    max-width: 52rem;
}

.btn {
    border-radius: 16px;
    padding: 0.82rem 1.08rem;
    font-weight: 700;
    box-shadow: 0 14px 28px rgba(11, 33, 56, 0.1);
}

.btn-sm {
    padding: 0.68rem 0.96rem;
    border-radius: 14px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, #2b82d9 100%);
}

.btn-secondary {
    background: linear-gradient(135deg, var(--secondary) 0%, #17b29a 100%);
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger) 0%, #ea6d86 100%);
}

.btn-outline {
    background: rgba(255, 255, 255, 0.76);
    border-color: rgba(129, 156, 186, 0.34);
    color: var(--heading);
}

.btn-ghost {
    background: rgba(18, 42, 68, 0.06);
    border: 1px solid rgba(18, 42, 68, 0.08);
    color: var(--heading);
}

.filters-card {
    padding: 1rem 1.05rem;
    gap: 0.85rem;
}

.filter-item {
    min-width: 190px;
    flex: 1 1 220px;
    gap: 0.42rem;
}

.filter-item label,
.form-grid label {
    color: var(--muted);
    font-size: 0.88rem;
    font-weight: 700;
}

.form-grid {
    gap: 0.95rem;
}

.form-grid input,
.form-grid select,
.form-grid textarea {
    border-radius: 16px;
    min-height: 48px;
    padding: 0.82rem 0.95rem;
    border-color: rgba(115, 144, 175, 0.28);
    background: rgba(255, 255, 255, 0.92);
    color: var(--heading);
}

.form-grid textarea {
    min-height: 120px;
}

.form-grid input:focus,
.form-grid select:focus,
.form-grid textarea:focus {
    border-color: rgba(22, 102, 197, 0.42);
    box-shadow: 0 0 0 4px rgba(22, 102, 197, 0.12);
    background: #fff;
}

.form-actions {
    gap: 0.7rem;
}

.inline-filter {
    gap: 0.65rem;
    flex-wrap: wrap;
}

.cards-grid {
    gap: 1rem;
}

.card-stat {
    padding: 1.2rem;
    gap: 1rem;
}

.card-stat strong {
    font-family: 'Sora', sans-serif;
    color: var(--heading);
}

.dashboard-page {
    gap: 1.1rem;
}

.dashboard-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(320px, 0.95fr);
    gap: 1rem;
}

.dashboard-hero-main,
.dashboard-hero-side {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    box-shadow: 0 34px 80px rgba(11, 33, 56, 0.16);
}

.dashboard-hero-main {
    padding: clamp(1.35rem, 2vw, 2rem);
    background:
        radial-gradient(circle at top right, rgba(43, 130, 217, 0.15), transparent 28%),
        linear-gradient(145deg, rgba(255, 255, 255, 0.96) 0%, rgba(242, 248, 255, 0.92) 100%);
    border: 1px solid rgba(129, 156, 186, 0.24);
}

.dashboard-hero-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    flex-wrap: wrap;
}

.dashboard-hero-head h2 {
    max-width: 14ch;
    font-size: clamp(1.9rem, 3vw, 2.8rem);
}

.dashboard-hero-head p {
    max-width: 60ch;
    margin-top: 0.75rem;
    font-size: 1rem;
}

.dashboard-context-chips,
.dashboard-toolbar-meta,
.dashboard-hero-actions {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    flex-wrap: wrap;
}

.dashboard-hero-actions {
    margin-top: 1.4rem;
}

.context-chip,
.meta-pill,
.metric-pill,
.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    width: fit-content;
    padding: 0.45rem 0.78rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 800;
}

.context-chip,
.meta-pill,
.metric-pill {
    color: var(--heading);
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(129, 156, 186, 0.24);
}

.dashboard-highlight-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.8rem;
    margin-top: 1.35rem;
}

.highlight-card {
    padding: 1rem;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid rgba(129, 156, 186, 0.2);
}

.highlight-card span {
    display: block;
    color: var(--muted);
    font-size: 0.8rem;
    font-weight: 700;
}

.highlight-card strong {
    display: block;
    margin-top: 0.28rem;
    font-family: 'Sora', sans-serif;
    font-size: 1.7rem;
    color: var(--heading);
}

.highlight-card small {
    display: block;
    margin-top: 0.3rem;
    color: var(--muted);
}

.dashboard-hero-side {
    padding: 1.35rem;
    display: grid;
    gap: 1rem;
    background:
        radial-gradient(circle at top right, rgba(23, 178, 154, 0.2), transparent 34%),
        linear-gradient(180deg, #0c2034 0%, #122c45 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #fff;
}

.dashboard-hero-side h3,
.dashboard-hero-side strong {
    color: #fff;
}

.dashboard-hero-side p,
.dashboard-hero-side span,
.dashboard-hero-side small {
    color: rgba(235, 244, 255, 0.8);
}

.dashboard-side-head,
.insight-stack,
.progress-card,
.chart-card,
.insight-panel,
.table-card {
    display: grid;
    gap: 1rem;
}

.insight-row {
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
    padding: 0.95rem;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.insight-icon,
.card-stat-icon,
.feature-icon {
    width: 52px;
    height: 52px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    font-size: 1.05rem;
}

.insight-icon.is-blue,
.card-stat-icon.is-blue,
.feature-icon {
    background: rgba(22, 102, 197, 0.12);
    color: var(--primary);
}

.insight-icon.is-green,
.card-stat-icon.is-green {
    background: rgba(15, 154, 134, 0.12);
    color: var(--secondary);
}

.insight-icon.is-gold,
.card-stat-icon.is-gold {
    background: rgba(242, 184, 75, 0.18);
    color: #b27913;
}

.card-stat-icon.is-rose {
    background: rgba(217, 77, 103, 0.14);
    color: var(--danger);
}

.progress-card {
    padding: 1rem;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.progress-card-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.8rem;
}

.progress-card-head strong {
    font-family: 'Sora', sans-serif;
    font-size: 1.35rem;
}

.progress-bar {
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    overflow: hidden;
}

.progress-bar span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(135deg, #35c7ac 0%, #76ddc4 100%);
}

.dashboard-toolbar {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.dashboard-filters {
    flex: 1 1 720px;
}

.dashboard-kpi-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.status-pill.is-good,
.metric-pill.is-good {
    background: rgba(21, 149, 112, 0.12);
    border: 1px solid rgba(21, 149, 112, 0.18);
    color: var(--success);
}

.status-pill.is-warning,
.metric-pill.is-warning {
    background: rgba(238, 154, 50, 0.14);
    border: 1px solid rgba(238, 154, 50, 0.18);
    color: #ae6b12;
}

.status-pill.is-neutral,
.metric-pill.is-neutral {
    background: rgba(99, 118, 139, 0.12);
    border: 1px solid rgba(99, 118, 139, 0.16);
    color: #617285;
}

.status-dot-text {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    font-weight: 700;
}

.status-dot-text::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: currentColor;
}

.status-dot-text.is-good {
    color: var(--success);
}

.status-dot-text.is-warning {
    color: #ae6b12;
}

.status-dot-text.is-neutral {
    color: #62748a;
}

.dashboard-panels {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(320px, 0.95fr);
    gap: 1rem;
    align-items: start;
}

.chart-card-wide {
    grid-column: 1;
    grid-row: span 2;
}

.chart-card-compact,
.insight-panel {
    grid-column: 2;
}

.chart-canvas-wrap-lg {
    height: 380px;
}

.chart-canvas-wrap-sm {
    height: 320px;
}

.ranking-list {
    display: grid;
    gap: 0.75rem;
}

.ranking-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    padding: 0.95rem 1rem;
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(247, 250, 255, 0.98), rgba(240, 246, 253, 0.92));
    border: 1px solid rgba(129, 156, 186, 0.22);
}

.ranking-item-main {
    display: grid;
    gap: 0.18rem;
}

.ranking-item-main span {
    color: var(--muted);
    font-size: 0.84rem;
}

.ranking-item-metrics {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.empty-state {
    min-height: 220px;
    display: grid;
    place-items: center;
    gap: 0.6rem;
    border-radius: 22px;
    border: 1px dashed rgba(129, 156, 186, 0.32);
    background: rgba(243, 248, 254, 0.7);
    text-align: center;
}

.empty-state i {
    color: var(--primary);
    font-size: 1.4rem;
}

.table {
    min-width: 760px;
    border-collapse: separate;
    border-spacing: 0;
}

.table th,
.table td {
    padding: 1rem 1.05rem;
    border-bottom: 1px solid rgba(129, 156, 186, 0.18);
}

.table th {
    background: rgba(245, 249, 255, 0.96);
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.table tbody tr:hover {
    background: rgba(237, 244, 252, 0.66);
}

.table-primary-cell {
    display: grid;
    gap: 0.2rem;
}

.table-primary-cell span {
    color: var(--muted);
    font-size: 0.82rem;
}

.actions {
    gap: 0.55rem;
}

.alert {
    padding: 0.95rem 1.05rem;
    border-radius: 18px;
    box-shadow: 0 14px 28px rgba(11, 33, 56, 0.08);
    font-weight: 700;
}

.modal {
    background: rgba(6, 20, 33, 0.56);
    backdrop-filter: blur(8px);
}

.modal-content,
.confirm-modal {
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(129, 156, 186, 0.24);
    box-shadow: 0 34px 80px rgba(11, 33, 56, 0.16);
}

.perfil-grid {
    grid-template-columns: minmax(0, 1.65fr) minmax(280px, 0.95fr);
}

.profile-card .profile-head {
    margin-bottom: 1.15rem;
    padding-bottom: 1.1rem;
    border-bottom: 1px solid rgba(129, 156, 186, 0.18);
}

.gea-item,
.ai-json-preview-wrap,
.ai-helper-card,
.gea-content pre {
    border-radius: 22px;
}

.public-wrapper {
    position: relative;
    z-index: 1;
    width: min(1240px, calc(100vw - 32px));
    margin: 0 auto;
    padding: 2rem 0 2.8rem;
    display: grid;
    gap: 1.2rem;
}

.public-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.18fr) minmax(360px, 0.92fr);
    gap: 1rem;
    align-items: stretch;
}

.public-hero-main,
.public-hero-panel,
.public-access-grid .auth-card,
.public-access-copy,
.public-section,
.public-cta-card {
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 28px;
    box-shadow: 0 34px 80px rgba(11, 33, 56, 0.16);
    backdrop-filter: blur(20px);
}

.public-section,
.public-cta-card {
    padding: 1.45rem;
}

.public-hero-main {
    padding: clamp(1.45rem, 2vw, 2.2rem);
    display: grid;
    gap: 1.25rem;
}

.public-hero-main h1 {
    max-width: 12ch;
    font-size: clamp(2.25rem, 5vw, 4rem);
}

.public-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.8rem;
}

.public-metric-card {
    padding: 1rem;
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(245, 249, 255, 0.96), rgba(236, 244, 252, 0.9));
    border: 1px solid rgba(129, 156, 186, 0.2);
}

.public-metric-card span,
.preview-panel span {
    display: block;
    color: var(--muted);
    font-size: 0.8rem;
    font-weight: 800;
}

.public-metric-card strong,
.preview-panel strong {
    display: block;
    margin-top: 0.35rem;
    font-family: 'Sora', sans-serif;
    color: var(--heading);
}

.public-hero-panel {
    padding: 1rem;
}

.public-preview-card {
    height: 100%;
    display: grid;
    gap: 1rem;
    padding: 1.2rem;
    border-radius: 22px;
    background:
        radial-gradient(circle at top right, rgba(37, 202, 176, 0.18), transparent 34%),
        linear-gradient(180deg, #0b2034 0%, #11324e 100%);
    color: #fff;
}

.public-preview-card h2,
.preview-badge {
    color: #fff;
}

.preview-panel strong {
    color: #fff;
}

.public-preview-card .section-tag {
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.12);
}

.preview-card-head,
.preview-topbar,
.public-access-grid,
.public-cta-card {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.preview-badge,
.public-access-points span {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.preview-badge {
    padding: 0.45rem 0.76rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.12);
    font-size: 0.8rem;
    font-weight: 800;
}

.preview-window {
    padding: 1rem;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    display: grid;
    gap: 1rem;
}

.preview-dot {
    width: 11px;
    height: 11px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.58);
}

.preview-search {
    margin-left: auto;
    padding: 0.55rem 0.9rem;
    border-radius: 999px;
    min-width: 210px;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(235, 244, 255, 0.84);
    font-size: 0.82rem;
}

.preview-grid,
.public-feature-grid,
.public-process-grid {
    display: grid;
    gap: 0.85rem;
}

.preview-grid {
    grid-template-columns: 1.2fr 1fr;
}

.preview-panel,
.feature-card,
.process-card {
    padding: 1rem;
    border-radius: 22px;
}

.preview-panel {
    display: grid;
    gap: 0.4rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.preview-panel span,
.preview-panel small,
.preview-panel p {
    color: rgba(235, 244, 255, 0.8);
}

.preview-panel-main {
    grid-row: span 2;
}

.preview-bars {
    display: grid;
    gap: 0.55rem;
    margin-top: 0.55rem;
}

.preview-bars span {
    display: block;
    height: 10px;
    border-radius: 999px;
    background: linear-gradient(135deg, #2fb9f1 0%, #4fe0b7 100%);
}

.public-access-grid {
    display: grid;
    grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 0;
}

.public-access-copy {
    padding: 1.45rem;
    display: grid;
    gap: 1rem;
}

.public-access-points {
    display: grid;
    gap: 0.75rem;
}

.public-access-points span {
    padding: 0.82rem 0.95rem;
    border-radius: 18px;
    background: rgba(240, 246, 255, 0.76);
    border: 1px solid rgba(129, 156, 186, 0.18);
    color: var(--heading);
    font-weight: 700;
}

.public-feature-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.feature-card {
    display: grid;
    gap: 0.78rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(244, 249, 255, 0.92));
    border: 1px solid rgba(129, 156, 186, 0.2);
    box-shadow: none;
}

.card-stat-modern {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(248, 251, 255, 0.88));
}

.feature-card-accent {
    background: linear-gradient(180deg, rgba(234, 243, 255, 0.98), rgba(244, 249, 255, 0.92));
}

.public-process-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.process-card {
    display: grid;
    gap: 0.75rem;
    border: 1px solid rgba(129, 156, 186, 0.18);
    background: rgba(255, 255, 255, 0.9);
}

.process-card strong {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    background: rgba(22, 102, 197, 0.1);
    color: var(--primary);
}

.public-section-featured {
    background: linear-gradient(145deg, rgba(248, 251, 255, 0.98), rgba(233, 242, 251, 0.92));
}

.public-section-layout {
    display: grid;
    grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
    gap: 1rem;
    align-items: stretch;
}

.public-section-aside {
    padding: 1.45rem;
    border-radius: 24px;
    background:
        radial-gradient(circle at top right, rgba(80, 213, 184, 0.2), transparent 30%),
        linear-gradient(180deg, #0d2741 0%, #123a5c 100%);
    color: #fff;
    display: grid;
    gap: 1rem;
}

.public-section-aside .section-tag {
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.14);
}

.public-section-aside h2,
.public-section-aside strong {
    color: #fff;
}

.public-section-aside p,
.public-section-aside span,
.public-section-aside small {
    color: rgba(232, 241, 251, 0.82);
}

.public-aside-points,
.public-aside-stats,
.feature-card-head,
.feature-list,
.process-section-head,
.process-summary,
.process-list,
.public-cta-side,
.public-cta-badges {
    display: flex;
    gap: 0.7rem;
    flex-wrap: wrap;
}

.public-aside-points {
    flex-direction: column;
}

.public-aside-points span,
.public-aside-stat,
.feature-list span,
.process-list span,
.public-cta-badges span {
    border-radius: 18px;
}

.public-aside-points span {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.85rem 0.95rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    font-weight: 700;
}

.public-aside-stat {
    flex: 1 1 140px;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: grid;
    gap: 0.22rem;
}

.public-aside-stat strong {
    font-size: 1.75rem;
    font-family: 'Sora', sans-serif;
}

.public-feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.feature-card {
    padding: 1.15rem;
    border-radius: 24px;
    gap: 0.9rem;
}

.feature-card-head {
    align-items: center;
    justify-content: space-between;
}

.feature-eyebrow {
    display: inline-flex;
    align-items: center;
    padding: 0.38rem 0.66rem;
    border-radius: 999px;
    background: rgba(18, 42, 68, 0.06);
    color: var(--primary-dark);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.feature-card-wide {
    grid-column: span 2;
}

.feature-card-dark {
    background:
        radial-gradient(circle at top right, rgba(62, 210, 176, 0.16), transparent 32%),
        linear-gradient(160deg, #0d2741 0%, #103a59 100%);
    border-color: rgba(255, 255, 255, 0.08);
}

.feature-card-dark h3,
.feature-card-dark p,
.feature-card-dark .feature-eyebrow {
    color: #fff;
}

.feature-card-dark .feature-eyebrow {
    background: rgba(255, 255, 255, 0.08);
}

.feature-card-contrast {
    background: linear-gradient(180deg, rgba(239, 248, 245, 0.98), rgba(226, 243, 238, 0.92));
}

.feature-list span {
    padding: 0.48rem 0.72rem;
    background: rgba(22, 102, 197, 0.08);
    color: var(--primary-dark);
    font-size: 0.8rem;
    font-weight: 700;
}

.public-section-process {
    background:
        radial-gradient(circle at top right, rgba(56, 214, 185, 0.18), transparent 32%),
        linear-gradient(160deg, #0b2237 0%, #123b5e 100%);
    border-color: rgba(255, 255, 255, 0.08);
}

.public-section-process .section-tag {
    color: rgba(255, 255, 255, 0.92);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.12);
}

.public-section-process h2,
.public-section-process h3,
.public-section-process strong,
.public-section-process .process-step {
    color: #fff;
}

.public-section-process p,
.public-section-process span {
    color: rgba(232, 241, 251, 0.8);
}

.process-section-head {
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.process-summary-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.45rem 0.72rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    font-size: 0.8rem;
    font-weight: 700;
}

.process-line {
    height: 1px;
    margin-bottom: 1rem;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.08), rgba(82, 205, 177, 0.54), rgba(255, 255, 255, 0.08));
}

.public-process-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: stretch;
}

.process-card {
    padding: 1.15rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(14px);
}

.process-step {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.12);
    font-family: 'Sora', sans-serif;
    font-size: 1rem;
}

.process-list span {
    padding: 0.5rem 0.75rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.82rem;
    font-weight: 700;
}

.public-cta-card-strong {
    background:
        radial-gradient(circle at top right, rgba(80, 213, 184, 0.18), transparent 34%),
        linear-gradient(135deg, #0c253d 0%, #175684 100%);
    border-color: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.public-cta-card-strong .section-tag {
    color: rgba(255, 255, 255, 0.92);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.12);
}

.public-cta-card-strong h2,
.public-cta-card-strong p,
.public-cta-card-strong span {
    color: #fff;
}

.public-cta-copy,
.public-cta-side {
    display: grid;
    gap: 0.9rem;
}

.public-cta-side {
    justify-items: end;
}

.public-cta-badges {
    justify-content: flex-end;
}

.public-cta-badges span {
    display: inline-flex;
    align-items: center;
    gap: 0.48rem;
    padding: 0.56rem 0.78rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    font-size: 0.82rem;
    font-weight: 700;
}

@media (max-width: 1280px) {
    .dashboard-hero,
    .dashboard-panels,
    .perfil-grid,
    .public-hero,
    .public-access-grid,
    .public-section-layout {
        grid-template-columns: 1fr;
    }

    .chart-card-wide,
    .chart-card-compact,
    .insight-panel {
        grid-column: auto;
        grid-row: auto;
    }

    .public-feature-grid,
    .dashboard-kpi-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .public-cta-side {
        justify-items: start;
    }

    .public-cta-badges {
        justify-content: flex-start;
    }
}

@media (max-width: 760px) {
    .public-wrapper {
        width: min(100vw - 20px, calc(100vw - 20px));
        padding: 1rem 0 1.8rem;
    }

    .cards-grid,
    .dashboard-kpi-grid,
    .public-feature-grid,
    .public-process-grid,
    .preview-grid,
    .public-metrics,
    .dashboard-highlight-grid,
    .public-aside-stats {
        grid-template-columns: 1fr;
    }

    .hero-actions .btn,
    .dashboard-hero-actions .btn,
    .form-actions .btn,
    .head-actions .btn {
        flex: 1 1 100%;
    }

    .ranking-item,
    .section-heading,
    .page-head,
    .progress-card-head {
        flex-direction: column;
        align-items: flex-start;
    }

    .preview-search {
        min-width: 0;
        width: 100%;
        margin-left: 0;
    }

    .dashboard-hero-head h2,
    .public-hero-main h1 {
        max-width: none;
    }

    .dashboard-hero-head {
        flex-direction: column;
        align-items: flex-start;
    }

    .dashboard-context-chips {
        width: 100%;
    }

    .feature-card-wide {
        grid-column: auto;
    }

    .process-section-head,
    .public-cta-badges {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* School System Theme Refresh */
:root {
    --school-navy: #0f2d4a;
    --school-blue: #1f5f9f;
    --school-sky: #2f84c8;
    --school-green: #2b8a65;
    --school-gold: #c7932b;
    --school-ink: #17324b;
    --school-muted: #5f768d;
    --school-paper: #f5f8fc;
    --school-paper-soft: #eef4fa;
    --school-line: #d3e0ec;
    --school-shadow: 0 18px 32px rgba(12, 35, 57, 0.1);
}

body {
    font-family: 'Nunito Sans', 'Segoe UI', sans-serif;
    color: var(--school-ink);
}

h1,
h2,
h3,
h4,
.sidebar-brand h2,
.topbar-title h1,
.card-stat strong,
.page-head h2 {
    font-family: 'Merriweather', 'Times New Roman', serif;
    letter-spacing: -0.012em;
}

body.app-body {
    background:
        radial-gradient(circle at 8% 7%, rgba(31, 95, 159, 0.12), transparent 28%),
        radial-gradient(circle at 91% 14%, rgba(43, 138, 101, 0.1), transparent 24%),
        linear-gradient(180deg, #f7fafd 0%, #eef4fa 44%, #e8f0f7 100%);
}

.dashboard-shell {
    position: relative;
    min-height: 100vh;
}

.dashboard-shell::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image:
        repeating-linear-gradient(
            0deg,
            rgba(31, 95, 159, 0.035) 0,
            rgba(31, 95, 159, 0.035) 1px,
            transparent 1px,
            transparent 24px
        );
    opacity: 0.34;
    z-index: 0;
}

.sidebar,
.dashboard-main,
.public-wrapper {
    position: relative;
    z-index: 1;
}

.sidebar {
    width: 304px;
    background:
        radial-gradient(circle at 85% 12%, rgba(220, 182, 108, 0.2), transparent 28%),
        linear-gradient(180deg, #0f2d4a 0%, #14375a 60%, #173f64 100%);
    border-right: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 24px 0 44px rgba(9, 23, 37, 0.2);
}

.sidebar-brand,
.sidebar-user,
.sidebar-workspace,
.sidebar-footer-card {
    background: rgba(255, 255, 255, 0.09);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 18px;
}

.brand-icon {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.22), rgba(199, 147, 43, 0.28));
    color: #fff;
}

.sidebar-tag {
    display: inline-flex;
    width: fit-content;
    padding: 0.28rem 0.62rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #f8fbff;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.sidebar-section-label {
    color: rgba(235, 244, 254, 0.76);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-top: 0.15rem;
}

.menu-link,
.menu-group-toggle,
.menu-submenu a,
.sidebar-logout {
    border-radius: 12px;
    font-weight: 700;
}

.menu-link.active,
.menu-group-toggle.active,
.menu-submenu a.active {
    background: linear-gradient(135deg, rgba(47, 132, 200, 0.34), rgba(199, 147, 43, 0.24));
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.topbar {
    border-radius: 18px;
    border: 1px solid var(--school-line);
    box-shadow: var(--school-shadow);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(245, 250, 255, 0.93));
}

.topbar-kicker {
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #486782;
}

.topbar-title h1 {
    color: #163955;
}

.topbar-title p {
    color: var(--school-muted);
}

.topbar-date {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.56rem 0.72rem;
    border-radius: 999px;
    border: 1px solid var(--school-line);
    background: #f6f9fd;
    color: #35516b;
    font-weight: 700;
    font-size: 0.84rem;
}

.card,
.table-wrapper,
.filters-card,
.auth-card,
.card-stat,
.gea-section-card,
.gea-side-card {
    border-radius: 20px;
    border: 1px solid var(--school-line);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(245, 250, 255, 0.92));
    box-shadow: var(--school-shadow);
    backdrop-filter: blur(8px);
}

.card {
    padding: 1.2rem;
}

.page-subtitle,
.card p,
.form-grid label,
.filter-item label,
.gea-note,
.gea-section-head span {
    color: var(--school-muted);
}

.btn {
    border-radius: 12px;
    font-weight: 800;
    box-shadow: 0 10px 18px rgba(12, 35, 57, 0.12);
}

.btn-primary {
    background: linear-gradient(135deg, var(--school-blue) 0%, var(--school-sky) 100%);
}

.btn-secondary {
    background: linear-gradient(135deg, #1d7a62 0%, #2c9d7e 100%);
}

.btn-outline {
    border: 1px solid var(--school-line);
    color: #204360;
    background: rgba(255, 255, 255, 0.94);
}

.btn-ghost {
    border: 1px solid #d8e4ef;
    background: #f5f9fd;
    color: #204360;
}

.form-grid input,
.form-grid select,
.form-grid textarea {
    border-radius: 12px;
    border: 1px solid #c6d8e8;
    background: #fff;
    color: #15344d;
}

.form-grid input:focus,
.form-grid select:focus,
.form-grid textarea:focus {
    border-color: #4f86b8;
    box-shadow: 0 0 0 3px rgba(31, 95, 159, 0.16);
}

.table {
    min-width: 760px;
    border-collapse: separate;
    border-spacing: 0;
}

.table th {
    background: #edf4fb;
    color: #496783;
    font-weight: 800;
    border-bottom: 1px solid #cddcea;
}

.table td {
    border-bottom: 1px solid #dfe9f3;
}

.table tbody tr:hover {
    background: #f3f8fd;
}

.alert {
    border-radius: 14px;
    border-width: 1px;
    border-style: solid;
    font-weight: 700;
}

.ai-helper-card,
.ai-json-preview-wrap,
.gea-content pre,
.gea-item {
    border-radius: 16px;
    border: 1px solid #d1e0ec;
    background: #f8fbff;
}

.gea-item.active {
    border-color: #5d8fbe;
    background: #ebf3fb;
}

.public-body {
    background:
        radial-gradient(circle at 12% 10%, rgba(45, 131, 201, 0.22), transparent 28%),
        radial-gradient(circle at 88% 16%, rgba(199, 147, 43, 0.18), transparent 23%),
        linear-gradient(145deg, #0d2a44 0%, #173c61 55%, #1f4f7d 100%);
}

.public-hero-main,
.public-hero-panel,
.public-section,
.public-access-copy,
.public-access-grid .auth-card,
.public-cta-card {
    border-radius: 22px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.95);
}

.public-preview-card,
.public-section-aside,
.public-section-process,
.public-cta-card-strong {
    border-radius: 22px;
}

.public-brand h1,
.public-hero-main h1,
.public-section h2,
.public-preview-card h2 {
    font-family: 'Merriweather', 'Times New Roman', serif;
}

.page-section > * {
    animation: school-fade-up 0.42s ease both;
}

.page-section > *:nth-child(2) {
    animation-delay: 0.04s;
}

.page-section > *:nth-child(3) {
    animation-delay: 0.08s;
}

.page-section > *:nth-child(4) {
    animation-delay: 0.12s;
}

@keyframes school-fade-up {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .page-section > * {
        animation: none;
    }
}

@media (max-width: 980px) {
    .sidebar {
        width: 296px;
    }

    .dashboard-main {
        width: 100%;
        padding: 0.82rem;
    }

    .topbar {
        border-radius: 16px;
    }
}

@media (max-width: 760px) {
    .card,
    .table-wrapper,
    .filters-card,
    .auth-card,
    .card-stat,
    .gea-section-card,
    .gea-side-card,
    .public-hero-main,
    .public-hero-panel,
    .public-section,
    .public-access-copy,
    .public-access-grid .auth-card,
    .public-cta-card {
        border-radius: 16px;
    }

    .page-head,
    .topbar,
    .ranking-item,
    .process-section-head {
        gap: 0.6rem;
    }
}
