/* ================================================================
   Kursplattform — Stylesheet
   ================================================================ */

/* ----------------------------------------------------------------
   Source Sans 3 — Local font faces
   ---------------------------------------------------------------- */
/* source-sans-3-200 - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 200;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-200.woff2') format('woff2');
}
/* source-sans-3-200italic - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: italic;
  font-weight: 200;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-200italic.woff2') format('woff2');
}
/* source-sans-3-300 - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 300;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-300.woff2') format('woff2');
}
/* source-sans-3-300italic - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: italic;
  font-weight: 300;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-300italic.woff2') format('woff2');
}
/* source-sans-3-regular - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 400;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-regular.woff2') format('woff2');
}
/* source-sans-3-italic - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: italic;
  font-weight: 400;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-italic.woff2') format('woff2');
}
/* source-sans-3-500 - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 500;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-500.woff2') format('woff2');
}
/* source-sans-3-500italic - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: italic;
  font-weight: 500;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-500italic.woff2') format('woff2');
}
/* source-sans-3-600 - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 600;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-600.woff2') format('woff2');
}
/* source-sans-3-600italic - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: italic;
  font-weight: 600;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-600italic.woff2') format('woff2');
}
/* source-sans-3-700 - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 700;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-700.woff2') format('woff2');
}
/* source-sans-3-700italic - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: italic;
  font-weight: 700;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-700italic.woff2') format('woff2');
}
/* source-sans-3-800 - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 800;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-800.woff2') format('woff2');
}
/* source-sans-3-800italic - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: italic;
  font-weight: 800;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-800italic.woff2') format('woff2');
}
/* source-sans-3-900 - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 900;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-900.woff2') format('woff2');
}
/* source-sans-3-900italic - latin */
@font-face {
  font-display: swap;
  font-family: 'Source Sans 3';
  font-style: italic;
  font-weight: 900;
  src: url('fonts/source-sans-3-v19-latin/source-sans-3-v19-latin-900italic.woff2') format('woff2');
}

/* ----------------------------------------------------------------
   Custom properties
   ---------------------------------------------------------------- */

:root {
    --color-bg: #f3f1ef;
    --color-surface: #ffffff;
    --color-surface-raised: #f9f5ec;
    --color-text: #212529;
    --color-text-muted: #667a7a;
    --color-primary: #5f8c98;
    --color-primary-hover: #4a7580;
    --color-primary-light: #e8f0f2;
    --color-accent: #dea47d;
    --color-accent-gold: #e7c191;
    --color-border: #e5e2dc;
    --color-error: #b33a3a;
    --color-error-bg: #fdf0f0;
    --color-success: #3a7a3a;
    --color-success-bg: #e8f0e7;
    --color-footer-bg: #0b152b;
    --color-footer-text: #dee2e6;
    --color-footer-link: #b98c05;

    --font-body: 'Source Sans 3', system-ui, -apple-system, sans-serif;
    --font-display: 'Source Sans 3', system-ui, -apple-system, sans-serif;

    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;

    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.1);

    --max-width: 800px;
    --spacing: 1.5rem;
}

/* ----------------------------------------------------------------
   Reset & Base
   ---------------------------------------------------------------- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-body);
    color: var(--color-text);
    background: var(--color-bg);
    line-height: 1.6;
    min-height: 100vh;
}

/* ----------------------------------------------------------------
   App Shell
   ---------------------------------------------------------------- */
.app-shell {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.app-header {
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    padding: 1rem var(--spacing);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.lang-switch,
.header-link {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    text-decoration: none;
    padding: 0.25em 0.6em;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    transition: all 0.15s ease;
}

.lang-switch:hover,
.header-link:hover {
    color: var(--color-text);
    border-color: var(--color-text-muted);
}

.logo {
    font-family: var(--font-display);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-text);
}

.company-badge {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    background: var(--color-bg);
    padding: 0.3em 0.8em;
    border-radius: 20px;
    font-weight: 500;
}

.app-main {
    flex: 1;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 2rem var(--spacing);
    width: 100%;
}

.app-footer {
    background: var(--color-footer-bg);
    border-top: none;
    padding: 1.5rem var(--spacing);
    text-align: center;
    color: var(--color-footer-text);
    font-size: 0.85rem;
}

.app-footer a {
    color: var(--color-footer-link);
    text-decoration: underline;
    text-underline-offset: 5px;
    font-weight: 600;
}

.app-footer a:hover {
    color: #d27d06;
}

.footer-sep {
    margin: 0 0.4em;
    opacity: 0.5;
}

/* ----------------------------------------------------------------
   Typography
   ---------------------------------------------------------------- */
h1 {
    font-family: var(--font-display);
    font-size: 2rem;
    line-height: 1.2;
    margin-bottom: 0.75rem;
    letter-spacing: -0.02em;
}

h2 {
    font-family: var(--font-display);
    font-size: 1.4rem;
    line-height: 1.3;
    margin-bottom: 0.5rem;
}

h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

p {
    margin-bottom: 0.75rem;
}

/* ----------------------------------------------------------------
   Buttons
   ---------------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4em;
    padding: 0.7em 1.5em;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
    line-height: 1.4;
}

.btn-primary {
    background: var(--color-accent-gold);
    color: var(--color-text);
    border: 1px solid var(--color-accent);
}

.btn-primary:hover:not(:disabled):not(.btn-disabled) {
    background: var(--color-accent);
    border-color: var(--color-accent);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.btn-secondary {
    background: var(--color-surface);
    color: var(--color-text);
    border: 1px solid var(--color-border);
}

.btn-secondary:hover {
    background: var(--color-bg);
}

.btn-large {
    padding: 1em 2.5em;
    font-size: 1.1rem;
}

.btn:disabled,
.btn-disabled {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
}

/* ----------------------------------------------------------------
   Hero / Home
   ---------------------------------------------------------------- */
.hero-section {
    text-align: center;
    padding: 4rem 1rem;
}

.hero-section h1 {
    font-size: 2.4rem;
    margin-bottom: 1rem;
}

.hero-section p {
    color: var(--color-text-muted);
    font-size: 1.1rem;
}

/* ----------------------------------------------------------------
   Course Landing
   ---------------------------------------------------------------- */
.course-landing {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.course-header h1 {
    font-size: 2.2rem;
}

.course-description {
    color: var(--color-text-muted);
    font-size: 1.05rem;
}

.course-meta {
    display: flex;
    gap: 1rem;
    margin-top: 0.75rem;
}

.meta-item {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    background: var(--color-primary-light);
    padding: 0.25em 0.7em;
    border-radius: 20px;
    font-weight: 500;
}

/* Steps overview list */
.course-steps-overview {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
}

.steps-list {
    list-style: none;
    counter-reset: step-counter;
}

.step-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
    counter-increment: step-counter;
}

.step-item:last-child {
    border-bottom: none;
}

.step-icon {
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 0.85rem;
    flex-shrink: 0;
}

.step-done .step-icon {
    background: var(--color-success-bg);
    color: var(--color-success);
}

.step-current .step-icon {
    background: var(--color-primary);
    color: #fff;
}

.step-locked .step-icon {
    background: var(--color-bg);
    color: var(--color-text-muted);
}

.step-title {
    flex: 1;
    font-weight: 450;
}

.step-locked .step-title {
    color: var(--color-text-muted);
}

.step-status {
    font-size: 0.85rem;
}

.step-done .step-status {
    color: var(--color-success);
}

.step-locked .step-status {
    color: var(--color-text-muted);
}

/* Identify form */
.identify-section {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
}

.identify-form {
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.form-group label {
    font-size: 0.9rem;
    font-weight: 500;
}

.form-group input,
.form-group select {
    font-family: var(--font-body);
    font-size: 1rem;
    padding: 0.65em 0.85em;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-bg);
    color: var(--color-text);
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-light);
}

.start-section {
    text-align: center;
    padding: 1rem 0;
}

/* ----------------------------------------------------------------
   Step Container (Video & Quiz)
   ---------------------------------------------------------------- */
.step-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Progress bar */
.step-progress-bar {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.progress-track {
    flex: 1;
    height: 6px;
    background: var(--color-border);
    border-radius: 3px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--color-primary);
    border-radius: 3px;
    transition: width 0.5s ease;
}

.progress-text {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    white-space: nowrap;
    font-weight: 500;
}

/* Step content */
.step-content {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
}

.step-content h1 {
    font-size: 1.15rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    margin-bottom: 0.25rem;
}

.step-description {
    color: var(--color-text-muted);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 1rem;
}

/* Separator between heading block and quiz form */
.step-content h1 + .quiz-form,
.step-description + .quiz-form {
    margin-top: 1.75rem;
    padding-top: 1.75rem;
    border-top: 1px solid var(--color-border);
}

.step-content h1 + .alert,
.step-description + .alert {
    margin-top: 1.5rem;
}

/* Video */
.video-wrapper {
    margin: 1rem 0;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.video-wrapper video-player {
    display: block;
    width: 100%;
    max-height: 500px;
    aspect-ratio: 16 / 9;
}

.video-wrapper > video {
    width: 100%;
    display: block;
    max-height: 500px;
    background: #000;
}

.video-missing {
    margin: 1rem 0;
    padding: 3rem 1.5rem;
    border-radius: var(--radius-md);
    background: var(--color-surface-raised);
    border: 1px dashed var(--color-border);
    text-align: center;
    color: var(--color-text-muted);
}

.subtitle-picker {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: var(--color-text-muted);
}

.subtitle-picker select {
    padding: 0.3em 0.6em;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-surface);
    color: var(--color-text);
    font-family: var(--font-body);
    font-size: 0.85rem;
}

.step-text-content {
    margin-top: 1rem;
    line-height: 1.7;
}

/* Navigation */
.step-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

/* ----------------------------------------------------------------
   Quiz
   ---------------------------------------------------------------- */
.quiz-info {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--color-border);
}

.question-block {
    border: none;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--color-border);
}

.question-block:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
}

.question-text {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    display: block;
}

.question-number {
    color: var(--color-primary);
    margin-right: 0.25em;
}

.question-hint {
    font-weight: 400;
    color: var(--color-text-muted);
    font-size: 0.85rem;
}

.options-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.option-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.7rem 0.85rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.15s ease;
    position: relative;
}

.option-label:hover {
    background: var(--color-bg);
    border-color: var(--color-primary);
}

.option-label input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.option-indicator {
    width: 20px;
    height: 20px;
    border: 2px solid var(--color-border);
    border-radius: 50%;
    flex-shrink: 0;
    transition: all 0.15s ease;
    position: relative;
}

input[type="checkbox"] ~ .option-indicator {
    border-radius: 4px;
}

input:checked ~ .option-indicator {
    border-color: var(--color-primary);
    background: var(--color-primary);
}

input:checked ~ .option-indicator::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    background: #fff;
    border-radius: 50%;
}

input[type="checkbox"]:checked ~ .option-indicator::after {
    border-radius: 1px;
    width: 10px;
    height: 6px;
    background: transparent;
    border-left: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: translate(-50%, -60%) rotate(-45deg);
}

.option-text {
    font-size: 0.95rem;
}

/* Quiz feedback */
.question-feedback {
    margin-top: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
}

.question-feedback.correct {
    background: var(--color-success-bg);
    color: var(--color-success);
}

.question-feedback.incorrect {
    background: var(--color-error-bg);
    color: var(--color-error);
}

.option-label.correct-answer {
    border-color: var(--color-success);
    background: var(--color-success-bg);
}

.option-label.wrong-answer {
    border-color: var(--color-error);
    background: var(--color-error-bg);
}

.quiz-result {
    padding: 1.25rem;
    border-radius: var(--radius-md);
    text-align: center;
    margin: 1rem 0;
}

.quiz-result.passed {
    background: var(--color-success-bg);
    color: var(--color-success);
}

.quiz-result.failed {
    background: var(--color-error-bg);
    color: var(--color-error);
}

.quiz-result h3 {
    margin-bottom: 0.25rem;
}

.quiz-actions {
    display: flex;
    justify-content: center;
    padding-top: 0.5rem;
}

/* ----------------------------------------------------------------
   Completed
   ---------------------------------------------------------------- */
.completed-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    padding: 2rem 0;
}

.completed-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 3rem 2rem;
    text-align: center;
    width: 100%;
    box-shadow: var(--shadow-md);
}

.completed-icon {
    width: 64px;
    height: 64px;
    background: var(--color-success);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin: 0 auto 1.5rem;
}

.completed-card h1 {
    font-size: 2.5rem;
    margin-bottom: 0.25rem;
}

.completed-subtitle {
    color: var(--color-text-muted);
    font-size: 1.05rem;
    margin-bottom: 1rem;
}

.completed-course-title {
    font-size: 1.5rem;
    color: var(--color-primary);
    margin-bottom: 1.25rem;
}

.completed-user,
.completed-date,
.completed-company {
    color: var(--color-text-muted);
    margin-bottom: 0.25rem;
}

.completed-scores {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
}

.score-row {
    display: flex;
    justify-content: space-between;
    padding: 0.4rem 0;
}

.score-value {
    font-weight: 600;
    color: var(--color-primary);
}

/* ----------------------------------------------------------------
   Error
   ---------------------------------------------------------------- */
.error-container {
    display: flex;
    justify-content: center;
    padding: 4rem 1rem;
}

.error-card {
    text-align: center;
    max-width: 450px;
}

.error-icon {
    width: 56px;
    height: 56px;
    background: var(--color-error-bg);
    color: var(--color-error);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1.5rem;
}

.error-card h1 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.error-card p {
    color: var(--color-text-muted);
}

/* ----------------------------------------------------------------
   Alerts
   ---------------------------------------------------------------- */
.alert {
    padding: 0.85rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.alert p:last-child {
    margin-bottom: 0;
}

.alert ul {
    list-style: disc;
    padding-left: 1.2rem;
}

.alert-error {
    background: var(--color-error-bg);
    color: var(--color-error);
}

.alert-success {
    background: var(--color-success-bg);
    color: var(--color-success);
}

/* ----------------------------------------------------------------
   Report
   ---------------------------------------------------------------- */
.report-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.report-header h1 {
    font-size: 1.8rem;
}

.report-company {
    color: var(--color-text-muted);
}

.report-summary {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.summary-item {
    font-size: 0.85rem;
    font-weight: 600;
    background: var(--color-primary-light);
    padding: 0.3em 0.8em;
    border-radius: 20px;
    color: var(--color-primary);
}

.report-table-wrapper {
    overflow-x: auto;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
}

.report-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.report-table th {
    text-align: left;
    padding: 0.85rem 1rem;
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--color-text-muted);
    border-bottom: 2px solid var(--color-border);
}

.report-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--color-border);
    vertical-align: middle;
}

.report-table tr:last-child td {
    border-bottom: none;
}

.participant-name {
    font-weight: 500;
    display: block;
}

.participant-details {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

.mini-progress {
    width: 80px;
    height: 5px;
    background: var(--color-border);
    border-radius: 3px;
    overflow: hidden;
    display: inline-block;
    vertical-align: middle;
    margin-right: 0.5rem;
}

.mini-progress-bar {
    height: 100%;
    background: var(--color-primary);
    border-radius: 3px;
}

.progress-label {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

.quiz-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.2em 0.5em;
    border-radius: 4px;
}

.quiz-passed {
    background: var(--color-success-bg);
    color: var(--color-success);
}

.quiz-failed {
    background: var(--color-error-bg);
    color: var(--color-error);
}

.text-muted {
    color: var(--color-text-muted);
}

.report-empty {
    text-align: center;
    color: var(--color-text-muted);
    padding: 2rem;
}

/* ----------------------------------------------------------------
   Responsive
   ---------------------------------------------------------------- */
@media (max-width: 600px) {
    :root {
        --spacing: 1rem;
    }

    h1 {
        font-size: 1.6rem;
    }

    .hero-section h1 {
        font-size: 1.8rem;
    }

    .completed-card {
        padding: 2rem 1.25rem;
    }

    .completed-card h1 {
        font-size: 2rem;
    }

    .step-navigation {
        flex-direction: column;
    }

    .step-navigation .btn {
        width: 100%;
        justify-content: center;
    }

    .report-table {
        font-size: 0.8rem;
    }

    .report-table th,
    .report-table td {
        padding: 0.6rem 0.5rem;
    }
}

/* ================================================================
   GDPR section
   ================================================================ */

.gdpr-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--color-border);
}

.gdpr-section h3 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.gdpr-warning {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    margin-bottom: 1rem;
    line-height: 1.5;
}

.gdpr-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    flex-wrap: wrap;
}

.gdpr-delete-form {
    display: inline;
}

.btn-danger {
    background: var(--color-error);
    color: #fff;
    border: none;
    cursor: pointer;
}

.btn-danger:hover {
    background: #922e2e;
}

.btn-small {
    font-size: 0.85rem;
    padding: 0.4rem 1rem;
}

.consent-label {
    display: flex;
    gap: 0.5rem;
    align-items: flex-start;
    font-size: 0.85rem;
    color: var(--color-text-muted);
    line-height: 1.5;
    cursor: pointer;
}

.consent-label input[type="checkbox"] {
    margin-top: 0.25rem;
    flex-shrink: 0;
}

.form-group-consent {
    margin-top: 1rem;
    margin-bottom: 1rem;
}

/* ----------------------------------------------------------------
   Policy pages
   ---------------------------------------------------------------- */
.policy-container {
    max-width: 700px;
    margin: 0 auto;
}

.policy-content {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 2rem;
}

.policy-content h1 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.policy-content h2 {
    font-size: 1rem;
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}

.policy-content p {
    font-size: 0.9rem;
    line-height: 1.6;
}

.policy-intro {
    color: var(--color-text-muted);
    margin-bottom: 1.5rem;
}

.cookie-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 0.35rem;
    font-size: 0.85rem;
    margin: 1rem 0;
}

.cookie-table th {
    padding: 0.5rem 0.75rem;
    text-align: left;
    font-weight: 500;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--color-text-muted);
    border: none;
}

.cookie-table td {
    padding: 0.75rem;
    background: var(--color-bg);
    border: none;
    vertical-align: top;
}

.cookie-table tr td:first-child {
    border-radius: var(--radius-sm) 0 0 var(--radius-sm);
}

.cookie-table tr td:last-child {
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    white-space: nowrap;
    color: var(--color-text-muted);
}

.cookie-table code {
    font-size: 0.8rem;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    padding: 0.15em 0.45em;
    border-radius: 4px;
    white-space: nowrap;
}

.policy-back {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
}

.policy-back a {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    text-decoration: none;
}

.policy-back a:hover {
    color: var(--color-text);
}
