:root {
    /* =========================
       BRAND COLORS
    ========================= */
    --sb-blue: #005fbb;
    --sb-blue-dark: #003f7d;
    --sb-yellow: #ffd447;

    /* =========================
       OCEAN / REEF PALETTE
    ========================= */
    --reef-teal: #00b8c9;
    --parrotfish-green: #4cc38a;
    --butterfly-orange: #ff9f43;
    --coral-pink: #ff6f91;

    /* =========================
       NEUTRALS
    ========================= */
    --sand: #fff8e8;
    --foam: #f4fbff;
    --white: #ffffff;
    --text: #17324d;
    --muted: #6b7f95;
    --border: rgba(0, 95, 187, 0.10);

    /* =========================
       SHADOWS / RADII / SPACING
    ========================= */
    --shadow: 0 12px 30px rgba(0, 63, 125, 0.15);
    --radius-lg: 22px;
    --radius-md: 14px;
    --radius-sm: 10px;

    --space-xs: 6px;
    --space-sm: 10px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;

    /* =========================
       TRANSITIONS
    ========================= */
    --transition-fast: 0.2s ease;
}

/* =========================
   RESET / GLOBAL
========================= */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    min-height: 100%;
    font-family: "Segoe UI", Tahoma, Arial, sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top right, rgba(255, 212, 71, 0.22), transparent 20%),
        radial-gradient(circle at bottom left, rgba(0, 184, 201, 0.18), transparent 25%),
        linear-gradient(135deg, #eef8ff 0%, #fffdf5 100%);
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

/* =========================
   APP LAYOUT
========================= */
.app-shell {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 290px;
    height: 100vh;
    position: sticky;
    top: 0;
    display: flex;
    flex-direction: column;
    padding: 22px 18px;
    color: var(--white);
    background: linear-gradient(
        180deg,
        var(--sb-blue-dark) 0%,
        var(--sb-blue) 70%,
        var(--reef-teal) 100%
    );
    box-shadow: var(--shadow);
}

.main-panel {
    flex: 1;
    padding: var(--space-lg);
}

.content-area {
    display: block;
}

/* =========================
   BRAND PANEL
========================= */
.brand-panel {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 28px;
    padding: 12px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(6px);
}

.brand-logo {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-logo-img {
    width: 70%;
    height: 70%;
    object-fit: contain;
}

.brand-title {
    font-size: 1.2rem;
    font-weight: 800;
    letter-spacing: 0.2px;
}

.brand-subtitle {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* =========================
   SIDEBAR NAVIGATION
========================= */
.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nav-section-title {
    margin-top: 18px;
    margin-bottom: 6px;
    padding: 0 12px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.75);
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px 14px;
    border-radius: 14px;
    color: var(--white);
    font-weight: 600;
    transition: var(--transition-fast);
}

.nav-item i {
    width: 20px;
    text-align: center;
}

.nav-item:hover,
.nav-item:focus-visible {
    background: rgba(255, 255, 255, 0.16);
    transform: translateX(2px);
}

.nav-item.active {
    background: rgba(255, 255, 255, 0.22);
}

/* =========================
   SIDEBAR FOOTER / USER
========================= */
.sidebar-footer {
    margin-top: auto;
    padding-top: 18px;
}

.user-card {
    margin-bottom: 12px;
    padding: 14px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.14);
}

.user-card-name {
    margin-bottom: 4px;
    font-weight: 700;
}

.user-card-role {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* =========================
   BUTTONS
========================= */
.btn-primary-action,
.logout-btn,
.login-btn {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 14px;
    border: none;
    border-radius: 14px;
    font-weight: 800;
    cursor: pointer;
    transition: var(--transition-fast);
    background: linear-gradient(135deg, var(--sb-yellow), #ffe68c);
    color: var(--sb-blue-dark);
}

.btn-primary-action:hover,
.logout-btn:hover,
.login-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(255, 212, 71, 0.25);
}

/* Optional secondary button style */
.btn-secondary-action {
    color: var(--sb-blue-dark) !important;
}

.btn-secondary-action,
.btn-secondary-action:link,
.btn-secondary-action:visited {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.82);
    color: var(--sb-blue-dark);
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition-fast);
}

.btn-secondary-action:hover,
.btn-secondary-action:focus {
    background: var(--white);
    color: var(--sb-blue-dark);
    transform: translateY(-1px);
}

/* =========================
   TOPBAR / PAGE HEADER
========================= */
.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
    padding: 24px 28px;
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.78);
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
}

.page-title {
    margin: 0;
    font-size: 1.9rem;
    color: var(--sb-blue-dark);
}

.page-subtitle {
    margin: 6px 0 0;
    color: var(--muted);
}

/* =========================
   BADGES
========================= */

.topbar-badge {
    position: relative;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: #fff;
    overflow: visible;
}

.badge-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.badge-fallback {
    font-size: 12px;
    font-weight: bold;
    color: #0f3d57;
}


.badge-count {
    position: absolute;
    top: -11px;
    right: -11px;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 8px;
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
    color: #fff;
    background: #ff3b30;
    border-radius: 999px;
    border: 2px solid #fff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.45);
}

.badge {
    display: inline-flex;
    align-items: center;
    padding: 10px 14px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 800;
}

.badge-yellow {
    background: rgba(255, 212, 71, 0.25);
    color: #8a6200;
}

.badge-blue {
    background: rgba(0, 95, 187, 0.12);
    color: var(--sb-blue-dark);
}

.badge-fish {
    background: rgba(255, 111, 145, 0.16);
    color: #b3365b;
}

.badge-green {
    background: rgba(76, 195, 138, 0.18);
    color: #1d7a4d;
}

.badge-orange {
    background: rgba(255, 159, 67, 0.18);
    color: #a85600;
}

/* =========================
   GRID LAYOUTS
========================= */
.dashboard-grid,
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}

/* =========================
   CARDS
========================= */
.info-card,
.app-card {
    padding: 22px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.90),
        rgba(255, 255, 255, 0.82)
    );
    box-shadow: var(--shadow);
}

.info-card h3,
.app-card h3 {
    margin-top: 0;
    margin-bottom: 8px;
    color: var(--sb-blue-dark);
}

.info-card p,
.app-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.55;
}

.card-accent-blue {
    border-top: 6px solid var(--sb-blue);
}

.card-accent-yellow {
    border-top: 6px solid var(--sb-yellow);
}

.card-accent-teal {
    border-top: 6px solid var(--reef-teal);
}

.card-accent-green {
    border-top: 6px solid var(--parrotfish-green);
}

.card-accent-orange {
    border-top: 6px solid var(--butterfly-orange);
}

.card-accent-pink {
    border-top: 6px solid var(--coral-pink);
}

/* =========================
   ADMIN / USER CARDS
========================= */
.user-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 20px;
}

.user-admin-card {
    padding: 22px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.94),
        rgba(255, 255, 255, 0.86)
    );
    box-shadow: var(--shadow);
}

.user-admin-card-header {
    margin-bottom: 14px;
}

.user-admin-card-name {
    margin: 0 0 4px;
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--sb-blue-dark);
}

.user-admin-card-email {
    color: var(--muted);
    font-size: 0.95rem;
}

.user-admin-card-roles {
    margin: 14px 0;
}

.role-badge {
    display: inline-block;
    margin: 0 6px 6px 0;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
    background: rgba(0, 184, 201, 0.12);
    color: #0b6d77;
}

.user-admin-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

/* =========================
   TABLES
========================= */
.table-wrap {
    overflow-x: auto;
}

.app-table {
    width: 100%;
    border-collapse: collapse;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.88);
    box-shadow: var(--shadow);
}

.app-table thead {
    background: linear-gradient(135deg, var(--sb-blue), var(--reef-teal));
    color: var(--white);
}

.app-table th,
.app-table td {
    padding: 14px 16px;
    text-align: left;
}

.app-table tbody tr {
    border-bottom: 1px solid rgba(0, 95, 187, 0.08);
}

.app-table tbody tr:hover {
    background: rgba(0, 184, 201, 0.05);
}

/* =========================
   ALERTS
========================= */
.alert {
    padding: 14px 18px;
    border-radius: var(--radius-md);
    margin-bottom: 18px;
    font-weight: 600;
}

.alert-danger {
    background: rgba(255, 111, 145, 0.14);
    border: 1px solid rgba(255, 111, 145, 0.25);
    color: #9f274c;
}

.alert-success {
    background: rgba(76, 195, 138, 0.14);
    border: 1px solid rgba(76, 195, 138, 0.25);
    color: #1f7b4e;
}

.alert-warning {
    background: rgba(255, 212, 71, 0.18);
    border: 1px solid rgba(255, 212, 71, 0.35);
    color: #8a6200;
}

.alert-info {
    background: rgba(0, 184, 201, 0.12);
    border: 1px solid rgba(0, 184, 201, 0.22);
    color: #0d6f79;
}

/* =========================
   FORMS
========================= */
.form-card {
    padding: 24px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 18px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 700;
    color: var(--sb-blue-dark);
}

.form-control,
.form-select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid rgba(0, 95, 187, 0.16);
    border-radius: var(--radius-md);
    background: var(--white);
    color: var(--text);
    font: inherit;
    transition: var(--transition-fast);
}

.form-control:focus,
.form-select:focus {
    outline: none;
    border-color: var(--reef-teal);
    box-shadow: 0 0 0 4px rgba(0, 184, 201, 0.12);
}

/* =========================
   UTILITY CLASSES
========================= */
.text-muted {
    color: var(--muted);
}

.text-center {
    text-align: center;
}

.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-auto {
    margin-top: auto;
}

.w-100 {
    width: 100%;
}

.d-flex {
    display: flex;
}

.flex-wrap {
    flex-wrap: wrap;
}

.justify-between {
    justify-content: space-between;
}

.align-center {
    align-items: center;
}

.gap-10 {
    gap: 10px;
}

.gap-14 {
    gap: 14px;
}

.gap-20 {
    gap: 20px;
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 980px) {
    .app-shell {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }

    .main-panel {
        padding: 16px;
    }

    .topbar {
        flex-direction: column;
        align-items: flex-start;
        padding: 20px;
    }

    .dashboard-grid,
    .card-grid,
    .user-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .page-title {
        font-size: 1.5rem;
    }

    .brand-panel {
        padding: 10px;
    }

    .info-card,
    .app-card,
    .user-admin-card,
    .form-card {
        padding: 18px;
    }

    .app-table th,
    .app-table td {
        padding: 12px;
    }
}
.user-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 22px;
}

.user-admin-card {
    position: relative;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.user-admin-card::before {
    content: "";
    position: absolute;
    top: -30px;
    right: -30px;
    width: 110px;
    height: 110px;
    background: radial-gradient(rgba(255, 212, 71, 0.22), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.user-admin-card::after {
    content: "";
    position: absolute;
    bottom: -35px;
    left: -35px;
    width: 120px;
    height: 120px;
    background: radial-gradient(rgba(0, 184, 201, 0.16), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.user-admin-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 36px rgba(0, 63, 125, 0.18);
}

.user-admin-card-header {
    position: relative;
    z-index: 1;
    padding-bottom: 12px;
    margin-bottom: 12px;
    border-bottom: 1px solid rgba(0, 95, 187, 0.08);
}

.user-admin-card-name {
    font-size: 1.15rem;
    line-height: 1.2;
}

.user-admin-card-email {
    word-break: break-word;
}

.user-admin-card-roles {
    position: relative;
    z-index: 1;
    min-height: 38px;
}

.role-badge {
    background: linear-gradient(135deg, rgba(0, 184, 201, 0.14), rgba(76, 195, 138, 0.16));
    color: var(--sb-blue-dark);
    border: 1px solid rgba(0, 95, 187, 0.08);
    box-shadow: 0 4px 10px rgba(0, 95, 187, 0.06);
}

.user-admin-card-actions {
    position: relative;
    z-index: 1;
    margin-top: 18px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.user-admin-card-actions form {
    margin: 0;
}

.user-admin-card-actions .btn-secondary-action,
.user-admin-card-actions .btn-primary-action {
    width: auto;
    min-width: 110px;
}

.user-admin-card-actions .btn-primary-action {
    background: linear-gradient(135deg, #ff8aa5, #ff6f91);
    color: #fff;
}

.user-admin-card-actions .btn-primary-action:hover {
    box-shadow: 0 10px 20px rgba(255, 111, 145, 0.24);
}

@media (max-width: 640px) {
    .user-admin-card-actions {
        flex-direction: column;
    }

    .user-admin-card-actions .btn-secondary-action,
    .user-admin-card-actions .btn-primary-action,
    .user-admin-card-actions form {
        width: 100%;
    }
}
/* =========================
   FORM GRID
========================= */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
}

/* =========================
   ROLES SECTION
========================= */
.roles-section {
    margin-top: 20px;
}

/* =========================
   ROLES GRID (FUN + CLEAN)
========================= */
.roles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
}

/* =========================
   ROLE OPTION CARD
========================= */
.role-option {
    position: relative;
    cursor: pointer;
}

.role-option input {
    position: absolute;
    opacity: 0;
}

.role-option-content {
    display: block;
    padding: 14px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: linear-gradient(
        135deg,
        rgba(255,255,255,0.9),
        rgba(255,255,255,0.82)
    );
    transition: 0.2s ease;
    text-align: center;
    font-weight: 700;
    color: var(--sb-blue-dark);
}

/* hover effect */
.role-option:hover .role-option-content {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 95, 187, 0.12);
}

/* checked state */
.role-option input:checked + .role-option-content {
    background: linear-gradient(
        135deg,
        rgba(0, 184, 201, 0.22),
        rgba(76, 195, 138, 0.22)
    );
    border-color: var(--reef-teal);
    box-shadow: 0 10px 22px rgba(0, 184, 201, 0.25);
}

/* =========================
   ROLE TEXT
========================= */
.role-option-name {
    font-size: 0.95rem;
}

/* =========================
   FORM ACTIONS
========================= */
.form-actions {
    margin-top: 26px;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 640px) {
    .form-actions {
        flex-direction: column;
    }

    .form-actions .btn-primary-action,
    .form-actions .btn-secondary-action {
        width: 100%;
    }
}
/* =========================
   ROLE GRID
========================= */
.role-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 22px;
}

/* =========================
   ROLE CARD
========================= */
.role-card {
    position: relative;
    padding: 22px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    background: linear-gradient(
        180deg,
        rgba(255,255,255,0.94),
        rgba(255,255,255,0.86)
    );
    box-shadow: var(--shadow);
    transition: 0.2s ease;
    overflow: hidden;
}

/* decorative bubbles */
.role-card::before {
    content: "";
    position: absolute;
    top: -30px;
    right: -30px;
    width: 100px;
    height: 100px;
    background: radial-gradient(rgba(255,159,67,0.25), transparent 70%);
    border-radius: 50%;
}

.role-card::after {
    content: "";
    position: absolute;
    bottom: -30px;
    left: -30px;
    width: 110px;
    height: 110px;
    background: radial-gradient(rgba(0,184,201,0.18), transparent 70%);
    border-radius: 50%;
}

/* hover */
.role-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 36px rgba(0, 63, 125, 0.18);
}

/* =========================
   ROLE HEADER
========================= */
.role-card-header {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.role-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--butterfly-orange), var(--sb-yellow));
    color: var(--sb-blue-dark);
    font-size: 1.2rem;
    box-shadow: 0 6px 14px rgba(0,0,0,0.12);
}

.role-name {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--sb-blue-dark);
}

/* =========================
   BODY
========================= */
.role-card-body {
    position: relative;
    z-index: 1;
    margin-bottom: 18px;
}

/* =========================
   ACTIONS
========================= */
.role-card-actions {
    position: relative;
    z-index: 1;
}

.role-card-actions form {
    margin: 0;
}

.role-card-actions .btn-primary-action {
    width: 100%;
    background: linear-gradient(135deg, #ff8aa5, #ff6f91);
    color: #fff;
}

.role-card-actions .btn-primary-action:hover {
    box-shadow: 0 10px 20px rgba(255, 111, 145, 0.24);
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 640px) {
    .role-card-actions .btn-primary-action {
        width: 100%;
    }
}
.role-create-shell {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr);
    gap: 22px;
    align-items: start;
}

.role-create-main {
    min-width: 0;
}

.role-create-side {
    position: relative;
    overflow: hidden;
}

.role-create-side::before {
    content: "";
    position: absolute;
    top: -28px;
    right: -28px;
    width: 100px;
    height: 100px;
    background: radial-gradient(rgba(255, 159, 67, 0.24), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.role-create-side::after {
    content: "";
    position: absolute;
    bottom: -34px;
    left: -34px;
    width: 110px;
    height: 110px;
    background: radial-gradient(rgba(0, 184, 201, 0.18), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.role-create-side h3,
.role-create-side p,
.role-tip-list {
    position: relative;
    z-index: 1;
}

.role-create-side h3 {
    margin-top: 0;
    margin-bottom: 10px;
    color: var(--sb-blue-dark);
}

.role-create-side p {
    margin-bottom: 16px;
    color: var(--muted);
    line-height: 1.55;
}

.role-tip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.role-name-input {
    font-size: 1.05rem;
    font-weight: 600;
}

@media (max-width: 900px) {
    .role-create-shell {
        grid-template-columns: 1fr;
    }
}
/* Slight variation for create page accent feel */
.form-card.card-accent-green::before {
    content: "";
    position: absolute;
    top: -35px;
    right: -35px;
    width: 120px;
    height: 120px;
    background: radial-gradient(rgba(76, 195, 138, 0.25), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

/* Password inputs feel more important */
input[type="password"] {
    letter-spacing: 0.1em;
}
/* =========================
   LOGIN PAGE
========================= */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 20px;
    background:
        radial-gradient(circle at top right, rgba(255, 212, 71, 0.20), transparent 20%),
        radial-gradient(circle at bottom left, rgba(0, 184, 201, 0.18), transparent 24%),
        linear-gradient(135deg, #eef8ff 0%, #fffdf5 100%);
}

.login-shell {
    width: 100%;
    max-width: 1120px;
}

.login-brand-panel {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 24px;
    padding: 20px 22px;
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.85);
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
}

.login-brand-badge {
    width: 64px;
    height: 64px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--sb-blue-dark);
    background: linear-gradient(135deg, var(--sb-yellow), var(--butterfly-orange));
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.14);
}

.login-title {
    margin: 0;
    font-size: 2rem;
    color: var(--sb-blue-dark);
}

.login-subtitle {
    margin: 6px 0 0;
    color: var(--muted);
}

.login-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
    gap: 24px;
    align-items: start;
}

.login-card {
    position: relative;
    overflow: hidden;
    padding: 28px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.94),
        rgba(255, 255, 255, 0.86)
    );
    box-shadow: var(--shadow);
}

.login-card::before {
    content: "";
    position: absolute;
    top: -36px;
    right: -36px;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: radial-gradient(rgba(255, 212, 71, 0.22), transparent 70%);
    pointer-events: none;
}

.login-card::after {
    content: "";
    position: absolute;
    bottom: -38px;
    left: -38px;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: radial-gradient(rgba(0, 184, 201, 0.16), transparent 70%);
    pointer-events: none;
}

.login-card-header,
.login-form,
.login-empty-state,
.external-login-list {
    position: relative;
    z-index: 1;
}

.login-card-header {
    margin-bottom: 18px;
}

.login-card-title {
    margin: 0 0 8px;
    color: var(--sb-blue-dark);
    font-size: 1.35rem;
}

.login-card-text {
    margin: 0;
    color: var(--muted);
    line-height: 1.55;
}

.login-form .form-group + .form-group {
    margin-top: 18px;
}

.login-form input[type="password"] {
    letter-spacing: 0.08em;
}

.remember-row {
    margin: 16px 0 18px;
}

.remember-label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--text);
    font-weight: 600;
    cursor: pointer;
}

.remember-label .form-check-input {
    margin: 0;
    width: 18px;
    height: 18px;
}

.login-submit-btn {
    width: 100%;
    font-size: 1rem;
    padding: 14px 18px;
}

.login-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 18px;
}

.login-links a {
    color: var(--sb-blue-dark);
    font-weight: 600;
    transition: var(--transition-fast);
}

.login-links a:hover {
    color: var(--reef-teal);
}

.login-side-card {
    min-height: 100%;
}

.login-empty-state {
    text-align: center;
}

.login-empty-icon {
    width: 58px;
    height: 58px;
    margin: 0 auto 14px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--reef-teal), var(--parrotfish-green));
    color: var(--white);
    font-size: 1.35rem;
    box-shadow: 0 8px 18px rgba(0, 95, 187, 0.14);
}

.external-login-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.external-login-btn {
    width: 100%;
    justify-content: center;
    min-height: 48px;
}

/* =========================
   LOGIN RESPONSIVE
========================= */
@media (max-width: 900px) {
    .login-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .login-page {
        padding: 18px;
    }

    .login-brand-panel {
        align-items: flex-start;
        padding: 18px;
    }

    .login-title {
        font-size: 1.6rem;
    }

    .login-card {
        padding: 20px;
    }
}
.employee-id-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

.employee-id-card {
    position: relative;
    overflow: hidden;
    border-radius: 22px;
    background: linear-gradient(160deg, #ffffff 0%, #f4fbff 100%);
    border: 1px solid rgba(0, 95, 187, 0.12);
    box-shadow: 0 14px 30px rgba(0, 63, 125, 0.16);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.employee-id-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 36px rgba(0, 63, 125, 0.20);
}

.employee-id-card::before {
    content: "";
    position: absolute;
    top: -45px;
    right: -45px;
    width: 130px;
    height: 130px;
    border-radius: 50%;
    background: radial-gradient(rgba(255, 212, 71, 0.25), transparent 70%);
}

.employee-id-card::after {
    content: "";
    position: absolute;
    bottom: -45px;
    left: -45px;
    width: 130px;
    height: 130px;
    border-radius: 50%;
    background: radial-gradient(rgba(0, 184, 201, 0.18), transparent 70%);
}

.employee-id-card__header {
    position: relative;
    z-index: 1;
    padding: 18px 20px;
    background: linear-gradient(135deg, var(--sb-blue-dark), var(--sb-blue), var(--reef-teal));
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.employee-id-card__brand {
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: 0.3px;
}

.employee-id-card__type {
    font-size: 0.85rem;
    font-weight: 700;
    opacity: 0.95;
}

.employee-id-card__body {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 96px 1fr;
    gap: 18px;
    padding: 20px;
    align-items: center;
}

.employee-id-card__photo-wrap {
    display: flex;
    justify-content: center;
    align-items: center;
}

.employee-id-card__photo {
    width: 96px;
    height: 96px;
    object-fit: cover;
    border-radius: 16px;
    border: 3px solid rgba(0, 95, 187, 0.10);
    background: white;
    box-shadow: 0 8px 18px rgba(0, 63, 125, 0.10);
}

.employee-id-card__photo--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    color: var(--muted);
    background: linear-gradient(135deg, #eef8ff, #fffdf5);
}

.employee-id-card__name {
    margin: 0 0 10px;
    color: var(--sb-blue-dark);
    font-size: 1.15rem;
    line-height: 1.25;
}

.employee-id-card__meta {
    margin-bottom: 6px;
    color: var(--text);
    font-size: 0.95rem;
}

@media (max-width: 640px) {
    .employee-id-card__body {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .employee-id-card__photo-wrap {
        justify-content: center;
    }
}
.location-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 22px;
}

.location-card {
    position: relative;
    overflow: hidden;
    padding: 22px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    background: linear-gradient(
        180deg,
        rgba(255,255,255,0.94),
        rgba(255,255,255,0.86)
    );
    box-shadow: var(--shadow);
    transition: 0.2s ease;
}

.location-card::before {
    content: "";
    position: absolute;
    top: -30px;
    right: -30px;
    width: 100px;
    height: 100px;
    background: radial-gradient(rgba(255,159,67,0.25), transparent 70%);
    border-radius: 50%;
}

.location-card::after {
    content: "";
    position: absolute;
    bottom: -30px;
    left: -30px;
    width: 110px;
    height: 110px;
    background: radial-gradient(rgba(0,184,201,0.16), transparent 70%);
    border-radius: 50%;
}

.location-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 36px rgba(0, 63, 125, 0.18);
}

.location-card-header,
.location-card-body,
.location-card-actions {
    position: relative;
    z-index: 1;
}

.location-card-header {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 16px;
}

.location-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--butterfly-orange), var(--sb-yellow));
    color: var(--sb-blue-dark);
    font-size: 1.2rem;
    box-shadow: 0 6px 14px rgba(0,0,0,0.12);
}

.location-name {
    margin: 0;
    color: var(--sb-blue-dark);
    font-size: 1.15rem;
    font-weight: 800;
}

.location-subtitle {
    margin-top: 4px;
    color: var(--muted);
    font-size: 0.9rem;
}

.location-meta {
    margin-bottom: 8px;
    color: var(--text);
    line-height: 1.5;
}

.location-flag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.location-card-actions {
    margin-top: 18px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.location-card-actions form {
    margin: 0;
}

.location-card-actions .btn-secondary-action,
.location-card-actions .btn-primary-action {
    width: auto;
    min-width: 110px;
}

.location-card-actions .btn-primary-action {
    background: linear-gradient(135deg, #ff8aa5, #ff6f91);
    color: #fff;
}

.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 14px;
    margin-top: 16px;
}

.checkbox-card {
    position: relative;
    cursor: pointer;
}

.checkbox-card input {
    position: absolute;
    opacity: 0;
}

.checkbox-card__content {
    display: block;
    padding: 16px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: linear-gradient(
        135deg,
        rgba(255,255,255,0.92),
        rgba(255,255,255,0.84)
    );
    transition: 0.2s ease;
}

.checkbox-card__title {
    display: block;
    font-weight: 800;
    color: var(--sb-blue-dark);
    margin-bottom: 4px;
}

.checkbox-card__text {
    display: block;
    color: var(--muted);
    line-height: 1.45;
    font-size: 0.92rem;
}

.checkbox-card:hover .checkbox-card__content {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 95, 187, 0.12);
}

.checkbox-card input:checked + .checkbox-card__content {
    background: linear-gradient(
        135deg,
        rgba(0, 184, 201, 0.22),
        rgba(76, 195, 138, 0.20)
    );
    border-color: var(--reef-teal);
    box-shadow: 0 10px 22px rgba(0, 184, 201, 0.18);
}

@media (max-width: 640px) {
    .location-card-actions {
        flex-direction: column;
    }

    .location-card-actions .btn-secondary-action,
    .location-card-actions .btn-primary-action,
    .location-card-actions form {
        width: 100%;
    }
}
.employee-admin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 420px));
    justify-content: center; /* keeps cards centered instead of stretched */
    gap: 22px;
}

.employee-admin-card {
    position: relative;
    overflow: hidden;
    padding: 22px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    background: linear-gradient(
        180deg,
        rgba(255,255,255,0.94),
        rgba(255,255,255,0.86)
    );
    box-shadow: var(--shadow);
    transition: 0.2s ease;
}

.employee-admin-card::before {
    content: "";
    position: absolute;
    top: -30px;
    right: -30px;
    width: 110px;
    height: 110px;
    background: radial-gradient(rgba(255, 212, 71, 0.22), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.employee-admin-card::after {
    content: "";
    position: absolute;
    bottom: -36px;
    left: -36px;
    width: 120px;
    height: 120px;
    background: radial-gradient(rgba(0, 184, 201, 0.16), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.employee-admin-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 36px rgba(0, 63, 125, 0.18);
}

.employee-admin-card-header,
.employee-admin-card-body,
.employee-admin-card-actions {
    position: relative;
    z-index: 1;
}

.employee-admin-card-header {
    display: grid;
    grid-template-columns: 84px 1fr;
    gap: 14px;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 1px solid rgba(0, 95, 187, 0.08);
}

.employee-admin-card-photo-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
}

.employee-admin-card-photo {
    width: 84px;
    height: 84px;
    object-fit: cover;
    border-radius: 18px;
    border: 3px solid rgba(0, 95, 187, 0.08);
    box-shadow: 0 8px 18px rgba(0, 63, 125, 0.10);
    background: #fff;
}

.employee-admin-card-photo--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: var(--sb-blue-dark);
    background: linear-gradient(135deg, #eef8ff, #fffdf5);
}

.employee-admin-card-name {
    margin: 0 0 6px;
    color: var(--sb-blue-dark);
    font-size: 1.15rem;
    font-weight: 800;
    line-height: 1.2;
}

.employee-admin-card-subtitle {
    color: var(--muted);
    font-size: 0.95rem;
}

.employee-admin-card-body {
    display: grid;
    gap: 10px;
}

.employee-admin-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    color: var(--text);
    font-size: 0.95rem;
}

.employee-admin-meta-row strong {
    color: var(--sb-blue-dark);
    flex: 0 0 auto;
}

.employee-admin-meta-row span:last-child {
    text-align: right;
    word-break: break-word;
}

.employee-admin-card-actions {
    margin-top: 18px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.employee-admin-card-actions form {
    margin: 0;
}

.employee-admin-card-actions .btn-secondary-action,
.employee-admin-card-actions .btn-primary-action {
    width: auto;
    min-width: 110px;
}

.employee-admin-card-actions .btn-primary-action {
    background: linear-gradient(135deg, #ff8aa5, #ff6f91);
    color: #fff;
}

.employee-admin-card-actions .btn-primary-action:hover {
    box-shadow: 0 10px 20px rgba(255, 111, 145, 0.24);
}

@media (max-width: 640px) {
    .employee-admin-card-header {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .employee-admin-meta-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .employee-admin-meta-row span:last-child {
        text-align: left;
    }

    .employee-admin-card-actions {
        flex-direction: column;
    }

    .employee-admin-card-actions .btn-secondary-action,
    .employee-admin-card-actions .btn-primary-action,
    .employee-admin-card-actions form {
        width: 100%;
    }
}
.employee-admin-card-photo-wrap {
    border-radius: 18px;
    padding: 4px;
    display: inline-flex;
    background: #fff;
    transition: all 0.2s ease;
}

.photo-border-active {
    border: 3px solid #22c55e;
    box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.15);
}

.photo-border-terminated {
    border: 3px solid #ef4444;
    box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.15);
}
.employee-id-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 420px));
    justify-content: center;
    gap: 22px;
}

.employee-id-card {
    width: 100%;
    max-width: 420px;
}

.employee-id-card__photo-wrap {
    border-radius: 14px;
    padding: 4px;
    background: #fff;
    display: inline-flex;
    transition: all 0.2s ease;
}

.photo-border-active {
    border: 3px solid #22c55e;
    box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.15);
}

.photo-border-terminated {
    border: 3px solid #ef4444;
    box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.15);
}

.employee-id-card:hover .photo-border-active {
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.35);
}

.employee-id-card:hover .photo-border-terminated {
    box-shadow: 0 0 12px rgba(239, 68, 68, 0.35);
}
.user-card-wrapper {
    display: flex;
    justify-content: center;
    align-items: center; /* remove if you don't want vertical centering */
    width: 100%;
}
.assignment-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 420px));
    justify-content: center;
    gap: 22px;
}

.assignment-card {
    background: #fff;
    border: 1px solid #e7edf3;
    border-radius: 18px;
    box-shadow: 0 10px 24px rgba(17, 43, 60, 0.08);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.assignment-card__header {
    padding: 20px 20px 10px;
    border-bottom: 1px solid #eef3f7;
}

.assignment-card__title {
    margin: 0 0 10px;
    font-size: 1.15rem;
    font-weight: 700;
    color: #17384d;
}

.assignment-card__meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.assignment-card__body {
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.assignment-card__row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid #eef3f7;
    padding-bottom: 10px;
}

.assignment-card__row strong {
    color: #29475b;
    white-space: nowrap;
}

.assignment-card__row span {
    text-align: right;
    color: #5c6f7d;
    word-break: break-word;
}

.assignment-card__actions {
    margin-top: auto;
    padding: 18px 20px 20px;
    border-top: 1px solid #eef3f7;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.form-card {
    background: #fff;
    border: 1px solid #e7edf3;
    border-radius: 18px;
    box-shadow: 0 10px 24px rgba(17, 43, 60, 0.08);
    padding: 24px;
    min-height: 100vh;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group--full {
    grid-column: 1 / -1;
}

.form-label {
    margin-bottom: 8px;
    font-weight: 600;
    color: #29475b;
}

.form-help {
    margin-top: 6px;
    color: #6b7b88;
    font-size: 0.86rem;
}

.form-actions {
    margin-top: 24px;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.assignment-layout {
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 22px;
    min-height: 100vh;
}

.assignment-table {
    width: 100%;
    border-collapse: collapse;
}

.assignment-table th,
.assignment-table td {
    text-align: left;
    padding: 12px 10px;
    border-bottom: 1px solid #eef3f7;
}

.assignment-table th {
    color: #29475b;
    font-weight: 700;
}

.section-header {
    margin-bottom: 14px;
}

.section-header h3 {
    margin: 0;
    color: #17384d;
}

.empty-state-inline {
    padding: 18px;
    border-radius: 12px;
    background: #f8fbfd;
    color: #6b7b88;
}

.badge-red {
    background: #fee2e2;
    color: #b91c1c;
}

.badge-slate {
    background: #e5e7eb;
    color: #475569;
}

.checkbox-group .checkbox-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

@media (max-width: 900px) {
    .assignment-layout {
        grid-template-columns: 1fr;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .assignment-card__row {
        flex-direction: column;
        align-items: flex-start;
    }

    .assignment-card__row span {
        text-align: left;
    }
}
.assignment-badge-preview {
    margin-top: 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.assignment-badge-preview__image-wrap {
    width: 110px;
    height: 110px;
    border-radius: 18px;
    border: 1px solid #e7edf3;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.assignment-badge-preview__image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.card-accent-purple {
    border-left: 6px solid #7c3aed;
}

.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 18px;
    margin: 20px 0 28px;
    padding: 26px;
    border-radius: 20px;
    background: linear-gradient(135deg,#005fbb 0%,#0077c8 100%);
    box-shadow: 0 10px 28px rgba(0,95,187,.22);
}

.dashboard-stat {
    background: rgba(255,255,255,.14);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,.20);
    border-radius: 16px;
    padding: 22px 18px;
    text-align: center;
    transition: .2s ease;
}

.dashboard-stat:hover {
    transform: translateY(-4px);
    background: rgba(255,255,255,.20);
}

.stat-number {
    display: block;
    font-size: 2.4rem;
    font-weight: 800;
    color: #FFD447;
    line-height: 1;
    margin-bottom: 8px;
}

.stat-label {
    display: block;
    font-size: .95rem;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.dashboard-card-action {
    display: flex;
    justify-content: center;
    margin-top: 24px;
}

.dashboard-card-action .btn-secondary-action {
    min-width: 240px;
    height: 46px;
    background: var(--sb-yellow);
    color: var(--sb-blue-dark);
    border: 2px solid rgba(255,255,255,.35);
    border-radius: 14px;
    font-weight: 700;
}

.dashboard-card-action .btn-secondary-action:hover {
    background: #ffffff;
    color: var(--sb-blue-dark);
    border-color: var(--sb-yellow);
}

.embedded-content-wrap {
    height: 100%;
    display: flex;
    width: 100%;
    min-height: 650px;
    border: 1px solid #e7edf3;
    border-radius: 16px;
    overflow: hidden;
    background: #f8fbfd;
}

.embedded-content-frame {
    flex: 1;
    width: 100%;
    border: 0;
    display: block;
}

.embedded-content-fallback {
    min-height: 220px;
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 14px;
    text-align: center;
    padding: 24px;
    background: #f8fbfd;
}

@media (max-width:600px) {

    .dashboard-stats {
        grid-template-columns: 1fr;
    }
}

/* =========================
   BADGE ADMIN GRID
========================= */
.badge-admin-shell {
    padding: 28px;
}

.badge-admin-header {
    margin-bottom: 24px;
}

.badge-create-btn {
    width: auto;
    min-width: 170px;
}

.badge-admin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 22px;
}

.badge-admin-card {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100%;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: linear-gradient( 180deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.86) );
    box-shadow: var(--shadow);
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

    .badge-admin-card::before {
        content: "";
        position: absolute;
        top: -34px;
        right: -34px;
        width: 120px;
        height: 120px;
        border-radius: 50%;
        background: radial-gradient(rgba(255, 212, 71, 0.20), transparent 70%);
        pointer-events: none;
    }

    .badge-admin-card::after {
        content: "";
        position: absolute;
        bottom: -38px;
        left: -38px;
        width: 120px;
        height: 120px;
        border-radius: 50%;
        background: radial-gradient(rgba(0, 184, 201, 0.16), transparent 70%);
        pointer-events: none;
    }

    .badge-admin-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 18px 36px rgba(0, 63, 125, 0.18);
    }

.badge-admin-card-top,
.badge-admin-body,
.badge-admin-actions {
    position: relative;
    z-index: 1;
}

.badge-admin-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 22px 22px 12px;
}

.badge-admin-art {
    flex-shrink: 0;
}

.badge-admin-image,
.badge-admin-fallback {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    border: 4px solid rgba(255, 255, 255, 0.92);
    box-shadow: 0 10px 22px rgba(0, 63, 125, 0.14);
}

.badge-admin-image {
    object-fit: cover;
    background: var(--white);
}

.badge-admin-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--sb-blue-dark);
    background: linear-gradient(135deg, var(--sb-yellow), var(--butterfly-orange));
}

.badge-admin-status-wrap {
    display: flex;
    justify-content: flex-end;
}

.badge-admin-body {
    padding: 0 22px 18px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.badge-admin-name {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--sb-blue-dark);
    line-height: 1.2;
}

.badge-admin-description {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
    min-height: 72px;
}

.badge-admin-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding-top: 6px;
    border-top: 1px solid rgba(0, 95, 187, 0.08);
}

.badge-admin-meta-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.badge-admin-meta-label {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--muted);
}

.badge-admin-meta-value {
    font-weight: 700;
    color: var(--sb-blue-dark);
}

.badge-admin-actions {
    margin-top: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 0 22px 22px;
}

    .badge-admin-actions .btn-secondary-action,
    .badge-admin-actions .btn-primary-action {
        width: auto;
        min-width: 96px;
    }

.badge-delete-btn {
    background: linear-gradient(135deg, #ff8aa5, #ff6f91);
    color: #fff;
}

    .badge-delete-btn:hover {
        box-shadow: 0 10px 20px rgba(255, 111, 145, 0.24);
    }

.badge-admin-empty {
    text-align: center;
    padding: 48px 24px;
    border: 1px dashed rgba(0, 95, 187, 0.20);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.72);
}


.badge-admin-empty-icon {
    width: 74px;
    height: 74px;
    margin: 0 auto 16px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.7rem;
    color: var(--sb-blue-dark);
    background: linear-gradient(135deg, var(--sb-yellow), var(--butterfly-orange));
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.12);
}

@media (max-width: 640px) {
    .badge-admin-shell {
        padding: 18px;
    }

    .badge-admin-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .badge-create-btn {
        width: 100%;
    }

    .badge-admin-actions {
        flex-direction: column;
    }

        .badge-admin-actions .btn-secondary-action,
        .badge-admin-actions .btn-primary-action {
            width: 100%;
        }
}

/* =========================
   BADGE FORM
========================= */

.topbar-badges {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
}

.topbar-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    flex: 0 0 auto;
}

.badge-form-shell {
    padding: 28px;
}

.badge-form-header {
    margin-bottom: 24px;
}

.badge-form-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 28px;
}

.badge-form-fields {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* Modern form controls */
.form-group-modern label {
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--sb-blue-dark);
}

.form-control-modern {
    width: 100%;
    padding: 14px 16px; /* slightly larger for balance */
    border-radius: 12px;
    border: 1px solid var(--border);
    background: #fff;
    font-size: 18px; /*  your main change */
    line-height: 1.4;
    transition: all 0.2s ease;
}

textarea.form-control-modern {
    padding: 14px 16px;
    font-size: 18px;
}

.form-control-modern:focus {
    border-color: var(--sb-blue);
    box-shadow: 0 0 0 3px rgba(0, 95, 187, 0.12);
    outline: none;
}

/* Checkbox */
.form-check-modern {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
}

/* Actions */
.form-actions-modern {
    display: flex;
    gap: 12px;
    margin-top: 10px;
}

/* =========================
   PREVIEW CARD
========================= */

.badge-preview-card {
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    background: linear-gradient( 180deg, rgba(255,255,255,0.95), rgba(255,255,255,0.85) );
    padding: 24px;
    text-align: center;
    box-shadow: var(--shadow);
}

.badge-preview-art {
    width: 110px;
    height: 110px;
    margin: 0 auto 16px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid #fff;
    box-shadow: 0 10px 22px rgba(0, 63, 125, 0.18);
}

    .badge-preview-art img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.badge-preview-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: 800;
    color: var(--sb-blue-dark);
    background: linear-gradient(135deg, var(--sb-yellow), var(--butterfly-orange));
}

.badge-preview-name {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--sb-blue-dark);
    margin-bottom: 8px;
}

.badge-preview-desc {
    font-size: 0.9rem;
    color: var(--muted);
}

.snorkel-view {
    display: none;
}

    .snorkel-view.active {
        display: block;
    }

.island-wide-card,
.area-wide-card {
    cursor: pointer;
}

.island-condition-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(320px, 1fr));
    gap: 46px 58px;
    padding: 20px;
}

.island-condition-card {
    position: relative;
    min-height: 245px;
    border: 10px solid #5aaeff;
    background-size: cover;
    background-position: center;
    cursor: pointer;
    overflow: hidden;
    box-shadow: 0 10px 22px rgba(0,0,0,.14);
    transition: transform .18s ease, box-shadow .18s ease;
}

    .island-condition-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 18px 34px rgba(0,0,0,.22);
    }

.island-condition-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    padding: 34px;
    background: rgba(0, 45, 80, .10);
}

    .island-condition-overlay h2 {
        margin: 0;
        color: white;
        font-size: clamp(34px, 4vw, 50px);
        line-height: 1;
        font-weight: 900;
        letter-spacing: -1px;
        text-shadow: 3px 4px 6px rgba(0,0,0,.55);
    }

@media (max-width: 900px) {
    .island-condition-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .island-condition-card {
        min-height: 220px;
    }
}
.area-condition-card {
    padding: 24px;
}

.condition-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 22px;
}

.condition-title {
    margin: 0;
    font-size: 2rem;
    color: var(--sb-blue-dark);
}

.condition-dot,
.table-dot {
    display: inline-block;
    border-radius: 999px;
}

.condition-dot {
    width: 18px;
    height: 18px;
    margin-left: 8px;
}

.table-dot {
    width: 14px;
    height: 14px;
    margin-left: 8px;
}

.condition-score {
    width: 82px;
    height: 82px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: white;
    font-weight: 900;
}

.table-wrap {
    overflow-x: auto;
}

.condition-table {
    width: 100%;
    border-collapse: collapse;
}

.condition-table th {
    background: #0b66c3;
    color: white;
    text-align: left;
    padding: 16px;
    font-weight: 800;
}

.condition-table td {
    padding: 16px;
    border: 1px solid #dbe3ea;
}

.condition-table tbody tr:hover {
    background: rgba(0,95,187,.04);
}

.condition-description {
    margin-top: 24px;
    line-height: 1.8;
    font-size: 1rem;
}

.condition-description strong {
    color: var(--sb-blue-dark);
}

/* =========================
   ASSIGNMENT WORK VIEW
========================= */
.assignment-content-card {
    position: relative;
    overflow: hidden;
}

.assignment-content-card--locked .assignment-content-inner,
.assignment-content-card--locked .section-header {
    filter: blur(6px);
    pointer-events: none;
    user-select: none;
}

.assignment-content-card--locked::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.45);
    z-index: 2;
}

.assignment-content-lock {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-align: center;
    color: var(--sb-blue-dark);
}

.assignment-content-lock i {
    font-size: 2rem;
}

.assignment-content-lock strong {
    font-size: 1.25rem;
}

.assignment-filter-bar {
    max-width: 360px;
    margin-bottom: 24px;
}


/* Assignment card action buttons */
.assignment-card__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: auto;
}

.assignment-card__actions form {
    margin: 0;
}

.assignment-card__actions a,
.assignment-card__actions button {
    width: auto;
    min-width: 150px;
    height: 44px;
}

/* Danger button */
.btn-danger-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 150px;
    height: 44px;
    padding: 0 18px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #ff6b6b, #ef4444);
    color: #fff;
    font-weight: 700;
    font-size: .95rem;
    cursor: pointer;
    transition: all .2s ease;
}

.btn-danger-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(239, 68, 68, .35);
}

/* Assignment test form */
.assignment-test-form {
    max-width: 900px;
    margin: 0 auto;
}

.assignment-test-header {
    text-align: center;
    margin-bottom: 36px;
}

.assignment-test-header h2 {
    margin: 0 0 8px;
    color: var(--sb-blue-dark);
    font-size: 2rem;
    font-weight: 800;
}

.assignment-test-subtitle {
    margin: 0;
    color: var(--muted);
    font-size: 1rem;
}

.question-card {
    background: #fff;
    border: 1px solid #dce8f5;
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 34px;
    box-shadow: 0 6px 18px rgba(17, 43, 60, 0.07);
}

.question-card-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 24px;
}

.question-number {
    flex: 0 0 auto;
    min-width: 34px;
    color: var(--sb-blue);
    font-size: 1.15rem;
    font-weight: 900;
    line-height: 1.5;
}

.question-title {
    flex: 1;
    color: var(--sb-blue-dark);
    font-size: 1.12rem;
    font-weight: 800;
    line-height: 1.55;
}

.question-options {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding-left: 46px;
}

.question-option {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 18px;
    border: 2px solid #dfe7ef;
    border-radius: 12px;
    background: #fff;
    color: #29475b;
    cursor: pointer;
    transition: 0.18s ease;
}

.question-option:hover {
    background: #eef7ff;
    border-color: var(--sb-blue);
}

.question-option input[type="radio"] {
    transform: scale(1.15);
    accent-color: var(--sb-blue);
}

.question-option:has(input:checked) {
    background: #dff1ff;
    border-color: var(--sb-blue);
    box-shadow: 0 0 0 2px rgba(0, 95, 187, 0.12);
}

.option-text {
    font-size: 1rem;
    line-height: 1.45;
}

.assignment-test-footer {
    margin-top: 52px;
    padding-top: 24px;
    border-top: 1px solid #e5edf5;
    text-align: center;
}

.btn-submit-test {
    width: auto;
    min-width: 320px;
    padding: 16px 28px;
    font-size: 1rem;
}

.dashboard-card--wide {
    grid-column: span 2;
}

.dashboard-widget {
    border-radius: 16px;
    overflow: hidden;
    background: #eef6fb;
    min-height: 720px;
}

.dashboard-widget-frame {
    width: 100%;
    height: 720px;
    border: 0;
    display: block;
}

@media (max-width: 640px) {
    .question-card {
        padding: 18px;
    }

    .question-card-header {
        gap: 8px;
    }

    .question-options {
        padding-left: 0;
    }

    .btn-submit-test,
    .assignment-card__actions a,
    .assignment-card__actions button {
        width: 100%;
        min-width: 0;
    }
}
html,
body {
    min-height: 100%;
}

.sidebar {
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.brand-panel {
    flex: 0 0 auto;
}

.sidebar-nav {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-gutter: stable;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.sidebar-footer {
    flex: 0 0 auto;
}

/* Firefox */
.sidebar-nav {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.45) transparent;
}

    /* Chrome, Edge and Safari */
    .sidebar-nav::-webkit-scrollbar {
        width: 7px;
    }

    .sidebar-nav::-webkit-scrollbar-track {
        background: transparent;
    }

    .sidebar-nav::-webkit-scrollbar-thumb {
        background-color: rgba(255, 255, 255, 0.4);
        border-radius: 10px;
    }

        .sidebar-nav::-webkit-scrollbar-thumb:hover {
            background-color: rgba(255, 255, 255, 0.65);
        }
