:root {
    --lulus-primary: #15803d;
    --lulus-secondary: #22c55e;
    --lulus-accent: #facc15;
    --lulus-bg: #f8fafc;
    --lulus-card-bg: rgba(255, 255, 255, 0.98);
    --lulus-bg-gradient: linear-gradient(135deg, #d4fc79 0%, #15803d 100%);
    --lulus-text: #1e293b;
    --lulus-text-light: #64748b;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0) rotate(0);
    }

    50% {
        transform: translateY(-15px) rotate(5deg);
    }
}

@keyframes shine {
    0% {
        left: -100%;
        opacity: 0;
    }

    20% {
        opacity: 0.5;
    }

    100% {
        left: 100%;
        opacity: 0;
    }
}

.animate-up {
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.delay-1 {
    animation-delay: 0.2s;
}

.delay-2 {
    animation-delay: 0.4s;
}

.floating-deco {
    position: absolute;
    color: rgba(255, 255, 255, 1);
    font-size: 2.5rem;
    pointer-events: none;
    z-index: 2;
    animation: float 6s infinite ease-in-out;
}

html {
    scroll-behavior: smooth;
}

body {
    position: relative;
    overflow-x: hidden;
    background-color: var(--lulus-bg);
    line-height: 1.5;
    -webkit-overflow-scrolling: touch;
}

.overflow-hidden {
    overflow: hidden !important;
}

.table-responsive {
    display: block;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: inherit;
    overflow-y: hidden;
}

/* Global Sticky Column Utilities */
.sticky-col-check {
    position: sticky !important;
    left: 0;
    width: 45px;
    z-index: 15 !important;
    box-shadow: 2px 0 0 0 #f8fafc;
}

.sticky-col-no {
    position: sticky !important;
    left: 45px;
    width: 43px;
    z-index: 14 !important;
    box-shadow: 2px 0 0 0 #f8fafc, -2px 0 0 0 #f8fafc;
}

.sticky-col-name {
    position: sticky !important;
    left: 78px;
    width: 254px;
    z-index: 13 !important;
    border-right: 2px solid #f1f5f9 !important;
    text-align: left !important;
    box-shadow: 2px 0 0 0 #f8fafc, -2px 0 0 0 #f8fafc;
}

/* Header Sticky - Consistent Light */
thead .sticky-col-check,
thead .sticky-col-no,
thead .sticky-col-name {
    background-color: #f8fafc !important;
}

/* Body Sticky - Sync Styles */
tbody tr td.sticky-col-check,
tbody tr td.sticky-col-no,
tbody tr td.sticky-col-name {
    background-color: #ffffff !important;
    background-clip: padding-box;
    box-shadow: 2px 0 0 0 #ffffff, -2px 0 0 0 #ffffff;
}

/* Row-Status Sync for Sticky Columns & Gaskets */
tbody tr.tr-lulus td.sticky-col-check,
tbody tr.tr-lulus td.sticky-col-no,
tbody tr.tr-lulus td.sticky-col-name {
    background-color: #f1fbf5 !important;
    box-shadow: 2px 0 0 0 #f1fbf5, -2px 0 0 0 #f1fbf5 !important;
}

tbody tr.tr-tidak-lulus td.sticky-col-check,
tbody tr.tr-tidak-lulus td.sticky-col-no,
tbody tr.tr-tidak-lulus td.sticky-col-name {
    background-color: #fdf2f2 !important;
    box-shadow: 2px 0 0 0 #fdf2f2, -2px 0 0 0 #fdf2f2 !important;
}

tbody tr.tr-lulus-bersyarat td.sticky-col-check,
tbody tr.tr-lulus-bersyarat td.sticky-col-no,
tbody tr.tr-lulus-bersyarat td.sticky-col-name {
    background-color: #fffaf0 !important;
    box-shadow: 2px 0 0 0 #fffaf0, -2px 0 0 0 #fffaf0 !important;
}

/* Ensure table inside glass-card follows the rounding */
.glass-card .table {
    border-collapse: separate !important;
    border-spacing: 0 !important;
    width: 100%;
    border-radius: inherit;
}

/* Public Landing Styles V2 */
.public-landing {
    min-height: 100vh;
    background: white;
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
}

.landing-bg-wrapper {
    position: absolute;
    transform: rotate(-10deg);
    border-radius: 150px;
    z-index: -1;
    top: -250px;
    /* Lebih ke atas untuk tutup celah */
    left: -80px;
    /* Lebih ke kiri untuk tutup celah */
    right: -50px;
    bottom: 150px;
    /* Lebih ke bawah agar hijau dominan */
    background: var(--lulus-bg-gradient);
    overflow: hidden;
}

/* Un-skew the bokeh only */
.bokeh-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    /* Prevent floating bokeh from leaking out */
}

.bokeh {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    filter: blur(40px);
    animation: floating 15s infinite ease-in-out;
}

@keyframes floating {

    0%,
    100% {
        transform: translate(0, 0);
    }

    50% {
        transform: translate(30px, -50px);
    }
}

.public-content {
    position: relative;
    z-index: 10;
    padding: clamp(60px, 10vh, 120px) 5% 120px 5%;
    min-height: 100vh;
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.bokeh-polygon {
    position: absolute;
    background: rgba(255, 255, 255, 0.08);
    clip-path: polygon(30% 0%, 70% 0%, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0% 70%, 0% 30%);
    animation: floating 20s infinite ease-in-out;
}

:root {
    --h: 76px;
    /* Even number for perfect 50% split (38px) */
    --w: 52px;
}

.flip-clock {
    display: flex;
    gap: 4px;
    perspective: 2000px;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: center;
}

.flip-colon {
    font-size: 28px;
    font-weight: 700;
    color: white;
    margin: 0 4px;
    height: var(--h);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.9;
    padding-top: 2px;
    /* Subtle optical adjustment only */
}

.flip-segment {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0 2px;
}

.flip-unit {
    position: relative;
    width: var(--w);
    height: var(--h);
    background: #0d1629;
    border-radius: 4px;
    font-size: 56px;
    /* Slightly adjusted */
    font-weight: 700;
    letter-spacing: -1px;
    color: white;
    perspective: 1000px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
    margin-bottom: 25px;
    font-family: 'Segoe UI', Tahoma, Arial, sans-serif;
}

/* Ensure digits inside card are balanced */
.flip-unit .d-flex {
    gap: 4px !important;
    /* Spacing between digits within a unit */
}

/* Base containers for halves */
.upper,
.lower {
    position: absolute;
    left: 0;
    width: 100%;
    height: 50%;
    overflow: hidden;
    background: #0d1629;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

.leaf-front,
.leaf-back {
    position: absolute;
    left: 0;
    width: 100%;
    height: 100%;
    /* Fill the 50% parent (.flip-leaf) */
    overflow: hidden;
    background: #0d1629;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}



/* Static containers are 50% of unit */
.upper {
    top: 0;
    border-radius: 4px 4px 0 0;
    z-index: 2;
}

.lower {
    bottom: 0;
    border-radius: 0 0 4px 4px;
    z-index: 1;
}

/* THE MAGIC: Bulletproof State-Sync Centering */
.flip-unit span {
    display: block;
    position: absolute;
    left: 0;
    width: 100%;
    height: var(--h);
    /* Full unit height */
    line-height: var(--h);
    /* Perfect vertical center via line-height */
    text-align: center;
    -webkit-font-smoothing: antialiased;
}

/* Positioning mapping */
.upper span,
.leaf-front span {
    top: 0;
}

.lower span,
.leaf-back span {
    bottom: 0;
}

.flip-leaf {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 50%;
    z-index: 20 !important;
    /* Higher than stationary cards */
    transform-origin: bottom;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
}

.flipping .flip-leaf {
    transform: rotateX(-180deg);
}

.leaf-front {
    z-index: 12;
    background: #0d1629;
    border-radius: 4px 4px 0 0;
}

.leaf-back {
    transform: rotateX(-180deg);
    z-index: 11;
    background: #0d1629;
    border-radius: 0 0 4px 4px;
}


.flip-label {
    font-size: 11px;
    /* Slightly smaller labels */
    text-transform: uppercase;
    color: #ffffff;
    font-weight: 700;
    letter-spacing: 2px;
    text-align: center;
    margin-top: -5px;
    /* Pull labels up closer */
}

.landing-header h1 {
    font-size: clamp(2.2rem, 10vw, 5.5rem);
    font-weight: 900;
    color: white;
    line-height: 0.95;
    margin-bottom: 25px;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.landing-header p {
    color: var(--lulus-accent);
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 15px;
    font-size: clamp(0.8rem, 2vw, 1.2rem);
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.2;
    }
}

.blink-text {
    animation: blink 2s infinite ease-in-out;
}

.mascot-box {
    text-align: center;
    width: 100%;
    margin-top: 20px;
    position: relative;
    z-index: 5;
}


.mascot-img {
    max-width: clamp(250px, 45vw, 550px);
    width: 100%;
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.2));
    animation: bounce 4s infinite ease-in-out;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-20px);
    }
}




/* Fading Animation for Motivational Text */
.fading-container {
    width: 100%;
    background: rgba(0, 0, 0, 0.05);
    padding: 12px 0;
    position: relative;
    z-index: 5;
    text-align: center;
    min-height: 50px;
}

.fading-text {
    font-weight: 700;
    color: var(--lulus-primary);
    font-size: 1.1rem;
    letter-spacing: 2px;
    animation: fadeUpDown 4s infinite ease-in-out;
}

@keyframes fadeUpDown {

    0%,
    100% {
        opacity: 0;
        transform: translateY(10px);
    }

    30%,
    70% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Label Pengumuman Custom - Removed based on user request */

/* Restore Login Card Glass */
/* Restore Login Card Glass */
.login-card-glass {
    background: rgba(21, 128, 61, 0.35) !important;
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 40px;
    padding: 60px 40px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    color: white;
}

.login-card-glass::after {
    display: none;
}

.login-card-glass h3 {
    color: white;
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 35px !important;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.login-card-glass .input-group {
    background: #f8fafc !important;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    transition: all 0.3s;
    padding: 12px 10px;
    margin-bottom: 25px;
}

.login-card-glass .input-group:focus-within {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    background: #ffffff !important;
}

.login-card-glass .form-control {
    font-size: 1.15rem;
    font-weight: 500;
    color: #1e293b !important;
    background: transparent !important;
}

.login-card-glass .input-group-text i {
    font-size: 1.4rem;
    color: #166534 !important;
}

.login-card-glass .btn-primary {
    background: #166534 !important;
    border-radius: 30px !important;
    padding: 18px !important;
    font-size: 1.2rem;
    font-weight: 800;
    letter-spacing: 1.5px;
    border: none;
    transition: all 0.3s;
    margin-top: 15px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.login-card-glass .btn-primary:hover {
    background: #14532d !important;
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

/* Profile Logout Button */
.profile-logout-btn {
    position: fixed;
    top: 25px;
    right: 30px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(15px);
    border-radius: 50px;
    padding: 5px 20px 5px 5px;
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none !important;
    color: white !important;
    font-weight: 700;
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.profile-logout-btn:hover {
    background: white;
    color: var(--lulus-primary) !important;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.profile-icon-circle {
    width: 35px;
    height: 35px;
    background: var(--lulus-accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #15803d;
    font-size: 1.1rem;
}

/* Shared Top Left Logo Branding */
.school-logo-top {
    position: fixed;
    top: 25px;
    left: 30px;
    z-index: 1000;
    transition: all 0.3s ease;
}

.school-logo-top img {
    height: 60px;
    width: auto;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.15));
}


.profile-logout-btn:hover .profile-icon-circle {
    background: var(--lulus-primary);
    color: white;
}

/* Realistic Envelope Styles V6 - Final Polished Air Mail */
.envelope-wrapper {
    position: relative;
    width: 360px;
    height: 240px;
    margin: 80px auto;
    perspective: 1500px;
}

.envelope-container {
    position: relative;
    width: 100%;
    height: 100%;
    background: #fff;
    /* Stripes as border */
    border: 8px solid transparent;
    border-image: repeating-linear-gradient(135deg,
            #ff4b4b,
            #ff4b4b 15px,
            #fff 15px,
            #fff 30px,
            #4b73ff 30px,
            #4b73ff 45px,
            #fff 45px,
            #fff 60px) 10;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
    cursor: pointer;
    overflow: visible;
}

.envelope-container:hover {
    transform: translateY(-5px) rotateX(5deg);
}

.envelope-back {
    position: absolute;
    width: 100%;
    height: 100%;
    background: #fdfdfd;
    z-index: 1;
}

.envelope-top {
    position: absolute;
    top: -4px;
    left: -4px;
    width: calc(100% + 8px);
    height: 100%;
    z-index: 20;
    transform: translateZ(10px);
    /* Front when closed */
    transform-origin: top;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    clip-path: polygon(0% 0%, 50% 55%, 100% 0%);
    background: #fdfdfd;
    border-bottom: 2px solid rgba(0, 0, 0, 0.03);
}

.envelope-container.open .envelope-top {
    transform: rotateX(170deg) translateZ(-5px);
    /* Push behind paper */
    z-index: 1;
    background: #fdfdfd;
}

.envelope-front {
    position: absolute;
    bottom: -4px;
    left: -4px;
    width: calc(100% + 8px);
    height: 100%;
    z-index: 10;
    transform: translateZ(5px);
    pointer-events: none;
    background: #fff;
    /* Solid body */
    clip-path: polygon(0% 0%, 50% 45%, 100% 0%, 100% 100%, 0% 100%);
    /* V-notch at top! */
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.03);
}

/* Remove old complex flaps */
.envelope-front::before,
.envelope-front::after,
.envelope-right {
    display: none;
}

.envelope-front h6 {
    position: absolute;
    top: 65%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #475569;
    text-align: center;
    z-index: 25;
    /* Always on top */
    transition: opacity 0.3s;
}

.envelope-container.open .envelope-front h6 {
    opacity: 0;
}

/* Paper Inside stays within the pocket area */
.paper {
    position: absolute;
    bottom: 0;
    left: 15px;
    width: calc(100% - 30px);
    height: 180px;
    background: white;
    z-index: 5;
    transform: translateY(150px) translateZ(2px);
    /* Tucked in depth */
    padding: 15px;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border-radius: 4px;
    opacity: 0;
}

.envelope-container.open .paper {
    transform: translateY(-110px) translateZ(2px);
    /* Peek through the V-notch */
    opacity: 1;
    z-index: 5;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    transition-delay: 0.3s;
}

/* Splatter Effect */
.splatter-box {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    width: 300px;
    height: 300px;
    z-index: 100;
    pointer-events: none;
    opacity: 0;
    transition: all 0.5s;
}

.splatter-box.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

@keyframes burst {
    0% {
        transform: translate(-50%, -50%) scale(0);
        opacity: 0;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.5);
        opacity: 1;
    }

    100% {
        transform: translate(-50%, -50%) scale(2);
        opacity: 0;
    }
}

.splatter-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Results Reveal Classes */
.result-reveal {
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.5s 0.6s;
}

.envelope-container.open .result-reveal {
    opacity: 1;
    transform: translateY(0);
}

/* Profile Logout Button is handled above */

body.lulus-admin {
    background-color: var(--lulus-bg);
    background-image:
        radial-gradient(at 0% 0%, rgba(79, 70, 229, 0.05) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(14, 165, 233, 0.05) 0px, transparent 50%);
    font-family: 'Outfit', sans-serif;
    color: var(--lulus-text);
}

.glass-card {
    background: var(--lulus-card-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.02);
    transition: all 0.3s ease;
    overflow: hidden;
    /* Restored for perfect corner clipping */
}

.premium-sidebar {
    width: 280px;
    height: 100vh;
    background: white;
    position: fixed;
    border-right: 1px solid #f1f5f9;
    padding: 2rem 1.5rem;
    z-index: 5000;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar-link {
    display: flex;
    align-items: center;
    padding: 0.85rem 1.25rem;
    color: var(--lulus-text-light);
    text-decoration: none !important;
    border-radius: 12px;
    margin-bottom: 0.5rem;
    font-weight: 500;
    transition: all 0.2s;
}

.sidebar-link i {
    width: 24px;
    font-size: 1.1rem;
    margin-right: 0.75rem;
}

.sidebar-link:hover {
    background: rgba(79, 70, 229, 0.05);
    color: var(--lulus-primary);
}

.sidebar-link.active {
    background: var(--lulus-primary);
    color: white;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.main-content {
    margin-left: 280px;
    padding: 2rem;
    min-height: 100vh;
    padding-bottom: 5rem;
    /* Ensure space for bulk action bar */
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    padding: 1rem 0.7rem;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 20px -5px rgba(0, 0, 0, 0.1);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.stat-val {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--lulus-text);
}

.stat-label {
    font-size: 0.85rem;
    color: var(--lulus-text-light);
    font-weight: 500;
}

.premium-table thead th {
    background: #f8fafc;
    border: none;
    padding: 1rem;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--lulus-text-light);
    letter-spacing: 0.5px;
}

.premium-table tbody td {
    padding: 1rem;
    vertical-align: middle;
    border-bottom: 1px solid #f1f5f9;
}

.btn-premium {
    padding: 0.6rem 1.25rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Modals & Forms */
.premium-fieldset {
    border: 2.5px solid #f1f5f9;
    border-radius: 16px;
    padding: 0 15px 5px 15px;
    margin-bottom: 25px;
    position: relative;
    transition: border-color 0.3s;
}

.premium-fieldset:focus-within {
    border-color: var(--lulus-primary);
}

.premium-legend {
    width: auto;
    float: none;
    padding: 0 8px;
    font-size: 11px;
    font-weight: 800;
    color: var(--lulus-text-light);
    text-transform: uppercase;
    margin-bottom: 0;
}

.premium-fieldset input,
.premium-fieldset select,
.premium-fieldset textarea {
    width: 100%;
    border: none !important;
    background: transparent !important;
    padding: 10px 0;
    font-weight: 600;
    color: var(--lulus-text);
    outline: none !important;
}

/* Responsive Layouts */
.mobile-header {
    display: none;
    background: white;
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 5010;
    /* Much higher to stay above everything but the sidebar */
    align-items: center;
    justify-content: space-between;
    height: 60px;
}

.hamburger {
    font-size: 1.5rem;
    color: var(--lulus-text);
    background: none;
    border: none;
    padding: 0;
    position: relative;
    z-index: 1001;
    cursor: pointer;
}

.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 4999;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    display: block;
    opacity: 1;
}

/* Bulk Action Bar (Universal Base) */
.bulk-action-bar {
    position: fixed;
    bottom: -200px;
    left: 50%;
    transform: translateX(-50%);
    width: auto;
    max-width: 95%;
    min-width: 320px;
    height: auto;
    background: #1e293b;
    border-radius: 20px;
    z-index: 900;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    padding: 12px;
}

.bulk-action-bar.show {
    bottom: 30px;
}

/* ==========================================================================
   Responsive Adjustments & Mobile Optimization (Admin Lulus)
   ========================================================================== */

/* Desktop Refinements (992px and up) */
@media (min-width: 992px) {
    .mascot-box {
        margin-top: 50px;
    }

    .public-content {
        align-items: flex-start;
        text-align: left;
        padding-top: clamp(120px, 15vh, 200px);
    }

    .flip-clock {
        justify-content: flex-start !important;
        flex-wrap: nowrap !important;
    }

    .mascot-box {
        text-align: right !important;
        margin-top: -360px;
        position: relative;
        z-index: 20;
    }

    .mascot-img {
        max-width: clamp(300px, 45vw, 500px);
        filter: drop-shadow(0 15px 35px rgba(0, 0, 0, 0.25));
    }
}

/* Common Mobile/Tablet Fixes (Below 992px) */
@media (max-width: 991.98px) {
    .public-content {
        padding: 40px 15px;
        text-align: center;
    }

    .flip-clock {
        justify-content: center !important;
        gap: 15px !important;
    }

    .mascot-box {
        margin-top: 30px;
    }

    .school-logo-top {
        position: absolute !important;
        top: 15px !important;
        left: 15px !important;
        transform: scale(0.65);
        transform-origin: top left;
    }

    .premium-sidebar {
        left: -280px;
        top: 0;
        height: 100vh;
        transition: all 0.3s ease;
        z-index: 5020;
        /* Keep sidebar above the fixed header */
    }

    .premium-sidebar.active,
    .premium-sidebar.show {
        left: 0;
    }

    .main-content {
        margin-left: 0 !important;
        padding: 1rem;
        padding-top: 80px !important;
        /* Adjust for fixed mobile-header (60px) + gap */
        padding-bottom: 120px;
        width: 100% !important;
        max-width: 100vw !important;
        overflow-x: hidden !important;
    }

    .main-content>.d-flex.justify-content-between {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 1.5rem;
    }

    .main-content>.d-flex.justify-content-between>div:last-child {
        width: 100%;
        display: flex;
        flex-wrap: wrap;
        gap: 0.75rem;
    }

    .main-content>.d-flex.justify-content-between>div:last-child .btn {
        width: 100% !important;
        margin-bottom: 5px;
        justify-content: center;
    }

    .mobile-header {
        display: flex;
    }

    .sidebar-overlay.active,
    .sidebar-overlay.show {
        display: block;
        opacity: 1;
        z-index: 4999;
        /* Just below sidebar */
    }

    /* Stats & Tables */
    .stat-grid {
        grid-template-columns: 1fr;
    }

    /* Bulk Action Bar (Mobile Grid) */
    .bulk-action-bar {
        width: 94%;
        min-width: 280px;
        bottom: -250px;
        padding: 0.8rem 1rem;
        border-radius: 20px;
        left: 50%;
        transform: translateX(-50%);
        box-shadow: 0 -10px 25px rgba(0, 0, 0, 0.2) !important;
        z-index: 900;
    }

    .bulk-action-bar.show {
        bottom: 15px;
    }

    .bulk-action-bar .d-flex {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .bulk-action-bar .text-white {
        grid-column: span 2;
        text-align: center;
        margin-bottom: 2px;
        font-size: 0.75rem;
        opacity: 0.8;
    }

    .bulk-action-bar .btn-sm {
        width: 100%;
        padding: 8px 4px !important;
        font-size: 0.7rem !important;
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 4px;
        border-radius: 10px;
    }

    .bulk-action-bar .btn-outline-light {
        grid-column: span 2;
        margin-top: 2px;
        padding: 6px !important;
    }

    .bulk-action-bar .vr {
        display: none !important;
    }

    /* Flip Clock Mobile Scales */
    :root {
        --h: 68px;
        --w: 46px;
    }

    .flip-unit {
        font-size: 50px;
    }
}

/* Small Screens (Max 768px) */
@media (max-width: 768px) {
    .landing-bg-wrapper {
        padding: 10px;
    }

    .public-content {
        padding-top: 20px !important;
    }
}

/* Tiny Screens (Max 576px) */
@media (max-width: 575.98px) {
    .landing-header h1 {
        font-size: 2rem !important;
    }

    .flip-clock {
        grid-template-columns: repeat(2, auto);
        display: grid !important;
        gap: 15px 10px !important;
        justify-content: center;
        width: fit-content;
        margin: 20px auto !important;
    }

    .flip-colon {
        display: none !important;
    }

    .flip-segment {
        margin: 0 !important;
        width: 100px;
    }

    .public-landing {
        min-height: auto !important;
        padding-top: 110px !important;
    }

    .landing-bg-wrapper {
        top: -100px;
        left: -10%;
        right: -10%;
        width: 120%;
        bottom: 0;
        border-radius: 40px;
        transform: rotate(-3deg);
    }

    :root {
        --h: 56px;
        --w: 38px;
    }

    .flip-unit {
        font-size: 40px !important;
        margin-bottom: 12px !important;
    }

    .mascot-box {
        order: -1;
        margin-bottom: 15px;
    }

    .mascot-img {
        max-width: 130px;
        margin: 0 auto;
        display: block;
    }
}

/* Ultra-Compact Layouts (Max 480px) */
@media (max-width: 480px) {
    .profile-logout-btn {
        top: 20px !important;
        right: 20px !important;
        padding: 0 !important;
        width: 45px !important;
        height: 45px !important;
        border-radius: 50% !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        z-index: 9999 !important;
        background: var(--lulus-accent) !important;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3) !important;
        border: 2px solid white !important;
    }

    .profile-logout-btn span {
        display: none !important;
    }

    .envelope-wrapper {
        transform: scale(0.85);
        margin: 10px auto 40px auto !important;
    }
}