@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css');

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    background-attachment: fixed;
    color: #333;
    margin: 0;
    padding: 20px;
    line-height: 1.7;
    min-height: 100vh;
}

.container {
    width: 90%;
    max-width: 900px;
    margin: 0 auto;
    padding: 40px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

h2 {
    color: #333;
    margin-bottom: 20px;
    font-weight: 500;
    font-size: 26px;
}

input {
    width: 100%;
    padding: 12px;
    margin: 8px 0;
    border: 1px solid #ddd;
    border-radius: 5px;
    background: #ffffff;
    color: #333;
    box-sizing: border-box;
    font-size: 15px;
    transition: border-color 0.3s ease;
}

input:focus {
    outline: none;
    border-color: #20c997;
    box-shadow: 0 0 5px rgba(32, 201, 151, 0.3);
}

select {
    width: 100%;
    padding: 12px;
    margin: 8px 0;
    border: 1px solid #ddd;
    border-radius: 5px;
    background: #ffffff;
    color: #333;
    box-sizing: border-box;
    font-size: 15px;
    transition: border-color 0.3s ease;
}

select:focus {
    outline: none;
    border-color: #20c997;
    box-shadow: 0 0 5px rgba(32, 201, 151, 0.3);
}

button, .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 24px;
    margin: 5px;
    color: #fff;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    position: relative;
    overflow: hidden;
}

button:hover, .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.5);
    background: linear-gradient(135deg, #5a67d8, #667eea);
}

button:active, .btn:active {
    transform: translateY(0);
}

/* Button variants */
.btn-secondary {
    background: linear-gradient(135deg, #718096, #4a5568);
    box-shadow: 0 4px 15px rgba(113, 128, 150, 0.3);
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #4a5568, #2d3748);
    box-shadow: 0 8px 25px rgba(113, 128, 150, 0.5);
}

form {
    margin-bottom: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background: #ffffff;
    color: #333;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

th, td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

th {
    background: #f8f9fa;
    font-weight: 600;
    color: #495057;
}

tr:hover {
    background-color: #f1f3f5;
}

.table-container {
    overflow-x: auto;
    margin: 20px 0;
    border-radius: 4px;
}

.success {
    color: #155724;
    padding: 12px;
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 5px;
    margin: 15px 0;
}

.info {
    color: #0c5460;
    padding: 12px;
    background: #d1ecf1;
    border: 1px solid #bbe5eb;
    border-radius: 5px;
    margin: 15px 0;
}

.error {
    color: #721c24;
    padding: 12px;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 5px;
    margin: 15px 0;
}

/* Navigation and buttons styling */
.nav-buttons {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    padding: 25px;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

/* Form labels */
label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #555;
}

/* Total row highlighting */
.total {
    background-color: #e8f4ff;
    font-weight: bold;
}

/* Welcome section */
.welcome-section {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 30px;
    border-radius: 15px;
    margin-bottom: 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.welcome-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(255,255,255,0.1) 0%, transparent 100%);
    pointer-events: none;
}

.welcome-section h2 {
    color: white;
    margin: 0;
    font-weight: 600;
    font-size: 28px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Modern Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.stat-card .icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    color: white;
    font-size: 20px;
}

.stat-card .value {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 5px;
}

.stat-card .label {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

/* Form section */
.form-section {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    padding: 30px;
    border-radius: 15px;
    margin-bottom: 30px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.form-section h2, .form-section h3 {
    margin-top: 0;
    color: #333;
    font-weight: 600;
}

/* Custom date fields */
#custom-dates {
    margin-top: 15px;
    padding: 15px;
    background: #ffffff;
    border-radius: 5px;
    border: 1px solid #ddd;
}

/* Chart container */
canvas {
    max-width: 100%;
    margin: 20px 0;
}

/* Radio button styling */
input[type="radio"] {
    width: auto;
    margin-right: 8px;
}

/* Table input styling */
table input {
    width: 100%;
    padding: 8px;
    margin: 2px 0;
    border: 1px solid #ddd;
    border-radius: 4px;
}

table input:focus {
    border-color: #20c997;
    box-shadow: 0 0 3px rgba(32, 201, 151, 0.3);
}

/* Radio button container */
td label {
    display: inline-block;
    margin-right: 15px;
    margin-bottom: 0;
    font-weight: normal;
}

/* Responsive design */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }
    
    .container {
        width: 95%;
        padding: 20px;
        margin: 10px auto;
    }
    
    .welcome-section {
        padding: 20px;
    }
    
    .welcome-section h2 {
        font-size: 22px;
    }
    
    .nav-buttons {
        flex-direction: column;
        padding: 15px;
    }
    
    button, .btn {
        width: 100%;
        margin: 5px 0;
        justify-content: center;
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 15px;
    }
    
    .stat-card {
        padding: 20px;
    }
    
    .stat-card .value {
        font-size: 20px;
    }
    
    table {
        font-size: 14px;
    }
    
    th, td {
        padding: 10px;
    }
    
    .form-section {
        padding: 20px;
    }
}
