/* css/app.css */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

body {
    font-family: 'Inter', sans-serif;
    background-color: #f8f9fa;
    color: #212529;
}

/* Auth Page specific */
.auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0d6efd 0%, #0dcaf0 100%);
    padding: 1rem;
}

.auth-card {
    background: #fff;
    border-radius: 1rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    overflow: hidden;
    width: 100%;
    max-width: 900px;
    display: flex;
}

.auth-sidebar {
    background: #0d6efd;
    color: white;
    padding: 3rem;
    width: 40%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.auth-form-area {
    padding: 3rem;
    width: 60%;
}

@media (max-width: 768px) {
    .auth-card {
        flex-direction: column;
    }
    .auth-sidebar, .auth-form-area {
        width: 100%;
    }
}

/* Dashboard Layout */
.wrapper {
    display: flex;
    height: 100vh;
    overflow: hidden;
    position: relative;
}

.sidebar {
    width: 260px;
    background: #ffffff;
    border-right: 1px solid #dee2e6;
    display: flex;
    flex-direction: column;
    transition: all 0.3s;
    z-index: 1000;
}

.sidebar-header {
    padding: 1.5rem;
    font-weight: 700;
    font-size: 1.25rem;
    color: #0d6efd;
    border-bottom: 1px solid #dee2e6;
}

.sidebar-nav {
    flex: 1;
    overflow-y: auto;
    padding: 1rem 0;
}

.nav-link {
    color: #495057;
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
}

.nav-link:hover, .nav-link.active {
    background-color: #f8f9fa;
    color: #0d6efd;
}

.main-panel {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    background-color: #f8f9fa;
}

.top-navbar {
    background: #ffffff;
    border-bottom: 1px solid #dee2e6;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
}

.content-wrapper {
    flex: 1;
    padding: 1.5rem;
    overflow-y: auto;
    min-width: 0;
}

/* Components */
.stat-card {
    border-radius: 0.75rem;
    border: none;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: transform 0.2s;
}

.stat-card:hover {
    transform: translateY(-3px);
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.table-responsive {
    background: #fff;
    border-radius: 0.75rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    padding: 1rem;
    overflow-x: auto;
}

.mobile-sidebar-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 1040;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

@media (max-width: 1199.98px) {
    .top-navbar {
        height: auto;
        min-height: 60px;
        padding: 0.75rem 1rem;
        gap: 0.5rem;
        flex-wrap: wrap;
    }
    .top-navbar .top-left {
        min-width: 0;
    }
    #page-title {
        font-size: 1.05rem !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 52vw;
    }
}

@media (max-width: 991.98px) {
    .wrapper {
        overflow: visible;
    }
    .sidebar {
        position: fixed;
        top: 0;
        left: -270px;
        height: 100vh;
        width: 260px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.2);
        z-index: 1050;
    }
    .wrapper.menu-open .sidebar {
        left: 0;
    }
    .wrapper.menu-open + .mobile-sidebar-backdrop,
    .wrapper.menu-open ~ .mobile-sidebar-backdrop {
        opacity: 1;
        pointer-events: auto;
    }
    .main-panel {
        width: 100%;
    }
    .content-wrapper {
        padding: 1rem;
    }
    .table-responsive {
        padding: 0.5rem;
        border-radius: 0.6rem;
    }
}

@media (max-width: 767.98px) {
    .sidebar-header {
        padding: 1rem 1.2rem;
        font-size: 1.1rem;
    }
    .nav-link {
        padding: 0.7rem 1.2rem;
        font-size: 0.98rem;
    }
    .content-wrapper {
        padding: 0.75rem;
    }
    .card {
        border-radius: 0.65rem !important;
    }
    .table {
        font-size: 0.9rem;
    }
    .btn {
        white-space: nowrap;
    }
    #page-title {
        max-width: 68vw;
        font-size: 1rem !important;
    }
}

/* ID Card Styles */
.id-card-preview {
    border: 1px solid #dee2e6;
    border-radius: 0.75rem;
    overflow: hidden;
    width: 320px;
    background: #fff;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    margin: 0 auto;
}

.id-card-header {
    background: #0d6efd;
    color: white;
    text-align: center;
    padding: 1rem;
}

.id-card-body {
    padding: 2rem 1.5rem;
    text-align: center;
}

.id-card-photo {
    width: 100px;
    height: 100px;
    background: #e9ecef;
    border-radius: 50%;
    margin: -3rem auto 1rem;
    border: 4px solid #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: #6c757d;
}

#reader {
    width: 100%;
    border-radius: 0.5rem;
    overflow: hidden;
}
