/* ============================================
           GLOBAL STYLES & RESET
           ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

/* ============================================
           UTILITY CLASSES
           ============================================ */
.hidden {
    display: none !important;
}

.container {
    /* max-width: 1200px; */
    margin: 0 auto;
    /* padding: 20px; */
}

/* ============================================
           AUTH PAGES STYLES (Login, Register, Forgot Password)
           ============================================ */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-card {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    padding: 40px;
    width: 100%;
    max-width: 450px;
}

.auth-logo {
    text-align: center;
    margin-bottom: 20px;
}

.auth-logo .h1 {
    width: 200px;
    margin-bottom: 10px;
}

.auth-logo p {
    color: #666;
    font-size: 16px;
}

/* Form Styles */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
    font-size: 14px;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 16px;
    transition: all 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
}

/* Password Input Wrapper */
.password-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-wrapper input {
    flex: 1;
    width: 100%;
    padding-right: 40px;
}

.password-toggle-btn {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    transition: all 0.2s ease;
}

.password-toggle-btn:hover {
    opacity: 0.7;
}

.password-toggle-btn:active {
    opacity: 0.5;
}

.eye-icon {
    font-size: 18px;
}

/* Remember Me & Links */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
}

.remember-me input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.link-button {
    background: none;
    border: none;
    color: #667eea;
    font-size: 14px;
    cursor: pointer;
    font-weight: 500;
    text-decoration: none;
}

.link-button:hover {
    text-decoration: underline;
}

/* Submit Button */
.submit-btn {
    width: 100%;
    padding: 14px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.submit-btn:hover {
    background: #5568d3;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.submit-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

/* Messages */
.message {
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 14px;
}

.message.error {
    background: #fee;
    border: 1px solid #fcc;
    color: #c00;
}

.message.success {
    background: #efe;
    border: 1px solid #cfc;
    color: #0a0;
}

/* Auth Footer */
.auth-footer {
    text-align: center;
    margin-top: 20px;
    color: #666;
    font-size: 14px;
}

/* ============================================
           DASHBOARD STYLES
           ============================================ */
.dashboard {
    min-height: 100vh;
    background: #f5f5f5;
}

/* Header / Navbar */
.navbar {
    background: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.navbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
}

.navbar-logo {
    font-size: 24px;
    font-weight: bold;
    color: #667eea;
}

.hamburger-menu {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.hamburger-icon {
    width: 24px;
    height: 20px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.hamburger-icon span {
    width: 100%;
    height: 3px;
    background: #333;
    border-radius: 2px;
    transition: all 0.3s;
}

/* User Menu */
.user-menu {
    position: relative;
}

.user-icon-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.user-icon {
    width: 32px;
    height: 32px;
    background: #667eea;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 16px;
}

.user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 10px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    min-width: 180px;
    overflow: hidden;
}

.user-dropdown button {
    width: 100%;
    padding: 12px 16px;
    border: none;
    background: none;
    text-align: left;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.2s;
}

.user-dropdown button:hover {
    background: #f5f5f5;
}

.user-dropdown .logout-btn {
    color: #dc3545;
}

/* Sidebar */
.sidebar {
    position: fixed;
    top: 64px;
    left: 0;
    bottom: 0;
    width: 260px;
    background: white;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    transform: translateX(-100%);
    transition: transform 0.3s;
    z-index: 999;
    overflow-y: auto;
}

.sidebar.open {
    transform: translateX(0);
}

.sidebar-menu {
    padding: 20px;
}

.menu-item {
    width: 100%;
    padding: 12px 16px;
    border: none;
    background: none;
    text-align: left;
    cursor: pointer;
    font-size: 15px;
    border-radius: 8px;
    margin-bottom: 8px;
    transition: all 0.2s;
    color: #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.menu-item:hover {
    background: #f0f0f0;
}

.menu-item.active {
    background: #667eea;
    color: white;
    font-weight: 600;
}

/* Submenu */
.submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s;
    margin-left: 16px;
}

.submenu.open {
    max-height: 300px;
}

.submenu-item {
    padding: 10px 16px;
    font-size: 14px;
    color: #666;
}

.submenu-item.active {
    background: #e8ebfa;
    color: #667eea;
}

/* Main Content */
.main-content {
    margin-top: 64px;
    /* padding: 24px; */
    transition: margin-left 0.3s;
}

.main-content.sidebar-open {
    margin-left: 260px;
}

/* Content Card */
.content-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.content-card h2 {
    font-size: 28px;
    color: #333;
    margin-bottom: 16px;
}

.content-card p {
    color: #666;
    line-height: 1.6;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.stat-card {
    background: white;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.stat-card h3 {
    font-size: 16px;
    margin-bottom: 12px;
}

.stat-card .stat-value {
    font-size: 32px;
    font-weight: bold;
    color: #333;
}

.stat-card.blue h3 {
    color: #667eea;
}

.stat-card.green h3 {
    color: #10b981;
}

.stat-card.purple h3 {
    color: #8b5cf6;
}

/* Table */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.data-table th {
    background: #f8f9fa;
    padding: 12px;
    text-align: left;
    font-weight: 600;
    color: #333;
    border-bottom: 2px solid #e0e0e0;
}

.data-table td {
    padding: 12px;
    border-bottom: 1px solid #e0e0e0;
}

.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.badge.success {
    background: #d1fae5;
    color: #065f46;
}

.badge.warning {
    background: #fef3c7;
    color: #92400e;
}

/* Profile Page */
.profile-header {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 30px;
}

.profile-avatar {
    width: 80px;
    height: 80px;
    background: #667eea;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    font-weight: bold;
}

.profile-info h3 {
    font-size: 24px;
    color: #333;
    margin-bottom: 4px;
}

.profile-info p {
    color: #666;
}

/* Overlay for mobile */
.overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    display: none;
}

.overlay.active {
    display: block;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 1024px) {
    .main-content.sidebar-open {
        margin-left: 260px;
    }

    .auth-card {
        padding: 35px 25px;
        width: 100%;
        max-width: 420px;
    }

    .form-group input {
        font-size: 16px;
        padding: 12px 14px;
        min-height: 44px;
    }

    .form-group label {
        font-size: 14px;
    }
}

@media (max-width: 768px) {
    .main-content.sidebar-open {
        margin-left: 0;
    }

    .auth-card {
        padding: 28px 20px;
        width: 95%;
        max-width: 420px;
    }

    .auth-logo .h1 {
        width: 180px;
    }

    .form-group {
        margin-bottom: 16px;
    }

    .form-group label {
        font-size: 13px;
        margin-bottom: 6px;
    }

    .form-group input {
        font-size: 16px;
        padding: 12px 12px;
        min-height: 44px;
        border-radius: 8px;
    }

    .form-group input:focus {
        border-color: #667eea;
        box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    }

    .password-input-wrapper input {
        padding-right: 44px;
    }

    .password-toggle-btn {
        right: 10px;
        width: 40px;
        height: 40px;
    }

    .form-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        margin-bottom: 16px;
    }

    .remember-me {
        width: 100%;
    }

    .auth-link {
        text-align: center;
        width: 100%;
    }

    .auth-button {
        min-height: 44px;
        font-size: 14px;
        border-radius: 8px;
    }

    .popup-container {
        top: 10px;
        right: 10px;
        left: 10px;
    }

    .popup-box {
        min-width: auto;
        width: calc(100% - 20px);
        max-width: 100%;
        font-size: 13px;
    }

    .popup-icon {
        font-size: 20px;
    }

    .popup-message {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .auth-page {
        padding: 12px;
    }

    .auth-card {
        padding: 24px 16px;
        border-radius: 16px;
    }

    .auth-logo {
        margin-bottom: 16px;
    }

    .auth-logo .h1 {
        width: 160px;
        margin-bottom: 8px;
    }

    .auth-logo p {
        font-size: 14px;
    }

    .form-group {
        margin-bottom: 14px;
    }

    .form-group label {
        font-size: 12px;
        margin-bottom: 6px;
        font-weight: 600;
    }

    .form-group input {
        font-size: 16px;
        padding: 12px 12px;
        min-height: 44px;
        border-radius: 8px;
    }

    .form-options {
        gap: 10px;
    }

    .remember-me input[type="checkbox"] {
        width: 18px;
        height: 18px;
    }

    .auth-link {
        text-align: center;
        font-size: 13px;
    }

    .auth-link a {
        font-weight: 600;
    }

    .auth-button {
        width: 100%;
        min-height: 44px;
        font-size: 14px;
        font-weight: 600;
        border-radius: 8px;
        padding: 12px 16px;
    }

    .popup-container {
        top: 8px;
        right: 8px;
        left: 8px;
    }

    .popup-box {
        padding: 12px 16px;
        gap: 10px;
        font-size: 12px;
    }

    .popup-icon {
        font-size: 18px;
    }

    .popup-message {
        font-size: 12px;
    }
}

/* Chevron icons for menu */
.chevron {
    width: 16px;
    height: 16px;
    transition: transform 0.3s;
}

.chevron.down {
    transform: rotate(90deg);
}

/* POPUP CONTAINER */
.popup-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 2000;
    display: none;
}

.popup-box {
    background: #ffffff;
    padding: 15px 20px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 250px;
    animation: slideIn 0.3s ease-out;
}

/* Icons */
.popup-icon {
    font-size: 24px;
    font-weight: bold;
}

.popup-message {
    font-size: 16px;
    font-weight: 500;
}

/* Types */
.popup-success .popup-icon {
    color: #28a745;
}

.popup-error .popup-icon {
    color: #dc3545;
}

.popup-warning .popup-icon {
    color: #ffc107;
}

.popup-info .popup-icon {
    color: #007bff;
}

@keyframes slideIn {
    from {
        transform: translateX(120%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(120%);
        opacity: 0;
    }
}

/* ============================================
           EXPENSE MODAL STYLES
           ============================================ */
.expense-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease;
}

.expense-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    cursor: pointer;
}

.expense-modal-box {
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    padding: 20px;
    width: 90%;
    max-width: 600px;
    position: relative;
    z-index: 1001;
    max-height: 85vh;
    overflow-y: auto;
    animation: slideUp 0.3s ease;
}

.expense-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 10px;
}

.expense-modal-header h2 {
    font-size: 17px;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

.expense-modal-close {
    background: none;
    border: none;
    font-size: 22px;
    cursor: pointer;
    color: #6b7280;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.expense-modal-close:hover {
    background: #f3f4f6;
    color: #1f2937;
}

.expense-modal-form {
    margin-bottom: 20px;
}

.expense-form-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 14px;
}

.expense-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.expense-form-group {
    display: flex;
    flex-direction: column;
}

.expense-form-group-full {
    grid-column: 1 / -1;
}

.expense-form-group label {
    font-weight: 600;
    color: #374151;
    margin-bottom: 4px;
    font-size: 12px;
}

.expense-form-input {
    padding: 7px 10px;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    font-size: 12px;
    font-family: inherit;
    transition: all 0.3s ease;
    color: #1f2937;
}

.expense-form-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    background: #fafbff;
}

.expense-form-input:disabled {
    background-color: #f3f4f6;
    cursor: not-allowed;
    color: #9ca3af;
}

.expense-form-textarea {
    resize: vertical;
    min-height: 70px;
    font-family: inherit;
}

.expense-modal-footer {
    display: flex;
    justify-content: flex-start;
    gap: 8px;
    border-top: 1px solid #e5e7eb;
    padding-top: 12px;
}

.expense-modal-footer-left {
    justify-content: flex-start;
}

.expense-btn-cancel {
    padding: 7px 12px;
    background: white;
    color: #374151;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    font-weight: 600;
    cursor: pointer;
    font-size: 11px;
    transition: all 0.3s ease;
}

.expense-btn-cancel:hover {
    background: #f3f4f6;
    border-color: #d1d5db;
}

.expense-btn-save {
    padding: 7px 14px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 5px;
    font-weight: 600;
    cursor: pointer;
    font-size: 11px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.expense-btn-save:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

/* ============================================
           RESPONSIVE DESIGN FOR MODAL
           ============================================ */
@media (max-width: 768px) {
    .expense-modal-box {
        width: 95%;
        padding: 16px;
        max-width: 550px;
    }

    .expense-form-row {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .expense-form-grid {
        gap: 10px;
        margin-bottom: 12px;
    }

    .expense-modal-header {
        margin-bottom: 14px;
        padding-bottom: 8px;
    }

    .expense-modal-header h2 {
        font-size: 15px;
    }

    .expense-form-group label {
        font-size: 11px;
        margin-bottom: 3px;
    }

    .expense-form-input {
        padding: 6px 9px;
        font-size: 11px;
    }

    .expense-form-textarea {
        min-height: 60px;
    }

    .expense-modal-footer {
        gap: 6px;
        padding-top: 10px;
    }

    .expense-btn-cancel,
    .expense-btn-save {
        padding: 6px 10px;
        font-size: 10px;
    }

    .expense-modal-close {
        font-size: 20px;
        width: 28px;
        height: 28px;
    }
}

@media (max-width: 480px) {
    .expense-modal-box {
        width: 96%;
        padding: 14px;
        max-height: 92vh;
        max-width: 100%;
    }

    .expense-form-row {
        grid-template-columns: 1fr;
        gap: 9px;
    }

    .expense-form-grid {
        gap: 9px;
        margin-bottom: 10px;
    }

    .expense-modal-header {
        margin-bottom: 12px;
        padding-bottom: 8px;
    }

    .expense-modal-header h2 {
        font-size: 14px;
    }

    .expense-form-group label {
        font-size: 10px;
        margin-bottom: 2px;
    }

    .expense-form-input {
        padding: 5px 8px;
        font-size: 11px;
    }

    .expense-form-textarea {
        min-height: 55px;
    }

    .expense-modal-footer {
        gap: 6px;
        padding-top: 10px;
    }

    .expense-btn-cancel,
    .expense-btn-save {
        padding: 5px 10px;
        font-size: 10px;
    }

    .expense-modal-close {
        font-size: 18px;
        width: 26px;
        height: 26px;
    }
}


/* ============================================
   FORM IMPROVEMENTS FOR EXPENSE MANAGEMENT
   ============================================ */

/* Full width form group for notes */
.form-group-full {
    grid-column: 1 / -1 !important;
}

/* Improved form actions alignment */
.form-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #e5e7eb;
}

/* Medium-sized buttons */
.btn-cancel,
.btn-submit {
    padding: 8px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    min-width: 90px;
}

.btn-cancel {
    background: white;
    color: #374151;
    border: 1px solid #d1d5db;
}

.btn-cancel:hover {
    background: #f3f4f6;
    border-color: #9ca3af;
}

.btn-submit {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.btn-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-submit:active {
    transform: translateY(0);
}

/* Improved textarea styling */
.form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s ease;
    resize: vertical;
    min-height: 80px;
}

.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Improved select styling */
.form-group select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.form-group select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-group select:disabled {
    background-color: #f3f4f6;
    cursor: not-allowed;
    color: #9ca3af;
    opacity: 0.6;
}

/* Improved input styling */
.form-group input[type="number"],
.form-group input[type="text"],
.form-group input[type="date"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Modal header improvements */
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 16px;
    margin-bottom: 20px;
    border-bottom: 2px solid #e5e7eb;
}

.modal-header h3 {
    font-size: 20px;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

.modal-header input[type="date"] {
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
}

.close-btn {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #6b7280;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.close-btn:hover {
    background: #f3f4f6;
    color: #1f2937;
}

/* Form row spacing */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

/* Required field indicator */
.required {
    color: #dc3545;
    margin-left: 2px;
}

/* Label styling */
.form-group label {
    display: block;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
    font-size: 14px;
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */

@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
        gap: 12px;
        margin-bottom: 12px;
    }

    .form-actions {
        flex-direction: row;
        justify-content: flex-end;
        gap: 8px;
        padding-top: 12px;
    }

    .btn-cancel,
    .btn-submit {
        padding: 10px 18px;
        font-size: 13px;
        min-width: 80px;
    }

    .modal-header h3 {
        font-size: 18px;
    }

    .form-group textarea {
        min-height: 70px;
        font-size: 13px;
    }

    .form-group label {
        font-size: 13px;
        margin-bottom: 5px;
    }
}

@media (max-width: 480px) {
    .form-row {
        gap: 10px;
        margin-bottom: 10px;
    }

    .form-actions {
        gap: 8px;
        padding-top: 10px;
        margin-top: 16px;
    }

    .btn-cancel,
    .btn-submit {
        padding: 9px 16px;
        font-size: 12px;
        min-width: 75px;
    }

    .modal-header {
        padding-bottom: 12px;
        margin-bottom: 16px;
    }

    .modal-header h3 {
        font-size: 16px;
    }

    .modal-header input[type="date"] {
        padding: 6px 10px;
        font-size: 13px;
    }

    .close-btn {
        font-size: 24px;
        width: 28px;
        height: 28px;
    }

    .form-group textarea {
        min-height: 65px;
        font-size: 13px;
        padding: 8px 10px;
    }

    .form-group label {
        font-size: 12px;
        margin-bottom: 4px;
    }

    .form-group select,
    .form-group input[type="number"],
    .form-group input[type="text"],
    .form-group input[type="date"] {
        padding: 8px 10px;
        font-size: 13px;
    }
}

/* Additional table and layout improvements */
.table-container {
    overflow-x: auto;
    margin-top: 20px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.data-table th {
    background: #f9fafb;
    padding: 12px;
    text-align: left;
    font-weight: 600;
    color: #374151;
    border-bottom: 2px solid #e5e7eb;
    font-size: 14px;
}

.data-table td {
    padding: 12px;
    border-bottom: 1px solid #e5e7eb;
    color: #4b5563;
    font-size: 14px;
}

.data-table tr:hover {
    background: #f9fafb;
}

/* Staff header improvements */
.staff-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.staff-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

.btn-add {
    padding: 10px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.btn-add:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

/* Pagination improvements */
.pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #e5e7eb;
}

.pagination-info {
    color: #6b7280;
    font-size: 14px;
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.pagination-controls button {
    padding: 8px 16px;
    /*background: white;*/
    border: 1px solid #d1d5db;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
}

.pagination-controls button:hover:not(:disabled) {
    background: #f3f4f6;
    border-color: #9ca3af;
}

.pagination-controls button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.page-number {
    color: #374151;
    font-weight: 600;
    font-size: 14px;
}

/* Action buttons in table */
.btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 4px;
    transition: all 0.2s;
}

.resetbtn{
    background:none;
    border:none;
    cursor:pointer;
    color:#6366f1;
    transition: all 0.3s;
    
}
.resetbtn:hover{
    color:#0005ff;
    /*font-weight: 900;*/

}

.btn-edit {
    color: #667eea;
}

.btn-edit:hover {
    background: #e8ebfa;
}

.icon-edit {
    font-size: 16px;
    font-style: normal;
}

@media (max-width: 768px) {
    .pagination {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }

    .pagination-controls {
        width: 100%;
        justify-content: space-between;
    }

    .staff-header {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }

    .staff-header h2 {
        font-size: 20px;
    }

    .btn-add {
        width: 100%;
    }
}