:root {
    --primary: #1a4f8c;
    --secondary: #3b82f6;
    --accent: #f59e0b;
    --light: #f3f4f6;
    --dark: #1f2937;
    --success: #10b981;
    --danger: #ef4444;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    color: var(--dark);
    min-height: 100vh;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Styles */
header {
    background: linear-gradient(to right, var(--primary), var(--secondary));
    color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo {
    width: 70px;
    height: 70px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 24px;
    color: var(--primary);
}

.header-text h1 {
    font-size: 28px;
    margin-bottom: 5px;
}

.header-text p {
    font-size: 16px;
    opacity: 0.9;
}

.header-buttons {
    display: flex;
    gap: 15px;
}

.btn {
    padding: 12px 25px;
    border-radius: 50px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: white;
    color: var(--primary);
}

.btn-primary:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid white;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* Main Content Styles */
.hero {
    text-align: center;
    padding: 40px 20px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
}

.hero h2 {
    font-size: 36px;
    color: var(--primary);
    margin-bottom: 20px;
}

.hero p {
    font-size: 18px;
    color: var(--dark);
    max-width: 800px;
    margin: 0 auto 30px;
    line-height: 1.6;
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.feature-card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-card i {
    font-size: 40px;
    color: var(--secondary);
    margin-bottom: 15px;
}

.feature-card h3 {
    font-size: 22px;
    margin-bottom: 15px;
    color: var(--primary);
}

.feature-card p {
    color: var(--dark);
    line-height: 1.6;
}

/* Forms */
.form-container {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
    display: none;
}

.form-container.active {
    display: block;
}

.form-title {
    text-align: center;
    color: var(--primary);
    margin-bottom: 25px;
    font-size: 28px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--dark);
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 14px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.form-footer {
    text-align: center;
    margin-top: 20px;
}

/* Login Credentials */
.credentials-display {
    background: #f8fafc;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
}

.credential-item {
    background: white;
    padding: 15px;
    border-radius: 8px;
    margin: 15px 0;
    border-left: 4px solid var(--secondary);
}

.warning-note {
    background: #fef3c7;
    padding: 15px;
    border-radius: 8px;
    margin-top: 20px;
    border-left: 4px solid var(--accent);
}

/* Exam Module */
.exam-container {
    display: none;
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
}

.exam-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.timer {
    background: var(--primary);
    color: white;
    padding: 10px 20px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 18px;
}

.question-number {
    font-size: 18px;
    font-weight: 600;
    color: var(--dark);
}

.question {
    font-size: 20px;
    margin-bottom: 25px;
    line-height: 1.5;
    color: var(--dark);
}

.options {
    display: grid;
    grid-template-columns: 1fr;
    gap: 15px;
    margin-bottom: 30px;
}

.option {
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.option:hover {
    border-color: var(--secondary);
    background: #f0f7ff;
}

.option.selected {
    border-color: var(--secondary);
    background: #dbeafe;
}

.exam-footer {
    display: flex;
    justify-content: space-between;
}

/* Results Section */
.results-display {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 30px;
    margin-bottom: 30px;
}

.result-card {
    text-align: center;
    padding: 20px;
    background: #f8fafc;
    border-radius: 12px;
}

.score-circle {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 20px auto;
    font-size: 24px;
}

.result-details {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.result-details p {
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

/* Certificate */
.certificate-container {
    display: none;
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
    text-align: center;
}

.certificate {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border: 20px solid transparent;
    border-image: linear-gradient(45deg, #ffd700, #fef08a, #ffd700);
    border-image-slice: 1;
    padding: 50px;
    margin: 30px auto;
    max-width: 800px;
    position: relative;
}

.certificate-header {
    margin-bottom: 30px;
}

.certificate-title {
    font-size: 36px;
    color: var(--primary);
    margin-bottom: 10px;
}

.certificate-subtitle {
    font-size: 20px;
    color: var(--dark);
    margin-bottom: 40px;
}

.certificate-body {
    margin-bottom: 40px;
}

.certificate-name {
    font-size: 32px;
    color: var(--primary);
    margin-bottom: 20px;
    font-weight: bold;
}

.certificate-details {
    font-size: 18px;
    margin-bottom: 10px;
    color: var(--dark);
}

.certificate-footer {
    display: flex;
    justify-content: space-between;
    margin-top: 50px;
}

.signature {
    width: 200px;
    text-align: center;
}

.signature-line {
    border-top: 1px solid var(--dark);
    margin: 10px 0;
    padding-top: 10px;
}

.qr-code {
    margin: 20px auto;
    width: 120px;
    height: 120px;
}

/* Footer */
footer {
    text-align: center;
    padding: 30px 0;
    color: var(--dark);
    border-top: 1px solid #ddd;
    margin-top: 30px;
}

.admin-login-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    margin-top: 15px;
    display: inline-block;
}

.admin-login-link:hover {
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 768px) {
    .header-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    header {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    
    .logo-container {
        justify-content: center;
    }
    
    .certificate {
        padding: 20px;
    }
    
    .certificate-title {
        font-size: 28px;
    }
    
    .certificate-name {
        font-size: 24px;
    }
    
    .certificate-footer {
        flex-direction: column;
        gap: 30px;
    }
    
    .results-display {
        grid-template-columns: 1fr;
    }
}