:root {
    --brand: #0f766e;
    --brand-2: #159a9c;
    --brand-dark: #0b3d3a;
    --accent: #e76f51;
    --highlight: #f4b942;
    --sky: #2f80ed;
    --ink: #173b3a;
    --muted: #526a68;
    --line: #d5e5e1;
    --soft: #edf8f5;
    --paper: #ffffff;
    --warning: #f59e0b;
    --danger: #dc2626;
    --success: #16a34a;
    --radius: 18px;
    --shadow: 0 24px 70px rgba(15, 23, 42, 0.1);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background:
        linear-gradient(135deg, rgba(47, 128, 237, 0.08) 0%, transparent 32%),
        linear-gradient(315deg, rgba(231, 111, 81, 0.07) 0%, transparent 30%),
        linear-gradient(180deg, #f7fbff 0%, #eef8f5 52%, #ffffff 100%);
    font-family: Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Fallback ringan untuk class Bootstrap penting jika CDN sedang lambat/offline. */
.container { width: min(1140px, calc(100% - 24px)); margin-inline: auto; }
.row { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 1rem; }
.g-2 { gap: 0.5rem; }
.g-3 { gap: 1rem; }
.row > * { grid-column: span 12; min-width: 0; }
.col-6 { grid-column: span 6; }
.col-12 { grid-column: span 12; }
.d-flex { display: flex; }
.d-grid { display: grid; }
.flex-wrap { flex-wrap: wrap; }
.flex-column { flex-direction: column; }
.justify-content-between { justify-content: space-between; }
.justify-content-center { justify-content: center; }
.align-items-center { align-items: center; }
.align-items-start { align-items: flex-start; }
.align-self-start { align-self: flex-start; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 1rem; }
.w-100 { width: 100%; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.mt-auto { margin-top: auto; }
.p-4 { padding: 1.5rem; }
.p-md-5 { padding: 3rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 1rem; padding-bottom: 1rem; }
.px-4 { padding-left: 1.5rem; padding-right: 1.5rem; }
.ps-3 { padding-left: 1rem; }
.text-center { text-align: center; }
.text-uppercase { text-transform: uppercase; }
.text-decoration-none { text-decoration: none; }
.fw-bold { font-weight: 800; }
.small { font-size: 0.875rem; }
.h3 { font-size: 1.75rem; }
.h5 { font-size: 1.25rem; }
.h6 { font-size: 1rem; }
.text-muted { color: var(--muted); }
.text-success { color: var(--success); }
.text-dark { color: var(--ink); }
.text-white-50 { color: rgba(255, 255, 255, 0.68); }
.mx-auto { margin-left: auto; margin-right: auto; }
.table-responsive { width: 100%; overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { padding: 0.85rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table-hover tbody tr:hover { background: rgba(17, 107, 95, 0.04); }
.btn {
    border: 1px solid transparent;
    border-radius: 12px;
    padding: 0.58rem 0.9rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    text-decoration: none;
    cursor: pointer;
    line-height: 1.35;
    background: #ffffff;
    color: var(--ink);
    transition: 0.2s ease;
}
.btn-sm { padding: 0.42rem 0.7rem; font-size: 0.875rem; }
.btn-light { background: #ffffff; color: var(--brand); border-color: #ffffff; }
.btn-success { background: var(--success); color: #ffffff; border-color: var(--success); }
.btn-danger { background: var(--danger); color: #ffffff; border-color: var(--danger); }
.btn-warning { background: var(--warning); color: #111827; border-color: var(--warning); }
.btn-secondary { background: #64748b; color: #ffffff; border-color: #64748b; }
.btn-outline-light { background: transparent; color: #ffffff; border-color: rgba(255, 255, 255, 0.55); }
.btn-outline-primary { background: transparent; color: var(--accent); border-color: var(--accent); }
.btn-outline-success { background: transparent; color: var(--success); border-color: var(--success); }
.btn-outline-danger { background: transparent; color: var(--danger); border-color: var(--danger); }
.btn-outline-secondary { background: transparent; color: #475569; border-color: #94a3b8; }
.btn:hover { filter: brightness(0.97); transform: translateY(-1px); }
.alert { padding: 0.9rem 1rem; border-radius: 14px; border: 1px solid transparent; }
.alert-info { background: #eff6ff; color: #1e3a8a; border-color: #bfdbfe; }
.alert-success { background: #f0fdf4; color: #166534; border-color: #bbf7d0; }
.alert-warning { background: #fffbeb; color: #92400e; border-color: #fde68a; }
.alert-danger { background: #fef2f2; color: #991b1b; border-color: #fecaca; }
.badge {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 0.35rem 0.65rem;
    font-size: 0.78rem;
    font-weight: 800;
}
.rounded-pill { border-radius: 999px; }
.bg-light { background: #f8fafc; }
.text-bg-info { background: #e0f2fe; color: #075985; }
.text-bg-secondary { background: #e2e8f0; color: #334155; }
.text-bg-success { background: #dcfce7; color: #166534; }
.text-bg-danger { background: #fee2e2; color: #991b1b; }
.text-bg-warning { background: #fef3c7; color: #92400e; }
.border-0 { border: 0; }
.shadow-sm { box-shadow: 0 10px 25px rgba(15, 23, 42, 0.06); }

.document-status-badge {
    border: 1px solid transparent;
    font-weight: 800;
}

.document-status-verified {
    background: #e4f2e9;
    border-color: #b8d8c2;
    color: #28633f;
}

.document-status-pending {
    background: #fbf2dc;
    border-color: #e6cd91;
    color: #795d22;
}

.document-status-revision {
    background: #f8e8e2;
    border-color: #e2b8a9;
    color: #874b3c;
}

@media (min-width: 768px) {
    .col-md-3 { grid-column: span 3; }
    .col-md-4 { grid-column: span 4; }
    .col-md-6 { grid-column: span 6; }
    .flex-md-row { flex-direction: row; }
}

@media (min-width: 992px) {
    .col-lg-2 { grid-column: span 2; }
    .col-lg-3 { grid-column: span 3; }
    .col-lg-4 { grid-column: span 4; }
    .flex-lg-row { flex-direction: row; }
}

a {
    color: inherit;
}

img {
    max-width: 100%;
}

.app-frame {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 282px minmax(0, 1fr);
}

.desktop-sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    padding: 24px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 252, 251, 0.93));
    border-right: 1px solid rgba(148, 163, 184, 0.25);
    box-shadow: inset -4px 0 0 rgba(244, 185, 66, 0.16);
    backdrop-filter: blur(18px);
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.mobile-topbar {
    display: none;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.sidebar-brand img,
.brand-logo,
.auth-logo,
.phone-logo {
    object-fit: contain;
    background: #ffffff;
    border: 1px solid rgba(17, 107, 95, 0.12);
    box-shadow: 0 12px 30px rgba(17, 107, 95, 0.12);
}

.sidebar-brand img {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    padding: 8px;
}

.sidebar-brand strong {
    display: block;
    font-size: 0.98rem;
    line-height: 1.15;
}

.sidebar-brand span {
    color: var(--muted);
    font-size: 0.82rem;
}

.side-nav {
    display: grid;
    gap: 8px;
}

.side-nav a,
.side-nav button {
    width: 100%;
    border: 0;
    border-radius: 14px;
    padding: 12px 14px;
    background: transparent;
    color: #334155;
    text-align: left;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    transition: 0.2s ease;
}

.side-nav a:hover,
.side-nav a.active,
.side-nav button:hover {
    background: var(--soft);
    color: var(--brand);
}

.nav-mark {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--brand);
    background: rgba(17, 107, 95, 0.1);
    flex: 0 0 34px;
    font-size: 0.8rem;
}

.app-icon {
    width: 18px;
    height: 18px;
    display: block;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.sidebar-footer {
    margin-top: auto;
    padding: 16px;
    border-radius: 18px;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    color: #ffffff;
}

.sidebar-footer p {
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.88rem;
    line-height: 1.6;
}

.mobile-topbar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    color: var(--ink);
    text-decoration: none;
}

.mobile-topbar-brand img {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    object-fit: contain;
    padding: 6px;
    background: #ffffff;
    border: 1px solid rgba(15, 118, 110, 0.14);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
    flex: 0 0 42px;
}

.mobile-topbar-brand span {
    min-width: 0;
    display: grid;
    gap: 1px;
}

.mobile-topbar-brand strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.95rem;
    line-height: 1.15;
}

.mobile-topbar-brand small {
    color: var(--muted);
    font-weight: 700;
    font-size: 0.76rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mobile-logout {
    border: 0;
    border-radius: 14px;
    min-height: 42px;
    padding: 8px 10px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: var(--soft);
    color: var(--brand);
    font-weight: 900;
    text-decoration: none;
    flex: 0 0 auto;
}

.mobile-logout .app-icon {
    width: 17px;
    height: 17px;
}

.main-area {
    min-width: 0;
    padding: 28px;
}

.content-wrap {
    width: min(1160px, 100%);
    margin: 0 auto;
    padding-bottom: 64px;
}

.app-shell,
.panel,
.dashboard-card,
.auth-card,
.chat-card,
.preview-notes,
.phone-frame {
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.app-shell {
    overflow: hidden;
}

.hero-card,
.dashboard-hero {
    border-radius: 24px;
    padding: clamp(24px, 4vw, 44px);
    color: #ffffff;
    background:
        linear-gradient(118deg, rgba(11, 63, 57, 0.99) 0%, rgba(15, 118, 110, 0.96) 54%, rgba(47, 128, 237, 0.92) 100%),
        url("/images/logo.png") right 28px center / 190px no-repeat;
    box-shadow: 0 28px 80px rgba(15, 118, 110, 0.2), 0 10px 24px rgba(47, 128, 237, 0.08);
    position: relative;
    overflow: hidden;
}

.school-hero {
    background:
        linear-gradient(118deg, rgba(11, 61, 58, 0.99) 0%, rgba(15, 118, 110, 0.96) 54%, rgba(47, 128, 237, 0.92) 100%),
        url("/images/logo.png") right 30px center / 180px no-repeat;
}

.school-hero::before {
    content: "";
    position: absolute;
    top: 0;
    right: 26%;
    width: 7px;
    height: 100%;
    background: linear-gradient(180deg, rgba(244, 185, 66, 0.92), rgba(231, 111, 81, 0.62));
    transform: skewX(-18deg);
    opacity: 0.78;
}

.hero-card::after,
.dashboard-hero::after {
    content: "";
    position: absolute;
    right: -54px;
    bottom: -68px;
    width: 300px;
    height: 150px;
    border: 1px solid rgba(244, 185, 66, 0.42);
    background: linear-gradient(135deg, rgba(244, 185, 66, 0.26), rgba(231, 111, 81, 0.08));
    transform: rotate(-15deg);
    border-radius: 24px;
}

.dashboard-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 18px;
}

.hero-content,
.dashboard-hero > * {
    position: relative;
    z-index: 1;
}

.hero-eyebrow,
.section-kicker,
.mobile-label {
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.74rem;
    font-weight: 800;
}

.hero-card h1 {
    max-width: 680px;
    margin: 10px 0 12px;
    font-size: clamp(2rem, 5vw, 4.2rem);
    line-height: 1;
    font-weight: 900;
}

.hero-card p {
    max-width: 670px;
    margin: 0;
    color: rgba(255, 255, 255, 0.86);
    font-size: 1.05rem;
    line-height: 1.75;
}

.hero-actions,
.header-actions,
.action-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.hero-actions {
    margin-top: 24px;
}

.btn-brand {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--brand);
    --bs-btn-border-color: var(--brand);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--brand-dark);
    --bs-btn-hover-border-color: var(--brand-dark);
    --bs-btn-focus-shadow-rgb: 17, 107, 95;
    background: var(--brand);
    border-color: var(--brand);
    color: #ffffff;
    border-radius: 12px;
    font-weight: 800;
}

.btn-soft {
    border: 1px solid rgba(255, 255, 255, 0.28);
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
    border-radius: 12px;
    font-weight: 800;
    text-decoration: none;
    padding: 0.62rem 1rem;
}

.btn-soft:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.22);
}

.install-pill {
    border: 0;
    border-radius: 999px;
    padding: 0.75rem 1rem;
    background: #ffffff;
    color: var(--brand);
    border-top: 3px solid var(--highlight);
    font-weight: 900;
    box-shadow: 0 18px 35px rgba(15, 23, 42, 0.18);
}

.section-grid {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 18px;
    margin-top: 18px;
}

.info-card {
    grid-column: span 4;
    padding: 22px;
    border-radius: 18px;
    background: #ffffff;
    border: 1px solid rgba(148, 163, 184, 0.24);
    box-shadow: 0 14px 35px rgba(15, 23, 42, 0.06);
}

.info-card.wide {
    border-top: 4px solid var(--brand-2);
}

.section-grid > .info-card:not(.wide) {
    border-top: 4px solid var(--accent);
}

.info-card h2 {
    line-height: 1.18;
}

.info-card.wide {
    grid-column: span 8;
}

.info-card h2,
.info-card h3 {
    margin: 0 0 10px;
    font-weight: 900;
}

.info-card p,
.info-card li {
    color: var(--muted);
    line-height: 1.7;
}

.home-topics {
    margin-top: 22px;
}

.home-topics-heading {
    margin-bottom: 14px;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 18px;
}

.home-topics-heading h2 {
    margin: 0;
    font-size: 1.6rem;
    line-height: 1.2;
    font-weight: 900;
}

.home-topics-hint {
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 700;
    text-align: right;
}

.home-topic-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.home-topic-card {
    --topic-color: var(--brand);
    --topic-soft: #eaf7f4;
    min-width: 0;
    min-height: 132px;
    padding: 17px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid rgba(148, 163, 184, 0.24);
    color: var(--ink);
    text-decoration: none;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: auto 1fr;
    gap: 14px 10px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.home-topic-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 4px;
    background: var(--topic-color);
}

.home-topic-card:hover {
    color: var(--ink);
    transform: translateY(-3px);
    border-color: color-mix(in srgb, var(--topic-color) 32%, #cbd5e1);
    box-shadow: 0 20px 44px rgba(15, 23, 42, 0.1);
}

.home-topic-card:focus-visible {
    outline: 3px solid color-mix(in srgb, var(--topic-color) 30%, transparent);
    outline-offset: 3px;
}

.home-topic-card strong {
    min-width: 0;
    align-self: end;
    font-size: 1rem;
    line-height: 1.28;
    overflow-wrap: anywhere;
}

.home-topic-icon,
.home-topic-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--topic-color);
    background: var(--topic-soft);
}

.home-topic-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
}

.home-topic-icon .app-icon {
    width: 21px;
    height: 21px;
}

.home-topic-arrow {
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: center;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    transition: transform 0.2s ease;
}

.home-topic-arrow .app-icon {
    width: 16px;
    height: 16px;
}

.home-topic-card:hover .home-topic-arrow {
    transform: translateX(3px);
}

.home-topic-card--major {
    --topic-color: #b7791f;
    --topic-soft: #fff8e6;
}

.home-topic-card--profile {
    --topic-color: #2f80ed;
    --topic-soft: #eff6ff;
}

.home-topic-card--flow {
    --topic-color: #15803d;
    --topic-soft: #edf9f0;
}

.home-topic-card--document {
    --topic-color: #b45309;
    --topic-soft: #fff7e8;
}

.quick-link-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.quick-link {
    min-height: 110px;
    padding: 16px;
    border-radius: 16px;
    background: #f8fafc;
    border: 1px solid rgba(148, 163, 184, 0.22);
    text-decoration: none;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: 0.2s ease;
}

.quick-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.09);
    border-color: rgba(17, 107, 95, 0.28);
}

.link-icon {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(17, 107, 95, 0.1);
    color: var(--brand);
    font-weight: 900;
}

.link-icon .app-icon {
    width: 20px;
    height: 20px;
}

.document-card {
    background:
        linear-gradient(180deg, #ffffff 0%, #f4fbf8 100%);
}

.clean-list {
    list-style: none;
    padding-left: 0;
    display: grid;
    gap: 10px;
}

.clean-list li {
    color: #334155;
    display: flex;
    align-items: center;
    gap: 10px;
}

.clean-list li::before {
    content: "";
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: var(--brand);
    box-shadow: 0 0 0 4px rgba(15, 118, 110, 0.12);
    flex: 0 0 10px;
}

.major-card {
    padding: 20px;
    border-radius: 18px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
}

.major-card:nth-child(2) {
    background: linear-gradient(135deg, #14532d, var(--brand));
}

.step-list {
    display: grid;
    gap: 12px;
}

.step-item,
.preview-list div {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.step-number,
.preview-list strong {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    background: var(--soft);
    color: var(--brand);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    flex: 0 0 36px;
}

.timeline-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.timeline-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 16px;
    border-radius: 16px;
    background: #f8fafc;
    border: 1px solid rgba(148, 163, 184, 0.2);
}

.timeline-item > span {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 36px;
    background: var(--brand);
    color: #ffffff;
    font-weight: 900;
    box-shadow: 0 10px 22px rgba(15, 118, 110, 0.2);
}

.timeline-item strong {
    display: block;
    margin-bottom: 4px;
}

.timeline-item p {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.ppdb-info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.ppdb-info-grid > div {
    padding: 18px;
    border-radius: 16px;
    background: #f8fafc;
    border: 1px solid rgba(148, 163, 184, 0.2);
}

.ppdb-info-grid span {
    width: 40px;
    height: 40px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--brand);
    background: var(--soft);
    margin-bottom: 12px;
}

.ppdb-info-grid strong {
    display: block;
    margin-bottom: 6px;
}

.ppdb-info-grid p {
    margin: 0;
    color: var(--muted);
    line-height: 1.65;
}

.dashboard-card,
.panel {
    padding: 20px;
}

.stat-box {
    min-height: 132px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.stat-box strong {
    font-size: 2.3rem;
    line-height: 1;
    font-weight: 900;
    color: var(--brand);
}

.step-pill {
    min-height: 124px;
    border: 1px solid rgba(148, 163, 184, 0.22);
    background: #f8fafc;
    border-radius: 16px;
    padding: 14px;
    display: grid;
    gap: 5px;
}

.step-pill span {
    width: 32px;
    height: 32px;
    border-radius: 11px;
    background: #e2e8f0;
    color: #475569;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.step-pill.done {
    background: #effaf4;
    border-color: rgba(22, 163, 74, 0.24);
}

.step-pill.done span {
    background: var(--success);
    color: #ffffff;
}

.form-control,
.form-select {
    width: 100%;
    display: block;
    padding: 0.62rem 0.78rem;
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #cbd5e1;
    border-color: #cbd5e1;
    min-height: 44px;
}

.form-label {
    display: inline-block;
    margin-bottom: 0.38rem;
    font-weight: 800;
    color: #334155;
}

.form-text {
    color: var(--muted);
    font-size: 0.86rem;
}

.registration-file-status {
    display: flex;
    align-items: center;
    gap: 7px;
    min-height: 25px;
    margin-top: 7px;
    color: #718582;
    font-size: 0.82rem;
}

.registration-file-picker {
    display: flex;
    align-items: center;
    min-height: 48px;
    overflow: hidden;
    border: 1px solid #c7d9d6;
    border-radius: 12px;
    background: #ffffff;
}

.registration-file-button {
    flex: 0 0 auto;
    align-self: stretch;
    display: inline-flex;
    align-items: center;
    padding: 0 15px;
    border-right: 1px solid #c7d9d6;
    background: #f1f8f6;
    color: var(--brand);
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 800;
}

.registration-file-button:hover {
    background: #e4f2ee;
}

.registration-file-name {
    min-width: 0;
    padding: 0 13px;
    overflow: hidden;
    color: #718582;
    font-size: 0.9rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.registration-file-input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.registration-file-status.is-saved,
.registration-file-status.is-selected {
    width: fit-content;
    padding: 5px 9px;
    border: 1px solid #b8ddca;
    border-radius: 999px;
    background: #effaf3;
    color: #247044;
    font-weight: 700;
}

.registration-file-status.is-selected {
    border-color: #9fcbd0;
    background: #edfafa;
    color: #126b70;
}

.file-status-check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #2f9d62;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 900;
    line-height: 1;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--brand);
    box-shadow: 0 0 0 0.22rem rgba(17, 107, 95, 0.14);
}

.registration-form-grid {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 20px 22px;
}

.registration-form-grid > * {
    grid-column: span 12;
    width: auto;
    min-width: 0;
}

.registration-form-grid > .col-md-4 {
    grid-column: span 4;
}

.registration-form-grid > .col-md-6 {
    grid-column: span 6;
}

.registration-form-grid .form-control,
.registration-form-grid .form-select {
    width: 100%;
}

.registration-form-grid .form-label {
    line-height: 1.35;
}

@media (max-width: 767px) {
    .registration-form-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .registration-form-grid > .col-md-4,
    .registration-form-grid > .col-md-6 {
        grid-column: span 1;
    }
}

.registration-filters {
    display: grid;
    grid-template-columns: minmax(260px, 1.45fr) minmax(190px, 1fr) minmax(210px, 1.15fr) minmax(128px, 0.58fr);
    gap: 14px;
    align-items: end;
    padding: 18px;
    border: 1px solid rgba(15, 118, 110, 0.12);
    border-radius: 18px;
    background: linear-gradient(135deg, #f8fcfb 0%, #f5f9ff 100%);
}

.registration-filters .filter-field {
    min-width: 0;
}

.registration-filters label {
    display: block;
    margin: 0 0 7px;
    color: #31504e;
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.registration-filters .filter-control {
    min-height: 48px;
    border-color: #c7d9d6;
    box-shadow: 0 5px 14px rgba(15, 118, 110, 0.04);
}

.registration-filters .filter-control::placeholder {
    color: #819593;
}

.registration-filters .filter-submit-wrap {
    display: flex;
    min-width: 0;
}

.registration-filters .filter-submit {
    width: 100%;
    min-height: 48px;
    font-weight: 900;
    box-shadow: 0 9px 18px rgba(15, 118, 110, 0.16);
}

.registration-filters .filter-reset-row {
    grid-column: 1 / -1;
    padding-top: 1px;
}

.registration-filters .filter-reset {
    color: var(--brand);
    font-size: 0.86rem;
    font-weight: 800;
    text-decoration: none;
}

.registration-filters .filter-reset:hover {
    text-decoration: underline;
}

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

    .registration-filters .filter-submit-wrap {
        align-items: end;
    }
}

@media (max-width: 640px) {
    .registration-filters {
        grid-template-columns: 1fr;
        gap: 12px;
        padding: 14px;
    }

    .registration-filters .filter-reset-row {
        grid-column: auto;
    }
}

.table {
    --bs-table-bg: transparent;
}

.table thead th {
    color: #475569;
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.auth-shell {
    min-height: 100vh;
    padding: 24px;
    display: grid;
    place-items: center;
}

.auth-card {
    width: min(520px, 100%);
    padding: clamp(24px, 5vw, 38px);
}

.auth-logo {
    width: 70px;
    height: 70px;
    border-radius: 20px;
    padding: 10px;
    margin-bottom: 18px;
}

.auth-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border-radius: 999px;
    padding: 8px 12px;
    background: var(--soft);
    color: var(--brand);
    font-size: 0.8rem;
    font-weight: 900;
    margin-bottom: 12px;
}

.auth-card h1 {
    font-weight: 900;
    margin-bottom: 8px;
}

.auth-card p,
.auth-links,
.hint-box {
    color: var(--muted);
}

.auth-links {
    margin-top: 14px;
    text-align: center;
}

.auth-links a {
    color: var(--brand);
    font-weight: 800;
    text-decoration: none;
}

.hint-box {
    margin-top: 16px;
    padding: 12px 14px;
    border-radius: 14px;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    font-size: 0.88rem;
}

.mobile-nav {
    display: none;
}

.mobile-preview-shell {
    display: grid;
    grid-template-columns: 380px minmax(0, 1fr);
    gap: 24px;
    align-items: center;
}

.phone-frame {
    min-height: 650px;
    padding: 14px;
    border-radius: 34px;
    background: linear-gradient(180deg, #0f2f2b 0%, #071f1d 100%);
    color: #ffffff;
    box-shadow: 0 28px 70px rgba(15, 23, 42, 0.24);
}

.phone-screen {
    height: 100%;
    min-height: 620px;
    border-radius: 26px;
    overflow: hidden;
    background:
        radial-gradient(circle at top right, rgba(31, 143, 126, 0.14), transparent 34%),
        linear-gradient(180deg, #f7fbf9 0%, #ffffff 58%);
    color: var(--ink);
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.phone-status {
    display: flex;
    justify-content: space-between;
    font-size: 0.82rem;
    color: #475569;
}

.phone-hero {
    padding: 16px;
    border-radius: 20px;
    background: linear-gradient(135deg, #0f5f55 0%, #1f8f7e 100%);
    color: #ffffff;
    display: flex;
    gap: 12px;
    align-items: center;
    box-shadow: 0 18px 34px rgba(17, 107, 95, 0.2);
}

.phone-hero.compact {
    min-height: 96px;
}

.phone-logo {
    width: 58px;
    height: 58px;
    border-radius: 18px;
    padding: 8px;
}

.phone-hero p,
.phone-hero h1 {
    margin: 0;
}

.phone-hero h1 {
    font-size: 1.02rem;
    font-weight: 900;
}

.phone-card {
    padding: 14px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid rgba(148, 163, 184, 0.2);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.07);
}

.phone-card strong {
    display: block;
    font-size: 1.18rem;
}

.phone-status-card {
    background: #f0fbf7;
    border-color: rgba(17, 107, 95, 0.14);
}

.phone-action-grid,
.phone-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.phone-action,
.phone-grid a {
    min-height: 92px;
    padding: 13px;
    border-radius: 16px;
    background: #ffffff;
    color: var(--brand);
    font-weight: 900;
    text-decoration: none;
    border: 1px solid rgba(148, 163, 184, 0.2);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: space-between;
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.055);
    transition: 0.2s ease;
}

.phone-action:hover {
    transform: translateY(-2px);
    border-color: rgba(17, 107, 95, 0.28);
}

.phone-action span {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--soft);
    color: var(--brand);
}

.phone-action.primary {
    background: var(--brand);
    color: #ffffff;
    border-color: var(--brand);
}

.phone-action.primary span {
    background: rgba(255, 255, 255, 0.16);
    color: #ffffff;
}

.compact-steps {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin-top: 10px;
}

.compact-steps div {
    min-width: 0;
    padding: 10px 6px;
    border-radius: 14px;
    background: #f8fafc;
    border: 1px solid rgba(148, 163, 184, 0.18);
    text-align: center;
}

.compact-steps span {
    width: 26px;
    height: 26px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--soft);
    color: var(--brand);
    font-size: 0.82rem;
    font-weight: 900;
    margin-bottom: 6px;
}

.compact-steps strong {
    display: block;
    font-size: 0.74rem;
    color: #334155;
}

.preview-notes {
    padding: clamp(24px, 4vw, 36px);
}

.preview-list {
    display: grid;
    gap: 14px;
    margin-top: 20px;
}

.presentation-panel {
    align-self: stretch;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.presentation-panel h1 {
    max-width: 720px;
    font-size: clamp(1.85rem, 3vw, 2.75rem);
    line-height: 1.08;
}

.presentation-panel > p {
    max-width: 760px;
    font-size: 1rem;
    line-height: 1.8;
}

.presentation-list {
    display: grid;
    gap: 14px;
    margin-top: 22px;
}

.presentation-list > div {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 16px;
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 16px;
    background: #f8fafc;
}

.presentation-list > div > span {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 42px;
    color: var(--brand);
    background: var(--soft);
}

.presentation-list strong {
    display: block;
    margin-bottom: 4px;
}

.presentation-list p {
    margin: 0;
    color: var(--muted);
    line-height: 1.65;
}

.presentation-note {
    margin-top: 20px;
    padding: 16px;
    border-left: 4px solid var(--brand);
    border-radius: 14px;
    background: #f0fbf7;
    color: #164e45;
    line-height: 1.65;
}

.install-guide-card {
    background: linear-gradient(180deg, #f0fbf7 0%, #ffffff 100%) !important;
    border-color: rgba(15, 118, 110, 0.22) !important;
}

.install-status {
    display: block;
    margin-top: 10px;
    color: var(--muted);
    line-height: 1.55;
}

.install-dialog-backdrop {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: grid;
    place-items: center;
    padding: 18px;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(6px);
}

.install-dialog {
    width: min(480px, 100%);
    padding: 24px;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 30px 80px rgba(15, 23, 42, 0.28);
    position: relative;
}

.install-dialog h2 {
    margin: 0 0 14px;
    font-weight: 900;
    line-height: 1.15;
}

.install-dialog-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 12px;
    background: var(--soft);
    color: var(--brand);
    font-weight: 900;
}

.install-steps {
    margin: 0 0 18px;
    padding-left: 1.2rem;
    color: #334155;
    line-height: 1.75;
}

.install-steps li + li {
    margin-top: 8px;
}

.chat-page {
    min-height: calc(100vh - 56px);
    display: grid;
    gap: 18px;
}

.chat-card {
    overflow: hidden;
}

.chat-header {
    padding: 24px;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    color: #ffffff;
}

.chat-messages,
.floating-chat-messages {
    background: #f8fafc;
    overflow-y: auto;
}

.chat-messages {
    height: min(58vh, 520px);
    padding: 20px;
}

.chat-empty {
    min-height: 100%;
    display: grid;
    place-items: center;
    text-align: center;
    color: var(--muted);
}

.chat-input-area {
    padding: 14px;
    background: #ffffff;
    border-top: 1px solid var(--line);
}

.chat-form {
    display: flex;
    gap: 10px;
}

.message-user,
.message-assistant {
    display: flex;
    margin-bottom: 12px;
}

.message-user {
    justify-content: flex-end;
}

.message-assistant {
    justify-content: flex-start;
}

.message-content {
    max-width: min(78%, 620px);
    border-radius: 16px;
    padding: 11px 13px;
    line-height: 1.6;
    white-space: pre-wrap;
    word-break: break-word;
}

.message-user .message-content {
    background: var(--brand);
    color: #ffffff;
    border-bottom-right-radius: 5px;
}

.message-assistant .message-content {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-bottom-left-radius: 5px;
}

.loading-dots {
    display: inline-flex;
    gap: 5px;
    align-items: center;
    padding: 12px;
}

.loading-dots span {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: #94a3b8;
    animation: chatBounce 1s ease-in-out infinite;
}

.loading-dots span:nth-child(2) {
    animation-delay: 0.15s;
}

.loading-dots span:nth-child(3) {
    animation-delay: 0.3s;
}

@keyframes chatBounce {
    0%, 100% { transform: translateY(0); opacity: 0.55; }
    50% { transform: translateY(-5px); opacity: 1; }
}

.chat-widget {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 1050;
}

.chat-toggle {
    width: 58px;
    height: 58px;
    border: 0;
    border-radius: 999px;
    background: var(--brand);
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 45px rgba(17, 107, 95, 0.28);
}

.chat-popup {
    position: absolute;
    right: 0;
    bottom: 74px;
    width: min(390px, calc(100vw - 32px));
    height: 520px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 20px;
    background: #ffffff;
    border: 1px solid rgba(148, 163, 184, 0.28);
    box-shadow: 0 28px 80px rgba(15, 23, 42, 0.22);
}

.chat-popup.is-hidden {
    display: none;
}

.chat-popup-header {
    padding: 14px 16px;
    background: var(--brand);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.chat-popup-header h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 900;
}

.chat-close {
    border: 0;
    border-radius: 10px;
    width: 34px;
    height: 34px;
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
}

.floating-chat-messages {
    flex: 1;
    padding: 14px;
}

.floating-chat-form {
    padding: 12px;
    border-top: 1px solid var(--line);
    display: flex;
    gap: 8px;
}

.floating-chat-form .form-control {
    min-height: 42px;
}

.send-button {
    width: 46px;
    flex: 0 0 46px;
    border: 0;
    border-radius: 12px;
    background: var(--brand);
    color: #ffffff;
    font-weight: 900;
}

@media (max-width: 1080px) {
    .app-frame {
        grid-template-columns: 1fr;
    }

    .desktop-sidebar {
        display: none;
    }

    .mobile-topbar {
        position: sticky;
        top: 0;
        z-index: 1035;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 10px;
        padding: 10px 12px;
        background: rgba(255, 255, 255, 0.96);
        border-bottom: 1px solid rgba(148, 163, 184, 0.22);
        backdrop-filter: blur(16px);
        box-shadow: 0 14px 34px rgba(15, 23, 42, 0.06);
    }

    .main-area {
        padding: 14px;
    }

    .content-wrap {
        padding-bottom: 104px;
    }

    .mobile-nav {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 1040;
        display: grid;
        grid-template-columns: repeat(5, minmax(0, 1fr));
        gap: 6px;
        min-height: 74px;
        padding: 8px 10px calc(8px + env(safe-area-inset-bottom));
        background: rgba(255, 255, 255, 0.97);
        border-top: 1px solid rgba(148, 163, 184, 0.26);
        backdrop-filter: blur(16px);
        box-shadow: 0 -18px 46px rgba(15, 23, 42, 0.1);
    }

    .mobile-nav a {
        min-width: 0;
        min-height: 56px;
        border-radius: 15px;
        padding: 6px 3px 6px;
        color: #64748b;
        text-decoration: none;
        display: grid;
        justify-items: center;
        align-content: center;
        gap: 3px;
        font-size: 0.65rem;
        font-weight: 850;
        line-height: 1.08;
        text-align: center;
        position: relative;
        transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
    }

    .mobile-nav a > span:last-child {
        display: block;
        max-width: 100%;
        min-height: 1.25em;
        overflow-wrap: anywhere;
    }

    .mobile-nav a.active {
        color: var(--brand);
        background: var(--soft);
        box-shadow: inset 0 0 0 1px rgba(15, 118, 110, 0.16);
    }

    .mobile-nav a.active::after {
        content: "";
        width: 20px;
        height: 3px;
        border-radius: 999px;
        background: var(--brand);
        position: absolute;
        bottom: 4px;
        left: 50%;
        transform: translateX(-50%);
    }

    .mobile-nav .nav-icon,
    .mobile-nav .fab-icon {
        width: 30px;
        height: 30px;
        border-radius: 11px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        background: rgba(15, 118, 110, 0.1);
        color: var(--brand);
        font-size: 0.74rem;
        font-weight: 900;
    }

    .mobile-nav .nav-icon .app-icon,
    .mobile-nav .fab-icon .app-icon {
        width: 16px;
        height: 16px;
    }

    .mobile-nav .nav-fab {
        transform: none;
        background: var(--brand);
        color: #ffffff;
        box-shadow: 0 14px 28px rgba(15, 118, 110, 0.22);
    }

    .mobile-nav .nav-fab .fab-icon {
        background: rgba(255, 255, 255, 0.18);
        color: #ffffff;
    }

    .admin-hero {
        padding: 20px;
        border-radius: 22px;
        gap: 14px;
    }

    .admin-hero h1 {
        font-size: 1.55rem;
    }

    .admin-hero p {
        font-size: 0.92rem;
    }

    .admin-hero .d-flex {
        width: 100%;
    }

    .admin-hero .btn {
        flex: 1;
        min-height: 40px;
        white-space: nowrap;
    }

    .admin-stats {
        gap: 10px;
    }

    .admin-stats > .col-md-3 {
        grid-column: span 6;
    }

    .admin-stats .dashboard-card {
        padding: 14px;
        border-radius: 16px;
    }

    .admin-stats .stat-box {
        min-height: 84px;
    }

    .admin-stats .stat-box span {
        font-size: 0.82rem;
    }

    .admin-stats .stat-box strong {
        font-size: 1.8rem;
    }
}

@media (max-width: 900px) {
    .section-grid,
    .mobile-preview-shell {
        grid-template-columns: 1fr;
    }

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

    .info-card,
    .info-card.wide {
        grid-column: auto;
    }

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

    .timeline-grid,
    .ppdb-info-grid {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 640px) {
    .main-area {
        padding: 8px 8px 0;
    }

    .mobile-topbar {
        padding: 7px 9px;
    }

    .mobile-topbar-brand img {
        width: 34px;
        height: 34px;
        border-radius: 11px;
        flex-basis: 34px;
        padding: 5px;
    }

    .mobile-topbar-brand {
        gap: 8px;
    }

    .mobile-topbar-brand strong {
        font-size: 0.88rem;
    }

    .mobile-topbar-brand small {
        font-size: 0.68rem;
    }

    .mobile-logout {
        min-height: 34px;
        border-radius: 12px;
        padding: 6px 8px;
        font-size: 0.73rem;
        gap: 5px;
    }

    .mobile-logout .app-icon {
        width: 15px;
        height: 15px;
    }

    .admin-hero {
        padding: 14px;
        margin-bottom: 10px;
    }

    .admin-hero h1 {
        font-size: 1.28rem;
    }

    .admin-hero p {
        font-size: 0.84rem;
    }

    .admin-hero .d-flex {
        gap: 6px;
    }

    .hero-card,
    .dashboard-hero {
        border-radius: 16px;
        padding: 14px;
        background:
            linear-gradient(135deg, rgba(11, 63, 57, 0.98), rgba(17, 107, 95, 0.94)),
            url("/images/logo.png") right -28px top 14px / 118px no-repeat;
    }

    .hero-card h1 {
        font-size: 1.5rem;
        line-height: 1.08;
        margin: 6px 0 8px;
        max-width: 250px;
    }

    .hero-card p {
        display: -webkit-box;
        max-width: 100%;
        overflow: hidden;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 3;
        font-size: 0.82rem;
        line-height: 1.42;
    }

    .hero-eyebrow,
    .section-kicker,
    .mobile-label {
        font-size: 0.65rem;
        letter-spacing: 0.1em;
    }

    .hero-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
        margin-top: 11px;
    }

    .hero-actions .btn,
    .hero-actions .btn-soft,
    .hero-actions .install-pill {
        width: 100%;
        min-height: 40px;
        padding: 0.55rem 0.62rem;
        border-radius: 11px;
        font-size: 0.78rem;
        text-align: center;
    }

    .section-grid {
        gap: 10px;
        margin-top: 10px;
    }

    .home-topics {
        margin-top: 14px;
    }

    .home-topics-heading {
        margin-bottom: 10px;
        align-items: flex-start;
        flex-direction: column;
        gap: 3px;
    }

    .home-topics-heading h2 {
        font-size: 1.15rem;
    }

    .home-topics-hint {
        font-size: 0.78rem;
        text-align: left;
    }

    .home-topic-grid {
        gap: 8px;
    }

    .home-topic-card {
        min-height: 104px;
        padding: 12px;
        border-radius: 14px;
        gap: 9px 6px;
    }

    .home-topic-card strong {
        font-size: 0.84rem;
        line-height: 1.2;
    }

    .home-topic-icon {
        width: 36px;
        height: 36px;
        border-radius: 11px;
    }

    .home-topic-icon .app-icon {
        width: 18px;
        height: 18px;
    }

    .home-topic-arrow {
        width: 29px;
        height: 29px;
    }

    .home-topic-arrow .app-icon {
        width: 14px;
        height: 14px;
    }

    .quick-link-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
        margin-top: 12px !important;
    }

    .quick-link {
        min-height: 66px;
        padding: 9px;
        border-radius: 13px;
        gap: 7px;
        font-size: 0.86rem;
    }

    .link-icon {
        width: 34px;
        height: 34px;
        border-radius: 11px;
    }

    .link-icon .app-icon {
        width: 17px;
        height: 17px;
    }

    .dashboard-card,
    .panel,
    .info-card {
        padding: 13px;
        border-radius: 14px;
    }

    .info-card h2,
    .info-card h3 {
        margin-bottom: 6px;
        line-height: 1.15;
    }

    .info-card p,
    .info-card li {
        font-size: 0.88rem;
        line-height: 1.48;
    }

    .clean-list {
        gap: 7px;
    }

    .major-card {
        padding: 13px;
        border-radius: 14px;
        margin-bottom: 8px !important;
    }

    .timeline-grid,
    .ppdb-info-grid {
        gap: 8px;
        margin-top: 10px !important;
    }

    .timeline-item {
        gap: 9px;
        padding: 11px;
        border-radius: 13px;
    }

    .timeline-item > span {
        width: 30px;
        height: 30px;
        flex-basis: 30px;
        border-radius: 10px;
        font-size: 0.82rem;
    }

    .timeline-item strong,
    .ppdb-info-grid strong {
        font-size: 0.9rem;
        margin-bottom: 2px;
    }

    .timeline-item p,
    .ppdb-info-grid p {
        font-size: 0.82rem;
        line-height: 1.42;
    }

    .ppdb-info-grid > div {
        padding: 12px;
        border-radius: 13px;
        display: grid;
        grid-template-columns: 34px minmax(0, 1fr);
        column-gap: 9px;
        align-items: start;
    }

    .ppdb-info-grid span {
        width: 34px;
        height: 34px;
        border-radius: 11px;
        margin: 0;
        grid-row: span 2;
    }

    .stat-box {
        min-height: 84px;
    }

    .stat-box strong {
        font-size: 1.85rem;
    }

    .step-pill {
        min-height: 86px;
        padding: 11px;
        border-radius: 13px;
    }

    .step-pill span {
        width: 28px;
        height: 28px;
        border-radius: 10px;
        font-size: 0.82rem;
    }

    .step-pill p {
        font-size: 0.82rem;
        line-height: 1.35;
    }

    .phone-frame {
        min-height: auto;
        padding: 10px;
        border-radius: 26px;
    }

    .phone-screen {
        min-height: auto;
        padding: 11px;
        border-radius: 20px;
        gap: 8px;
    }

    .phone-status {
        font-size: 0.72rem;
    }

    .phone-hero,
    .phone-hero.compact {
        min-height: auto;
        padding: 11px;
        border-radius: 15px;
        gap: 9px;
    }

    .phone-logo {
        width: 44px;
        height: 44px;
        border-radius: 14px;
        padding: 6px;
    }

    .phone-hero h1 {
        font-size: 0.88rem;
    }

    .phone-card {
        padding: 10px;
        border-radius: 13px;
    }

    .phone-card strong {
        font-size: 1rem;
    }

    .phone-action-grid,
    .phone-grid {
        gap: 7px;
    }

    .phone-action,
    .phone-grid a {
        min-height: 66px;
        padding: 9px;
        border-radius: 13px;
        font-size: 0.84rem;
    }

    .phone-action span {
        width: 29px;
        height: 29px;
        border-radius: 10px;
    }

    .compact-steps {
        gap: 6px;
        margin-top: 7px;
    }

    .compact-steps div {
        padding: 7px 4px;
        border-radius: 11px;
    }

    .compact-steps span {
        width: 22px;
        height: 22px;
        border-radius: 8px;
        font-size: 0.72rem;
        margin-bottom: 4px;
    }

    .compact-steps strong {
        font-size: 0.7rem;
    }

    .dashboard-card .table th,
    .dashboard-card .table td {
        padding: 0.62rem;
        font-size: 0.84rem;
    }

    .dashboard-card .badge {
        font-size: 0.7rem;
        padding: 0.28rem 0.48rem;
    }

    .message-content {
        max-width: 88%;
    }

    .chat-widget {
        right: 12px;
        bottom: 78px;
    }

    .chat-popup {
        right: -2px;
        bottom: 70px;
        height: min(520px, calc(100vh - 170px));
    }
}

@media (max-width: 390px) {
    .mobile-nav {
        gap: 4px;
        padding-inline: 6px;
    }

    .mobile-nav a {
        border-radius: 14px;
        font-size: 0.59rem;
        padding-inline: 2px;
    }

    .mobile-nav .nav-icon,
    .mobile-nav .fab-icon {
        width: 28px;
        height: 28px;
        border-radius: 10px;
    }

    .mobile-nav .nav-icon .app-icon,
    .mobile-nav .fab-icon .app-icon {
        width: 15px;
        height: 15px;
    }
}
