/* ==========================================================================
   Gemeinsames Stylesheet für alle STIPP-Dateien
   (wegStipp2006_2, STIPP2007_1, STIPP2007_2, STIPP2008_1, STIPP2008_2,
    2005_2, 2006_1, STIPP2009_1)
   Speichern als z. B. stipp.css und im <head> einbinden:
   <link rel="stylesheet" href="stipp.css">
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Design-Tokens (Custom Properties)
   -------------------------------------------------------------------------- */
:root {
    /* Farben */
    --primary-color: #003366;
    --secondary-color: #f0f4f8;
    --text-color: #111;
    --light-text: #333;
    --accent-color: #00509e;
    --border-color: #ccc;
    --gold-color: #b8860b;

    /* Layout */
    --max-width: 1200px;

    /* Typografie */
    --font-main: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    --font-heading: Georgia, 'Times New Roman', Times, serif;
    --base-font-size: 1.05rem;

    /* Überschriften-Größen */
    --h1-size: 1.3rem;
    --h2-size: 1.2rem;
    --h3-size: 1.05rem;
}

/* --------------------------------------------------------------------------
   2. Reset & Basis
   -------------------------------------------------------------------------- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    line-height: 1.6;
    color: var(--text-color);
    background-color: #f9f9f9;
    padding: 20px;
}

/* --------------------------------------------------------------------------
   3. Container
   -------------------------------------------------------------------------- */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    background: #fff;
    padding: 30px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
}

/* --------------------------------------------------------------------------
   4. Header
   -------------------------------------------------------------------------- */
header {
    text-align: center;
    margin-bottom: 40px;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 20px;
}

.header-image {
    max-width: 100%;
    height: auto;
    margin-bottom: 20px;
    border-radius: 4px;
}

.header-top {
    display: flex;
    justify-content: space-between;
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.divider {
    height: 5px;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    margin: 10px 0 20px 0;
    border-radius: 2px;
}

/* --------------------------------------------------------------------------
   5. Typografie
   -------------------------------------------------------------------------- */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    color: var(--primary-color);
    margin-top: 30px;
    margin-bottom: 15px;
    line-height: 1.3;
}

h1 {
    font-size: var(--h1-size);
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

h2 { font-size: var(--h2-size); }
h3 { font-size: var(--h3-size); }
h4 { font-size: 1rem; }

span.small-font {
    font-size: 0.7rem;
    font-weight: normal;
    float: right;
}

p {
    margin-bottom: 15px;
    text-align: justify;
    font-size: var(--base-font-size);
}

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

a:hover {
    text-decoration: none;
}

.intro-text {
    font-size: 1.2rem;
    font-style: italic;
    color: var(--light-text);
    margin-bottom: 25px;
}

.signature {
    text-align: right;
    font-style: italic;
    margin-top: 10px;
    color: var(--light-text);
}

.text-left { text-align: left; }
.text-right { text-align: right; }
.text-center { text-align: center; }

/* --------------------------------------------------------------------------
   6. Bilder & Figuren
   -------------------------------------------------------------------------- */
figure {
    margin: 20px 0;
    text-align: center;
}

figure img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

figcaption {
    font-size: 0.9rem;
    color: var(--light-text);
    margin-top: 8px;
    font-style: italic;
}

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

.map-container {
    position: relative;
    margin: 20px auto;
    max-width: 684px;
}

.map-container img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
}

area {
    cursor: pointer;
}

/* --------------------------------------------------------------------------
   7. Listen
   -------------------------------------------------------------------------- */
ul, ol {
    margin-left: 30px;
    margin-bottom: 20px;
}

li {
    margin-bottom: 8px;
}

.recipe-list {
    list-style: none;
    margin-left: 0;
    padding: 0;
}

.recipe-list li {
    padding: 2px 0;
}

/* --------------------------------------------------------------------------
   8. Boxen
   -------------------------------------------------------------------------- */
.highlight-box {
    background-color: var(--secondary-color);
    border-left: 5px solid var(--primary-color);
    padding: 20px;
    margin: 25px 0;
    border-radius: 0 4px 4px 0;
}

.warning-box {
    background-color: #fff3f3;
    border: 2px solid #d9534f;
    padding: 15px;
    border-radius: 4px;
    margin: 20px 0;
}

.info-box {
    background-color: #eaf4ff;
    border: 1px solid var(--accent-color);
    padding: 15px;
    border-radius: 4px;
    margin: 20px 0;
}

.quote-box {
    border: 1px solid var(--border-color);
    background: #fdfdfd;
    padding: 20px;
    margin: 20px 0;
    border-radius: 4px;
}

/* --------------------------------------------------------------------------
   9. Tabellen
   -------------------------------------------------------------------------- */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    font-size: 0.95rem;
}

th, td {
    padding: 12px;
    border: 1px solid var(--border-color);
    text-align: left;
    vertical-align: top;
}

th {
    background-color: var(--primary-color);
    color: #fff;
    font-weight: 600;
}

tr:nth-child(even) {
    background-color: #f9f9f9;
}

/* --------------------------------------------------------------------------
   10. Inhaltsverzeichnis (oben)
   -------------------------------------------------------------------------- */
.toc {
    background: var(--secondary-color);
    padding: 20px;
    border-radius: 4px;
    margin: 20px 0;
}

.toc h3 {
    margin-top: 0;
}

.toc ul {
    list-style-type: none;
    margin-left: 0;
}

.toc li {
    padding: 5px 0;
    border-bottom: 1px dotted var(--border-color);
}

.toc a {
    color: var(--primary-color);
    text-decoration: none;
}

.toc a:hover {
    text-decoration: underline;
}

/* --------------------------------------------------------------------------
   11. Footer
   -------------------------------------------------------------------------- */
footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 2px solid var(--primary-color);
    font-size: 0.9rem;
    color: var(--light-text);
    text-align: center;
}

/* --------------------------------------------------------------------------
   12. Utility-Klassen
   -------------------------------------------------------------------------- */
.clearfix::after {
    content: "";
    clear: both;
    display: table;
}

.float-left {
    float: left;
    margin-right: 20px;
    margin-bottom: 10px;
}

.float-right {
    float: right;
    margin-left: 20px;
    margin-bottom: 10px;
}

.goldene-worte {
    color: var(--gold-color);
    font-family: 'Comic Sans MS', 'Comic Sans', cursive;
    font-size: 1.1rem;
    font-weight: bold;
    margin-bottom: 10px;
}

/* Sprungmarken-Offset, damit Anker nicht unter dem oberen Rand verschwinden */
article[id],
section[id],
nav[id],
div[id] {
    scroll-margin-top: 20px;
}

/* --------------------------------------------------------------------------
   13. Responsive Anpassungen
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }

    h1 { font-size: 1.4rem; }
    h2 { font-size: 1.2rem; }
    h3 { font-size: 1.05rem; }

    .header-top {
        flex-direction: column;
        gap: 5px;
    }

    table {
        font-size: 0.85rem;
    }

    th, td {
        padding: 8px;
    }
}

@media (max-width: 600px) {
    .float-left,
    .float-right {
        float: none;
        margin: 10px auto;
        display: block;
    }

    body {
        padding: 10px;
    }

    .container {
        padding: 12px;
    }

    p {
        font-size: 1rem;
    }
}

/* --------------------------------------------------------------------------
   14. Optional: Druck-Styles
   -------------------------------------------------------------------------- */
@media print {
    body {
        background: #fff;
        padding: 0;
    }

    .container {
        box-shadow: none;
        padding: 0;
        max-width: 100%;
    }

    .toc {
        display: none;
    }

    a {
        color: inherit;
        text-decoration: none;
    }

    figure img {
        box-shadow: none;
    }
}