/* === AI-Content Detector ML - Responsive Design === */
/* Version: 3.1 ML */

@media (max-width: 1200px) {
    .hero-content h1 {
        font-size: 2.8rem;
    }
}

@media (max-width: 1024px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }
    
    .hero-content p {
        margin-left: auto;
        margin-right: auto;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ===== MOBILE MENU - FIXED HEIGHT ===== */
@media (max-width: 768px) {
    /* Header & Navigation */
    header {
        position: sticky;
        top: 0;
        z-index: 1000;
        background: var(--bg-secondary);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
    }
    
    .navbar {
        position: relative;
        height: 70px;
    }
    
    /* Hamburger Menu Button */
    .menu-toggle {
        display: flex !important;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        width: 48px;
        height: 48px;
        background: transparent;
        border: none;
        cursor: pointer;
        padding: 0;
        z-index: 1002;
        position: relative;
        margin-left: auto;
    }
    
    .menu-toggle span {
        display: block;
        width: 28px;
        height: 3px;
        background: var(--accent-primary);
        margin: 4px 0;
        border-radius: 3px;
        transition: all 0.3s ease;
    }
    
    .menu-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(8px, 8px);
    }
    
    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
        transform: translateX(-10px);
    }
    
    .menu-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
    }
    
    /* Navigation Links - VOLLE HÖHE */
    .nav-links {
        display: none !important;
        position: fixed;
        top: 70px; /* Startet unter dem Header */
        left: 0;
        right: 0;
        bottom: 0;
        height: calc(100vh - 70px); /* VOLLE HÖHE minus Header */
        background: var(--bg-primary);
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        padding: 30px 20px 40px;
        gap: 12px;
        z-index: 1001;
        overflow-y: auto; /* WICHTIG: Scrollen wenn nötig */
        -webkit-overflow-scrolling: touch; /* Smooth scrolling auf iOS */
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease, visibility 0.3s ease;
        box-shadow: none;
        border: none;
    }
    
    .nav-links.show {
        display: flex !important;
        opacity: 1;
        visibility: visible;
    }
    
    /* Navigation Links Styling */
    .nav-links a {
        display: block;
        width: 100%;
        max-width: 320px;
        padding: 16px 24px;
        text-align: center;
        font-size: 1.2rem;
        color: var(--text-primary);
        background: var(--bg-tertiary);
        border-radius: 40px;
        border: 1px solid var(--border-color);
        transition: all 0.2s ease;
        text-decoration: none;
        font-weight: 500;
        flex-shrink: 0; /* Verhindert Schrumpfen */
    }
    
    .nav-links a:hover,
    .nav-links a:active {
        background: var(--accent-gradient);
        color: white;
        transform: scale(1.05);
    }
    
    .nav-links a.active {
        background: var(--accent-gradient);
        color: white;
        border: none;
    }
    
    .nav-links a.active::after {
        display: none;
    }
    
    /* Sprach-Dropdown im mobilen Menü */
    .language-dropdown {
        width: 100%;
        max-width: 320px;
        margin: 8px 0;
        flex-shrink: 0;
    }
    
    .lang-current {
        width: 100%;
        justify-content: center;
        padding: 16px 24px;
        background: var(--bg-tertiary);
        border: 1px solid var(--border-color);
        border-radius: 40px;
        font-size: 1.2rem;
        color: var(--text-primary);
        cursor: pointer;
        display: flex;
        align-items: center;
        gap: 8px;
    }
    
    .lang-current:hover {
        border-color: var(--accent-primary);
    }
    
    .lang-current.active {
        border-color: var(--accent-primary);
        background: var(--bg-card);
    }
    
    .lang-dropdown-content {
        position: static;
        width: 100%;
        margin-top: 8px;
        box-shadow: none;
        border: 1px solid var(--border-color);
        border-radius: 40px;
        overflow: hidden;
        background: var(--bg-card);
        display: none;
    }
    
    .lang-dropdown-content.show {
        display: block;
    }
    
    .lang-option {
        justify-content: center;
        padding: 14px 24px !important;
        font-size: 1.1rem;
        width: 100%;
        text-align: center;
        border-bottom: 1px solid var(--border-color);
    }
    
    .lang-option:last-child {
        border-bottom: none;
    }
    
    .lang-option.active {
        background: var(--accent-gradient);
        color: white !important;
    }
    
    /* Dark Mode Toggle im mobilen Menü */
    .dark-mode-toggle {
        width: 100%;
        max-width: 320px;
        justify-content: center;
        margin: 8px 0 16px;
        background: var(--bg-tertiary);
        border: 1px solid var(--border-color);
        border-radius: 40px;
        overflow: hidden;
        display: flex;
        flex-shrink: 0;
    }
    
    .theme-btn {
        flex: 1;
        text-align: center;
        padding: 14px;
        font-size: 1.2rem;
        background: transparent;
        border: none;
        color: var(--text-secondary);
        cursor: pointer;
        transition: all 0.2s ease;
    }
    
    .theme-btn:hover {
        background: var(--bg-card);
    }
    
    .theme-btn.active {
        background: var(--accent-gradient);
        color: white;
    }
    
    /* Logo für mobile */
    .logo-text {
        font-size: 1rem;
    }
    
    .logo img {
        height: 36px;
        width: auto;
    }
    
    .logo a {
        gap: 8px;
    }
    
    /* Hero Section */
    .hero {
        padding: 40px 0;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .hero .container {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    /* Features */
    .features-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .feature-card {
        padding: 24px;
    }
    
    /* FAQ */
    .faq-item {
        width: 100%;
        max-width: 100%;
        margin: 0 0 16px 0;
    }
    
    .faq-question {
        padding: 16px 20px;
        font-size: 1rem;
    }
    
    /* Download Buttons */
    .download-buttons {
        flex-direction: column;
        align-items: center;
        gap: 16px;
    }
    
    .download-btn {
        width: 100%;
        max-width: 300px;
        padding: 14px 24px;
    }
    
    /* Stats */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .stat-item {
        padding: 16px;
    }
    
    .stat-value {
        font-size: 2rem;
    }
    
    /* Tech Grid */
    .tech-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .tech-item {
        padding: 20px;
    }
    
    /* Demo */
    .demo-controls {
        flex-direction: column;
        gap: 12px;
    }
    
    .demo-tabs {
        flex-direction: column;
    }
    
    .demo-tab {
        padding: 14px;
        text-align: center;
        border-bottom: 1px solid var(--border-color);
    }
    
    .demo-tab:last-child {
        border-bottom: none;
    }
    
    .demo-content {
        padding: 24px;
    }
    
    .demo-textarea {
        min-height: 150px;
        padding: 16px;
    }
    
    .demo-result {
        flex-direction: column;
        text-align: center;
        gap: 16px;
        padding: 20px;
    }
    
    .demo-confidence {
        flex-direction: column;
        width: 100%;
    }
    
    .confidence-bar {
        width: 100%;
    }
    
    /* Footer */
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 30px;
    }
    
    .footer-col ul {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .footer-col ul li a {
        justify-content: center;
    }
    
    .social-links {
        align-items: center;
    }
    
    /* Cookie Consent */
    .cookie-content {
        flex-direction: column;
        text-align: center;
        gap: 16px;
    }
    
    .cookie-buttons {
        width: 100%;
        flex-direction: column;
        gap: 10px;
    }
    
    .btn-cookie-accept,
    .btn-cookie-essential {
        width: 100%;
        padding: 12px 20px;
    }
    
    /* Buttons allgemein */
    .btn,
    .btn-large {
        width: 100%;
        text-align: center;
        padding: 14px 24px;
    }
    
    /* Container */
    .container {
        padding: 0 20px;
    }
    
    /* Section Titles */
    .section-title {
        font-size: 2rem;
    }
    
    .section-subtitle {
        font-size: 1.1rem;
        margin-bottom: 40px;
    }
}

@media (max-width: 480px) {
    /* Extra kleine Geräte */
    .hero-content h1 {
        font-size: 1.8rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .stat-value {
        font-size: 1.8rem;
    }
    
    .feature-icon {
        font-size: 2.5rem;
    }
    
    .feature-title {
        font-size: 1.2rem;
    }
    
    /* Mobile Menu für kleine Geräte */
    .nav-links {
        padding: 20px 15px 30px;
    }
    
    .nav-links a {
        padding: 14px 20px;
        font-size: 1.1rem;
        max-width: 280px;
    }
    
    .language-dropdown,
    .dark-mode-toggle {
        max-width: 280px;
    }
    
    .legal-content {
        padding: 20px 15px;
    }
    
    .changelog-entry {
        padding: 20px 15px;
    }
    
    .version-tag {
        font-size: 0.8rem;
        padding: 4px 12px;
        left: 50%;
        transform: translateX(-50%);
    }
    
    .demo-content {
        padding: 16px;
    }
    
    .demo-textarea {
        min-height: 120px;
    }
}

/* Landscape-Modus auf Handys */
@media (max-width: 768px) and (orientation: landscape) {
    .nav-links {
        padding: 15px 20px 20px;
        top: 60px;
        height: calc(100vh - 60px);
    }
    
    .nav-links a {
        padding: 10px 16px;
        max-width: 400px;
        font-size: 1rem;
    }
    
    .language-dropdown,
    .dark-mode-toggle {
        max-width: 400px;
    }
    
    .lang-current {
        padding: 10px 16px;
    }
    
    .theme-btn {
        padding: 10px;
    }
    
    .hero {
        padding: 30px 0;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Druckoptimierung */
@media print {
    header,
    footer,
    .cookie-consent,
    .demo-controls,
    .dark-mode-toggle,
    .language-dropdown,
    .menu-toggle {
        display: none !important;
    }
    
    body {
        background: white;
        color: black;
    }
    
    .hero::before {
        display: none;
    }
    
    a {
        text-decoration: none;
        color: black;
    }
}