/* ===============================
   GLOBAL STYLES
=============================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background: #f4f6f9;
    color: #333;
}

/* ===============================
   LOGIN PAGE
=============================== */
.container {
    display: flex;
    min-height: 100vh;
}

/* Left Panel */
.left-panel {
    width: 55%;
    background: url('../images/office.jpg') no-repeat center center/cover;
    position: relative;
    color: #fff;
}

.overlay {
    background: rgba(13, 76, 146, 0.85);
    height: 100%;
    padding: 80px 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.overlay h1 {
    font-size: 48px;
    margin-bottom: 20px;
}

.overlay p {
    font-size: 18px;
    line-height: 1.6;
    max-width: 500px;
}

.features {
    display: flex;
    gap: 80px;
    margin-top: 40px;
}

/* Right Panel */
.right-panel {
    width: 45%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: #f5f7fb;
    padding: 20px;
}

/* Login Card */
.login-card {
    background: #fff;
    padding: 40px;
    width: 100%;
    max-width: 420px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    text-align: center;
}

.subtitle {
    color: #666;
    font-size: 14px;
    margin-bottom: 25px;
}

.input-group {
    text-align: left;
    margin-bottom: 18px;
}

.input-group label {
    font-size: 14px;
    font-weight: 500;
}

.input-group input {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #ccc;
    transition: 0.3s;
}

.input-group input:focus {
    border-color: #1557a0;
    outline: none;
    box-shadow: 0 0 5px rgba(21, 87, 160, 0.2);
}

.btn {
    width: 100%;
    padding: 14px;
    background: #1557a0;
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

.btn:hover {
    background: #0d3f78;
}

/* ===============================
   DASHBOARD LAYOUT
=============================== */
.main-wrapper {
    display: flex;
}

/* Sidebar */
.sidebar {
    width: 260px;
    height: 100vh;
    background: #fff;
    border-right: 1px solid #e5e7eb;
    position: fixed;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.sidebar-logo {
    padding: 20px;
}

.sidebar-logo img {
    width: 160px;
}

.sidebar-menu {
    list-style: none;
    padding: 10px;
}

.sidebar-menu li {
    margin: 8px 0;
}

.sidebar-menu a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    text-decoration: none;
    color: #374151;
    border-radius: 10px;
    font-weight: 500;
}

.sidebar-menu li.active a,
.sidebar-menu a:hover {
    background: #1656a5;
    color: #fff;
}

/* Sidebar User */
.sidebar-user {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px;
    border-top: 1px solid #eee;
}

.avatar {
    background: #1656a5;
    color: #fff;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Content */
.content {
    margin-left: 260px;
    width: calc(100% - 260px);
}

/* Header */
.top-header {
    background: #fff;
    padding: 15px 25px;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.search-box {
    background: #f1f5f9;
    padding: 8px 12px;
    border-radius: 20px;
    display: flex;
    align-items: center;
}

.search-box input {
    border: none;
    background: transparent;
    outline: none;
}

.cards {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
    padding: 20px;
}

.card {
    background: #fff;
    padding: 20px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.blue { background: #e0edff; color: #1656a5; }
.orange { background: #fff4e5; color: #f59e0b; }
.green { background: #e6f9f0; color: #10b981; }
.red { background: #ffe5e5; color: #ef4444; }
.purple { background: #ede9fe; color: #7c3aed; }

.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    padding: 0 20px 20px;
}

.chart-card,
.recent-card {
    background: #fff;
    border-radius: 14px;
    padding: 20px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

/* Chart Height Fix */
.chart-card {
    height: 350px;
}

#revenueChart {
    width: 100% !important;
    height: 280px !important;
}

.no-data {
    text-align: center;
    color: #6b7280;
    margin-top: 40px;
}

/* Footer */
footer {
    text-align: center;
    padding: 15px;
    color: #777;
}

/* Responsive */
@media (max-width: 1200px) {
    .cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 992px) {
    .left-panel {
        display: none;
    }

    .right-panel {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .sidebar {
        display: none;
    }

    .content {
        margin-left: 0;
        width: 100%;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
}

.btn-primary {
    background: #1656a5;
    color: #fff;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
}

.btn-primary:hover {
    background: #0d47a1;
}

.table-card {
    background: #fff;
    margin: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.table-header {
    padding: 15px;
    border-bottom: 1px solid #eee;
}

.table-search {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #ccc;
}

/* Table */
.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 15px;
    text-align: left;
}

.data-table th {
    background: #f9fafb;
}

.no-data {
    text-align: center;
    padding: 30px;
    color: #6b7280;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 999;
}

.modal {
    background: #fff;
    width: 600px;
    max-width: 95%;
    border-radius: 14px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    animation: fadeIn 0.3s ease;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #eee;
}

.close-btn {
    border: none;
    background: none;
    font-size: 20px;
    cursor: pointer;
}

.form-group {
    padding: 0 20px 15px;
}

.form-row {
    display: flex;
    gap: 15px;
    padding: 0 20px;
}

.form-control {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #ccc;
}

textarea.form-control {
    height: 80px;
    resize: none;
}

.btn-submit {
    width: calc(100% - 40px);
    margin: 15px 20px 20px;
    padding: 12px;
    border: none;
    border-radius: 8px;
    background: #1656a5;
    color: #fff;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
}

.btn-submit:hover {
    background: #0d47a1;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
}

.table-card {
    background: #fff;
    margin: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.table-header {
    padding: 15px;
    border-bottom: 1px solid #eee;
}

.table-search-wrapper {
    max-width: 420px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 15px;
    text-align: left;
}

.data-table th {
    background: #f9fafb;
    font-weight: 600;
}

.no-data {
    text-align: center;
    padding: 30px;
    color: #6b7280;
}

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 999;
}

.modal {
    background: #fff;
    width: 420px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
    animation: fadeIn 0.3s ease;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 22px;
    border-bottom: 1px solid #eee;
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    padding: 15px 20px;
    border-top: 1px solid #eee;
}

.close-btn {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
}

.profile-upload {
    text-align: center;
    margin-bottom: 15px;
    position: relative;
}

.avatar-preview {
    width: 100px;
    height: 100px;
    background: #eef2f7;
    border-radius: 50%;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: #7a8ca5;
    border: 3px solid #e5e7eb;
}

.upload-icon {
    position: absolute;
    bottom: 5px;
    right: calc(50% - 50px);
    background: #1656a5;
    color: #fff;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

/* Buttons */
.btn-primary {
    background: #1656a5;
    color: #fff;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
}

.btn-primary:hover {
    background: #0d47a1;
}

.btn-submit {
    width: 100%;
    padding: 12px;
    background: #1656a5;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
}

.btn-submit:hover {
    background: #0d47a1;
}

/* Form */
.form-group {
    margin-bottom: 15px;
}

.form-control {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
}

.page-subtitle {
    color: #6b7280;
    font-size: 14px;
}

/* Service Grid */
.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    padding: 0 20px 20px;
}

.service-card {
    background: #fff;
    border-radius: 14px;
    padding: 20px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    transition: 0.3s;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-icon {
    width: 40px;
    height: 40px;
    background: #e8f0fe;
    color: #1656a5;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
}

.service-card h3 {
    font-size: 18px;
    margin-bottom: 5px;
}

.service-category {
    color: #6b7280;
    font-size: 14px;
}

.service-footer {
    margin-top: 15px;
    display: flex;
    justify-content: space-between;
    font-weight: 600;
}

.service-footer span {
    color: #9ca3af;
    font-size: 12px;
}

/* Buttons */
.btn-primary {
    background: #1656a5;
    color: #fff;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
}

.btn-primary:hover {
    background: #0d47a1;
}


.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 999;
}

.modal {
    background: #fff;
    width: 450px;
    border-radius: 16px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
    animation: fadeIn 0.3s ease;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px;
    border-bottom: 1px solid #eee;
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    padding: 15px 20px;
    border-top: 1px solid #eee;
}

.close-btn {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
}

/* Form */
.form-group {
    margin-bottom: 15px;
}

.form-control {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    font-size: 14px;
}

.btn-submit {
    width: 100%;
    background: #1656a5;
    color: #fff;
    border: none;
    padding: 12px;
    border-radius: 10px;
    font-size: 16px;
    cursor: pointer;
}

.btn-submit:hover {
    background: #0d47a1;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.billing-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    padding: 20px;
}

.billing-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.billing-card .card-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.billing-card.income {
    background: #eaf7f0;
}

.billing-card.expenses {
    background: #fdecec;
}

.billing-card.profit {
    background: #eaf1fb;
}

.billing-card.income .card-icon {
    background: #c8ead8;
    color: #0f9d58;
}

.billing-card.expenses .card-icon {
    background: #f8caca;
    color: #d93025;
}

.billing-card.profit .card-icon {
    background: #d6e4ff;
    color: #1a73e8;
}

.card-label {
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
}

.table-card {
    background: #fff;
    margin: 0 20px 20px;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 15px;
    text-align: left;
}

.data-table th {
    background: #f9fafb;
}

.no-data {
    text-align: center;
    padding: 25px;
    color: #6b7280;
}

/* Modal Form Row */
.form-row {
    display: flex;
    gap: 15px;
}

.form-row .form-group {
    flex: 1;
}

.report-filter-card {
    background: #fff;
    margin: 20px;
    padding: 20px;
    border-radius: 14px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.generate-btn {
    display: flex;
    align-items: flex-end;
}

.report-tabs {
    display: flex;
    gap: 10px;
    margin: 0 20px 20px;
    background: #eef1f5;
    padding: 8px;
    border-radius: 30px;
}

.tab-btn {
    border: none;
    background: transparent;
    padding: 10px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 500;
    color: #555;
}

.tab-btn.active {
    background: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.report-section {
    display: none;
    margin: 0 20px 20px;
}

.report-section.active {
    display: block;
}

.report-card {
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    padding: 20px;
}

.report-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.btn-export {
    border: 1px solid #ddd;
    background: #fff;
    padding: 6px 14px;
    border-radius: 6px;
    margin-left: 5px;
    cursor: pointer;
}

.btn-export:hover {
    background: #f5f5f5;
}

.total-row {
    background: #f9fafb;
}

.text-success {
    color: #16a34a;
}

.text-danger {
    color: #dc2626;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 20px;
}

.page-subtitle {
    color: #6b7280;
    font-size: 14px;
}

.page-actions {
    display: flex;
    gap: 10px;
}

.btn-primary {
    background: #1656a5;
    color: #fff;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
}

.btn-secondary {
    background: #eef2f7;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
}

.btn-submit {
    width: 100%;
    background: #1656a5;
    color: #fff;
    border: none;
    padding: 12px;
    border-radius: 10px;
    font-size: 16px;
    cursor: pointer;
}

.table-card {
    background: #fff;
    margin: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 15px;
    text-align: left;
}

.data-table th {
    background: #f9fafb;
}


.badge-active {
    background: #16a34a;
    color: #fff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
}

.badge-role {
    background: #ede9fe;
    color: #6d28d9;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
}

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 999;
}

.modal {
    background: #fff;
    width: 450px;
    border-radius: 16px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
    animation: fadeIn 0.3s ease;
}

.modal-lg {
    width: 800px;
}

.modal-header,
.modal-footer {
    padding: 18px;
    border-bottom: 1px solid #eee;
}

.modal-footer {
    border-top: 1px solid #eee;
    border-bottom: none;
}

.modal-body {
    padding: 20px;
}

.close-btn {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
}

.form-group {
    margin-bottom: 15px;
}

.form-control {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
}

.form-row {
    display: flex;
    gap: 15px;
}

.time-inputs {
    display: flex;
    gap: 10px;
}

.action-icon {
    margin-right: 10px;
    cursor: pointer;
    color: #6b7280;
}

.text-danger {
    color: #dc2626;
}

.text-muted {
    color: #6b7280;
}

.attendance-date {
    margin-left: auto;
    margin-right: 10px;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 20px;
    padding: 20px;
}

.settings-card {
    background: #fff;
    border-radius: 14px;
    padding: 20px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.settings-card h3 {
    font-size: 18px;
    margin-bottom: 5px;
    color: #1f2937;
}

.card-subtitle {
    font-size: 13px;
    color: #6b7280;
    margin-bottom: 15px;
}

.toggle-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.toggle-desc {
    font-size: 12px;
    color: #6b7280;
}

/* Switch Style */
.switch {
    position: relative;
    display: inline-block;
    width: 42px;
    height: 22px;
}

.switch input {
    display: none;
}

.slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background-color: #ccc;
    border-radius: 34px;
    transition: 0.3s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background: #fff;
    border-radius: 50%;
    transition: 0.3s;
}

.switch input:checked + .slider {
    background-color: #1656a5;
}

.switch input:checked + .slider:before {
    transform: translateX(20px);
}

.btn-secondary {
    background: #f3f4f6;
    border: none;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
}

.full-width {
    width: 100%;
    margin-top: 10px;
}

/* Footer */
.settings-footer {
    text-align: right;
    padding: 10px 25px 25px;
}
.main-header {
    display: flex;
    align-items: center;
    padding: 15px 40px;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.logo img {
    height: 45px;
}

.login-logo {
    text-align: center;
    margin-bottom: 10px;
}

.login-logo img {
    width: 70px;
    height: auto;
}

.left-panel .overlay h1 {
    font-size: 40px;
    font-weight: 700;
    margin-bottom: 10px;
}