:root {
    --text-dark: #0F1A2A;
    --line: #E5E5E5;
    --card-bg: #ffffff;
}

/* GLOBAL */
body {
    margin: 0;
    font-family: Arial, sans-serif;
    background: white;
    color: var(--text-dark);
}

/* INTRO TEXT */
.intro-text {
    font-size: 16px;
    font-weight: 600;
    color: #1F3B63;
    text-align: center;
    margin-top: 40px;
    margin-bottom: 10px;
    padding: 0 20px;
}

/* HEADER */
.hero-header {
    position: relative;
    height: 260px;
    background-image: url('https://www.gc-schlei.de/app/assets/header.jpg');
    background-size: cover;
    background-position: center;
}

.hero-header .overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.45);
}

/* LOGO – mittig, größer */
.header-logo {
    position: absolute;
    top: 30px;
    left: 50%;
    transform: translateX(-50%);
    height: 100px;
    z-index: 10;
}

/* HEADER-TEXT – unten, weiß, perfekt sichtbar */
.header-text {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    z-index: 10;
}

.header-text h1 {
    margin: 0;
    font-size: 28px;
    color: white;
    text-shadow: 0 2px 4px rgba(0,0,0,0.4);
}

.header-text p {
    margin: 6px 0 0;
    font-size: 16px;
    color: white;
    text-shadow: 0 2px 4px rgba(0,0,0,0.4);
}

/* TILES */
.tiles {
    padding: 20px;
}

.tile {
    display: block;
    background: var(--card-bg);
    border-radius: 14px;
    padding: 0 24px 24px 24px;
    text-decoration: none;
    color: var(--text-dark);
    box-shadow: 0 4px 14px rgba(0,0,0,0.08);
    margin-bottom: 20px;
    overflow: hidden;
}

.tile-icon {
    font-size: 40px;
    margin: 16px 0 12px 0;
}

.tile h2 {
    width: calc(100% + 48px);
    margin-left: -24px;
    margin-right: -24px;
    background-color: #d8eaff;
    color: #003366;
    padding: 14px 0;
    margin-top: 0;
    margin-bottom: 12px;
    text-align: center;
    font-size: 20px;
    font-weight: 700;
    border-radius: 14px 14px 0 0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    display: block;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.tile-badge {
    display: block;
    text-align: center;
    color: #000;
    font-size: 14px;
    font-weight: 500;
    margin-top: 4px;
}

/* NEWS SECTION */
.news-section {
    padding: 20px;
}

.news-title {
    display: inline-block;
    background-color: #d8eaff;
    color: #003366;
    padding: 10px 16px;
    border-radius: 10px;
    font-size: 20px;
    font-weight: 700;
    margin: 20px 0 20px 14px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

/* Wrapper für horizontales Scrollen */
/* Wrapper: nur horizontal scrollbar für die Kacheln */
.news-slider-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch; /* smooth scrolling iOS */
    padding-bottom: 10px;
    scrollbar-width: none; /* Firefox */
}

.news-slider-wrapper::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

/* Container horizontal anordnen */
.news-container {
    display: flex;
    flex-direction: row;
    gap: 16px;
    flex-wrap: nowrap; /* verhindert Zeilenumbruch */
}

/* Kacheln fixieren */
.news-item {
    flex: 0 0 250px; /* feste Breite */
    background: #ffffff;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.06);
    transition: transform 0.3s ease;
}

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

.news-item h3 {
    display: inline-block;
    background-color: #d8eaff;
    color: #003366;
    padding: 8px 14px;
    border-radius: 10px;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 10px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.news-item p {
    margin: 0 0 12px;
    color: #555;
    font-size: 15px;
}

.news-readmore {
    display: inline-block;
    background: #DCE6F2;
    color: #1F3B63;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* POST PAGE */
.post-wrapper {
    padding: 20px;
    display: flex;
    justify-content: center;
}

.post-tile {
    background: #ffffff;
    border-radius: 18px;
    padding: 0 26px 30px 26px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.10);
    max-width: 900px;
    width: 100%;
    overflow: hidden;
    border: 1px solid rgba(0,0,0,0.05);
}

.post-title {
    background-color: #d8eaff;
    color: #003366;
    padding: 18px 16px;
    margin: 0 0 24px 0;
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    border-radius: 18px 18px 0 0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
}

.post-content {
    font-size: 17px;
    line-height: 1.7;
    color: #333;
}

.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 20px 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* BACK BUTTON */
.back-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: #d8eaff;
    color: #003366;
    padding: 10px 16px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    margin: 20px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.back-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.back-button .arrow {
    font-size: 20px;
    font-weight: bold;
    color: #003366;
}

/* CONTACT */
.contact-tile {
    display: block;
    text-align: left;
}

.contact-info {
    margin-left: 14px;
    margin-top: 10px;
    font-size: 14px;
    color: #000;
}

.contact-info a {
    color: #003366;
    font-weight: 600;
    text-decoration: none;
}

.contact-info a:hover {
    opacity: 0.7;
}

.map-container {
    margin: 15px 0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

img.wp-image {
    cursor: zoom-in;
}

/* LIGHTBOX */
#lightbox-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 999999;
}

#lightbox-overlay img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0,0,0,0.4);
}

#lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 40px;
    color: white;
    cursor: pointer;
    z-index: 1000000;
    font-weight: bold;
}

.post-content a[href$=".jpg"],
.post-content a[href$=".jpeg"],
.post-content a[href$=".png"],
.post-content a[href$=".webp"] {
    cursor: zoom-in;
}

/* HAMBURGER BUTTON */
/* BUTTON */
#menu-button {
    position: fixed;
    top: 20px;
    left: 20px;
    font-size: 32px;
    color: white;
    z-index: 10003;
    cursor: pointer;
}

/* MENÜ */
#side-menu {
    position: fixed;
    top: 0;
    left: -260px;
    width: 240px;
    height: 100%;
    background: #003366;
    padding-top: 80px;
    display: flex;
    flex-direction: column;
    transition: left 0.3s ease;
    z-index: 10002;
    overflow-y: auto;
}

/* LINKS */
#side-menu a {
    color: white;
    text-decoration: none;
    padding: 12px 20px;
    display: block;
}

#side-menu a:hover {
    background: rgba(255,255,255,0.1);
}

/* OVERLAY */
#menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    display: none;
    z-index: 10001;
}

body.menu-open {
    overflow: hidden;
}

/* SUBMENÜ */
.submenu-title {
    padding: 12px 20px;
    color: white;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
}

.submenu-items {
    display: none;
    flex-direction: column;
    background: rgba(255,255,255,0.05);
}

.submenu-items a {
    padding-left: 30px;
}

.submenu-items.active {
    display: flex;
}

.submenu-arrow {
    transition: transform 0.3s ease;
}

.submenu-title.active .submenu-arrow {
    transform: rotate(180deg);
}


@media (max-width: 480px) {
    .header-logo {
        height: 85px;
        top: 25px;
    }
    .header-text h1 {
        font-size: 20px;
    }
    .header-text p {
        font-size: 13px;
    }
    .header-text {
        bottom: 18px;
    }
}

.news-slider {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 16px;
    padding: 10px 0;
}

.news-slide {
    min-width: 85%;
    background: white;
    border-radius: 14px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.1);
    padding: 16px;
    scroll-snap-align: start;
}

#news-popup-text img,
#news-popup-images img,
.popup-content img {
    max-width: 100% !important;
    height: auto !important;
    max-height: 260px !important;
    object-fit: cover !important;
    border-radius: 10px;
    margin: 10px 0;
}
.menu-header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 10px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
    margin-bottom: 10px;
}

/* LOGO = GOLFBALL */
.menu-header img {
    max-width: 70px;
    height: auto;

    position: relative;

    transform: translateX(-250px) translateY(100px) rotate(-720deg) scale(0.3);
    opacity: 0;
}

body.menu-open .menu-header img {
    animation: golfshot 1s ease forwards;
}

@keyframes golfshot {
    0% {
        transform: translateX(-250px) translateY(100px) rotate(-720deg) scale(0.3);
        opacity: 0;
    }

    50% {
        transform: translateX(30px) translateY(-30px) rotate(30deg) scale(1.1);
        opacity: 1;
    }

    75% {
        transform: translateX(-10px) translateY(10px) rotate(-10deg) scale(0.95);
    }

    100% {
        transform: translateX(0) translateY(0) rotate(0) scale(1);
        opacity: 1;
    }
}
