* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background: #f4f4f4;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #e9ecef;
}

.header-actions {
    display: flex;
    gap: 10px;
}

h1, h2, h3 {
    color: #333;
    margin-bottom: 20px;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    color: white;
    font-size: 14px;
    transition: background 0.3s;
}

.btn-primary {
    background: #007bff;
}
.btn-primary:hover {
    background: #0056b3;
}

.btn-success {
    background: #28a745;
}
.btn-success:hover {
    background: #1e7e34;
}

.btn-danger {
    background: #dc3545;
}
.btn-danger:hover {
    background: #c82333;
}

.btn-secondary {
    background: #6c757d;
}
.btn-secondary:hover {
    background: #5a6268;
}

.btn-info {
    background: #17a2b8;
}
.btn-info:hover {
    background: #138496;
}

.btn-sm {
    padding: 5px 10px;
    font-size: 12px;
}

.form-container {
    max-width: 600px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #007bff;
}

.login-form {
    max-width: 400px;
    margin: 50px auto;
    padding: 30px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.login-form form {
    margin-top: 20px;
}

.error {
    background: #f8d7da;
    color: #721c24;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.success {
    background: #d4edda;
    color: #155724;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.home-options {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 40px;
}

.card {
    background: #f8f9fa;
    padding: 30px;
    border-radius: 8px;
    text-align: center;
    min-width: 200px;
}

.card h3 {
    margin-bottom: 15px;
}

.card p {
    margin-bottom: 20px;
    color: #666;
}

.exam-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.exam-card {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.exam-card h4 {
    color: #007bff;
    margin-bottom: 10px;
}

.exam-card p {
    margin: 5px 0;
    font-size: 14px;
}

.exam-actions {
    margin-top: 15px;
    display: flex;
    gap: 10px;
}

.question-list {
    margin-top: 20px;
}

.question-item {
    background: #f8f9fa;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 4px;
    border-left: 4px solid #007bff;
}

.badge {
    background: #007bff;
    color: white;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
    margin-left: 10px;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

th {
    background: #f8f9fa;
    font-weight: bold;
}

@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .header-actions {
        margin-top: 10px;
    }
    
    .home-options {
        flex-direction: column;
        align-items: center;
    }
    
    .exam-list {
        grid-template-columns: 1fr;
    }
}

/* Additional styles for edit/delete functionality */
.btn-warning {
    background: #ffc107;
    color: #212529;
}
.btn-warning:hover {
    background: #e0a800;
}

.btn-danger {
    background: #dc3545;
    color: white;
}
.btn-danger:hover {
    background: #c82333;
}

.success-message {
    background: #d4edda;
    color: #155724;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 20px;
    border: 1px solid #c3e6cb;
}

.text-muted {
    color: #6c757d;
    font-size: 0.9em;
}

.exam-stats {
    display: flex;
    gap: 20px;
    margin: 10px 0;
}

.exam-stats span {
    background: #e9ecef;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 0.9em;
}

.question-actions {
    display: flex;
    gap: 10px;
    margin-left: 15px;
}

.question-item {
    background: #f8f9fa;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 4px;
    border-left: 4px solid #007bff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.question-content {
    flex: 1;
}

.badge-success {
    background: #28a745;
}

.badge-warning {
    background: #ffc107;
    color: #212529;
}

.btn-group {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.exam-card {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    transition: box-shadow 0.3s;
}

.exam-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

input[disabled] {
    background: #e9ecef;
    cursor: not-allowed;
}

small {
    display: block;
    margin-top: 5px;
    color: #6c757d;
}