/* =========================================
   ROOT THEME VARIABLES
========================================= */

:root {
    --primary: #65e4b3;
    --primary-dark: #42c998;
    --primary-light: #9af0cd;

    --text-main: #ffffff;
    --text-soft: rgba(255, 255, 255, 0.9);

    --bg-dark: #0f172a;
    --bg-light: #f8fafc;

    --unizik-green-1: #338a72;
    /* darkest */
    --unizik-green-2: #2b7a63;
    /* darker */
    --unizik-green-3: #4bb08a;
    /* medium-dark */
    --unizik-green-4: #1a5c3d;
    /* lighter, for contrast */
    --unizik-dark-green: #1a5c3d;
    --unizik-light-green: #e1f0e8;
    --input-border: #ced4da;

    --shadow-soft: 0 2px 3px rgba(0, 0, 0, 0.15);
}

/* Light Theme */
[data-theme="light"] {
    --text-main: #ffffff;
    --text-soft: rgba(255, 255, 255, 0.85);
    --navbar-bg: rgba(0, 0, 0, 0.2);
    /* darker overlay */
}

/* Dark Theme */
[data-theme="dark"] {
    --text-main: var(--bg-dark);
    --text-soft: #334155;
    --navbar-bg: rgba(0, 0, 0, 0.2);
    /* darker overlay for consistency */
}













/* LOGIN PAGE STYLES */
/* Background for login page */
.login-bg {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    background: linear-gradient(120deg, var(--unizik-green-1), var(--unizik-green-2), var(--unizik-green-3), var(--unizik-green-4));
    background-size: 1200% 1200%;
    animation: gradientShift 20s ease infinite;
}

/* Admin card / form container */
.admin-card {
    width: 450px;
    /* increased width */
    max-width: 100%;
    /* responsive on small screens */
    padding: 2.5rem 2rem;
    background-color: var(--bg-light);
    border-radius: 1rem;
    box-shadow: var(--shadow-soft);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-block-start: 60px;
}

/* Hover effect for depth */
.admin-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}

@media (max-width: 576px) {
    .login-bg {
        padding: 0;
    }

    .admin-card {
        width: 90%;
    }
}

/* Titles */
.admin-title {
    color: var(--unizik-dark-green);
}

/* Input styling */
.admin-card input.form-control {
    border-radius: 0.5rem;
    border: 1px solid var(--input-border);
    padding: 0.75rem 1rem;
    font-size: 1rem;
}

/* Button styling */
.admin-card button.btn-success {
    border-radius: 0.75rem;
    font-weight: bold;
    background: linear-gradient(120deg, var(--unizik-green-2), var(--unizik-green-3));
    transition: background 0.3s ease, transform 0.2s ease;
}

.admin-card button.btn-success:hover {
    background: linear-gradient(120deg, var(--unizik-green-3), var(--unizik-green-4));
    transform: translateY(-2px);
}

/* Gradient animation keyframes */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}















/* ADMIN DASHBOARD STYLES */
.admin-dashboard {
    margin-block-start: 60px;
}

.dash-cont {
    padding: 50px 140px;
}

.unizik-green-text {
    color: var(--unizik-dark-green);
}

.bg-unizik-dark {
    background-color: var(--unizik-dark-green) !important;
}

.bg-unizik-light {
    background-color: var(--unizik-light-green) !important;
}

.text-unizik-dark {
    color: var(--unizik-dark-green) !important;
}

.btn-unizik-primary {
    background-color: var(--unizik-dark-green);
    color: white;
    border: none;
    border-radius: 8px;
}

.btn-outline-unizik {
    border: 1.5px solid var(--unizik-dark-green);
    color: var(--unizik-dark-green);
    border-radius: 8px;
    background-color: transparent;
}

.btn-unizik-dark {
    background-color: var(--unizik-dark-green);
    color: white;
    border: none;
}

.border-unizik {
    border-color: var(--unizik-dark-green) !important;
}

.search-group {
    border-radius: 12px;
    overflow: hidden;
}

.search-group input:focus {
    box-shadow: none;
    border-color: var(--input-border);
}

/* Active state for filter buttons based on their data-active-class */
.filter-btn.active[data-active-class="btn-unizik-dark"] {
    background-color: #1f7a4d; /* replace with your actual unizik-dark color */
    color: white;
    border-color: #1f7a4d;
}

.filter-btn.active[data-active-class="btn-primary"] {
    background-color: #0d6efd; /* Bootstrap primary */
    color: white;
    border-color: #0d6efd;
}

.filter-btn.active[data-active-class="btn-success"] {
    background-color: #198754; /* Bootstrap success */
    color: white;
    border-color: #198754;
}

.bg-blue-light {
    background-color: #f0f7ff;
}

.bg-green-light {
    background-color: #f0fff4;
}

/* Custom Pill Navigation */
.fixed-bottom {
    max-width: 250px;
    left: 40%;
}

.fixed-bottom .bg-white {
    transition: all 0.3s ease;
    min-width: 100%;
}



/* Update modal CSS Styles */
#edit_passport_preview {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 6px;
}




/* Reduce horizontal padding on small screens */
@media (max-width: 992px) {
    .dash-cont {
        padding: 50px;
    }

    .d-flex.gap-2 {
        flex-wrap: wrap;
        /* wrap buttons or badges */
        gap: 0.5rem;
    }

    .fixed-bottom {
        max-width: 230px;
        left: 35%;
    }

    /* .fixed-bottom .bg-white {
        min-width: 100px;
        flex-direction: column;
    } */

    .fixed-bottom .bg-white a {
        padding: 0.5rem 0.75rem;
        font-size: 0.9rem;
    }

    .row.g-3>[class*="col-"] {
        margin-bottom: 1rem;
        /* spacing between cards */
    }
}


/* Top buttons (Students, Admin Users, Export, Logout) */
@media (max-width: 768px) {
    .dash-cont>.d-flex.justify-content-between {
        flex-direction: column;
        /* stack buttons vertically */
        gap: 0.75rem;
        align-items: stretch;
    }

    .dash-cont>.d-flex.justify-content-between>div.d-flex {
        flex-wrap: wrap;
        /* wrap buttons inside */
        justify-content: space-between;
    }

    .dash-cont .btn {
        flex: 1 1 48%;
        /* 2 buttons per row */
        font-size: 0.85rem;
        padding: 0.5rem 0.75rem;
    }

    #logoutBtn {
        background-color: #fff !important;
        color: #dc3545 !important;
        border: 1px solid #dc3545;
    }
}


/* Extra small screens */
@media (max-width: 576px) {
    .dash-cont {
        padding: 50px 0px;
        width: 90%;
    }

    .search-group .form-control {
        font-size: 13px;
    }

    .search-group .form-control::placeholder {
        font-size: 13px;
    }

    .fixed-bottom {
        left: 22%;
    }

    .fixed-bottom .bg-white a {
        flex: 1 1 100%;
        text-align: center;
    }
}


@media (max-width: 320px) {
    .fixed-bottom {
        left: 14%;
    }
}














/* PROFILE PAGE CSS STYLES */
/* Custom Styles utilizing your variables */

.profile-container {
    background-color: var(--bg-light);
    min-height: 100vh;
}

.prof-cont {
    margin-top: 70px;
}

.text-unizik-dark {
    color: var(--unizik-dark-green) !important;
}

.bg-unizik-light {
    background-color: var(--unizik-light-green) !important;
}

/* Action Buttons */
.btn-primary-action {
    background-color: #4c8bf5;
    /* Bootstrap-style Blue from image */
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.85rem;
}

.btn-unizik-action {
    background-color: var(--unizik-dark-green);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.85rem;
}

/* Profile Image */
.profile-img-wrapper {
    width: 150px;
    height: 150px;
    position: relative;
}

.profile-placeholder {
    width: 100%;
    height: 100%;
    background-color: #f1f5f9;
    border: 1px solid var(--input-border);
    display: flex;
    align-items: center;
    justify-content: center;
}

#profile_passport {
    width: 100%;
    height: 100%;
    object-fit: fill;
    border-radius: 0.5rem;
}

/* Info List Items */
.info-icon {
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.info-list .border-bottom {
    border-bottom: 1px solid #f1f5f9 !important;
}






/* ==========================
   GENERAL PROFILE & PAGE STYLES
   ========================== */
.profile-container {
    background-color: var(--bg-light);
    min-height: 100vh;
    padding: 0 10px;
}

.prof-cont {
    margin-top: 70px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 5px;
}

/* Profile Image */
.profile-img-wrapper {
    width: 150px;
    height: 150px;
    margin: 0 auto 1rem auto;
    position: relative;
}


/* Buttons */
.btn-primary-action,
.btn-unizik-action {
    font-size: 0.85rem;
    padding: 0.5rem 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

/* Info text */
.info-item small {
    font-size: 0.75rem;
}

.info-item span {
    font-size: 0.8rem;
    word-break: break-word;
}

/* Badges */
.badge {
    font-size: 0.75rem;
    padding: 0.3rem 0.7rem;
}

/* QR */
.qr-wrapper {
    width: 180px;
    height: 180px;
    margin: 0 auto;
}

/* Virtual ID text */
.qr-wrapper+p {
    font-size: 0.65rem;
    text-align: center;
}

/* Fixed bottom nav */
.fixed-bottom .btn {
    font-size: 0.75rem;
    padding: 0.4rem 0;
}

/* ==========================
   RESPONSIVE MEDIA QUERIES
   ========================== */

/* Medium phones: 576px to 767px */
@media (max-width: 767px) {
    .profile-img-wrapper {
        width: 120px;
        height: 120px;
    }

    .btn-primary-action,
    .btn-unizik-action {
        font-size: 0.8rem;
        padding: 0.4rem 0.6rem;
    }

    .info-item small {
        font-size: 0.65rem;
    }

    .info-item span {
        font-size: 0.75rem;
    }

    .badge {
        font-size: 0.65rem;
        padding: 0.25rem 0.6rem;
    }

    #profile_name {
        font-size: 1rem;
        word-break: break-word;
        text-align: center;
    }

    .qr-wrapper {
        width: 140px;
        height: 140px;
    }

    .qr-wrapper+p,
    .text-muted {
        font-size: 0.6rem;
    }
}

/* Small phones: <576px */
@media (max-width: 575px) {
    .profile-img-wrapper {
        width: 100px;
        height: 100px;
    }

    .btn-primary-action,
    .btn-unizik-action {
        font-size: 0.7rem;
        padding: 0.35rem 0.5rem;
    }

    .info-item small {
        font-size: 0.6rem;
    }

    .info-item span {
        font-size: 0.7rem;
    }

    .badge {
        font-size: 0.6rem;
        padding: 0.2rem 0.5rem;
    }

    #profile_name {
        font-size: 0.9rem;
        word-break: break-word;
        text-align: center;
    }

    .qr-wrapper {
        width: 120px;
        height: 120px;
    }

    .qr-wrapper+p,
    .text-muted {
        font-size: 0.55rem;
    }
}

/* Extra small devices: <400px */
@media (max-width: 400px) {

    .btn-primary-action,
    .btn-unizik-action {
        font-size: 0.65rem;
        padding: 0.3rem 0.5rem;
    }

    .info-item small {
        font-size: 0.55rem;
    }

    .info-item span {
        font-size: 0.65rem;
    }

    .badge {
        font-size: 0.55rem;
        padding: 0.2rem 0.4rem;
    }

    #profile_name {
        font-size: 0.85rem;
    }

    .qr-wrapper {
        width: 100px;
        height: 100px;
    }

    .qr-wrapper+p,
    .text-muted {
        font-size: 0.5rem;
    }
}













/* ID-CARD PAGE STYLES */
.student-id {
    width: 380px;
    height: 600px;
    background: #ffffff;
    border-radius: 10px;
    /* key for absolute children */
    font-family: 'Arial Narrow', sans-serif;
    overflow: hidden;
    color: #000;
    display: flex;
    flex-direction: column;
    /* stack content vertically */
    backface-visibility: hidden;
    position: absolute;
    top: 0;
    left: 0;
}

.top-wave {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 30px;
    z-index: 0;
}

.id-header {
    position: relative;
    z-index: 2;
    padding: 15px 0px 5px 0px;
    margin-top: 10px;
    display: flex;
    justify-content: center;
}

.logo {
    width: 50px;
    height: 60px;
}

.header-text {
    margin-left: 10px;
}

.header-text h4 {
    font-size: 22px;
    font-weight: bold;
    letter-spacing: 0.2px;
    font-family: 'Anton', 'Arial Narrow', Arial, sans-serif;
}

.sub-header {
    font-size: 13px;
    font-weight: 700;
    text-align: center;
    padding-right: 50px;
}

@media (max-width: 576px) {
    .header-text h4 {
        font-size: 17px;
        font-weight: bolder;
    }

    .sub-header {
        font-size: 12px;
    }
}

.type-label {
    font-size: 21px;
    font-weight: 800;
    color: #2b5983;
    border: 2px solid #2b5983;
    border-radius: 12px;
    padding: 8px 16px;
    display: inline-block;
}

/* Passport Frame */
.passport-wrapper {
    margin: 10px 0;
    display: flex;
    justify-content: center;
}

.passport-frame {
    width: 220px;
    height: 220px;
    border: 4px solid #8a6a45;
    /* Bronze border from image */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.passport {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: fill;
}

/* Content Details */
.student-name {
    font-size: 24px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .4px;
    margin: 7px 10px;
    text-shadow: 0 2px 2px rgba(0, 0, 0, 0.7);
}

.detail-group {
    margin-bottom: 5px;
}

.label {
    font-size: 14px;
    font-weight: 400;
    line-height: 1;
}

.value {
    font-size: 21px;
    font-weight: 800;
    text-transform: uppercase;
    color: #111;
}

/* Bottom Area */
.qr {
    width: 70px;
    height: 70px;
}

.number {
    font-size: 19px;
    font-weight: 800;
    margin-top: 2px;
}

/* Left side */
.reg-left {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    /* left aligned */
    font-size: 12px;
    font-weight: 700;
    line-height: 1.1;
}

.reg-left .label-top,
.reg-left .label-bottom {
    margin: 0;
    line-height: 1;
}



/* Right side */
.reg-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.1;
    /* tighter */
}

.label-top,
.label-bottom {
    margin: 0;
    line-height: 1;
    /* remove extra spacing */
}

.grad-year {
    font-size: 19px;
    font-weight: 800;
    margin-top: 2px;
}

/* The footer wave design */
.bottom-section {
    /* remove relative positioning and padding */
    flex-shrink: 0;
    /* ensure bottom-section doesn't shrink */
}


.bottom-curves-wrapper {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 30px;
    overflow: hidden;
}

.bottom-curves {
    width: 100%;
    height: 100%;
}



/* Animation Container */
.id-card-wrapper {
    perspective: 1000px;
    width: 380px;
    height: 630px;
}

.id-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s ease-in-out;
    transform-style: preserve-3d;
}

/* Flip Class */
.id-card-inner.flipped {
    transform: rotateY(180deg);
}


/* Back Face Styling */
.back-face {
    transform: rotateY(180deg);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding-bottom: 0;
}

.registrar-text {
    font-size: 19px;
    line-height: 1.5;
    color: #333;
}

.qr-large {
    width: 200px;
    height: 200px;
    border: 1px solid #ddd;
    padding: 10px;
    border-radius: 10px;
}

.verify-link {
    font-size: 16px;
    color: #5c6e9e;
    text-decoration: none;
    font-weight: bold;
}

.validity-text h4 {
    font-family: 'Arial Narrow Bold', sans-serif;
    font-size: 20px;
}

.bottom-curves-back {
    width: 100%;
    height: 25px;
}

#closeModal {
    top: 10px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
    z-index: 10;
    background-color: crimson;
    padding: 4px 7px;
    color: #ffffff;
    border-radius: 5px;
}

#closeModal:hover {
    background-color: rgb(245, 115, 141);
}












/*Today Males*/
.today-container {
    margin-top: 100px;
}

.passport-img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 12px;
    border: 2px solid #e9ecef;
}

.table tbody tr {
    transition: 0.2s ease;
}

.table tbody tr:hover {
    background-color: #f8fafc;
}

.card {
    transition: 0.2s ease;
}

.card:hover {
    transform: translateY(-2px);
}