body {
    --bg: #f4f7fb;
    --surface: rgba(255, 255, 255, 0.84);
    --surface-strong: #ffffff;
    --surface-soft: #edf4ff;
    --border: rgba(148, 163, 184, 0.22);
    --text: #14213d;
    --muted: #5b6b84;
    --primary: #1565d8;
    --primary-deep: #0f3f95;
    --accent: #10b981;
    --accent-soft: rgba(16, 185, 129, 0.14);
    --hero-start: #f7fbff;
    --hero-end: #e7f0ff;
    --shadow: 0 24px 60px rgba(15, 23, 42, 0.08);
    --shadow-soft: 0 14px 30px rgba(15, 23, 42, 0.05);
    background:
        radial-gradient(circle at top left, rgba(21, 101, 216, 0.1), transparent 28%),
        radial-gradient(circle at top right, rgba(16, 185, 129, 0.08), transparent 22%),
        linear-gradient(180deg, #f8fbff 0%, var(--bg) 40%, #edf2f9 100%);
    color: var(--text);
    font-family: "Manrope", "Segoe UI", sans-serif;
}

.frontend-body {
    min-height: 100vh;
}

h1,
h2,
h3,
h4,
h5,
h6,
.site-logo,
.section-title,
.hero-title {
    font-family: "Space Grotesk", "Manrope", sans-serif;
}

a {
    transition: color 0.22s ease, opacity 0.22s ease, transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease, background-color 0.22s ease;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 1030;
    backdrop-filter: blur(18px);
}

.site-header.is-scrolled .site-header-shell {
    transform: translateY(0);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
}

.site-header-aurora {
    position: absolute;
    inset: 0 auto auto 0;
    pointer-events: none;
    filter: blur(30px);
    opacity: 0.75;
}

.site-header-aurora-one {
    width: 280px;
    height: 140px;
    background: rgba(21, 101, 216, 0.18);
    top: -30px;
    left: 8%;
    animation: drift 8s ease-in-out infinite;
}

.site-header-aurora-two {
    width: 220px;
    height: 140px;
    background: rgba(16, 185, 129, 0.16);
    top: 18px;
    right: 10%;
    left: auto;
    animation: drift 9s ease-in-out infinite reverse;
}

.site-header-shell {
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 1.7rem;
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
    padding: 1rem 1.1rem;
    transition: box-shadow 0.24s ease, transform 0.24s ease, background-color 0.24s ease;
}

.header-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 1rem;
}

.brand-lockup {
    display: inline-flex;
    align-items: center;
    gap: 0.95rem;
    min-width: 0;
}

.brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 1rem;
    background:
        linear-gradient(145deg, rgba(21, 101, 216, 0.18), rgba(16, 185, 129, 0.14)),
        #fff;
    border: 1px solid rgba(21, 101, 216, 0.18);
    color: var(--primary-deep);
    font-family: "Space Grotesk", sans-serif;
    font-weight: 700;
    letter-spacing: 0.08em;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.site-logo {
    color: var(--text);
    font-size: 1.65rem;
    font-weight: 700;
    line-height: 1.05;
}

.site-tagline {
    color: var(--muted);
    font-size: 0.9rem;
}

.header-search {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) 190px auto;
    gap: 0.75rem;
    align-items: center;
    width: min(760px, 100%);
}

.header-search-field,
.header-search-select {
    position: relative;
}

.header-search .form-control,
.header-search .form-select {
    min-height: 3rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.28);
    background: rgba(255, 255, 255, 0.88);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.header-search-button,
.hero-card .btn-primary,
.btn-primary {
    border: 0;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-deep) 100%);
    box-shadow: 0 16px 28px rgba(21, 101, 216, 0.24);
}

.header-search-button:hover,
.hero-card .btn-primary:hover,
.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 18px 34px rgba(21, 101, 216, 0.28);
}

.site-nav {
    border-top: 1px solid rgba(148, 163, 184, 0.14);
    padding-top: 0.95rem;
}

.nav-toggle {
    border: 1px solid rgba(21, 101, 216, 0.2);
    border-radius: 999px;
    padding: 0.5rem 0.85rem;
    background: rgba(255, 255, 255, 0.85);
}

.nav-pill-row {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
}

.nav-pill-row .nav-link {
    position: relative;
    padding: 0.7rem 1rem;
    border-radius: 999px;
    color: var(--muted);
    font-weight: 700;
    font-size: 0.92rem;
}

.nav-pill-row .nav-link::after {
    content: "";
    position: absolute;
    inset: auto 18px 10px;
    height: 2px;
    border-radius: 999px;
    transform: scaleX(0);
    transform-origin: center;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transition: transform 0.22s ease;
}

.nav-pill-row .nav-link:hover,
.nav-pill-row .nav-link.active {
    color: var(--text);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.06);
}

.nav-pill-row .nav-link:hover::after,
.nav-pill-row .nav-link.active::after {
    transform: scaleX(1);
}

.nav-cta .btn {
    border-radius: 999px;
}

.hero-card,
.content-card,
.stats-card,
.admin-card,
.sidebar-card {
    position: relative;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 1.5rem;
    backdrop-filter: blur(14px);
    box-shadow: var(--shadow-soft);
}

.hero-card-enhanced {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.92) 0%, rgba(239, 247, 255, 0.94) 62%, rgba(227, 245, 239, 0.9) 100%);
    box-shadow: var(--shadow);
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(21, 101, 216, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(21, 101, 216, 0.05) 1px, transparent 1px);
    background-size: 34px 34px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent 100%);
    pointer-events: none;
}

.hero-orb {
    position: absolute;
    border-radius: 999px;
    filter: blur(8px);
    opacity: 0.75;
}

.hero-orb-one {
    width: 180px;
    height: 180px;
    right: 9%;
    top: 12%;
    background: radial-gradient(circle, rgba(21, 101, 216, 0.28) 0%, rgba(21, 101, 216, 0) 72%);
    animation: floatOrb 7s ease-in-out infinite;
}

.hero-orb-two {
    width: 150px;
    height: 150px;
    right: 22%;
    bottom: -14px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.2) 0%, rgba(16, 185, 129, 0) 74%);
    animation: floatOrb 9s ease-in-out infinite reverse;
}

.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.5rem 0.9rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.82);
    color: var(--primary-deep);
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.hero-eyebrow::before {
    content: "";
    width: 0.55rem;
    height: 0.55rem;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--accent), #34d399);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.45);
    animation: pulseDot 1.9s infinite;
}

.hero-title {
    max-width: 12ch;
    font-size: clamp(2.35rem, 4vw, 4rem);
    line-height: 0.98;
    letter-spacing: -0.04em;
}

.hero-copy {
    max-width: 58ch;
    color: var(--muted);
    font-size: 1.06rem;
    line-height: 1.8;
}

.hero-stat-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.85rem;
}

.hero-stat-card {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    padding: 1rem 1.05rem;
    border-radius: 1.1rem;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.58);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.hero-stat-value {
    font-family: "Space Grotesk", sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
}

.hero-stat-label {
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.hero-panel {
    position: relative;
    padding: 1.4rem;
    border-radius: 1.35rem;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.62);
    box-shadow: 0 22px 48px rgba(15, 23, 42, 0.11);
    animation: riseIn 0.7s ease both;
}

.hero-panel-kicker {
    display: inline-flex;
    margin-bottom: 0.45rem;
    color: var(--primary);
    font-size: 0.76rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.14em;
}

.hero-category-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
    margin-top: 1.25rem;
}

.hero-category-pill {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    padding: 1rem;
    border-radius: 1rem;
    text-decoration: none;
    color: var(--text);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(241, 246, 255, 0.95) 100%);
    border: 1px solid rgba(148, 163, 184, 0.15);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.05);
}

.hero-category-pill:hover {
    transform: translateY(-2px);
    border-color: rgba(21, 101, 216, 0.25);
    box-shadow: 0 18px 32px rgba(21, 101, 216, 0.12);
}

.hero-category-pill span {
    font-weight: 800;
}

.hero-category-pill small {
    color: var(--muted);
    font-weight: 700;
}

.hero-panel-footer {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin-top: 1rem;
    color: var(--muted);
    font-size: 0.9rem;
}

.hero-live-dot {
    width: 0.65rem;
    height: 0.65rem;
    border-radius: 999px;
    background: var(--accent);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.45);
    animation: pulseDot 2s infinite;
}

.ticker-wrap {
    position: relative;
    overflow: hidden;
    background: linear-gradient(90deg, #0d4db5 0%, #145bd3 60%, #0f7a8c 100%);
    border-radius: 1.2rem;
    color: #fff;
    box-shadow: var(--shadow-soft);
}

.ticker-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.14), transparent 30%, transparent 70%, rgba(255, 255, 255, 0.08));
    pointer-events: none;
}

.ticker-list {
    display: flex;
    gap: 2rem;
    overflow: auto;
    white-space: nowrap;
    scrollbar-width: none;
}

.ticker-list::-webkit-scrollbar {
    display: none;
}

.section-title {
    font-size: 1.28rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.notification-card {
    border: 1px solid var(--border);
    border-radius: 1.35rem;
    background: rgba(255, 255, 255, 0.84);
    height: 100%;
    box-shadow: var(--shadow-soft);
}

.notification-card,
.sidebar-card,
.content-card,
.update-item {
    animation: riseIn 0.6s ease both;
}

.notification-card:hover,
.sidebar-card:hover,
.content-card:hover,
.update-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 44px rgba(15, 23, 42, 0.1);
}

.notification-card .badge-soft {
    background: rgba(21, 101, 216, 0.12);
    color: var(--primary);
}

.sidebar-card {
    background: rgba(255, 255, 255, 0.84);
}

.overview-table th {
    width: 220px;
    background: #f6f9ff;
}

.site-footer {
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(12px);
}

.site-footer a {
    color: var(--muted);
}

.admin-body .table td,
.admin-body .table th {
    vertical-align: middle;
}

.rich-text {
    line-height: 1.8;
}

.form-section {
    border: 1px dashed #cbd5e1;
    border-radius: 0.9rem;
    padding: 1rem;
    margin-bottom: 1rem;
    background: #f8fafc;
}

.small-list a {
    color: inherit;
    text-decoration: none;
}

.small-list a:hover {
    color: var(--primary);
}

.update-stream {
    display: grid;
    gap: 1rem;
}

.update-item {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 1.25rem;
    padding: 1.1rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(244, 248, 255, 0.94) 100%);
}

.meta-chip {
    display: inline-flex;
    align-items: center;
    padding: 0.32rem 0.68rem;
    border-radius: 999px;
    background: #eef2ff;
    color: #1d4ed8;
    font-size: 0.75rem;
    font-weight: 700;
}

.meta-chip-source {
    background: #dcfce7;
    color: #166534;
}

.update-item-actions {
    min-width: 165px;
}

.btn-outline-primary {
    border-radius: 999px;
    border-color: rgba(21, 101, 216, 0.25);
    color: var(--primary);
}

.btn-outline-primary:hover {
    background: rgba(21, 101, 216, 0.08);
    color: var(--primary-deep);
    border-color: rgba(21, 101, 216, 0.25);
}

.btn-light.border {
    border-radius: 999px;
    border-color: rgba(148, 163, 184, 0.26) !important;
    background: rgba(255, 255, 255, 0.92);
}

.pagination {
    gap: 0.35rem;
}

.page-link {
    border-radius: 0.8rem;
    border-color: rgba(148, 163, 184, 0.18);
    color: var(--muted);
}

.page-item.active .page-link {
    background: linear-gradient(135deg, var(--primary), var(--primary-deep));
    border-color: transparent;
}

.form-control,
.form-select {
    border-radius: 1rem;
    border-color: rgba(148, 163, 184, 0.26);
    padding: 0.82rem 1rem;
    color: var(--text);
}

.form-control:focus,
.form-select:focus {
    border-color: rgba(21, 101, 216, 0.36);
    box-shadow: 0 0 0 0.25rem rgba(21, 101, 216, 0.12);
}

@keyframes drift {
    0%,
    100% {
        transform: translate3d(0, 0, 0);
    }
    50% {
        transform: translate3d(0, 10px, 0);
    }
}

@keyframes floatOrb {
    0%,
    100% {
        transform: translate3d(0, 0, 0) scale(1);
    }
    50% {
        transform: translate3d(0, -12px, 0) scale(1.05);
    }
}

@keyframes pulseDot {
    0% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}

@keyframes riseIn {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 1199px) {
    .header-top-row {
        flex-direction: column;
        align-items: stretch;
    }

    .header-search {
        width: 100%;
    }
}

@media (max-width: 991px) {
    .hero-stat-row,
    .hero-category-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .overview-table th {
        width: auto;
    }

    .update-item-actions {
        min-width: 0;
    }

    .site-header-shell {
        border-radius: 1.35rem;
    }
}

@media (max-width: 767px) {
    .site-logo {
        font-size: 1.35rem;
    }

    .site-tagline {
        font-size: 0.82rem;
    }

    .header-search {
        grid-template-columns: 1fr;
    }

    .hero-title {
        max-width: none;
    }

    .hero-stat-row,
    .hero-category-grid {
        grid-template-columns: 1fr;
    }

    .nav-pill-row {
        padding-top: 0.8rem;
    }

    .nav-cta {
        padding-top: 0.85rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}
