/* ============================================
   RÜHRWERK.COM - ONE-PAGER CSS
   Strukturiert und optimiert
   ============================================ */

/* ============================================
   1. IMPORTS & CSS VARIABLEN
   ============================================ */

@import url("fonts.css");

:root {
    --primary-green: #c8d300;
    --dark-green: #6b8729;
    --light-gray: #f5f5f5;
    --middle-gray: #7e7e7e;
    --dark-gray: #333;
    --text-color: #444;
    --white: #ffffff;
}

/* ============================================
   2. RESET & GLOBALE STYLES
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    max-width: 100%;
}

body {
    font-family: 'Open Sans Condensed', sans-serif;
    font-weight: 300;
    background-color: #fafafa;
    color: var(--text-color);
    line-height: 1.7;
    overflow-x: hidden;
    max-width: 100%;
    margin: 0;
    padding: 0;
}

/* Verhindert horizontales Scrollen */
section, 
.container,
.nav-container,
.event-grid {
    max-width: 100%;
    overflow-x: clip; /* ⭐ clip erlaubt overflow nach unten */
    overflow-y: visible;
}

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

/* ============================================
   3. TYPOGRAFIE
   ============================================ */

/* Links */
a {
    color: #c8d300;
    text-decoration: none;
    margin-bottom: 20px;
}

a:hover {
    color: #dddddd;
}

a:focus {
    color: #c8d300;
}

/* Absätze */
p {
    font-family: 'Open Sans Condensed', sans-serif;
    font-weight: 200;
    margin: 0 0 20px;
    word-spacing: 0.1em;
    line-height: 1.5;
    font-size: 24px;
    text-align: center;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

strong, b {
    font-family: 'Open Sans Condensed', sans-serif;
    font-weight: 100;
    color: #7e7e7e;
}

/* Überschriften */
h1 {
    font-family: 'Open Sans Condensed', sans-serif;
    font-weight: 700;
    padding-top: 20px;
    padding-bottom: 40px;
    margin-bottom: 20px;
    font-size: 5rem;
    letter-spacing: 1px;
    line-height: 1.3;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

h2 {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 100;
    text-align: center;
    padding-top: 20px;
    padding-bottom: 30px;
    font-size: 50px;
    color: #aaa;
    line-height: 1.5;
    hyphens: auto;
}

h3 {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 100;
    text-align: center;
    margin-top: 20px;
    margin-bottom: 30px;
    color: #ababab;
    font-size: 40px;
    letter-spacing: 1px;
    line-height: 1.5;
}

h4 {
    font-family: 'Open Sans', sans-serif;
    font-weight: 200;
    margin-top: 10px;
    margin-bottom: 10px;
    font-size: 30px;
    text-align: center;
    color: #fff;
    text-shadow: 3px 3px 4px #000;
    line-height: 1.5;
}
.datenschutz h4 {
    color: #666;
    text-shadow: 0px 0px 0px #fff;
}

h4 a {
    color: #fff;
}

h4 a:hover {
    color: #999;
}

h4 a:focus {
    color: #ddd;
}

/* ============================================
   4. NAVIGATION
   ============================================ */

nav {
    background: var(--primary-green);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 10000;
    transition: all 0.3s ease;
}


.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 2rem 1rem;
}

.logo img {
    margin-right: 30px;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.nav-links {
    font-family: 'Open Sans Condensed', sans-serif;
    font-weight: 100;
    display: flex;
    list-style: none;
    margin-top: 40px;
    gap: 1.2rem;
    align-items: center;
}

.nav-links a {
    color: var(--white);
    text-decoration: none;
    font-weight: 400;
    font-size: 1.2rem;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--white);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-links a:hover {
    color: var(--middle-gray);
}

/* Hamburger Menu */
.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
    position: relative;
    z-index: 1002;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--white);
    transition: all 0.3s ease;
}

/* ============================================
   5. RESPONSIVE NAVIGATION
   ============================================ */

/* Tablet */
@media (max-width: 1024px) {
    .nav-container {
        flex-direction: column;
        padding: 1rem 2rem;
    }
    
    .logo {
        margin-bottom: 1rem;
    }
    
    .logo img {
        margin-right: 0;
    }
    
    .nav-links {
        margin-top: 0;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }
    
    .nav-links a {
        font-size: 1.1rem;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .nav-container {
        padding: 1rem 1.5rem;
        flex-direction: row;
        position: relative;
    }
    
    .logo img {
        max-width: 180px;
    }
    
    .menu-toggle {
        display: flex;
        position: absolute;
        right: 1.5rem;
        top: 50%;
        transform: translateY(-50%);
    }
    
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--primary-green);
        flex-direction: column;
        gap: 0;
        margin-top: 0;
        padding: 1rem 0;
        box-shadow: 0 4px 20px rgba(0,0,0,0.1);
        z-index: 999;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .nav-links li {
        width: 100%;
        text-align: center;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .nav-links li:last-child {
        border-bottom: none;
    }
    
    .nav-links a {
        display: block;
        padding: 1rem 2rem;
        font-size: 1.1rem;
        width: 100%;
        margin-bottom: 0;
    }
    
    .nav-links a::after {
        display: none;
    }
    
    .nav-links a:hover {
        background: rgba(255, 255, 255, 0.1);
    }
    
    /* Hamburger Animation */
    .menu-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(7px, 7px);
    }
    
    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .menu-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
    }
}

/* Sehr kleine Geräte */
@media (max-width: 480px) {
    .nav-container {
        padding: 1rem 1rem;
    }
    
    .logo img {
        max-width: 150px;
    }
    
    .menu-toggle {
        right: 1rem;
    }
    
    .nav-links a {
        font-size: 1rem;
        padding: 0.9rem 1.5rem;
    }
}

/* ============================================
   6. PARALLAX BANNER
   ============================================ */

.parallax-banner {
    position: relative;
    height: 70vh;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
}

.parallax-banner-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 110%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    will-change: transform;
    transition: transform 0.1s ease-out;
}

.parallax-banner-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    padding: 20px;
    margin-top: 50px;
    max-width: 1200px;
}

.parallax-banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0);
    z-index: 1;
}

.parallax-banner-content h1 {
    margin: 0 0 10px 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.parallax-banner-content h4 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 300;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

/* Parallax Banner Responsive */
@media (max-width: 768px) {
    .parallax-banner {
        height: 500px;
    }
    
    .parallax-banner-content {
        margin-top: 30px;
    }
    
    .parallax-banner-content h1 {
        font-size: 3rem;
    }
    
    .parallax-banner-content h4 {
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .parallax-banner-content h4 {
        font-size: 1rem;
    }
}

/* ============================================
   7. SECTIONS
   ============================================ */

/*  section {
    padding: 5rem 2rem;
    max-width: 1400px;
    margin: 0 auto;
}    */

section {
    position: relative;
    z-index: 1;
    padding: 5rem 2rem;
    max-width: 1400px;
    margin: 0 auto;
}



section h2 {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 300;
    font-size: 3rem;
    color: var(--middle-gray);
    margin-bottom: 2rem;
    text-align: center;
}

section p {
    max-width: 800px;
    margin: 0 auto 1.5rem;
    font-size: 24px;
    text-align: center;
}

.section-alt {
    background: var(--light-gray);
}

/* ============================================
   8. EVENT GRID (KACHELN)
   ============================================ */

.event-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    width: 100%;
    gap: 0;
    box-sizing: border-box;
    overflow-x: clip; 
    overflow-y: visible;
}


.event-grid {
    position: relative;
    padding-bottom: 50px; /* ⭐ Platz für geöffnete Expander */
    z-index: 2; /* ⭐ Niedrig - damit Expander drüber kann */
}


/* 2. Normale Kacheln - mittel */
.tile-wrapper {
    position: relative;
    overflow: visible;
    z-index: 2; /* ⭐ Normal */
    max-width: 100%;
    box-sizing: border-box;
}


/* 3. Geöffnete Kachel - SEHR HOCH */
.tile-wrapper.expanded {
    z-index: 9999; /* ⭐ SEHR HOCH - über ALLEM */
    overflow: visible;
}

.tile-wrapper.expanded .expander {
    transform: scaleY(1);
    visibility: visible;
    overflow: visible;
}



.tile {
    position: relative;
    height: 300px;
    padding: 2rem 1rem 1rem 1rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    font-family: 'Open Sans', sans-serif;
    font-weight: 800;
    color: #fff;
    margin: 6px;
}

.tile::before {
    content: "";
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    z-index: 0;
    transition: transform 0.3s ease;
}

.tile::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(200, 211, 0, 0.1);
    z-index: 1;
    transition: background 0.5s ease;
}

.tile-wrapper:hover .tile::after {
    background: rgba(0, 0, 0, 0.2);
}

.tile-content {
    position: relative;
    min-height: 400px;
    z-index: 2;
    text-align: right;
    max-width: 99.5%;
}

.short-text {
    font-family: 'Open Sans', sans-serif;
    font-weight: 800;
    text-transform: uppercase;
    font-size: 3.5rem;
    line-height: 1;
    color: #fff;
    hyphens: none;
    position: absolute;
    bottom: 200px;
    right: 5px;
    padding: 0;
    margin: 0;
    z-index: 3;
}

.toggle-button {
    font-family: 'Open Sans Condensed', sans-serif;
    font-weight: 100;
    color: #fff;
    font-size: 40px;
    text-align: right;
    background-color: rgba(255, 255, 255, 0);
    hyphens: none;
    line-height: 1.2;
    border-radius: 2px;
    border: none;
    padding: 0 1rem 1rem 1rem;
    width: 100%;
    height: 100%;
    cursor: pointer;
    position: absolute;
    bottom: 0;
    left: 0;
    transform: none;
    transition: opacity 0.3s ease;
    z-index: 4;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
}

.toggle-button:hover {
    opacity: 0.6;
}

/* 4. Expander selbst - SEHR HOCH */
.expander {
    margin: -6px 0 0 6px;
    position: absolute;
    top: 100%;
    left: 0;
    width: 97%;
    background: var(--primary-green);
    padding: 1rem;
    border-top: 1px solid #fff;
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.3s ease;
    z-index: 2;
    visibility: hidden;
    color: #fff;
    line-height: 1.3;
}



.expander h4 {
    margin: 20px 0 60px 0;
    font-size: 50px;
    text-align: center;
    hyphens: auto;
    color: #fff;
    text-shadow: 1px 1px 2px #666;
    line-height: 1.4;
}

.expander h5 {
    margin: 20px 0 20px 0;
    font-size: 30px;
    text-align: center;
    color: #fff;
    text-shadow: 1px 1px 2px #999;
    line-height: 1.4;
}

.expander p {
    margin: 0px 0 20px 0;
}

.expander ul {
    margin: 0;
    padding: 0 20px 20px;
}

.holi {
    color: #fff;
}

.event-preis {
    font-family: 'Open Sans', sans-serif;
    font-weight: 400;
    font-size: 30px;
    color: #666;
}

.box-expander {
    background-color: #999;
    font-size: 30px;
    color: var(--primary-green);
    text-align: center;
    padding: 40px;
    margin: 30px -15px -15px -15px;
}

   /* Beispielhintergründe für einzelne Kacheln */
    .back01 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back02 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back03 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back04 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
	.back05 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back06 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back07 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back08 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back09 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back10 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back11 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back12 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back13 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back14 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back15 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back16 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back17 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back18 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back19 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
   .back20 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back21 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back22 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back23 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back24 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back25 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back26 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }
    .back27 .tile::before {
      background-image: url("../images/kachelbilder/farbkacheln28.jpg");
    }

/* Event Grid Responsive */
@media (max-width: 768px) {
    .event-grid {
        grid-template-columns: 1fr;
        gap: 0;
        padding: 0;
    }
}

@media (max-width: 480px) {
    .tile {
        margin: 3px;
        height: 350px;
    }
}

@media (max-width: 360px) {
    .short-text {
        font-size: 1.3rem;
        padding-right: 10px;
    }
}

/* ============================================
   9. NEWS GRID (DIE KÜCHE, WIR, DER UNTERSCHIED)
   ============================================ */

.news-container {
    width: 100%;
    padding: 40px 20px;
    margin-bottom: 40px;
}

.news-grid {
    display: grid;
    gap: 20px;
    max-width: 1320px;
    margin: 0 auto;
}

/* Responsive Grid */
@media (min-width: 1040px) {
    .news-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 900px) and (max-width: 1039px) {
    .news-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 600px) and (max-width: 899px) {
    .news-grid {
        grid-template-columns: repeat(1, 1fr);
    }
}

@media (max-width: 599px) {
    .news-grid {
        grid-template-columns: 1fr;
        max-width: 320px;
    }
}

.news-item {
    position: relative;
    width: 100%;
    aspect-ratio: 320 / 500;
    max-width: 320px;
    margin: 0 auto;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.news-item:hover {
    transform: translateY(-5px);
}

.news-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
    transition: opacity 0.4s ease;
}

.news-background.bg-default {
    opacity: 1;
}

.news-background.bg-hover {
    opacity: 0;
}

.news-item.active .news-background.bg-default {
    opacity: 0;
}

.news-item.active .news-background.bg-hover {
    opacity: 1;
}

.news-content {
    position: relative;
    height: 100%;
    padding: 25px;
    display: flex;
    flex-direction: column;
    z-index: 2;
}

.news-category {
    font-size: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0;
    padding-bottom: 0;
    transition: color 0.3s ease;
}

.news-headline {
    margin: 0;
    padding-bottom: 0;
    transition: color 0.3s ease;
}

.news-headline h3 {
    font-size: 26px;
    font-weight: bold;
    line-height: 1.1;
}

.news-white h3 {
    color: #fff;
}

.news-text {
    margin: 0;
    max-width: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-width 1s ease, opacity 2s ease 0.1s;
    white-space: normal;
}

.news-text p {
    font-size: 22px;
    line-height: 1.4;
}

.news-item.active .news-text {
    max-width: 100%;
    opacity: 1;
}

.news-more {
    position: absolute;
    bottom: 0;
    right: 25px;
    font-size: 16px;
    font-weight: 600;
    opacity: 0;
    transition: opacity 0.3s ease 0.3s;
    pointer-events: none;
    text-decoration: none;
    display: inline-block;
    z-index: 10;
}

.news-item.active .news-more {
    opacity: 1;
    pointer-events: auto;
}

/* Text-Farben basierend auf Hintergrund */
.news-item.dark-bg .news-category,
.news-item.dark-bg .news-category a,
.news-item.dark-bg .news-headline,
.news-item.dark-bg .news-text,
.news-item.dark-bg .news-more,
.news-item.dark-bg .news-headline h3 {
    color: white;
}

.news-item.light-bg .news-category,
.news-item.light-bg .news-headline,
.news-item.light-bg .news-text,
.news-item.light-bg .news-more {
    color: black;
}

/* Touch-Geräte */
@media (max-width: 1024px) {
    .news-item:hover {
        transform: none;
    }
}

/* ============================================
   10. KONTAKT & FOOTER
   ============================================ */

.contact-info {
    text-align: center;
    background: var(--light-gray);
    padding: 3rem 2rem;
    border-radius: 12px;
    margin: 2rem auto;
    max-width: 600px;
}

.contact-info h3 {
    font-size: 2rem;
    color: var(--dark-gray);
    margin-bottom: 1rem;
}

.contact-info p {
    margin: 0.5rem 0;
    font-size: 1.1rem;
}

.contact-info a {
    color: var(--primary-green);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.contact-info a:hover {
    color: var(--dark-green);
}

footer {
    background: var(--dark-gray);
    color: var(--white);
    padding: 3rem 2rem;
    text-align: center;
}

footer a {
    color: var(--primary-green);
    text-decoration: none;
    margin: 0 1rem;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--white);
}

/* ============================================
   11. SCROLL TO TOP BUTTON
   ============================================ */

.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: #c8d200;
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease, background-color 0.3s ease, transform 0.2s ease;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top:hover {
    background-color: #b0bb00;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.scroll-to-top:active {
    transform: translateY(-1px);
}

.scroll-to-top::before {
    content: '↑';
    font-size: 28px;
    line-height: 1;
}

@media (max-width: 768px) {
    .scroll-to-top {
        width: 45px;
        height: 45px;
        bottom: 20px;
        right: 20px;
        font-size: 22px;
    }
    
    .scroll-to-top::before {
        font-size: 24px;
    }
}

/* ============================================
   12. BUTTONS
   ============================================ */

.gutschein-button {
    display: inline-block;
    padding: 12px 30px;
    background-color: #c8d200;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    font-size: 1.1rem;
    transition: background-color 0.3s ease, transform 0.2s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.gutschein-button:hover {
    background-color: #b0bb00;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.gutschein-button:active {
    transform: translateY(0);
}

/* ============================================
   12. UTILITY KLASSEN
   ============================================ */

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

.mt-4 {
    margin-top: 2rem;
}

.mb-4 {
    margin-bottom: 2rem;
}

.fokus {
    color: var(--dark-green);
}

.fokus-container {
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 2rem 1rem;
    background: #c8d300;
}

/* ============================================
   ENDE DER DATEI
   ============================================ */
