* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.admin-container {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 250px;
    background: #2c3e50;
    color: #fff;
    padding: 20px;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-header {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #34495e;
}

.sidebar-header h2 {
    font-size: 18px;
    margin-bottom: 10px;
}

.sidebar-header p {
    font-size: 14px;
    color: #95a5a6;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.sidebar-nav a {
    color: #ecf0f1;
    text-decoration: none;
    padding: 12px 15px;
    border-radius: 5px;
    transition: all 0.3s;
}

.sidebar-nav a:hover {
    background: #34495e;
}

.sidebar-nav a.active {
    background: #3498db;
}

.sidebar-nav a.logout {
    margin-top: 20px;
    background: #e74c3c;
}

.sidebar-nav a.logout:hover {
    background: #c0392b;
}

.main-content {
    flex: 1;
    margin-left: 250px;
    padding: 30px;
    background: #f5f6fa;
}

.content-header {
    margin-bottom: 30px;
}

.content-header h1 {
    font-size: 28px;
    color: #2c3e50;
}

.dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.dashboard-card {
    background: #fff;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.dashboard-card h3 {
    font-size: 14px;
    color: #7f8c8d;
    margin-bottom: 10px;
}

.dashboard-card .number {
    font-size: 36px;
    font-weight: bold;
    color: #2c3e50;
}

.quick-actions {
    background: #fff;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.quick-actions h2 {
    margin-bottom: 20px;
    color: #2c3e50;
}

.action-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.config-section,
.employee-section,
.export-section,
.filter-section,
.attendance-list,
.employee-list {
    background: #fff;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.config-section h2,
.employee-section h2,
.export-section h2,
.filter-section h2,
.attendance-list h2,
.employee-list h2 {
    margin-bottom: 20px;
    color: #2c3e50;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #2c3e50;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #3498db;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    align-items: end;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
}

.btn-primary {
    background: #3498db;
    color: #fff;
}

.btn-primary:hover {
    background: #2980b9;
}

.btn-success {
    background: #27ae60;
    color: #fff;
}

.btn-success:hover {
    background: #229954;
}

.btn-warning {
    background: #f39c12;
    color: #fff;
}

.btn-warning:hover {
    background: #d68910;
}

.btn-danger {
    background: #e74c3c;
    color: #fff;
}

.btn-danger:hover {
    background: #c0392b;
}

.btn-secondary {
    background: #95a5a6;
    color: #fff;
}

.btn-secondary:hover {
    background: #7f8c8d;
}

.btn-sm {
    padding: 5px 10px;
    font-size: 12px;
}

.btn-lg {
    padding: 15px 30px;
    font-size: 16px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.data-table thead {
    background: #f8f9fa;
}

.data-table th,
.data-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ecf0f1;
}

.data-table th {
    font-weight: 600;
    color: #2c3e50;
}

.data-table tbody tr:hover {
    background: #f8f9fa;
}

.status-success {
    color: #27ae60;
    font-weight: 500;
}

.status-fail {
    color: #e74c3c;
    font-weight: 500;
}

.status-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge.enabled {
    background: #d5f5e3;
    color: #27ae60;
}

.status-badge.disabled {
    background: #fadbd8;
    color: #e74c3c;
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 20px;
}

.pagination a {
    color: #3498db;
    text-decoration: none;
    padding: 5px 15px;
    border: 1px solid #3498db;
    border-radius: 5px;
}

.pagination a:hover {
    background: #3498db;
    color: #fff;
}

.message {
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.message.success {
    background: #d5f5e3;
    color: #27ae60;
    border-left: 4px solid #27ae60;
}

.message.error {
    background: #fadbd8;
    color: #e74c3c;
    border-left: 4px solid #e74c3c;
}

.help-text {
    color: #7f8c8d;
    font-size: 14px;
    margin-bottom: 15px;
}

.help-list {
    color: #7f8c8d;
    font-size: 14px;
    padding-left: 20px;
}

.help-list li {
    margin-bottom: 10px;
}

.help-list a {
    color: #3498db;
    text-decoration: none;
}

.help-list a:hover {
    text-decoration: underline;
}

.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.login-box {
    background: #fff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
}

.login-box h1 {
    text-align: center;
    margin-bottom: 10px;
    color: #2c3e50;
    font-size: 24px;
}

.login-box h2 {
    text-align: center;
    margin-bottom: 30px;
    color: #7f8c8d;
    font-size: 18px;
    font-weight: 400;
}

.error-message {
    background: #fadbd8;
    color: #e74c3c;
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 20px;
    text-align: center;
}

.clockin-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.clockin-box {
    background: #fff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 500px;
}

.clockin-box h1 {
    text-align: center;
    margin-bottom: 30px;
    color: #2c3e50;
}

.location-status {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
    background: #f8f9fa;
}

.location-status.success {
    background: #d5f5e3;
    color: #27ae60;
}

.location-status.error {
    background: #fadbd8;
    color: #e74c3c;
}

.status-icon {
    font-size: 20px;
}

.result-message {
    margin-top: 20px;
    padding: 15px;
    border-radius: 5px;
    text-align: center;
    font-weight: 500;
}

.result-message.success {
    background: #d5f5e3;
    color: #27ae60;
}

.result-message.error {
    background: #fadbd8;
    color: #e74c3c;
}

.clockin-links {
    margin-top: 20px;
    text-align: center;
}

.records-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.records-box {
    background: #fff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 800px;
}

.records-box h1 {
    text-align: center;
    margin-bottom: 30px;
    color: #2c3e50;
}

.search-form {
    margin-bottom: 30px;
}

.records-summary {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.records-summary h2 {
    font-size: 18px;
    margin-bottom: 10px;
    color: #2c3e50;
}

.records-summary p {
    color: #7f8c8d;
}

.no-records {
    text-align: center;
    padding: 40px;
    color: #7f8c8d;
}

.back-link {
    margin-top: 20px;
    text-align: center;
}

.qr-section {
    background: #fff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.qr-section h2 {
    margin-bottom: 20px;
    color: #2c3e50;
}

.qr-info {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.qr-info p {
    margin-bottom: 5px;
}

.qr-url {
    font-family: monospace;
    background: #fff;
    padding: 10px;
    border-radius: 3px;
    word-break: break-all;
}

.qr-preview {
    text-align: center;
    margin-bottom: 20px;
}

.qr-preview img {
    max-width: 100%;
    border: 1px solid #ecf0f1;
    border-radius: 5px;
}

.qr-actions {
    text-align: center;
    margin-bottom: 30px;
}

.qr-help {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 5px;
}

.qr-help h3 {
    margin-bottom: 15px;
    color: #2c3e50;
}

.qr-help ul {
    padding-left: 20px;
}

.qr-help li {
    margin-bottom: 10px;
    color: #7f8c8d;
}

@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }
    
    .main-content {
        margin-left: 0;
        padding: 20px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .dashboard {
        grid-template-columns: 1fr;
    }
}