/* AIC Calendar System Styles */
/* Colors from AIC logo: Purple, Blue, Orange */

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

:root {
    --primary-purple: #7B3F9E;
    --primary-blue: #2E9FD9;
    --accent-orange: #F9A825;
    --light-purple: #9B5FB8;
    --light-blue: #5FB8E6;
    --dark-text: #333;
    --light-bg: #f5f5f5;
    --white: #fff;
    --success: #4CAF50;
    --danger: #f44336;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    padding: 20px;
}

/* Header Styles */
.header {
    text-align: center;
    margin-bottom: 30px;
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.logo-container {
    margin-bottom: 20px;
}

.logo {
    max-width: 150px;
    height: auto;
}

.header h1 {
    color: var(--primary-purple);
    font-size: 2.5em;
    margin-bottom: 10px;
}

.header p {
    color: var(--primary-blue);
    font-size: 1.2em;
}

/* Navigation */
.nav-bar {
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.nav-bar a, .nav-bar button {
    color: white;
    text-decoration: none;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 5px;
    margin: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
}

.nav-bar a:hover, .nav-bar button:hover {
    background: var(--accent-orange);
    transform: translateY(-2px);
}

.welcome-user {
    color: white;
    font-weight: bold;
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
}

/* Calendar View */
.calendar-view {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.calendar-view h2 {
    color: var(--primary-purple);
    margin-bottom: 20px;
    border-bottom: 3px solid var(--primary-blue);
    padding-bottom: 10px;
}

.section-title {
    color: var(--primary-blue);
    margin-top: 30px;
    margin-bottom: 15px;
    font-size: 1.5em;
}

/* Table Styles */
table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 30px;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

thead {
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    color: white;
}

th {
    padding: 15px;
    text-align: left;
    font-weight: bold;
    font-size: 1.1em;
}

td {
    padding: 15px;
    border-bottom: 1px solid #eee;
}

tr:hover {
    background: #f9f9f9;
}

.month-cell {
    font-weight: bold;
    color: var(--primary-purple);
}

.date-cell {
    color: var(--primary-blue);
}

/* Login Form */
.login-container {
    max-width: 450px;
    margin: 100px auto;
    background: white;
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.login-container h2 {
    color: var(--primary-purple);
    text-align: center;
    margin-bottom: 30px;
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--dark-text);
    font-weight: bold;
}

.form-group input, 
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-blue);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

/* Buttons */
.btn {
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: all 0.3s ease;
    margin: 5px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-success:hover {
    background: #45a049;
}

.btn-danger {
    background: var(--danger);
    color: white;
}

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

.btn-warning {
    background: var(--accent-orange);
    color: white;
}

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

.btn-full {
    width: 100%;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.btn-edit, .btn-delete {
    padding: 8px 15px;
    font-size: 14px;
}

/* Alerts */
.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 8px;
    font-weight: bold;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    overflow: auto;
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 30px;
    border-radius: 15px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s;
}

.close:hover {
    color: var(--danger);
}

/* Dashboard */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

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

.stat-card {
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    color: white;
    padding: 25px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.stat-card h3 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

.stat-card p {
    font-size: 1.1em;
}

/* Responsive */
@media (max-width: 768px) {
    .header h1 {
        font-size: 1.8em;
    }
    
    table {
        font-size: 14px;
    }
    
    th, td {
        padding: 10px;
    }
    
    .nav-bar {
        flex-direction: column;
        text-align: center;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
}

@media print {
    .nav-bar, .action-buttons, .btn {
        display: none;
    }
}

/* Loading Spinner */
.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-blue);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.hidden {
    display: none;
}
