/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    min-height: 100vh;
    color: #333;
    font-size: 18px;
    line-height: 1.6;
}

/* Header Styles */
.header {
    background: linear-gradient(135deg, #ff6b35 0%, #f7931e 50%, #ff6b35 100%);
    padding: 25px 20px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.header h1 {
    color: white;
    font-size: 1.8rem;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
    margin-bottom: 5px;
}

.header .tagline {
    color: #fff3e0;
    font-size: 1rem;
    margin-top: 8px;
    font-weight: 500;
}

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

/* Card Styles */
.card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.card h2 {
    color: #1e3c72;
    font-size: 1.3rem;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 3px solid #ff6b35;
}

/* Info Section */
.info-section {
    background: linear-gradient(to right, #fff, #fff8f5);
}

.instructions {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.instruction-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 10px;
    border-left: 4px solid #ff6b35;
}

.step {
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.instruction-item p {
    font-size: 1.1rem;
    color: #333;
}

/* Search Section */
.search-section {
    background: linear-gradient(to right, #fff, #f0f5ff);
}

.search-box {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 15px;
}

.search-box input {
    width: 100%;
    padding: 18px 20px;
    border: 3px solid #e0e0e0;
    border-radius: 12px;
    font-size: 1.2rem;
    font-family: 'Poppins', sans-serif;
    transition: border-color 0.3s;
    text-align: center;
    letter-spacing: 2px;
    box-sizing: border-box;
}

.search-box input:focus {
    outline: none;
    border-color: #1e3c72;
}

.search-box input::placeholder {
    letter-spacing: 0;
    font-size: 0.95rem;
}

.search-hint {
    color: #666;
    font-size: 0.95rem;
    text-align: center;
}

/* Buttons */
.btn {
    padding: 18px 35px;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
}

.btn-search {
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    color: white;
}

.btn-search:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(30, 60, 114, 0.4);
}

.btn-download {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    display: inline-block;
    text-decoration: none;
    text-align: center;
}

.btn-download:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(40, 167, 69, 0.4);
}

/* Results Section */
.results-section {
    background: linear-gradient(to right, #fff, #f0fff4);
}

.results-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Student Card */
.student-card {
    background: linear-gradient(135deg, #f8f9fa, #fff);
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    transition: transform 0.2s;
}

.student-card:hover {
    transform: translateX(5px);
}

.student-card.result-selected {
    border-left: 5px solid #28a745;
}

.student-card.result-waiting {
    border-left: 5px solid #f7931e;
}

.student-card.result-absent {
    border-left: 5px solid #dc3545;
}

.student-info {
    margin-bottom: 15px;
}

.info-row {
    display: flex;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    font-size: 1.1rem;
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    font-weight: 600;
    color: #1e3c72;
    width: 180px;
    flex-shrink: 0;
}

.info-value {
    color: #333;
    flex: 1;
}

/* Result Status Section */
.result-status {
    text-align: center;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 15px;
}

.result-status.status-selected {
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    border: 2px solid #28a745;
}

.result-status.status-waiting {
    background: linear-gradient(135deg, #fff3cd, #ffeeba);
    border: 2px solid #f7931e;
}

.result-status.status-absent {
    background: linear-gradient(135deg, #f8d7da, #f5c6cb);
    border: 2px solid #dc3545;
}

.result-badge {
    display: inline-block;
    padding: 8px 24px;
    border-radius: 25px;
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
}

.result-badge.badge-selected {
    background: #28a745;
    color: white;
}

.result-badge.badge-waiting {
    background: #f7931e;
    color: white;
}

.result-badge.badge-absent {
    background: #dc3545;
    color: white;
}

.result-message {
    font-size: 1rem;
    color: #333;
    line-height: 1.6;
    margin-top: 8px;
}

/* Download Section */
.download-section {
    text-align: center;
    padding-top: 15px;
    border-top: 2px dashed #e9ecef;
}

/* No Results Section */
.no-results-section {
    background: linear-gradient(to right, #fff, #fff5f5);
}

.no-results-content {
    text-align: center;
    padding: 30px;
}

.no-results-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #dc3545, #ff6b6b);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    font-weight: 700;
    margin: 0 auto 20px;
}

.no-results-content h3 {
    color: #dc3545;
    font-size: 1.4rem;
    margin-bottom: 15px;
}

.no-results-content p {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 10px;
}

.contact-info {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

/* Footer */
.footer {
    text-align: center;
    padding: 20px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
}

/* Loading Overlay */
.loading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.loading-overlay.active {
    display: flex;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 6px solid #e0e0e0;
    border-top-color: #ff6b35;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-overlay p {
    margin-top: 20px;
    color: #1e3c72;
    font-weight: 600;
    font-size: 1.2rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    body {
        font-size: 16px;
    }

    .header h1 {
        font-size: 1.5rem;
    }

    .container {
        padding: 15px;
    }

    .card {
        padding: 20px;
    }

    .card h2 {
        font-size: 1.15rem;
    }

    .search-box input {
        font-size: 1.1rem;
        padding: 15px;
    }

    .btn {
        width: 100%;
        padding: 15px 25px;
    }

    .info-row {
        flex-direction: column;
        gap: 5px;
    }

    .info-label {
        width: 100%;
    }

    .instruction-item {
        padding: 12px;
    }

    .step {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
}
