/*
Theme Name: GeneratePress Child
Theme URI: https://generatepress.com
Description: Default GeneratePress child theme
Author: Tom Usborne
Author URI: https://tomusborne.com
Template: generatepress
Version: 0.1
*/

/* ===================================================== */
/* 0. CUSTOM FONTS                                       */
/* ===================================================== */
@font-face {
    font-family: 'Tsusilago';
    src: url('/wp-content/themes/generatepress/assets/fonts/tussilagorg-bold-DaBADJEv.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* ===================================================== */
/* 1. VARIABLES & RESET CONFIGURATION                    */
/* ===================================================== */
:root {
    --main-blue: #027D8F;
    --main-blue-green: #09BE9C;
    --main-green: #83D374;
    --main-green-yellow: #C6E12E;
    --main-yellow: #FAF070;
    --secondary-blue: #3A91C1;
    --accent: #1e73be;
    --secondary-violet: #AA8BF7;
    --secondary-orange: #FF5715;
    --secondary-red: #D00D1E;
    --neutral-black: #000000;
    --neutral-white: #FFFFFF;
    --nav-bg-mobile: #e0f5f7;

    --dr-shadow: 0 10px 30px rgba(0,0,0,0.08);
    --dr-transition: all .3s cubic-bezier(.4, 0, .2, 1);
    --dr-arrow-svg: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23027D8F' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");

    --contrast: var(--neutral-black) !important;
}

html, body {
    margin: 0 !important;
    padding: 0 !important;
    width: 100% !important;
    overflow-x: hidden !important;
    background-color: var(--neutral-white) !important;
}

body { 
    padding-top: 75px; 
    margin-bottom: 0 !important;
}

/* Hide native elements */
.site-header, .entry-header, .featured-image, .post-image, 
.wp-post-image, .generate-page-header, .page-header-image-single, 
.cat-links, .site-footer, #footer-widgets, footer.site-info, .site-info { 
    display: none !important; 
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

/* Force full width */
.site, #page, #content, .container, .entry-content, 
.ast-container, .grid-container, .inside-article, .site-main, .error404 #page, .error404 #content {
    width: 100% !important; 
    max-width: 100% !important;
    padding: 0 !important; 
    margin: 0 !important;
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
    box-sizing: border-box !important;
    display: block !important;
}

img { 
    border-radius: 40px !important; 
    object-fit: cover; 
}

/* Prevent margins on the last elements */
#main > *:last-child, .entry-content > *:last-child, 
.lzb-block:last-of-type, .lzb-block, .lazyblock {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}

/* Universal margin for all Grid type groups in WordPress */
.wp-block-group.is-layout-grid {
    max-width: 1280px;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 5% !important;
    padding-right: 5% !important;
}

/* ===================================================== */
/* 2. GLOBAL TYPOGRAPHY (FLUID & SCALABLE)               */
/* ===================================================== */

/* BODY TEXT */
html body, html body p, html body span, html body li, 
html body div:not(.dr-hero-block *) {
    font-family: 'Roboto', sans-serif !important;
    font-size: clamp(16px, 2.15vh, 24px); 
    line-height: 1.6;
    color: var(--neutral-black);
    -webkit-font-smoothing: antialiased;
}

/* MAJOR TITLES (TSUSILAGO) - H1, H2, H3 */
html body h1, html body h2, html body h3,
.entry-content h1, .entry-content h2, .entry-content h3 {
    font-family: 'Tsusilago', serif !important; 
    color: var(--main-blue);
    font-weight: normal !important; 
    line-height: 1.2 !important;
    text-transform: none !important; 
}

/* MINOR TITLES */
html body h4, html body h5, html body h6 {
    font-family: 'Roboto', sans-serif !important;
    color: var(--main-blue) !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
}

/* Scalable title sizes (clamp: min, ideal, max) */
html body h1 { font-size: clamp(30px, 4vw, 54px) !important;}
html body h2 { font-size: clamp(2rem, 2vw, 3.5rem) !important;}
html body h3 { font-size: clamp(20px, 1vw, 34px) !important; font-family: 'Roboto', sans-serif !important;}

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

/* ===================================================== */
/* 3. COMPONENTS: BUTTONS AND BOXES                      */
/* ===================================================== */

/* Unified button style (KAUFEN) */
button, .ws-btn, .btn, .dr-btn, .btn-ws-register, .event-link-text {
    font-family: 'KAUFEN', sans-serif !important;
    font-size: clamp(14px, 1.2vw + 10px, 20px) !important;
    text-transform: uppercase !important;
    font-weight: 700 !important;
    border-radius: 40px !important;
    padding: 15px 35px !important;
    border: none;
    cursor: pointer;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    transition: var(--dr-transition);
    box-shadow: var(--dr-shadow);
}

button:hover, .ws-btn:hover, .dr-btn:hover { 
    transform: translateY(-3px); 
    box-shadow: 0 15px 40px rgba(0,0,0,0.15); 
}

.btn-pdf { background: #90EE90 !important; color: var(--neutral-black) !important; }
.btn-share { background: #8A2BE2 !important; color: white !important; }
.btn-register, .btn-ws-register { background: #FFD580 !important; color: var(--neutral-black) !important; }

/* Yellow Boxes */
.ws-box-details, .ws-reg-box, .ws-box-yellow { 
    background: var(--main-yellow) !important; 
    color: var(--neutral-black) !important; 
    border-radius: 40px !important; 
    padding: 40px; 
    box-shadow: var(--dr-shadow);
}

.ws-box-details h3, .ws-reg-box h3 {
    font-family: 'Tsusilago', serif !important;
    margin-top: 0;
}

/* ===================================================== */
/* 4. NAVBAR & DESKTOP NAVIGATION                        */
/* ===================================================== */

.dr-nav {
    position: fixed !important;
    top: 0 !important; 
    left: 0 !important; 
    width: 100% !important; 
    height: 11vh !important;
    margin: 0 !important;
    background: #e0f5f7 !important;
    backdrop-filter: blur(10px);
    padding: 0 0 0 15px !important; 
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
    z-index: 999999 !important;
    box-sizing: border-box !important;
    min-width: 1200px; 
}

/* Isolate the logo */
.dr-nav a.logo { 
    display: inline-flex !important; 
    align-items: center !important;
    padding: 0 !important;
    width: auto !important;
    background: transparent !important;
    border: none !important;
    margin-left: 3.5vh;
}

.dr-nav a.logo img { 
    max-height: 60px; 
    width: auto; 
    display: block; 
    object-fit: contain; 
}

.dr-menu-root { 
    display: flex; 
    align-items: center; 
    justify-content: flex-end; 
    width: auto; 
    flex: 1; 
    height: 75px;
    list-style: none; 
    margin: 0; 
    padding: 0 20px; 
    gap: 20px; 
    margin-right: 3.5vh;
}

.dr-nav a:not(.logo), .dr-nav .parent-link, .dr-nav .menu-item a, 
.dr-nav .wpml-ls-item a, .dr-nav .language-selector a {
    color: var(--main-blue) !important;
    padding: 10px 18px !important;
    font-size: clamp(14px, 2.2vh, 22px) !important; 
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 1.2px !important;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    text-decoration: none !important;
    background: transparent !important;
    border: none !important;
    white-space: nowrap; 
}

.menu-item-has-children > .parent-link::after {
    content: ""; display: inline-block; width: 12px; height: 12px; margin-left: 8px;
    background-image: var(--dr-arrow-svg); background-size: contain; background-repeat: no-repeat;
    transition: transform 0.3s ease;
}

.menu-item-has-children:hover > .parent-link::after { transform: rotate(180deg); }
.menu-item-has-children { position: relative; }

/* Desktop Submenu (Hover + Animation) */
.menu-item-has-children > .sub-menu {
    display: block !important; 
    visibility: hidden; 
    opacity: 0; 
    position: absolute;
    top: 100%; right: 0; background: #ffffff !important; box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    padding: 15px 0 !important; min-width: 220px; border-radius: 15px; z-index: 999999;
    transform: translateY(15px); 
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    list-style: none !important; margin: 0 !important;
    pointer-events: none;
}

.menu-item-has-children:hover > .sub-menu { 
    visibility: visible; 
    opacity: 1; 
    transform: translateY(0); 
    pointer-events: auto;
}

/* Avatar */
.dr-nav-avatar { 
    width: 35px; height: 35px; border-radius: 50%; object-fit: cover; 
    border: 2px solid var(--main-blue); transition: transform 0.3s ease; 
}
.user-avatar-link:hover .dr-nav-avatar { transform: scale(1.1); }
.dr-user-name-mobile { display: none; }

/* Hamburger Menu */
.menu-toggle {
    display: none; position: relative; 
    width: 42px !important; 
    height: 38px !important;
    flex: 0 0 42px !important; 
    padding: 0 !important; border: 1.5px solid var(--main-blue) !important;
    border-radius: 8px; background: transparent !important; z-index: 1000005;
    cursor: pointer;
    margin-right: 15px;
    box-sizing: border-box !important;
}

.menu-toggle::before, .menu-toggle::after, .menu-toggle span {
    content: ""; position: absolute; left: 10px; right: 10px; height: 2px;
    background: var(--main-blue); border-radius: 10px; transition: 0.3s;
}

.menu-toggle::before { top: 11px; }
.menu-toggle span { top: 50%; transform: translateY(-50%); }
.menu-toggle::after { bottom: 11px; }

/* Desktop Auth Container */
.dr-auth-container {
    margin-left: 0; 
    display: flex;
    height: 11vh; 
    align-items: stretch;
}

.dr-nav a.nav-btn-login, 
.dr-nav a.nav-btn-register {
    font-family: 'KAUFEN', sans-serif !important;
    height: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 30px !important; 
    font-weight: 800 !important;
    text-transform: uppercase;
    transition: all 0.3s ease;
    border-radius: 0 !important; 
    margin: 0 !important;
    border: none !important;
}

.dr-nav a.nav-btn-login { background: rgba(0, 0, 0, 0.04) !important; color: var(--main-blue) !important; }
.dr-nav a.nav-btn-register { background-color: #FFB347 !important; color: #000000 !important; }

/* ===================================================== */
/* 5. CUSTOM FOOTER                                      */
/* ===================================================== */
.dr-footer-new {
    background: #e0f5f7 !important; 
    color: var(--main-blue) !important; 
    padding: 60px 8% 20px !important; 
    width: 100vw !important; 
    position: relative !important;
    left: 50% !important; 
    transform: translateX(-50%) !important;
    margin-left: 0 !important; 
    margin-right: 0 !important;
    margin-top: -1px !important; 
    margin-bottom: 0 !important;
    box-sizing: border-box !important; 
    clear: both !important;
    display: block !important;
}

.footer-main-content { 
    display: flex; 
    gap: 40px; 
    flex-wrap: wrap; 
    padding-bottom: 60px; 
    max-width: 1400px; 
    margin: 0 auto;
    justify-content: space-between;
    align-items: flex-start;
}

/* Remove list dots and margins */
.footer-nav-col ul { 
    list-style: none !important; 
    padding: 0 !important; 
    margin: 0 !important; 
}

.footer-nav-col ul li {
    margin-bottom: 10px;
    list-style-type: none !important;
}

/* Column titles (Fixed categories) */
.footer-nav-col h4 {
    margin-bottom: 20px;
    cursor: default;
}

/* LINKS */
.footer-nav-col h4 a, 
.footer-nav-col ul li a { 
    display: inline-block;
    color: var(--main-blue) !important; 
    text-decoration: none !important;
    transition: all 0.3s ease-out !important;
    cursor: pointer !important;
}

.footer-nav-col h4 a:hover, 
.footer-nav-col ul li a:hover {
    color: #4da6ff !important;
    transform: translateX(6px);
}

.footer-nav-col ul li a { opacity: 0.9; }
.footer-nav-col ul li a:hover { opacity: 1; }

.footer-col-logo { flex: 1; min-width: 200px; }
.footer-col-logo img { max-width: 160px !important; height: auto !important; }

.footer-menu-grid { 
    flex: 3; 
    display: grid; 
    grid-template-columns: repeat(4, 1fr); 
    gap: 20px; 
    text-align: left;
}

.footer-menu-grid .footer-nav-col:nth-child(5) {
    display: none !important;
}

.footer-bottom-container {
    background: var(--main-blue) !important; 
    width: 100vw !important; 
    position: relative; 
    left: 50%; 
    margin-left: -50vw; 
    padding: 30px 8%; 
    display: flex; 
    flex-wrap: wrap; 
    align-items: center; 
    justify-content: space-between;
    box-sizing: border-box !important;
    margin-bottom: 0 !important; 
    float: left;
}

.footer-socials {
    display: flex;
    gap: 15px;
    align-items: center;
    margin-left: 3vh;
}

.footer-socials a { 
    color: white !important; 
    font-size: clamp(24px, 3.5vh, 40px) !important; 
    transition: transform 0.3s ease;
    display: inline-block;
    letter-spacing: 5px;
}

.footer-socials a:hover {
    transform: translateY(-3px);
    color: var(--main-yellow) !important;
}

.footer-legal {
    display: flex;
    gap: 25px;
    margin-right: 3vh;
}

.footer-legal a { 
    color: white !important; 
    font-size: clamp(16px, 1.5vw + 5px, 22px); 
    text-decoration: none;
    font-weight: 500;
}

.footer-legal a:hover { text-decoration: underline; }

.footer-copyright { 
    width: 100%; 
    text-align: center; 
    margin-top: 25px; 
    opacity: 0.8; 
    color: white !important; 
    font-size: clamp(12px, 1vw + 5px, 16px); 
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
}

/* ===================================================== */
/* 6. RESPONSIVE AND UNIFICATION (@media)                */
/* ===================================================== */
@media (max-width: 1024px) {
    /* Responsive Navbar */
    .dr-nav { min-width: 100%; padding: 0 !important; }
    .dr-nav a.logo { margin-left: 15px; }
    .menu-toggle { display: block !important; }

    /* Side menu (Hamburger) */
    .menu, .dr-nav .menu {
        position: fixed !important; 
        top: 0 !important;
        right: -100% !important; 
        width: 80% !important;
        max-width: 350px !important; 
        height: 100vh !important; 
        background: var(--nav-bg-mobile) !important; 
        box-shadow: -10px 0 30px rgba(0,0,0,0.15) !important;
        padding: 90px 25px !important;
        overflow-y: auto !important;
        display: flex !important;
        flex-direction: column;
        opacity: 0;
        visibility: hidden;
        transition: right 0.4s ease, transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s ease;
        z-index: 1000000;
    }

    .menu.active, .dr-nav .menu.active {
        opacity: 1;
        visibility: visible;
        right: 0 !important;
        transform: translateX(0);
    }

    .dr-menu-root {
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-start;
        height: auto;
        padding: 0 !important; 
        margin-right: 0 !important;
        width: 100%;
    }

    /* Mobile Links */
    .dr-nav a, .dr-nav .parent-link { 
        width: 100%; 
        padding: 18px 10px !important; 
        border-bottom: 1px solid rgba(0,0,0,0.08) !important; 
        color: var(--main-blue) !important;
        box-sizing: border-box;
    }
    
    .dr-nav .parent-link { justify-content: space-between; }

    /* Remove Hover on mobile */
    .menu-item-has-children:hover > .sub-menu { display: none !important; }
    .menu-item-has-children:hover > .parent-link::after { transform: none; }

    /* Submenu by Click (Accordion) */
    .menu-item-has-children > .sub-menu, .dr-nav .menu .menu-item-has-children > .sub-menu {
        position: static !important; 
        display: block !important; 
        visibility: hidden;
        opacity: 0;
        max-height: 0; 
        overflow: hidden;
        transform: none !important;
        width: 100% !important;
        padding: 0 !important;
        box-shadow: none !important;
        background: rgba(255, 255, 255, 0.4) !important;
        border-radius: 0 !important;
        transition: max-height 0.4s ease, opacity 0.3s ease, visibility 0.3s;
    }

    .menu-item-has-children:focus-within > .sub-menu,
    .menu-item-has-children > .parent-link[aria-expanded="true"] + .sub-menu {
        display: block !important;
        visibility: visible;
        opacity: 1;
        max-height: 1000px; 
        padding: 10px 0 !important;
    }

    .menu-item-has-children:focus-within > .parent-link::after,
    .menu-item-has-children > .parent-link[aria-expanded="true"]::after {
        transform: rotate(180deg);
    }

    /* Mobile Login Buttons */
    .dr-auth-container {
        position: sticky !important;
        bottom: 0 !important;
        margin-top: auto !important; 
        background: #e0f5f7 !important;
        border-top: 2px solid rgba(0,0,0,0.08) !important;
        flex-direction: column;
        height: auto;
        width: 100%;
        z-index: 100;
    }

    .dr-nav a.nav-btn-login, 
    .dr-nav a.nav-btn-register {
        height: 65px !important;
        width: 100% !important;
        font-size: clamp(16px, 4vw, 20px) !important; 
    }

    /* Mobile Footer */
    .footer-main-content { 
        flex-direction: column; 
        text-align: center; 
        gap: 40px;
    }

    .footer-menu-grid { grid-template-columns: 1fr; }

    .footer-bottom-container { flex-direction: column; }

    .footer-legal { 
        margin: 20px auto 0; 
        justify-content: center; 
        width: 100%; 
    }

    .footer-socials { margin: 0 auto; }
}

/* ===================================================== */
/* 7. LANGUAGE SWITCH (GTranslate / html lang)           */
/* ===================================================== */

/* Default: English visible */
.lang-de { display: none; }

/* When the language is German */
html[lang="de"] .lang-en { display: none !important; }
html[lang="de"] .lang-de { display: block !important; }

/* Fallback in case GTranslate uses body class */
body.de .lang-en { display: none !important; }
body.de .lang-de { display: block !important; }

/* Fix header logo cropping without affecting global images */
.dr-nav > a img {
    object-fit: contain !important;
    width: auto !important;
    max-width: 100% !important;
    border-radius: 0 !important; 
    padding-right: 2px !important;
}

/* =====================================================
   ADDTOANY SHARE BUTTON - DANCE PERFORMANCE
   ===================================================== */
.btn-ws-share {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: auto !important;
    min-width: 260px !important;
    background: #8A2BE2 !important;
    color: #ffffff !important;
    padding: 22px 55px !important;
    border-radius: 40px !important;
    font-family: 'KAUFEN', sans-serif !important;
    font-size: 26px !important;
    font-weight: 800 !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
    float: right !important;
    margin-right: 5% !important;
    margin-left: 0 !important;
}

.btn-ws-share::after {
    content: "";
    display: table;
    clear: both;
}

/* ===== PERFORMANCE PAGE ONLY (Page ID 1523) ===== */
.page-id-1523 .btn-ws-share {
    position: relative !important;
    top: -60px !important;
    float: right !important;
    margin: 0 5% 40px 0 !important;
}

/* ===== TEAM BUILDING ONLY (Page ID 2506) ===== */
.page-id-2506 .btn-ws-share {
    position: relative !important;
    top: -125px !important;
    float: right !important;
    margin: 0 5% 40px 0 !important;
}

/* Performance: always 3 cards on one row */
.page-id-1523 .info-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 30px !important;
}

/* Tablet */
@media (max-width: 1024px) {
    .page-id-1523 .info-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* Phone */
@media (max-width: 768px) {
    .page-id-1523 .info-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }

    .page-id-1523 .info-card {
        padding: 25px 20px !important;
        border-radius: 25px !important;
    }
}

/* ===== Workshops only ===== */
.ws-workshop-wrapper .ws-buttons-stack {
    display: flex !important;
    flex-direction: column !important;
    gap: 20px !important;
}

.ws-workshop-wrapper .ws-buttons-stack .btn-ws-register,
.ws-workshop-wrapper .ws-buttons-stack .btn-ws-share {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    min-width: unset !important;
    padding: 22px !important;
    font-size: clamp(24px, 2.2vw, 36px) !important;
    border-radius: 20px !important;
    margin: 0 !important;
    float: none !important;
    flex: 1 !important;
    box-sizing: border-box !important;
}