@import url('https://fonts.googleapis.com/css2?family=Inter:opsz,wght@14..32,300;14..32,400;14..32,500;14..32,600;14..32,700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
    background: #f5f7fa;
    color: #1e293b;
    line-height: 1.5;
    padding: 2rem 1rem;
}

/* Container – centered with max width for readability */
.container {
    max-width: 1280px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 1.25rem;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.05);
    padding: 2rem;
}

/* Responsive container margins */
@media (min-width: 640px) {
    body { padding: 2rem; }
    .container { padding: 2rem 2.5rem; }
}

/* Typography */
h1 {
    font-size: 1.875rem;
    font-weight: 600;
    color: #0f2b3d;
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}
h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}
h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.75rem;
}
p {
    margin-bottom: 1rem;
    color: #475569;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.6rem 1.25rem;
    border-radius: 2rem;
    font-weight: 500;
    font-size: 0.875rem;
    line-height: 1.25rem;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    background-color: #f1f5f9;
    color: #1e293b;
}
.btn-primary {
    background-color: #0f2b3d;
    color: white;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}
.btn-primary:hover {
    background-color: #1e4057;
    transform: translateY(-1px);
}
.btn-secondary {
    background-color: #ffffff;
    border: 1px solid #cbd5e1;
    color: #1e293b;
}
.btn-secondary:hover {
    background-color: #f8fafc;
}
.btn-success {
    background-color: #059669;
    color: white;
}
.btn-success:hover {
    background-color: #047857;
}
.btn-danger {
    background-color: #dc2626;
    color: white;
}
.btn-danger:hover {
    background-color: #b91c1c;
}

/* Cards */
.card {
    background: #ffffff;
    border: 1px solid #eef2f6;
    border-radius: 1rem;
    padding: 1.5rem;
    transition: box-shadow 0.2s;
}
.card:hover {
    box-shadow: 0 12px 24px -12px rgba(0, 0, 0, 0.1);
}

/* Grid */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

/* Alerts */
.alert {
    padding: 1rem 1.25rem;
    border-radius: 0.75rem;
    margin-bottom: 1.5rem;
    font-weight: 500;
    border-left: 4px solid;
}
.alert-success {
    background-color: #ecfdf5;
    border-left-color: #059669;
    color: #065f46;
}
.alert-error {
    background-color: #fef2f2;
    border-left-color: #dc2626;
    color: #991b1b;
}
.alert-info {
    background-color: #eff6ff;
    border-left-color: #3b82f6;
    color: #1e40af;
}

/* Forms */
.input-group {
    margin-bottom: 1.25rem;
}
label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: #0f2b3d;
}
input, select {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 0.75rem;
    font-size: 0.875rem;
    transition: 0.15s;
}
input:focus, select:focus {
    outline: none;
    border-color: #0f2b3d;
    box-shadow: 0 0 0 3px rgba(15, 43, 61, 0.1);
}

/* Tables (DataTable overrides) */
.dataTables_wrapper {
    margin: 1.5rem 0;
    font-size: 0.875rem;
}
table.dataTable {
    border-collapse: separate;
    border-spacing: 0;
    width: 80%;
}
table.dataTable thead th {
    background: #f8fafc;
    color: #0f2b3d;
    font-weight: 600;
    padding: 1rem;
    border-bottom: 1px solid #e2e8f0;
}
table.dataTable tbody td {
    padding: 0.875rem 1rem;
    border-bottom: 1px solid #f1f5f9;
}
table.dataTable tbody tr:hover {
    background-color: #fafcff;
}
.dataTables_paginate .paginate_button {
    border-radius: 2rem !important;
    padding: 0.3rem 0.8rem !important;
    margin: 0 0.2rem;
}
.dataTables_filter input {
    border-radius: 2rem;
    padding: 0.4rem 1rem;
}

/* Quiz specific */
.question-card {
    background: #ffffff;
    border-radius: 1.25rem;
    padding: 1.25rem;
    margin-bottom: 1rem;
    border: 1px solid #eef2ff;
    transition: box-shadow 0.2s;
}

.question-card:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.05);
}

.wrong-row {
    background-color: #ffebee !important;
}

.options {
    display: flex;
    gap: 2rem;
    margin-top: 0.75rem;
}

.options label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 400;
    cursor: pointer;
}


/* Utilities */
.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}
.mt-3 { margin-top: 1.5rem; }
.mb-3 { margin-bottom: 1.5rem; }
.text-center { text-align: center; }