/* Mobile First Styles */
:root {
    --nav-height-mobile: 60px;
    --nav-height-desktop: 80px;
    --primary-color: #000;
    --text-color: #FFFFFF;
    --background: linear-gradient(180deg, rgba(142,160,174,1), rgba(76,98,112,1), rgba(0,0,0,1));
    --text-gradient: linear-gradient(135deg, rgba(142,160,174,1), rgba(255,255,255,1));
}

/* Reset und Basis-Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

/* ========================================
   LOADING SCREEN
   ======================================== */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #000000, #1a1a1a, #2d2d2d);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-screen.loaded {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.loading-content {
    text-align: center;
    color: #fff;
}

.loading-logo {
    margin-bottom: 20px;
    animation: pulse 2s ease-in-out infinite;
}

.loading-text {
    font-size: 28px;
    font-weight: 900;
    letter-spacing: 4px;
    margin-bottom: 30px;
    background: linear-gradient(135deg, rgba(142,160,174,1), rgba(255,255,255,1));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: shimmer 2s ease-in-out infinite;
}

.loading-progress {
    width: 200px;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin: 0 auto 15px;
}

.loading-bar {
    height: 100%;
    background: linear-gradient(90deg, #8ea0ae, #fff);
    width: 0%;
    transition: width 0.3s ease;
    box-shadow: 0 0 10px rgba(142, 160, 174, 0.5);
}

.loading-status {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 1px;
}

body.loading {
    overflow: hidden;
    height: 100vh;
}

.linkwhite a{
    color: #FFFFFF;
    text-decoration: none;
    cursor: pointer;
}

.linkwhite a:hover{
    color: #8ea0ae;
    font-weight:900;
}   

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.05);
    }
}

@keyframes shimmer {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

/* ========================================
   INFO SECTIONS (Kontakt & Impressum)
   ======================================== */
.info-section {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(51, 51, 51, 0.98);
    z-index: 9998;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    overflow-y: auto;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.info-section a{
    color: #FFFFFF;
    text-decoration: none;
    cursor: pointer;
}

.info-section a:hover{
    color: #8ea0ae;
    font-weight:900;
}   

.info-section[aria-hidden="false"] {
    visibility: visible;
    opacity: 1;
}

.divider{
    height: 1px;
    border-top: 1px solid #FFFFFF;
    margin-top: 30px;
    margin-bottom: 30px;
    width: 100%;
    max-width: 600px;
}

.info-content {
    background: #333333;
    color: #fff;
    max-width: 800px;
    width: 100%;
    padding: 40px;
    border-radius: 8px;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.contact-content,
.impressum-content {
    background: #333333;
    color: #fff;
    max-width: 800px;
    width: 100%;
    padding: 40px;
    border-radius: 8px;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.info-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 32px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease, opacity 0.2s ease;
    line-height: 1;
}

.info-close:hover {
    transform: scale(1.2);
    opacity: 0.7;
}

.info-content h2 {
    margin-top: 0;
    margin-bottom: 30px;
    font-size: 32px;
    color: #fff;
}

.info-content h3 {
    margin-top: 25px;
    margin-bottom: 15px;
    font-size: 20px;
    color: #8ea0ae;
}

.info-content h4 {
    margin-top: 20px;
    margin-bottom: 10px;
    font-size: 16px;
    color: #8ea0ae;
}

.info-body {
    line-height: 1.4rem;
}
.info-body a {
    color: #FFFFFF;
    text-decoration: none;
    transition: color 0.2s ease;
}

.info-body a:hover {
    color: #8ea0ae;
}

.info-close-btn {
    display: block;
    margin: 20px auto 0;
}

.contact-content,
.impressum-content {
    max-width: 80%;
    max-height: 70vh;
    overflow-y: auto;
    margin: 0 auto;
    padding-right: 10px;
}

/* Desktop: Schmaler Content für bessere Lesbarkeit */
@media (min-width: 768px) {
    .contact-content,
    .impressum-content {
        max-width: 50%;
    }
}

/* Custom Scrollbar für Info-Sections */
.contact-content::-webkit-scrollbar,
.impressum-content::-webkit-scrollbar {
    width: 8px;
}

.contact-content::-webkit-scrollbar-track,
.impressum-content::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.contact-content::-webkit-scrollbar-thumb,
.impressum-content::-webkit-scrollbar-thumb {
    background: rgba(142, 160, 174, 0.6);
    border-radius: 4px;
}

.contact-content::-webkit-scrollbar-thumb:hover,
.impressum-content::-webkit-scrollbar-thumb:hover {
    background: rgba(142, 160, 174, 0.8);
}

body.info-open {
    overflow: hidden;
}

.close{
    cursor: pointer;
    text-decoration: none;
    font-size: 1.6rem;
    font-weight: 900;
    padding: 12px 24px;
    color: #FFFFFF;
    width: 100%;
    margin-top: 30px;
    background: rgba(142, 160, 174, 0.5);
    border-radius: 4px;
    text-align: center;
    border: none;
    transition: background 0.3s ease;
}

.close:hover {
    background: rgba(142, 160, 174, 0.8);
}


/* ========================================
   BASIC TEXT STYLES
   ======================================== */
.hraliasdark{
    width: 90%;
    height: 1px;
    margin-top: 10px;
    margin-bottom: 40px;
    border-bottom: 1px solid #666666;
    margin-left: auto;
    margin-right: auto;
}

/* ========================================
   HERO SECTION
   ======================================== */
.hero-title-left,
.hero-title-right {
    opacity: 0;
    visibility: visible;
    position: relative;
    z-index: 10;
    /* will-change wird dynamisch per JS gesetzt */
}

.hero-title-left {
    transform: translateX(-100vw);
}

.hero-title-right {
    transform: translateX(100vw);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
}

/* Navigation */
.top-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1000;
    height: var(--nav-height-mobile);
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.logo {
    background: url("../img/ihlowlogo2025.svg");
    background-size: contain;
    background-repeat: no-repeat;
    width: 50px;
    height: 50px;
    max-width: 50px;
    max-height: 50px;
}

.logo-image{
    width: 50px;
    height: 50px;
    max-width: 50px;
    max-height: 50px;
}

.logoclaim {
    width: 160px;
    max-width: 160px;
    max-height: 50px;
    font-size: 2.2em;
    font-weight: 900;
    background: var(--text-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    margin-left: 12px;
    justify-self: left;

}

.logoclaim a {
    text-decoration: none;  
}

.logoafter {
    width: 250px;
    max-width: 250px;
    max-height: 50px;
    font-size: 0.8em;
    font-weight: 300;
    color: #000000;
    margin-left: 12px;
    justify-self: left;
}

.nav-links {
    display: none;
    list-style: none;
}

/* Mobile menu open state - shows the nav links when .active is toggled by JS */
.nav-links.active {
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: absolute;
    top: var(--nav-height-mobile);
    left: 0;
    right: 0;
    background: rgba(0,0,0,0.95);
    padding: 12px 20px 18px 20px;
    z-index: 1100; /* above hero content */
}
.nav-links.active a {
    color: #fff;
    padding: 8px 6px;
}

/* Menu toggle active animation */
.menu-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle.active span:nth-child(2) { opacity: 0; }
.menu-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.menu-toggle {
    display: block;
    background: none;
    border: none;
    padding: 10px;
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 25px;
    height: 2px;
    background: #fff;
    margin: 5px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    height: 50vh;
    background: rgba(255,255,255,1);
    position: relative;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height:50vh;
    background: linear-gradient(180deg, rgba(76,98,112,1), rgba(142,160,174,1));
    background-size: cover;
    background-position: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 50vh;
    opacity: 1;
    transition: opacity 0.1s;
}

.hero-content {
    position: relative;
    z-index: 2;
    color: #fff;
    text-align: center;
    padding: 20px;
    line-height: calc(1em + 5.8vw) ; 
    margin-top: var(--nav-height-mobile);
}

.hero-content h1 {
    color: #FFFFFF;
	font-size: calc(1em + 5.5vw) ;  
	font-weight: 900;
    margin-bottom: 0px;
    vertical-align: middle;
    /* opacity: 0.5;*/
}   
/* Content Section */
.content {
    background: linear-gradient(180deg, rgba(142,160,174,1), rgba(76,98,112,1), rgba(0,0,0,1));
    position: relative;
    min-height: 100vh;
    overflow: hidden;
}

.parallax-layer-1 {
    position: absolute;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
}

.parallax-layer-2 {
    position: absolute;
    width: 100%;
    height: 100%;
    background: url("../img/genxguy_solo.webp") no-repeat;
    background-size: contain; /* Bild vollständig sichtbar ohne Beschnitt */
    background-position: right center; /* Rechts zentriert */
    opacity: 0.3; /* Endzustand direkt - keine Animation mehr */
    transition: none;
}

/* Mobile & Tablet: cover statt contain */
@media (max-width: 1024px) {
    .parallax-layer-2 {
        background-size: cover;
    }
}

.content-wrapper {
    position: relative;
    z-index: 10;
    padding: 10% 15%;
    opacity: 1;
    transform: none; /* Endzustand direkt - keine Animation mehr */
    transition: none;
}

.content-wrapper h2 {
    font-size: 2.5em;
    font-weight: 900;
    color: #FFFFFF;
    margin-bottom: 20px;
}

.content-wrapper h3 {
    font-size: 1.8em;
    font-weight: 900;
    color: #FFFFFF;
    margin-bottom: 20px;
}
.content-wrapper p, .content-wrapper ul, .content-wrapper ol {
    font-size: 1.1em;
    color: #FCFCFC;
    margin-bottom: 20px;
    list-style-position: inside;
}

.content-wrapper hr {
    border: none;
    border-top: 1px solid #FFFFFF;
    line-height: 1.4em;
    margin-top: 30px;
    margin-bottom: 30px;    

}

/* Vita Tabellen-Layout: 2-Spalten für Datum/Beschreibung */
.vita {
    background: rgba(0,0,0,1);
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.vita.collapsed {
    min-height: 0;
    max-height: 0;
    opacity: 0;
    visibility: hidden;
    overflow: hidden;
    pointer-events: none;
}

/* Toggle Button für Vita - in Content Section */
.vita-toggle {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    padding: 0.8rem 1.5rem;
    margin-top: 0.1rem;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.3s ease;
    display: block;
    width: 100%;
    max-width: 300px;
    margin-left: auto;
    margin-right: auto;
    font-weight: 500;
}

.vita-toggle:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.6);
    color: rgba(255, 255, 255, 1);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.1);
}

.vita-toggle:focus {
    outline: 2px solid rgba(255, 255, 255, 0.8);
    outline-offset: 2px;
}

.vita-toggle .toggle-icon {
    display: inline-block;
    transition: transform 0.3s ease;
    margin-left: 0.5rem;
}

.vita-toggle.active .toggle-icon {
    transform: rotate(180deg);
}

.vita-wrapper {
    position: relative;
    padding: 10% 15%;
    opacity: 1;
    transition: none;
}

.vita-wrapper h2 {
    font-size: 2.5em;
    font-weight: 900;
    color: #FFFFFF;
    margin-bottom: 20px;
}

.vita-wrapper h3 {
    font-size: 1.8em;
    font-weight: 900;
    color: #FFFFFF;
    margin-bottom: 20px;
}

.vita-content-img {
    max-width: 100%;
    background-position: center;
    min-height: 120px;
    margin-top:-50px;
}

.vita-col-left {
    display: inline-block;
    width: 40%;
    vertical-align: top;
    padding-right: 2%;
    font-weight: 600;
}

.vita-col-right {
    display: inline-block;
    width: 60%;
    vertical-align: top;
}

.odd{
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 12px;
    border-bottom: 1px solid #FFFFFF;
}

.even {
    background: rgba(255, 255, 255, 0.4);
    padding: 8px 12px;
    border-bottom: 1px solid #FFFFFF;
}

.vita-row:hover {
    background: rgba(255, 255, 255, 0.5);
    cursor: default;
}

.row-title {
    font-size: 1.2em;
    line-height:1.8rem;
    font-weight: 900;
    margin-top: 1.8rem;
    margin-bottom: 0.8rem;
    color: #FFFFFF;
}

.download-wrapper {
    display: flexbox;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 20px;
}

.download-item {
    display: flex;
    width: 100%;
    margin: 20px;
    padding-top: 10px;
    padding-bottom: 10px;
    text-align: center;
    cursor: pointer;
    border-bottom: 1px solid #FFFFFF;
}

/* Responsive: Auf kleinen Bildschirmen stapeln */
@media (max-width: 768px) {
    .vita-col-left,
    .vita-col-right {
        display: block;
        width: 100%;
        padding-right: 0;
    }
    
    .vita-col-left {
        margin-bottom: 0.5rem;
    }
}

/* Portfolio Section */
.portfolio {
    padding: 40px 20px;
    background: linear-gradient(180deg, rgba(0,0,0,1), rgba(76,98,112,1), rgba(142,160,174,1), rgba(255,255,255,1));
    z-index: 10;
    content-visibility: auto;
    contain-intrinsic-size: auto 2000px;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
    color: #FFFFFF;
}

.portfolio-item {
    position: relative;
    height: 300px;
    overflow: hidden;
    border-radius: 8px;
    will-change: transform;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.portfolio-bg {
    position: absolute;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.3s ease-out;
    will-change: transform;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.portfolio-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color:#FFFFFF;
}

.portfolio-list li{
    font-size: clamp(1.4rem, 60vw, 2.0rem);
    font-weight: 900;
    padding-left: 20px;
    margin-top: 10px;
    margin-bottom: 10px;
    border: 1px solid #FFFFFF;
    background-color: rgba(142, 160, 174, 0.5);
    margin-left: 10px;
    margin-right: 10px;
    vertical-align: middle;
    list-style: none;
}

h2 .pfdetail{
    font-size: clamp(1.4rem, 60vw, 2.0rem);
    font-weight: 900;
    margin-bottom: 20px;
    color: #FFFFFF;
}

.img-caption{
    font-size: 1.6rem;
    font-weight: 900;
    margin-top: 30px;
    margin-bottom:30px;
}

.bg_design{
    background: url("../img/design_xmp.webp");
    background-size: cover;
    background-position: center;
    width:100%;
    height:500px;
}

.bg_branding{
    background: url("../img/branding_xmp.webp");
    background-size: cover;
    background-position: center;
    width:100%;
    height:500px;
}

.bg_medien{
    background: url("../img/medien_xmp.webp");
    background-size: cover;
    background-position: center;
    width:100%;
    height:500px;
}

.bg_support{
    background: url("../img/support_xmp.webp");
    background-size: cover;
    background-position: center;
    width:100%;
    height:500px;
}

.bg_beratung{
    background: url("../img/beratung_xmp.webp");
    background-size: cover;
    background-position: center;
    width:100%;
    height:500px;
}

.bg_schulung{
    background: url("../img/schulung_xmp.webp");
    background-size: cover;
    background-position: center;
    width:100%;
    height:500px;
}   

.tags {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.tags span {
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    font-size: 0.8em;
}

/* CTA Section */
.blackfont{
    color: #000000;
}

.cta {
    background: rgba(255,255,255,1);
    padding: 40px 20px;
    text-align: center;
    /* Höhe nicht fixieren, damit der Carousel-Inhalt die Sektion nicht überlappt */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 18px;
}

.cta-button-wrapper {
    width: 100%;
}

.cta-button {
    display: inline-block;
    cursor: pointer;
    font-size: 1.6rem;
    font-weight: 900;
    width: 100%;
    padding: 12px 24px;
    background: rgba(142, 160, 174, 0.5);
    color:#FFFFFF;
    text-decoration: none;
    border-radius: 4px;
    margin-top: 20px;
    word-wrap: break-word;
    overflow-wrap: break-word;
    border: 1px solid #FFFFFF;
    white-space: normal;
    text-align: center;
    hyphens: auto;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
    word-break: break-word;
}

.cta-button:hover {
    background: rgba(255, 115, 0, 0.8);
    box-shadow: 0 4px 12px rgba(255, 115, 0, 0.3);
    transform: translateY(-2px);
    border-color: #FFFFFF;
}

/* Footer */
.footer {
    background: var(--primary-color);
    color: #fff;
    padding: 40px 20px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.footer-links {
    margin-bottom: 20px;
}

.footer-links a {
    color: #fff;
    text-decoration: none;
    margin: 0 10px;
}

/* Social Links in footer, centered under the footer-links */
.social-links {
    display: flex;
    gap: 14px;
    justify-content: center;
    align-items: center;
    margin-top: 8px;
    margin-bottom: 8px;
}
.social-link {
    display: inline-flex;
    width: 36px;
    height: 36px;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: rgba(255,255,255,0.06);
    border-radius: 50%;
    text-decoration: none;
    transition: transform 0.15s ease, background 0.15s ease, opacity 0.15s ease;
}
.social-link svg { width: 20px; height: 20px; display: block; }
.social-link:hover, .social-link:focus {
    transform: translateY(-3px);
    background: rgba(255,255,255,0.12);
    outline: none;
}

/* Desktop Styles */
@media (min-width: 768px) {
    .menu-toggle {
        display: none;
    }

    .nav-links {
        display: flex;
        gap: 30px;
    }

    .nav-links a {
        color: #fff;
        text-decoration: none;
        transition: 0.3s;
    }

    .nav-links a:hover {
        opacity: 0.8;
    }

    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .portfolio-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Modal / Lightbox Styles for portfolio details */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    display: none; /* shown via [aria-hidden="false"] or .open class */
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
    overflow-y: auto; /* Scroll-Fokus auf Overlay */
    -webkit-overflow-scrolling: touch; /* iOS smooth scrolling */
    overscroll-behavior: contain;
    /* iOS-spezifische Touch-Optimierungen */
    touch-action: none; /* Verhindere default Touch-Handling auf Overlay selbst */
}
.modal-overlay[aria-hidden="false"] {
    display: flex;
}

.modal-overlay {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(.4,0,.2,1);
}
.modal-overlay[aria-hidden="false"] {
    opacity: 1;
    pointer-events: auto;
}

.modal {
    transform: scale(0.96) translateY(30px);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(.4,0,.2,1), opacity 0.3s cubic-bezier(.4,0,.2,1);
    border: 1px solid #FFFFFF;
    border-radius: 8px;
    scrollbar-color: #555 #222;
    scrollbar-width: thin;
}
.modal-overlay[aria-hidden="false"] .modal {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.modal {
    background: rgba(0,0,0,1);
    max-width: 900px;
    width: 100%;
    border: 1px solid #FFFFFF;
    border-radius: 8px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.4);
    max-height: 90vh;
    overflow-y: auto; /* Explizit nur vertikales Scrolling */
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch; /* iOS smooth scrolling */
    overscroll-behavior: contain; /* Verhindere Scroll-Chaining */
    position: relative;
    padding: 24px;
    color: #FFFFFF;
    /* iOS Touch-Optimierungen */
    touch-action: pan-y; /* Erlaube NUR vertikales Touch-Scrolling */
    /* Verbesserte Scrollbar-Sichtbarkeit */
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.3) rgba(0,0,0,0.2);
}

/* Webkit Scrollbar für bessere Sichtbarkeit auf iOS/Safari */
.modal::-webkit-scrollbar {
    width: 8px;
}

.modal::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.2);
    border-radius: 4px;
}

.modal::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.3);
    border-radius: 4px;
}

.modal::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,0.5);
}

.modal p {
    color: #FFFFFF;
    margin-bottom:1.0rem;
}

.modal a {
    color: #FFFFFF;
    text-decoration: none;
    transition: color 0.2s ease;
}

.modal a:hover {
    color: #8ea0ae;
}

.modal h2, .modal h3 {
    color: #FFFFFF;
    margin-bottom: 2.0rem;
}

.modal ul, .modal ol {
    list-style-position: inside;
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: transparent;
    border: none;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    color: #FFFFFF;
}

.modal-content {
    padding-top: 8px;
}

.modal-body img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 12px 0;
}

/* Simple modal slider styles (only used inside portfolio modals) */
.modal-slider {
    display: flex;
    align-items: center;
    gap: 10px;
}
.modal-slider .slider-nav {
    background: transparent;
    border: none;
    font-size: 28px;
    cursor: pointer;
    padding: 6px 10px;
    color: #FFFFFF;
}
.modal-slider .slider-viewport {
    overflow: hidden;
    flex: 1 1 auto;
    touch-action: pan-y; /* allow vertical scroll, handle horizontal drag */
}
.modal-slider .slider-track {
    display: flex;
    transition: transform 0.35s cubic-bezier(.2,.8,.2,1);
    will-change: transform;
}
.modal-slider .slider-item {
    flex: 0 0 100%; /* each slide takes full modal width */
    width: 100%;
    margin-right: 12px;
}
.modal-slider .slider-viewport:active .slider-track,
.modal-slider .slider-viewport.dragging .slider-track {
    transition: none; /* disable transitions while dragging */
}
.modal-slider .slider-track.dragging {
    transition: none;
}
.modal-slider { cursor: grab; }
.modal-slider:active { cursor: grabbing; }
.modal-slider .slider-item img {
    display: block;
    width: 100%;
    height: auto;
}


@media (max-width: 600px) {
    .modal {
        padding: 16px;
        border-radius: 6px;
    }
    .modal-close {
        font-size: 24px;
    }
}