/* ==================================================
   KI-Simulatoren für den Informatikunterricht
   style.css
================================================== */

/* ---------- Grundeinstellungen ---------- */

:root {
    --primary: #0d6efd;
    --primary-dark: #084298;
    --primary-light: #eaf3ff;
    --text: #243142;
    --text-muted: #5f6f82;
    --background: #f4f7fb;
    --card-background: #ffffff;
    --border: #dfe7f1;
    --shadow: 0 8px 26px rgba(29, 53, 87, 0.1);
    --shadow-hover: 0 18px 42px rgba(29, 53, 87, 0.18);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--background);
    color: var(--text);
    font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
}

/* ---------- Hero-Bereich ---------- */

.hero {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 15% 25%,
            rgba(255, 255, 255, 0.18) 0,
            rgba(255, 255, 255, 0) 30%),
        radial-gradient(circle at 85% 15%,
            rgba(255, 255, 255, 0.14) 0,
            rgba(255, 255, 255, 0) 28%),
        linear-gradient(135deg, #084298 0%, #0d6efd 55%, #63a4ff 100%);
    color: #ffffff;
    padding: 70px 20px 76px;
    border-radius: 0 0 32px 32px;
    box-shadow: 0 10px 30px rgba(8, 66, 152, 0.2);
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 960px;
    margin: 0 auto;
}

/* ---------- Logo und Überschrift ---------- */

.hero-heading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 28px;
    margin: 0 auto 28px;
    max-width: 1100px;
}

.hero-logo {
    width: 110px;
    height: 110px;
    object-fit: contain;
    flex-shrink: 0;
}

.hero h1 {
    margin: 0;
    color: #fff;
    font-size: clamp(2.3rem, 5vw, 3.6rem);
    font-weight: 750;
    line-height: 1.1;
    letter-spacing: -0.03em;
    text-align: left;
}

.hero .lead {
    max-width: 850px;
    margin: 0 auto;
    color: rgba(255, 255, 255, .93);
    text-align: center;
    font-size: 1.2rem;
}

/* ---------- Hauptinhalt ---------- */

.simulation-section {
    padding-top: 64px;
    padding-bottom: 30px;
}

.section-heading {
    max-width: 760px;
    margin: 0 auto 38px;
    text-align: center;
}

.section-heading h2 {
    margin-bottom: 12px;
    color: var(--text);
    font-size: clamp(1.75rem, 3vw, 2.35rem);
    font-weight: 720;
}

.section-heading p {
    margin-bottom: 0;
    color: var(--text-muted);
    font-size: 1.05rem;
}

/* ---------- Karten ---------- */

.simulation-card {
    height: 100%;
    overflow: hidden;
    border: 1px solid rgba(13, 110, 253, 0.08);
    border-radius: 20px;
    background: var(--card-background);
    box-shadow: var(--shadow);
    transition:
        transform 0.28s ease,
        box-shadow 0.28s ease,
        border-color 0.28s ease;
}

.simulation-card:hover {
    transform: translateY(-8px);
    border-color: rgba(13, 110, 253, 0.24);
    box-shadow: var(--shadow-hover);
}

/* ---------- Bilder ---------- */

.card-image-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 390px;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
    background: white;
}

.simulation-card .card-img-top {
    display: block;
    width: 100%;
    height: 100%;
    padding: 8px;
    object-fit: contain;
    object-position: center;
    background: #ffffff;
}

/* ---------- Karteninhalt ---------- */

.simulation-card .card-body {
    display: flex;
    flex-direction: column;
    padding: 26px;
}

.category-label {
    display: inline-block;
    align-self: flex-start;
    margin-bottom: 12px;
    padding: 5px 10px;
    border-radius: 999px;
    background: var(--primary-light);
    color: var(--primary-dark);
    font-size: 0.73rem;
    font-weight: 750;
    letter-spacing: 0.075em;
    text-transform: uppercase;
}

.simulation-card .card-title {
    margin-bottom: 14px;
    color: var(--primary-dark);
    font-size: 1.32rem;
    font-weight: 720;
    line-height: 1.3;
}

.simulation-card .card-text {
    flex-grow: 1;
    margin-bottom: 0;
    color: var(--text-muted);
    font-size: 1rem;
}

/* ---------- Buttons ---------- */

.simulation-card .btn-primary {
    align-self: flex-start;
    margin-top: 24px;
    padding: 11px 21px;
    border: 0;
    border-radius: 999px;
    background: var(--primary);
    box-shadow: 0 6px 16px rgba(13, 110, 253, 0.2);
    font-weight: 650;
    transition:
        transform 0.2s ease,
        background-color 0.2s ease,
        box-shadow 0.2s ease;
}

.simulation-card .btn-primary:hover,
.simulation-card .btn-primary:focus {
    transform: translateY(-2px);
    background: var(--primary-dark);
    box-shadow: 0 9px 20px rgba(8, 66, 152, 0.25);
}

/* ---------- Footer ---------- */

.site-footer {
    margin-top: 54px;
    padding: 30px 20px;
    border-top: 1px solid var(--border);
    color: #6b7787;
    text-align: center;
    font-size: 0.94rem;
}

.site-footer strong {
    color: var(--primary-dark);
}

/* ---------- Tastaturbedienung ---------- */

a:focus-visible,
button:focus-visible {
    outline: 3px solid rgba(13, 110, 253, 0.35);
    outline-offset: 3px;
}

/* ---------- Responsive Anpassungen ---------- */

@media (max-width: 991.98px) {
    .hero {
        padding-top: 60px;
        padding-bottom: 66px;
    }

    .card-image-wrapper {
        height: 300px;
    }
}

.hero-heading {
    gap: 18px;
}

.hero-logo {
    width: 80px;
    height: 80px;
}

.hero h1 {
    font-size: 2rem;
}

@media (max-width: 767.98px) {
    .hero {
        padding: 50px 18px 56px;
        border-radius: 0 0 24px 24px;
    }

    .hero .lead {
        font-size: 1.08rem;
    }

    .simulation-section {
        padding-top: 48px;
    }

    .card-image-wrapper {
        height: 290px;
    }
}

@media (max-width: 575.98px) {
    .hero-heading {
        flex-direction: row;
        gap: 12px;
    }

    .hero-logo {
        width: 65px;
        height: 65px;
    }

    .hero h1 {
        font-size: 1.7rem;
        text-align: left;
    }


    .hero .lead {
        font-size: 1rem;
    }

    .card-image-wrapper {
        height: 270px;
    }

    .simulation-card .card-body {
        padding: 22px;
    }

    .simulation-card .btn-primary {
        width: 100%;
        text-align: center;
    }
}

/* ---------- Weniger Animation bei Bedarf ---------- */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .simulation-card,
    .simulation-card .btn-primary {
        transition: none;
    }

    .simulation-card:hover,
    .simulation-card .btn-primary:hover {
        transform: none;
    }
}