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

:root {
    --primary-color: #1e40af;
    --primary-dark: #1e3a8a;
    --secondary-color: #0f766e;
    --accent-color: #059669;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-light: #ffffff;
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-dark: #0f172a;
    --border-color: rgba(255, 255, 255, 0.15);
    --shadow-light: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-heavy: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --glass-bg: rgba(255, 255, 255, 0.08);
    --glass-border: rgba(255, 255, 255, 0.15);
}

/* Skip-Link für bessere Tastaturnavigation */
.skip-link {
    position: absolute;
    left: -9999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}
.skip-link:focus {
    position: fixed;
    left: 1rem;
    top: 1rem;
    width: auto;
    height: auto;
    background: #111827;
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    z-index: 2000;
}

/* Such-Overlay */
.search-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1500;
}
.search-overlay[style*="display: block"] { display: flex !important; }
.search-container {
    width: min(900px, 92vw);
    background: linear-gradient(135deg, #1f2937, #374151);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 12px;
    box-shadow: var(--shadow-heavy);
    padding: 1rem;
}
.search-container input[type="search"] {
    width: 100%;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.2);
    background: rgba(255,255,255,0.08);
    color: #fff;
}
.close-search {
    position: absolute;
    right: 1.5rem;
    top: 1.5rem;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid #ef4444;
    color: #fff;
    font-size: 1.5rem;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
}
.search-results {
    list-style: none;
    margin: 0.75rem 0 0 0;
    padding: 0;
    max-height: 50vh;
    overflow: auto;
}
.search-results li {
    padding: 0.5rem 0.25rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.search-results a {
    color: #e2e8f0;
    text-decoration: none;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: linear-gradient(135deg, #1e293b 0%, #334155 50%, #475569 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Fallback-Schriften falls externe Fonts abgelehnt werden */
body.no-webfonts {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.logo-text-alt {
    font-family: 'Courier New', monospace;
}

/* Hero Hook ausgelagerter Stil */
.hero-hook {
    font-family: 'JetBrains Mono', monospace;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.01em;
    background: linear-gradient(135deg, #ffffff, #60a5fa);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin: 0.25rem 0 1rem 0;
    text-shadow: 0 2px 12px rgba(96, 165, 250, 0.25);
}
@media (max-width: 768px) {
    .hero-hook { font-size: 1.6rem; }
}

/* E-Mail Fallback Abstände + Zentrierung */
.email-fallback { margin-top: 10px; }
.email-fallback-center { text-align: center; }

/* Admin Badge ausgelagerte Styles */
.admin-badge {
    position: absolute;
    bottom: 20px;
    right: 20px;
    opacity: 0.1;
    transition: opacity 0.3s;
}
.admin-badge:hover { opacity: 1; }
.admin-badge a {
    color: #fff;
    text-decoration: none;
    font-size: 12px;
}


/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    transition: all 0.3s ease;
}

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

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.nav-logo .logo-image {
    height: 60px;
    width: auto;
    border-radius: 8px;
    transition: transform 0.3s ease;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    z-index: 10;
}

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

.nav-logo .logo-text {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-light);
    text-decoration: none;
}

.nav-logo .logo-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.3s ease;
}

.nav-logo .logo-link:hover {
    opacity: 0.8;
}

.nav-menu {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: var(--secondary-color);
}

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

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

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-light);
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 120px;
    overflow: visible;
    z-index: 1;
    /* Höhe der Ellipse steuerbar halten */
    --ellipse-height: 210vh;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
}

.hero-particles {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(120, 219, 255, 0.3) 0%, transparent 50%);
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.hero-text {
    color: var(--text-light);
    position: relative;
    z-index: 1;
}

/* Ellipse entfernt */

/* Inhalte bewusst über der Ellipse halten */
.hero-content {
    position: relative;
    z-index: 1;
}

.hero-visual {
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.title-line {
    display: block;
    opacity: 0;
    transform: translateY(30px);
    animation: slideInUp 0.8s ease forwards;
}

.title-line:nth-child(2) { animation-delay: 0.2s; }
.title-line:nth-child(3) { animation-delay: 0.4s; }

@keyframes slideInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    animation: fadeIn 1s ease 0.6s forwards;
    opacity: 0;
}

@keyframes fadeIn {
    to { opacity: 0.9; }
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    animation: fadeIn 1s ease 0.8s forwards;
    opacity: 0;
}

/* "Keine Zeit? E-mail genügt" – erst nach dem Button einblenden und einfärben */

.hero .email-fallback {
    opacity: 0;
    animation: fadeIn 1s ease 1.2s forwards;
    color: #3f5673;
}

.hero .email-fallback a {
    color: #3f5673;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--text-light);
    box-shadow: var(--shadow-medium);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-heavy);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-light);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
}

/* Outline-Button sichtbar auf dunklem Hintergrund */
.btn-outline {
    background: transparent;
    color: var(--text-light);
    border: 1px solid var(--glass-border);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* Terminal Window */
.terminal-window {
    background: rgba(0, 0, 0, 0.8);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow-heavy);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    animation: slideInRight 1s ease 0.4s forwards;
    opacity: 0;
    transform: translateX(50px);
}

@keyframes slideInRight {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.terminal-header {
    background: rgba(255, 255, 255, 0.1);
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.terminal-buttons {
    display: flex;
    gap: 0.5rem;
}

.btn-red, .btn-yellow, .btn-green {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.btn-red { background: #ff5f56; }
.btn-yellow { background: #ffbd2e; }
.btn-green { background: #27ca3f; }

.terminal-title {
    color: var(--text-light);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9rem;
    opacity: 0.8;
}

.terminal-body {
    padding: 1.5rem;
    font-family: 'JetBrains Mono', monospace;
    color: var(--text-light);
    height: 200px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.terminal-line {
    margin-bottom: 0.5rem;
    display: flex;
    gap: 0.5rem;
    transition: opacity 0.3s ease-out;
}

.prompt {
    color: var(--secondary-color);
    font-weight: 600;
}

.command {
    color: #ffffff;
    font-weight: normal;
}

.output {
    color: #cccccc;
}

.cursor {
    color: var(--secondary-color);
    animation: blink 1s infinite;
    font-weight: bold;
}

.command {
    color: var(--text-light);
}

.output {
    color: var(--accent-color);
    margin-left: 1.5rem;
}

.blink {
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}

.scroll-arrow {
    width: 30px;
    height: 30px;
    border: 2px solid var(--text-light);
    border-top: none;
    border-left: none;
    transform: rotate(45deg);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-10px); }
    60% { transform: translateX(-50%) translateY(-5px); }
}

/* Section Styles */
section {
    padding: 5rem 0;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-light);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.25rem;
    color: var(--text-light);
    opacity: 0.8;
}

/* About Section */
.about {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    position: relative;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-card {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
}

.about-card h3 {
    color: var(--text-light);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.about-card p {
    color: var(--text-light);
    opacity: 0.9;
    margin-bottom: 1rem;
}

.tech-stack h4 {
    color: var(--text-light);
    margin-bottom: 1rem;
}

.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tech-tag {
    background: rgba(99, 102, 241, 0.3);
    color: var(--text-light);
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-size: 0.9rem;
    border: 1px solid rgba(99, 102, 241, 0.5);
}

.image-container {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
}

.profile-image {
    width: 100%;
    height: auto;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    z-index: 10;
    background: transparent;
}

.image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    padding: 2rem 1rem 1rem;
    color: var(--text-light);
    text-align: center;
}

.overlay-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.overlay-content i {
    font-size: 1.5rem;
    color: var(--secondary-color);
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.service-card {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    transition: all 0.3s ease;
    text-align: center;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-heavy);
}

.service-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
}

.service-icon i {
    font-size: 2rem;
    color: var(--text-light);
}

.service-card h3 {
    color: var(--text-light);
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.service-card p {
    color: var(--text-light);
    opacity: 0.9;
    margin-bottom: 1.5rem;
}

.service-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.service-tech span {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-light);
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.8rem;
    border: 1px solid var(--glass-border);
}

/* Portfolio Section */
.portfolio {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
}

/* Testimonials Section */
.testimonials {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.testimonial-card {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
}

.testimonial-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-heavy);
    background: rgba(255, 255, 255, 0.12);
}

.testimonial-content {
    padding: 2rem;
    position: relative;
}

.quote-icon {
    position: absolute;
    top: 1.5rem;
    right: 2rem;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.8;
}

.quote-icon i {
    color: var(--text-light);
    font-size: 1rem;
}

.testimonial-text {
    color: var(--text-light);
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 2rem;
    font-style: italic;
    opacity: 0.95;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author-info h4 {
    color: var(--text-light);
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.author-title {
    color: var(--text-light);
    opacity: 0.8;
    font-size: 0.9rem;
    margin: 0;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.portfolio-item {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.portfolio-item:hover {
    transform: scale(1.05);
}

.portfolio-image {
    position: relative;
    width: 100%;
    height: 250px;
    overflow: hidden;
}

.portfolio-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.portfolio-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--text-light);
    padding: 2rem;
}

.portfolio-placeholder i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.8;
}

.portfolio-placeholder h4 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.portfolio-placeholder p {
    font-size: 0.9rem;
    opacity: 0.9;
    line-height: 1.4;
}

.portfolio-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.portfolio-item:hover .portfolio-img {
    transform: scale(1.05);
}

.portfolio-item:hover .portfolio-image img {
    transform: scale(1.1);
}

/* View Images Button */
.view-images-btn {
    background: var(--secondary-color);
    color: var(--primary-color);
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.view-images-btn:hover {
    background: #64ffda;
    transform: translateY(-2px);
}

/* Einheitliche Modal-Styles mit verbessertem Kontrast */
.modal-base {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    backdrop-filter: blur(15px);
    justify-content: center;
    align-items: center;
}

.modal-container {
    background: linear-gradient(135deg, #1e293b, #334155);
    border-radius: 20px;
    border: 2px solid #475569;
    backdrop-filter: blur(20px);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6);
    max-width: 90vw;
    max-height: 90vh;
    width: 90%;
    overflow: hidden;
    position: relative;
    animation: modalSlideIn 0.3s ease-out;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    background: linear-gradient(135deg, #475569, #64748b);
    border-bottom: 2px solid #64748b;
    backdrop-filter: blur(15px);
}

.modal-header h3 {
    color: #ffffff;
    margin: 0;
    font-size: 1.6rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.modal-header h3 i {
    color: #38bdf8;
    font-size: 1.4rem;
    text-shadow: 0 0 10px rgba(56, 189, 248, 0.5);
}

.close-modal {
    background: rgba(239, 68, 68, 0.1);
    border: 2px solid #ef4444;
    color: #ffffff;
    font-size: 2.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-modal:hover {
    color: #ffffff;
    background: #ef4444;
    transform: scale(1.1);
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.5);
}

.modal-content {
    padding: 30px;
    color: #f1f5f9;
    max-height: calc(90vh - 120px);
    overflow-y: auto;
    background: rgba(15, 23, 42, 0.3);
}

.modal-content p {
    margin-bottom: 20px;
    font-size: 1.1rem;
    line-height: 1.7;
    color: #e2e8f0;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Spezifische Modal-Typen */
.image-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 1000;
    backdrop-filter: blur(15px);
    justify-content: center;
    align-items: center;
}

.image-modal-container {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(51, 65, 85, 0.95));
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(20px);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
    max-width: 90vw;
    max-height: 90vh;
    width: 90%;
    overflow: hidden;
    position: relative;
    animation: modalSlideIn 0.3s ease-out;
}

.image-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    background: rgba(255, 255, 255, 0.08);
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(15px);
}

.image-modal-content {
    padding: 30px;
    color: #e2e8f0;
    max-height: calc(90vh - 120px);
    overflow-y: auto;
}

.game-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 1000;
    backdrop-filter: blur(15px);
    justify-content: center;
    align-items: center;
}

/* Desktop: geöffnete Modals zentrieren wie auf Mobile */
.image-modal[style*="display: block"], .game-modal[style*="display: block"] {
    display: flex !important;
    justify-content: center;
    align-items: center;
    padding: 10px;
    box-sizing: border-box;
}

.game-modal-container {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(51, 65, 85, 0.95));
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(20px);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
    max-width: 600px;
    max-height: 90vh;
    width: 90%;
    overflow: hidden;
    position: relative;
    animation: modalSlideIn 0.3s ease-out;
}

.game-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    background: rgba(255, 255, 255, 0.08);
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(15px);
}

.game-modal-content {
    padding: 30px;
    color: #e2e8f0;
    max-height: calc(90vh - 120px);
    overflow-y: auto;
}

/* Modal Animation */
@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Verbesserte Modal-Inhalte mit hohem Kontrast */
.modal-content h4 {
    color: #38bdf8;
    margin: 20px 0 15px 0;
    font-size: 1.3rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.modal-content h4 i {
    color: #0ea5e9;
    font-size: 1.1rem;
    text-shadow: 0 0 8px rgba(14, 165, 233, 0.6);
}

.modal-content strong {
    color: #fbbf24;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.modal-content a {
    color: #38bdf8;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 600;
    border-bottom: 1px solid transparent;
}

.modal-content a:hover {
    color: #ffffff;
    border-bottom: 1px solid #38bdf8;
    text-shadow: 0 0 8px rgba(56, 189, 248, 0.6);
}

/* Modal Scrollbar Styling mit hohem Kontrast */
.modal-content::-webkit-scrollbar {
    width: 10px;
}

.modal-content::-webkit-scrollbar-track {
    background: rgba(15, 23, 42, 0.8);
    border-radius: 5px;
    border: 1px solid #475569;
}

.modal-content::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #38bdf8, #0ea5e9);
    border-radius: 5px;
    border: 1px solid #0ea5e9;
    box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.3);
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.5);
}

.deepdream-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 30px;
}

.deepdream-image-container {
    text-align: center;
}

.deepdream-large {
    width: 100%;
    max-width: 500px;
    height: auto;
    border-radius: 15px;
    border: 2px solid var(--secondary-color);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
}

.deepdream-large:hover {
    transform: scale(1.02);
}

/* Production Modal Styles */
.production-section {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.production-section h4 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.production-section p {
    color: var(--text-light);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.8rem;
    margin-top: 1rem;
}

.process-step {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 0.8rem 1rem;
    border-radius: 12px;
    text-align: center;
    font-weight: 500;
    font-size: 0.9rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.process-step:hover {
    transform: translateY(-2px);
}

.view-details-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.view-details-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.deepdream-image-container p {
    margin-top: 15px;
    font-size: 0.9rem;
    opacity: 0.8;
    color: var(--secondary-color);
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tech-used {
    margin-top: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.tech-used span {
    background: var(--primary-color);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.overlay-content {
    text-align: center;
    color: #ffffff;
    padding: 2rem;
}

.overlay-content h4 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

.overlay-content p {
    color: #e2e8f0;
    margin-bottom: 1.5rem;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
}

.overlay-content .btn {
    background: linear-gradient(135deg, #38bdf8, #0ea5e9);
    color: #ffffff;
    border: 2px solid #0ea5e9;
    padding: 12px 24px;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    box-shadow: 0 4px 15px rgba(56, 189, 248, 0.3);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.overlay-content .btn:hover {
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
    border-color: #0284c7;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(56, 189, 248, 0.5);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.overlay-content .btn:active {
    transform: translateY(0);
    box-shadow: 0 4px 15px rgba(56, 189, 248, 0.4);
}

/* Contact Section */
.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-info {
    display: grid;
    gap: 1.5rem;
}

.contact-card {
    background: rgba(255, 255, 255, 0.1);
    padding: 1.5rem;
    border-radius: 15px;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    text-align: center;
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.contact-icon i {
    font-size: 1.5rem;
    color: var(--text-light);
}

.contact-card h4 {
    color: var(--text-light);
    margin-bottom: 0.5rem;
}

.contact-card p {
    color: var(--text-light);
    opacity: 0.9;
}

/* Contact Form */
.contact-form {
    flex: 1;
    max-width: 600px;
}

/* Legal Content (für Datenschutz) */
.legal-content {
    padding: 4rem 0;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    min-height: 80vh;
}

.legal-card {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    padding: 3rem;
    max-width: 900px;
    margin: 0 auto;
    box-shadow: var(--shadow-medium);
}

.legal-card h1 {
    color: var(--primary-color);
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-align: center;
}

.legal-card h2 {
    color: var(--secondary-color);
    font-size: 1.5rem;
    margin: 2rem 0 1rem 0;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 0.5rem;
}

.legal-card p {
    color: var(--text-light);
    line-height: 1.7;
    margin-bottom: 1rem;
}

.legal-card a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.legal-card a:hover {
    color: var(--secondary-color);
}

.legal-card ul {
    color: var(--text-light);
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.legal-card li {
    margin-bottom: 0.5rem;
}

.legal-card hr {
    border: none;
    height: 1px;
    background: rgba(255, 255, 255, 0.2);
    margin: 2rem 0;
}

.back-to-home {
    text-align: center;
    margin-top: 2rem;
}

/* Contact Actions */
.contact-actions {
    margin-bottom: 2rem;
}

.action-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    margin-bottom: 1.5rem;
}

.action-card h4 {
    color: #60a5fa;
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.action-card h4 i {
    color: #1e40af;
}

.action-card p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.action-buttons .btn {
    padding: 0.8rem 1.5rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border-radius: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.action-buttons .btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.action-buttons .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.contact-divider {
    text-align: center;
    margin: 2rem 0;
    position: relative;
}

.contact-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.contact-divider span {
    background: var(--dark-bg);
    padding: 0 1rem;
    color: var(--text-light);
    font-size: 0.9rem;
}

.form {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form input,
.form textarea {
    width: 100%;
    padding: 1rem;
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-light);
    font-family: inherit;
    transition: all 0.3s ease;
}

.form input::placeholder,
.form textarea::placeholder {
    color: var(--text-light);
    opacity: 0.7;
}

.form input:focus,
.form textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

/* Footer */
.footer {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--glass-border);
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2rem;
    padding: 3rem 0;
}

.footer-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.footer-logo .footer-logo-image {
    height: 70px;
    width: auto;
    border-radius: 10px;
    transition: transform 0.3s ease;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    z-index: 10;
}

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

.footer-logo .logo-text {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-light);
}

.footer-logo p {
    color: var(--text-light);
    opacity: 0.8;
    margin-top: 0.5rem;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-links a {
    color: var(--text-light);
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.footer-links a:hover {
    opacity: 1;
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.social-link {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid var(--glass-border);
}

.social-link:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
}

.footer-bottom {
    text-align: center;
    padding: 1.5rem 0;
    border-top: 1px solid var(--glass-border);
    color: var(--text-light);
    opacity: 0.7;
}

/* 4-Gewinnt Spiel Styling */

.game-container {
    background: linear-gradient(135deg, #1e293b, #334155);
    border-radius: 20px;
    padding: 2rem;
    max-width: 600px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.game-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    color: white;
}

.close-game {
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.close-game:hover {
    opacity: 1;
}

.game-disclaimer {
    background: rgba(255, 193, 7, 0.1);
    border: 1px solid rgba(255, 193, 7, 0.3);
    border-radius: 8px;
    padding: 0.75rem;
    margin-bottom: 1rem;
    text-align: center;
}

.game-disclaimer p {
    margin: 0;
    color: #f59e0b;
    font-size: 0.9rem;
}

.game-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    color: white;
}

.current-player {
    font-weight: 600;
}

.restart-btn {
    background: linear-gradient(135deg, #0f766e, #059669);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.restart-btn:hover {
    transform: translateY(-2px);
}

.game-board {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: min(8px, 1.5vw);
    background: #1e40af;
    padding: min(20px, 4vw);
    border-radius: 15px;
    margin-bottom: 1rem;
    max-width: 100%;
    box-sizing: border-box;
}

.cell {
    /* Dynamische Größe basierend auf Viewport-Breite */
    width: min(48px, calc(8vw - 8px));
    height: min(48px, calc(8vw - 8px));
    background: #1e293b;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid #334155;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Desktop-schmale Viewports: zusätzlich verkleinern wie auf Mobile */
@media (max-width: 1200px) {
    .game-board {
        gap: min(6px, 1vw);
        padding: min(16px, 3vw);
    }
    .cell {
        width: min(40px, calc(9vw - 6px));
        height: min(40px, calc(9vw - 6px));
    }
}

.game-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.ai-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #e2e8f0;
}

.ai-toggle input[type="checkbox"] {
    width: 18px;
    height: 18px;
}

.cell:hover {
    border-color: #0f766e;
    transform: scale(1.05);
}

.cell.red {
    background: linear-gradient(135deg, #dc2626, #991b1b);
    box-shadow: inset 0 4px 8px rgba(0, 0, 0, 0.3);
}

.cell.yellow {
    background: linear-gradient(135deg, #eab308, #a16207);
    box-shadow: inset 0 4px 8px rgba(0, 0, 0, 0.3);
}

.cell.winning {
    animation: winPulse 1s infinite;
}

@keyframes winPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.game-status {
    text-align: center;
    color: white;
    font-weight: 500;
}

.game-btn {
    background: linear-gradient(135deg, #1e40af, #1d4ed8);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    margin-top: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.game-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(30, 64, 175, 0.3);
}

/* Form Messages */
.form-message {
    margin-top: 1rem;
    padding: 1rem;
    border-radius: 8px;
    font-weight: 500;
    text-align: center;
}

.form-message-success {
    background: rgba(5, 150, 105, 0.1);
    color: #059669;
    border: 1px solid rgba(5, 150, 105, 0.3);
}

.form-message-error {
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
    border: 1px solid rgba(220, 38, 38, 0.3);
}

.form-message-info {
    background: rgba(30, 64, 175, 0.1);
    color: #1e40af;
    border: 1px solid rgba(30, 64, 175, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero {
        --ellipse-height: 210vh;
    }
    .nav-container {
        position: relative;
    }
    .nav-logo .logo-image {
        height: 32px;
    }
    
    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(15, 23, 42, 0.98);
        backdrop-filter: blur(10px);
        border-bottom: 1px solid var(--glass-border);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
        flex-direction: column;
        gap: 0;
        padding: 0.5rem 0;
        animation: fadeIn 0.2s ease-in-out;
    }
    
    .nav-menu.active {
        display: flex;
    }
    
    .nav-link {
        display: block;
        padding: 0.9rem 1.5rem;
    }
    
    .nav-link + .nav-link {
        border-top: 1px solid rgba(255, 255, 255, 0.06);
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .nav-toggle.active span:nth-child(1) {
        transform: translateY(6px) rotate(45deg);
    }
    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
        transform: scaleX(0);
    }
    .nav-toggle.active span:nth-child(3) {
        transform: translateY(-6px) rotate(-45deg);
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .testimonials-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }
    
    /* Ellipse entfernt */
}

@media (max-width: 480px) {
    .hero {
        --ellipse-height: 210vh;
    }
    .container {
        padding: 0 1rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .terminal-window {
        font-size: 0.8rem;
    }
    
    .terminal-body {
        padding: 1rem;
    }
    
    /* Ellipse entfernt */
}

/* Smooth scrolling and animations */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

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

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

/* Impressum Page Styles */
.impressum-hero {
    min-height: 60vh;
    padding-top: 120px;
}

.impressum-hero .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
}

.impressum-hero .hero-title {
    font-size: 3rem;
}

.impressum-content {
    padding: 4rem 0;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
}

.impressum-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.impressum-card {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    overflow: hidden;
    transition: all 0.3s ease;
}

.impressum-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
    background: rgba(255, 255, 255, 0.12);
}

.impressum-card.full-width {
    grid-column: 1 / -1;
}

.impressum-card .card-header {
    background: rgba(255, 255, 255, 0.1);
    padding: 1.5rem;
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.impressum-card .card-header i {
    font-size: 1.5rem;
    color: var(--secondary-color);
    width: 24px;
    text-align: center;
}

.impressum-card .card-header h2 {
    color: var(--text-light);
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.impressum-card .card-content {
    padding: 1.5rem;
}

.impressum-card .card-content h3 {
    color: var(--text-light);
    font-size: 1.1rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.impressum-card .card-content p {
    color: var(--text-light);
    opacity: 0.9;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.impressum-card .card-content p:last-child {
    margin-bottom: 0;
}

.impressum-card .card-content strong {
    color: var(--text-light);
    font-weight: 600;
}

.impressum-card .card-content a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.impressum-card .card-content a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

.impressum-card .card-content ul {
    color: var(--text-light);
    opacity: 0.9;
    margin: 1rem 0;
    padding-left: 1.5rem;
}

.impressum-card .card-content li {
    margin-bottom: 0.5rem;
}

.impressum-card .card-content em {
    opacity: 0.7;
    font-style: italic;
}

/* Responsive Design for Impressum */
@media (max-width: 768px) {
    .impressum-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .impressum-hero .hero-title {
        font-size: 2.5rem;
    }
    
    .impressum-card .card-header {
        padding: 1rem;
    }
    
    .impressum-card .card-content {
        padding: 1rem;
    }
}

@media (max-width: 480px) {
    .impressum-hero .hero-title {
        font-size: 2rem;
    }
    
    .impressum-content {
        padding: 2rem 0;
    }
}

/* Spamschutz-Styles */
.spam-info {
    margin-bottom: 1rem;
    text-align: center;
    color: #6c757d;
    font-size: 0.875rem;
}

.spam-info small {
    opacity: 0.8;
}

.honeypot-field {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* Cookie Banner */
.cookie-banner, .privacy-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(15px);
    z-index: 2147483647; /* über allem */
    padding: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.cookie-content {
    width: 90%;
    max-width: 900px;
    max-height: 90vh;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(51, 65, 85, 0.95));
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
}

.cookie-text h4 {
    color: var(--text-light);
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.cookie-text p {
    color: var(--text-light);
    opacity: 0.8;
    margin-bottom: 1rem;
    line-height: 1.6;
    font-size: 0.9rem;
}

/* Scrollbarer Textbereich, falls Inhalte lang sind */
.cookie-text {
    max-height: 55vh;
    overflow-y: auto;
    padding-right: 6px;
}

.cookie-text ul {
    color: var(--text-light);
    opacity: 0.8;
    margin: 1rem 0 1rem 1.5rem;
    padding-left: 0;
}

.cookie-text li {
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

.cookie-text a {
    color: var(--secondary-color);
    text-decoration: none;
}

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

.cookie-options {
    display: grid;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.cookie-option {
    display: flex;
    align-items: center;
}

.cookie-checkbox {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    color: var(--text-light);
}

.cookie-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--secondary-color);
}

.cookie-label {
    display: flex;
    flex-direction: column;
}

.cookie-label strong {
    font-weight: 600;
}

.cookie-label small {
    opacity: 0.7;
    font-size: 0.875rem;
}

.cookie-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 0.5rem;
    margin-bottom: 1rem;
    justify-content: center;
}

.cookie-links {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
}

.cookie-links a {
    color: var(--secondary-color);
    text-decoration: none;
    font-size: 0.875rem;
    transition: color 0.3s ease;
}

.cookie-links a:hover {
    color: var(--accent-color);
}

/* Responsive Cookie Banner */
@media (max-width: 768px) {
    .cookie-banner, .privacy-banner {
        padding: 10px;
    }
    
    .cookie-buttons {
        flex-direction: column;
    }
    
    .cookie-links {
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
    }

    .cookie-content {
        width: 95%;
        max-height: 95vh;
        padding: 1rem;
    }

    .cookie-text {
        max-height: 60vh;
    }
}

/* Cookie-Warnung für Kontaktformular */
.cookie-warning {
    background: rgba(255, 193, 7, 0.1);
    border: 1px solid rgba(255, 193, 7, 0.3);
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 1.5rem;
}

/* Privacy Banner (Fallback für Brave Shields) */
.privacy-banner {
    z-index: 2147483647;
}

.privacy-banner .pb-content {
    max-width: 1200px;
    margin: 0 auto;
}

.privacy-banner .pb-text h4 {
    color: var(--text-light);
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.privacy-banner .pb-text p {
    color: var(--text-light);
    opacity: 0.8;
    margin-bottom: 1rem;
    line-height: 1.6;
    font-size: 0.9rem;
}

.privacy-banner .pb-options {
    display: grid;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.privacy-banner .pb-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-light);
}

.privacy-banner .pb-row input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--secondary-color);
}

.privacy-banner .pb-controls {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.privacy-banner .btn {
    color: var(--text-light);
}

/* Sicherstellen, dass Outline-Button Text sichtbar ist */
.privacy-banner .btn.btn-outline {
    color: #ffffff !important;
    border-color: rgba(255,255,255,0.5) !important;
}

/* Shadow-DOM Panel (eingebettete Styles berücksichtigen wir bereits im JS, hier nur globale Fallbacks) */
#dp-root { all: initial; }

.privacy-banner .pb-links a {
    color: var(--secondary-color);
    text-decoration: none;
    font-size: 0.875rem;
    transition: color 0.3s ease;
}

.privacy-banner .pb-links a:hover {
    color: var(--accent-color);
}

.warning-content {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.warning-content i {
    color: #ffc107;
    font-size: 1.5rem;
    margin-top: 0.25rem;
}

.warning-text strong {
    color: #ffc107;
    display: block;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.warning-text p {
    color: var(--text-light);
    margin: 0;
    line-height: 1.5;
}

.warning-text a {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 500;
}

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

/* DSGVO-Einwilligung Checkbox */
.consent-group {
    margin-bottom: 1.5rem;
}

.consent-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
    color: var(--text-light);
}

.consent-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--secondary-color);
    margin-top: 0.25rem;
}

.consent-text {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.consent-text strong {
    font-weight: 600;
    color: var(--text-light);
}

.consent-text small {
    opacity: 0.8;
    line-height: 1.5;
    font-size: 0.875rem;
}

.consent-text a {
    color: var(--secondary-color);
    text-decoration: none;
}

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

/* Syntana.ai Modal Styles */
.syntana-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
    padding: 20px;
    background: rgba(0, 212, 255, 0.1);
    border-radius: 15px;
    border: 1px solid rgba(0, 212, 255, 0.3);
}

.syntana-logo {
    width: 80px;
    height: 80px;
    object-fit: contain;
    border-radius: 10px;
}

.syntana-header p {
    margin: 0;
    flex: 1;
}

.syntana-section {
    margin-bottom: 30px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    border-left: 4px solid #00d4ff;
}

.syntana-section h4 {
    color: #00d4ff;
    margin-bottom: 15px;
    font-size: 1.2em;
}

.tech-grid, .application-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    margin-top: 15px;
}

.tech-item, .app-item {
    background: linear-gradient(135deg, #475569, #64748b);
    color: #ffffff;
    padding: 8px 12px;
    border-radius: 20px;
    text-align: center;
    font-size: 0.9em;
    font-weight: 600;
    border: 2px solid #64748b;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.tech-item:hover, .app-item:hover {
    background: linear-gradient(135deg, #64748b, #94a3b8);
    border-color: #94a3b8;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

/* Feature-Listen mit hohem Kontrast */
.feature-list {
    list-style: none;
    padding: 0;
    margin: 15px 0;
}

.feature-list li {
    margin-bottom: 10px;
    padding: 12px 15px;
    background: rgba(15, 23, 42, 0.6);
    border-radius: 8px;
    border-left: 4px solid #38bdf8;
    color: #e2e8f0;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
}

.feature-list li:hover {
    background: rgba(15, 23, 42, 0.8);
    border-left-color: #0ea5e9;
    transform: translateX(5px);
}

.status-info {
    background: rgba(255, 193, 7, 0.1);
    border: 1px solid rgba(255, 193, 7, 0.3);
    border-radius: 8px;
    padding: 15px;
    margin-top: 20px;
}

.status-info p {
    margin: 5px 0;
    color: #ffc107;
}

/* Web-Lösungen Modal Styles */
.web-section {
    margin-bottom: 30px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    border-left: 4px solid #17a2b8;
}

         .web-section h4 {
             color: #17a2b8;
             margin-bottom: 15px;
             font-size: 1.2em;
         }
         
         /* Wellness-Interface Modal Styles */
         .wellness-header {
             display: flex;
             align-items: center;
             gap: 20px;
             margin-bottom: 30px;
             padding: 20px;
             background: rgba(255, 105, 180, 0.1);
             border-radius: 15px;
             border: 1px solid rgba(255, 105, 180, 0.3);
         }
         
         .wellness-icon {
             font-size: 3em;
             color: #ff69b4;
         }
         
         .wellness-header p {
             margin: 0;
             flex: 1;
         }
         
         .wellness-section {
             margin-bottom: 30px;
             padding: 20px;
             background: rgba(255, 255, 255, 0.05);
             border-radius: 10px;
             border-left: 4px solid #ff69b4;
         }
         
         .wellness-section h4 {
             color: #ff69b4;
             margin-bottom: 15px;
             font-size: 1.2em;
         }
         
         /* MCP Server Modal Styles */
         .mcp-header {
             display: flex;
             align-items: center;
             gap: 20px;
             margin-bottom: 30px;
             padding: 20px;
             background: rgba(138, 43, 226, 0.1);
             border-radius: 15px;
             border: 1px solid rgba(138, 43, 226, 0.3);
         }
         
         .mcp-icon {
             font-size: 3em;
             color: #8a2be2;
         }
         
         .mcp-header p {
             margin: 0;
             flex: 1;
         }
         
         .mcp-section {
             margin-bottom: 30px;
             padding: 20px;
             background: rgba(255, 255, 255, 0.05);
             border-radius: 10px;
             border-left: 4px solid #8a2be2;
         }
         
         .mcp-section h4 {
             color: #8a2be2;
             margin-bottom: 15px;
             font-size: 1.2em;
         }
         
         /* RAG System Modal Styles */
         .rag-header {
             display: flex;
             align-items: center;
             gap: 20px;
             margin-bottom: 30px;
             padding: 20px;
             background: rgba(255, 165, 0, 0.1);
             border-radius: 15px;
             border: 1px solid rgba(255, 165, 0, 0.3);
         }
         
         .rag-icon {
             font-size: 3em;
             color: #ffa500;
         }
         
         .rag-header p {
             margin: 0;
             flex: 1;
         }
         
         .rag-section {
             margin-bottom: 30px;
             padding: 20px;
             background: rgba(255, 255, 255, 0.05);
             border-radius: 10px;
             border-left: 4px solid #ffa500;
         }
         
         .rag-section h4 {
             color: #ffa500;
             margin-bottom: 15px;
             font-size: 1.2em;
         }
         
         /* Prozess-Flow Styles */
         .process-flow {
             display: flex;
             flex-direction: column;
             gap: 10px;
             margin-top: 20px;
             padding: 15px;
             background: rgba(255, 255, 255, 0.05);
             border-radius: 10px;
             border: 1px solid rgba(255, 255, 255, 0.1);
         }
         
         .flow-step {
             display: flex;
             align-items: center;
             gap: 10px;
             padding: 8px 12px;
             background: rgba(0, 123, 255, 0.1);
             border-radius: 8px;
             border-left: 3px solid #007bff;
             font-size: 0.9em;
             color: #007bff;
         }

/* Projekt-Start Meeting Modal Styles */
.meeting-intro {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, rgba(30, 64, 175, 0.1), rgba(59, 130, 246, 0.1));
    border-radius: 15px;
    border: 1px solid rgba(30, 64, 175, 0.3);
    box-shadow: 0 4px 15px rgba(30, 64, 175, 0.1);
}

.meeting-intro p {
    margin: 10px 0;
    color: #38bdf8;
    font-weight: 500;
}

.meeting-form {
    max-width: 100%;
}

/* Multi-Step Form Styles */
.form-step {
    display: none;
    animation: fadeIn 0.3s ease-in-out;
}

.form-step:first-child {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.step-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid rgba(30, 64, 175, 0.2);
}

.step-header h4 {
    margin: 0;
    color: #38bdf8;
    font-size: 1.3em;
    font-weight: 600;
}

.step-indicator {
    background: linear-gradient(135deg, #38bdf8, #0ea5e9);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(30, 64, 175, 0.3);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #e2e8f0;
    font-weight: 500;
    font-size: 0.95em;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: #ffffff;
    font-size: 0.95em;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #38bdf8;
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.form-group select option {
    background: #1e293b;
    color: #ffffff;
}

.step-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.step-actions .btn {
    min-width: 120px;
    padding: 12px 24px;
    font-size: 1em;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.step-actions .btn-primary {
    background: linear-gradient(135deg, #38bdf8, #0ea5e9);
    border: none;
    color: white;
    box-shadow: 0 4px 15px rgba(30, 64, 175, 0.3);
}

.step-actions .btn-primary:hover {
    background: linear-gradient(135deg, #1e3a8a, #2563eb);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(30, 64, 175, 0.4);
}

.step-actions .btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #e2e8f0;
}

.step-actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
}

/* Fortschrittsbalken */
.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    margin: 20px 0;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #38bdf8, #0ea5e9, #0284c7);
    border-radius: 4px;
    transition: width 0.5s ease;
    width: 14.28%; /* Startet bei Schritt 1 (1/7) */
    box-shadow: 0 0 10px rgba(30, 64, 175, 0.5);
}

/* Checkbox-Labels für intelligente Rechnungsstellungsadresse */
.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    font-weight: normal;
    padding: 12px;
    background: rgba(30, 64, 175, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(30, 64, 175, 0.2);
    transition: all 0.3s ease;
}

.checkbox-label:hover {
    background: rgba(30, 64, 175, 0.1);
    border-color: rgba(30, 64, 175, 0.4);
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: #38bdf8;
}

.checkbox-label span {
    flex: 1;
    color: #e2e8f0;
    font-size: 0.95em;
}

/* Responsive Anpassungen */
@media (max-width: 768px) {
    .step-actions {
        flex-direction: column;
        gap: 15px;
    }
    
    .step-actions .btn {
        width: 100%;
        max-width: 300px;
    }
    
    .step-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .meeting-intro {
        padding: 15px;
    }
    
    /* Alle Modals mobile Zentrierung für Tablets - nur wenn sie geöffnet sind */
    .image-modal[style*="display: block"], .game-modal[style*="display: block"] {
        display: flex !important;
        justify-content: center;
        align-items: center;
        padding: 10px;
        box-sizing: border-box;
    }
    
    .image-modal-container {
        margin: 0;
        max-width: 95vw;
        max-height: 95vh;
        width: 95%;
    }
}

/* Cookie Info Message für EmailJS-Fallback */
.cookie-info-message {
    position: fixed;
    top: 20px;
    right: 20px;
    max-width: 400px;
    background: linear-gradient(135deg, #1e40af, #3b82f6);
    color: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(30, 64, 175, 0.3);
    z-index: 10000;
    animation: slideInRight 0.5s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.cookie-info-content h4 {
    margin: 0 0 15px 0;
    font-size: 1.1em;
    color: #e0f2fe;
}

.cookie-info-content p {
    margin: 0 0 10px 0;
    font-size: 0.9em;
    line-height: 1.5;
    opacity: 0.95;
}

.cookie-info-content strong {
    color: #e0f2fe;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Neue About-Section Styles */
.about-intro {
    background: linear-gradient(135deg, rgba(30, 64, 175, 0.1), rgba(59, 130, 246, 0.1));
    padding: 20px;
    border-radius: 12px;
    border-left: 4px solid #1e40af;
    margin-bottom: 25px;
}

.about-intro p {
    margin: 0;
    font-size: 1.1em;
    line-height: 1.6;
    color: #e2e8f0;
}

.expertise-section {
    margin-bottom: 25px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.expertise-section:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(30, 64, 175, 0.3);
    transform: translateY(-2px);
}

.expertise-section h4 {
    color: #60a5fa;
    margin: 0 0 15px 0;
    font-size: 1.2em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.expertise-section h4 i {
    color: #1e40af;
}

.expertise-section p {
    margin: 0 0 15px 0;
    line-height: 1.6;
    color: #cbd5e1;
}

.expertise-section p:last-child {
    margin-bottom: 0;
}

.tech-stack h4 {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #60a5fa;
    margin-bottom: 20px;
}

.tech-stack h4 i {
    color: #1e40af;
}

.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.tech-tag {
    background: linear-gradient(135deg, #1e40af, #3b82f6);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.tech-tag:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(30, 64, 175, 0.4);
}

.tech-tag i {
    font-size: 0.8em;
}

.about-cta {
    background: linear-gradient(135deg, rgba(30, 64, 175, 0.15), rgba(59, 130, 246, 0.15));
    padding: 25px;
    border-radius: 12px;
    border: 1px solid rgba(30, 64, 175, 0.3);
    margin-top: 30px;
    text-align: center;
}

.about-cta p {
    margin: 0 0 20px 0;
    font-size: 1.1em;
    line-height: 1.6;
    color: #e2e8f0;
}

.cta-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.cta-buttons .btn {
    min-width: 180px;
}

/* Responsive Anpassungen für About */
@media (max-width: 768px) {
    .expertise-section {
        padding: 15px;
        margin-bottom: 20px;
    }
    
    .about-intro {
        padding: 15px;
        margin-bottom: 20px;
    }
    
    .about-cta {
        padding: 20px;
        margin-top: 25px;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .cta-buttons .btn {
        width: 100%;
        max-width: 300px;
    }
    
    .tech-tags {
        gap: 10px;
    }
    
    .tech-tag {
        font-size: 0.8rem;
        padding: 4px 8px;
    }
    
    /* Game-Modal Mobile-Optimierung */
    .game-modal[style*="display: block"] {
        display: flex !important;
        justify-content: center;
        align-items: center;
        padding: 10px;
        box-sizing: border-box;
    }
    
    .game-modal-container {
        width: 95%;
        max-width: none;
        max-height: 95vh;
        margin: 0; /* Remove auto margin - flex centering handles it */
        position: relative; /* Ensure proper positioning */
    }
    
    .game-modal-header {
        padding: 15px 20px;
    }
    
    .game-modal-header h3 {
        font-size: 1.2rem;
    }
    
    .game-modal-content {
        padding: 20px;
        max-height: calc(95vh - 100px);
    }
    
    .game-board {
        gap: min(4px, 1vw);
        padding: min(15px, 3vw);
        margin-bottom: 15px;
    }
    
    .cell {
        /* Kleinere Mindestgröße auf Tablets */
        width: min(35px, calc(10vw - 5px));
        height: min(35px, calc(10vw - 5px));
        border-width: 1px;
    }
    
    .game-controls {
        flex-direction: column;
        gap: 15px;
        align-items: center;
        margin-bottom: 20px;
    }
    
    .game-controls .btn {
        width: 100%;
        max-width: 200px;
    }
    
    .ai-toggle {
        width: 100%;
        justify-content: center;
    }
    
    .game-info {
        text-align: center;
    }
    
    .current-player {
        font-size: 1rem;
        margin-bottom: 10px;
    }
    
    #gameStatus {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .game-modal[style*="display: block"] {
        display: flex !important;
        justify-content: center;
        align-items: center;
        padding: 5px;
        box-sizing: border-box;
    }
    
    .game-modal-container {
        width: 98%;
        margin: 0; /* Remove auto margin - flex centering handles it */
        max-height: 98vh;
    }
    
    .game-modal-header {
        padding: 12px 15px;
    }
    
    .game-modal-header h3 {
        font-size: 1.1rem;
    }
    
    .game-modal-content {
        padding: 15px;
        max-height: calc(98vh - 80px);
    }
    
    .game-board {
        gap: min(2px, 0.5vw);
        padding: min(10px, 2.5vw);
    }
    
    .cell {
        /* Sehr kleine Geräte - minimale Größe */
        width: min(25px, calc(8vw - 3px));
        height: min(25px, calc(8vw - 3px));
    }
    
    .game-disclaimer p {
        font-size: 0.85rem;
    }
    
    .tech-tag {
        padding: 6px 12px;
        font-size: 0.85em;
    }
    
    /* Alle Modals mobile Zentrierung für Smartphones */
    .image-modal-container {
        margin: 0;
        max-width: 98vw;
        max-height: 98vh;
        width: 98%;
    }
}

/* Screenreader-only Utility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}