:root {
    --crm-ink: #0f1f32;
    --crm-ink-soft: #24364c;
    --crm-amber: #d89a4f;
    --crm-amber-deep: #b77426;
    --crm-cream: #f7f3ed;
    --crm-surface: rgba(255, 255, 255, 0.92);
    --crm-line: rgba(15, 31, 50, 0.12);
    --crm-shadow: 0 24px 60px rgba(10, 22, 38, 0.12);
}

* {
    box-sizing: border-box;
}

body.crm-body {
    font-family: "Plus Jakarta Sans", sans-serif;
    background:
        radial-gradient(circle at top left, rgba(216, 154, 79, 0.22), transparent 28%),
        radial-gradient(circle at top right, rgba(15, 31, 50, 0.18), transparent 24%),
        linear-gradient(180deg, #fbf8f2 0%, #f3efe8 100%);
    color: var(--crm-ink);
    min-height: 100vh;
}

.page-shell {
    min-height: 100vh;
}

.crm-navbar {
    background: linear-gradient(120deg, rgba(15, 31, 50, 0.98), rgba(33, 55, 81, 0.95));
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(14px);
}

.brand-logo {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.08);
    padding: 6px;
}

.navbar-brand strong {
    font-family: "Outfit", sans-serif;
    letter-spacing: 0.02em;
}

.navbar-brand small {
    opacity: 0.72;
    font-size: 0.76rem;
}

.nav-link {
    font-weight: 600;
    border-radius: 999px;
    padding-inline: 0.95rem !important;
}

.nav-link.active,
.nav-link:hover {
    background: rgba(255, 255, 255, 0.09);
}

.user-pill {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 0.55rem 0.95rem;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.08);
}

.user-pill span {
    color: #fff;
    font-weight: 700;
    font-size: 0.92rem;
}

.user-pill small {
    color: rgba(255, 255, 255, 0.75);
}

.hero-card,
.panel-card,
.stats-card,
.auth-card {
    border: 0;
    border-radius: 28px;
    background: var(--crm-surface);
    box-shadow: var(--crm-shadow);
}

.hero-card {
    position: relative;
    overflow: hidden;
    color: #fff;
    background:
        linear-gradient(135deg, rgba(15, 31, 50, 0.96), rgba(15, 31, 50, 0.76)),
        url('https://images.unsplash.com/photo-1511578314322-379afb476865?auto=format&fit=crop&w=1600&q=80') center/cover;
}

.hero-card::after {
    content: "";
    position: absolute;
    inset: auto -10% -35% auto;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(216, 154, 79, 0.36), transparent 60%);
}

.hero-label {
    display: inline-flex;
    padding: 0.45rem 0.85rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
    font-size: 0.82rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.hero-card h1,
.hero-card h2,
.panel-title,
.auth-card h1 {
    font-family: "Outfit", sans-serif;
}

.hero-card .btn-warning,
.btn-accent {
    background: linear-gradient(135deg, var(--crm-amber), var(--crm-amber-deep));
    border-color: transparent;
    color: #fff;
}

.hero-card .btn-warning:hover,
.btn-accent:hover {
    color: #fff;
    filter: brightness(0.96);
}

.stats-card {
    padding: 1.25rem;
}

.stats-card .metric {
    font-size: 2rem;
    line-height: 1;
    font-weight: 800;
    font-family: "Outfit", sans-serif;
}

.stats-icon {
    width: 52px;
    height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    font-size: 1.35rem;
    color: #fff;
}

.panel-card {
    padding: 1.45rem;
}

.panel-title {
    font-size: 1.2rem;
    margin-bottom: 0;
}

.table-shell {
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(15, 31, 50, 0.08);
}

.table thead th {
    background: rgba(15, 31, 50, 0.05);
    border-bottom-width: 1px;
    font-size: 0.84rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.table > :not(caption) > * > * {
    padding: 0.95rem 1rem;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.38rem 0.7rem;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.status-primary { background: rgba(13, 110, 253, 0.12); color: #0d6efd; }
.status-info { background: rgba(13, 202, 240, 0.16); color: #087990; }
.status-warning { background: rgba(255, 193, 7, 0.18); color: #997404; }
.status-accent { background: rgba(216, 154, 79, 0.16); color: #9c5d16; }
.status-success { background: rgba(25, 135, 84, 0.14); color: #146c43; }
.status-secondary { background: rgba(108, 117, 125, 0.16); color: #495057; }
.status-dark { background: rgba(33, 37, 41, 0.12); color: #212529; }
.status-danger { background: rgba(220, 53, 69, 0.16); color: #b02a37; }

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

.contact-actions .btn {
    border-radius: 999px;
}

.filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}

.form-section-title {
    font-family: "Outfit", sans-serif;
    font-size: 1rem;
    margin-bottom: 0.9rem;
    color: var(--crm-ink-soft);
}

.auth-wrap {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 2rem;
}

.auth-card {
    max-width: 1120px;
    overflow: hidden;
}

.auth-cover {
    min-height: 100%;
    color: #fff;
    background:
        linear-gradient(135deg, rgba(15, 31, 50, 0.94), rgba(15, 31, 50, 0.7)),
        url('https://images.unsplash.com/photo-1520607162513-77705c0f0d4a?auto=format&fit=crop&w=1200&q=80') center/cover;
    padding: 2.5rem;
}

.auth-cover h2 {
    font-family: "Outfit", sans-serif;
    font-size: clamp(2rem, 4vw, 3rem);
}

.auth-form {
    padding: 2.5rem;
}

.mini-list {
    display: grid;
    gap: 1rem;
}

.mini-item {
    padding: 1rem 1.1rem;
    border-radius: 18px;
    background: rgba(15, 31, 50, 0.04);
}

.mini-item strong {
    display: block;
}

.form-control,
.form-select {
    border-radius: 14px;
    border-color: rgba(15, 31, 50, 0.12);
    padding: 0.82rem 0.95rem;
}

.form-control:focus,
.form-select:focus {
    border-color: rgba(216, 154, 79, 0.72);
    box-shadow: 0 0 0 0.2rem rgba(216, 154, 79, 0.18);
}

.btn {
    border-radius: 14px;
    font-weight: 700;
}

.soft-meta {
    color: #64748b;
    font-size: 0.9rem;
}

.assignment-grid {
    display: grid;
    gap: 1rem;
}

.assignment-card {
    border: 1px solid rgba(15, 31, 50, 0.08);
    border-radius: 18px;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.66);
}

@media (max-width: 991.98px) {
    .auth-cover {
        min-height: 280px;
    }

    .navbar-brand span small {
        display: none;
    }
}
