/* ============================================
   ki-schulwissen.de – Stylesheet
   ============================================ */

/* --- Custom Properties --- */
:root {
    --color-primary: #1e3a5f;
    --color-accent: #3b82f6;
    --color-light: #eff6ff;
    --color-bg: #ffffff;
    --color-text: #1f2937;
    --color-text-light: #6b7280;
    --color-border: #e5e7eb;
    --font-stack: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --max-width: 1200px;
    --header-height: 70px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-stack);
    font-size: 17px;
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-bg);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex: 1;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--color-accent);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

ul, ol {
    list-style: none;
}

/* --- Headings --- */
h1, h2, h3, h4, h5, h6 {
    color: var(--color-primary);
    line-height: 1.3;
}

h1 {
    font-size: 2.2rem;
}

h2 {
    font-size: 1.6rem;
}

h3 {
    font-size: 1.25rem;
}

/* --- Header --- */
.site-header {
    position: sticky;
    top: 0;
    background-color: var(--color-primary);
    height: var(--header-height);
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

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

.site-logo {
    color: #ffffff;
    font-weight: 700;
    font-size: 1.3rem;
    text-decoration: none;
}

.site-logo:hover {
    text-decoration: none;
    opacity: 0.9;
}

.main-nav ul {
    display: flex;
    gap: 0.25rem;
    list-style: none;
}

.main-nav a {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    padding: 0.5rem 0.9rem;
    border-radius: 6px;
    font-size: 0.95rem;
    transition: background-color 0.2s, color 0.2s;
}

.main-nav a:hover,
.main-nav a.active {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.15);
    text-decoration: none;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #ffffff;
    font-size: 1.6rem;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    line-height: 1;
}

.menu-toggle:hover {
    background-color: rgba(255, 255, 255, 0.15);
}

/* --- Footer --- */
.site-footer {
    background-color: var(--color-primary);
    color: rgba(255, 255, 255, 0.8);
    text-align: center;
    padding: 0.75rem 1.5rem;
    font-size: 0.85rem;
}

.site-footer p {
    margin-bottom: 0.25rem;
}

.site-footer a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
}

.site-footer a:hover {
    color: #ffffff;
    text-decoration: underline;
}

.footer-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0;
}

.footer-links a:not(:first-child)::before {
    content: "|";
    padding: 0 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    pointer-events: none;
}

/* --- Hero --- */
.hero {
    background-color: var(--color-light);
    padding: 4rem 1.5rem;
    text-align: center;
}

.hero-tagline {
    text-transform: uppercase;
    color: var(--color-accent);
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.15em;
    margin-bottom: 1rem;
}

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

.hero p {
    color: var(--color-text-light);
    max-width: 600px;
    margin: 0 auto 2rem auto;
    font-size: 1.1rem;
}

.btn {
    display: inline-block;
    background-color: var(--color-accent);
    color: #ffffff;
    padding: 0.75rem 1.75rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: background-color 0.2s, transform 0.2s;
}

.btn:hover {
    background-color: #2563eb;
    transform: translateY(-2px);
    text-decoration: none;
    color: #ffffff;
}

/* --- Sections --- */
.section {
    padding: 3rem 1.5rem;
}

.section-inner {
    max-width: var(--max-width);
    margin: 0 auto;
}

.section-title {
    text-align: center;
    margin-bottom: 2rem;
}

.section-more {
    text-align: center;
    margin-top: 2rem;
}

/* --- Card Grid --- */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.5rem;
}

.card {
    background-color: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: 10px;
    padding: 1.5rem;
    transition: box-shadow 0.2s, transform 0.2s;
}

.card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    transform: translateY(-3px);
}

.card-icon {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}

.card h3 {
    margin-bottom: 0.5rem;
}

.card p {
    color: var(--color-text-light);
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.card-link {
    font-size: 0.9rem;
    font-weight: 600;
}

/* --- About Preview --- */
.about-preview {
    background-color: var(--color-light);
}

.about-preview-inner {
    display: flex;
    align-items: center;
    gap: 3rem;
}

.about-avatar {
    width: 150px;
    height: 150px;
    min-width: 150px;
    border-radius: 50%;
    background-color: var(--color-primary);
    color: #ffffff;
    font-size: 3rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.about-text h2 {
    margin-bottom: 0.75rem;
}

.about-text p {
    color: var(--color-text-light);
    margin-bottom: 1rem;
}

/* --- Blog Teaser --- */
.blog-list {
    list-style: none;
}

.blog-list li {
    border-bottom: 1px solid var(--color-border);
    padding: 1.25rem 0;
}

.blog-list li:last-child {
    border-bottom: none;
}

.blog-date {
    font-size: 0.85rem;
    color: var(--color-text-light);
}

.blog-list h3 {
    margin: 0.25rem 0 0.5rem 0;
}

.blog-list h3 a {
    color: var(--color-primary);
}

.blog-list h3 a:hover {
    color: var(--color-accent);
}

.blog-list p {
    color: var(--color-text-light);
    font-size: 0.95rem;
}

/* --- Page Banner (Subpages) --- */
.page-banner {
    background-color: var(--color-light);
    padding: 2.5rem 1.5rem;
    text-align: center;
}

.page-banner h1 {
    margin-bottom: 0.5rem;
}

.page-banner .subtitle {
    color: var(--color-text-light);
    font-size: 1.05rem;
}

/* --- Content Page (Subpages) --- */
.content-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.content-page h2 {
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
}

.content-page h2:first-child {
    border-top: none;
    margin-top: 0;
    padding-top: 0;
}

.content-page p {
    margin-bottom: 1rem;
}

.content-page ul,
.content-page ol {
    margin: 1rem 0;
    padding-left: 1.5rem;
}

.content-page ul {
    list-style: disc;
}

.content-page ol {
    list-style: decimal;
}

.content-page li {
    margin-bottom: 0.5rem;
}

/* --- Profile Header --- */
.profile-header {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 2rem;
}

.profile-header .about-avatar {
    width: 120px;
    height: 120px;
    min-width: 120px;
    font-size: 2.5rem;
}

.profile-info h1 {
    margin-bottom: 0.25rem;
}

.profile-info p {
    color: var(--color-text-light);
}

/* --- Booking Page --- */
.booking-hero {
    background: linear-gradient(135deg, var(--color-primary) 0%, #2563eb 100%);
    color: #ffffff;
    padding: 5rem 1.5rem;
    text-align: center;
}

.booking-hero h1 {
    color: #ffffff;
    font-size: 2.8rem;
    margin-bottom: 1rem;
}

.booking-hero p {
    color: rgba(255, 255, 255, 0.9);
    max-width: 650px;
    margin: 0 auto 2rem auto;
    font-size: 1.15rem;
}

.booking-hero .btn {
    background-color: #ffffff;
    color: var(--color-primary);
    font-size: 1.1rem;
    padding: 0.9rem 2rem;
}

.booking-hero .btn:hover {
    background-color: rgba(255, 255, 255, 0.9);
    color: var(--color-primary);
    transform: translateY(-2px);
}

.formats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.5rem;
}

.format-card {
    background-color: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: 2rem 1.5rem;
    text-align: center;
    transition: box-shadow 0.2s, transform 0.2s;
}

.format-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    transform: translateY(-4px);
}

.format-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.format-card h3 {
    margin-bottom: 0.5rem;
}

.format-card p {
    color: var(--color-text-light);
    font-size: 0.95rem;
}

.topics-list {
    max-width: 700px;
    margin: 0 auto;
    list-style: none;
}

.topics-list li {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-border);
    font-size: 1.05rem;
}

.topics-list li:last-child {
    border-bottom: none;
}

.topic-icon {
    font-size: 1.3rem;
    min-width: 1.5rem;
    text-align: center;
}

.booking-form-section {
    background-color: var(--color-light);
}

.booking-form {
    max-width: 650px;
    margin: 0 auto;
    background-color: var(--color-bg);
    border-radius: 12px;
    padding: 2.5rem;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.4rem;
    font-size: 0.95rem;
    color: var(--color-text);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    font-size: 1rem;
    font-family: var(--font-stack);
    color: var(--color-text);
    background-color: var(--color-bg);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-submit {
    text-align: center;
    margin-top: 1.5rem;
}

.form-submit .btn {
    border: none;
    cursor: pointer;
    font-family: var(--font-stack);
    padding: 0.85rem 2.5rem;
    font-size: 1.05rem;
}

.form-hint {
    font-size: 0.85rem;
    color: var(--color-text-light);
    margin-top: 0.25rem;
}

.form-status {
    text-align: center;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.form-status.success {
    background-color: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.form-status.error {
    background-color: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .main-nav {
        display: none;
        position: absolute;
        top: var(--header-height);
        left: 0;
        right: 0;
        background-color: var(--color-primary);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }

    .main-nav.open {
        display: block;
    }

    .main-nav ul {
        flex-direction: column;
        padding: 0.75rem 0;
    }

    .main-nav a {
        display: block;
        padding: 0.75rem 1.5rem;
        border-radius: 0;
    }

    .hero {
        padding: 2.5rem 1.5rem;
    }

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

    .about-preview-inner {
        flex-direction: column;
        text-align: center;
    }

    .profile-header {
        flex-direction: column;
        text-align: center;
    }

    .booking-hero {
        padding: 3rem 1.5rem;
    }

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

    .form-row {
        grid-template-columns: 1fr;
    }
}
