/* 
  FINARADE - PREMIUM FINANCE DESIGN SYSTEM
  Mobile-First Architecture
*/

:root {
    --primary-color: #007AB8;
    --primary-hover: #005f8d;
    --accent-color: #F57C00;
    --accent-hover: #e67600;
    --bg-color: #ffffff;
    --bg-alt: #f1f5f9;
    --text-main: #0f172a;
    --text-muted: #475569;
    --white: #ffffff;
    --glass: rgba(255, 255, 255, 0.98);
    --border-radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* 1. Global Resets & Defaults */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: var(--text-main);
    background-color: var(--bg-color);
    line-height: 1.6;
    overflow-x: hidden;
    width: 100%;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

/* 2. Utility Classes */
.section-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px;
}

@media (min-width: 1024px) {
    .section-container {
        padding: 100px 40px;
    }
}

.heading-secondary {
    font-size: clamp(1.75rem, 5vw, 2.75rem);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 24px;
    color: var(--text-main);
}

.text-paragraph {
    font-size: 1.125rem;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.section-tagline {
    display: block;
    font-weight: 700;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.875rem;
    margin-bottom: 12px;
}

/* 3. Common Components */
.btn-primary {
    display: inline-block;
    background-color: var(--accent-color);
    color: var(--white);
    padding: 16px 32px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1.125rem;
    box-shadow: 0 4px 14px 0 rgba(245, 124, 0, 0.39);
    transition: var(--transition);
}

.btn-primary:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(245, 124, 0, 0.23);
}

/* 4. Advertisement Bar - Truly Responsive */
.ad-top-bar {
    background-color: #f8fafc;
    color: #64748b;
    padding: 10px 16px;
    text-align: center;
    font-size: 0.75rem;
    font-weight: 600;
    border-bottom: 1px solid #e2e8f0;
    width: 100%;
    line-height: 1.4;
    position: relative;
    z-index: 1005;
}

/* 5. Header & Navigation */
.main-header {
    background-color: var(--white);
    position: sticky;
    top: 0;
    width: 100%;
    z-index: 1000;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    height: 70px;
    display: flex;
    align-items: center;
}

@media (min-width: 1024px) {
    .main-header {
        background-color: var(--glass);
        backdrop-filter: blur(12px);
    }
}

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

.logo-text {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--primary-color);
    letter-spacing: -1px;
}

/* Desktop Nav */
.nav-menu {
    display: none;
}

.nav-item-close {
    display: none;
}

.header-cta {
    display: none;
}

@media (min-width: 1024px) {
    .main-header {
        height: 80px;
    }

    .nav-menu {
        display: flex;
        gap: 32px;
    }

    .nav-link {
        font-weight: 600;
        font-size: 0.95rem;
    }

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

    .header-cta {
        display: inline-block;
        background-color: var(--primary-color);
        color: white;
        padding: 10px 24px;
        border-radius: 6px;
        font-weight: 600;
    }

    .mobile-toggle {
        display: none !important;
    }
}

/* Mobile Toggle - Hidden on desktop by media query */
.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    background: none;
    border: none;
}

@media (max-width: 1023px) {
    .mobile-toggle {
        display: flex;
    }
}

.hamburger-line {
    width: 25px;
    height: 3px;
    background-color: var(--text-main);
    border-radius: 2px;
}

@media (max-width: 1023px) {
    .nav-menu {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        right: -100%;
        width: 75% !important;
        height: 100vh;
        background-color: #ffffff !important;
        padding: 30px 24px;
        transition: right 0.4s ease;
        z-index: 9999;
        box-shadow: -15px 0 40px rgba(0, 0, 0, 0.25);
        overflow-y: auto;
        filter: none !important;
        backdrop-filter: none !important;
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-item-close {
        display: flex !important;
        justify-content: flex-end;
        width: 100%;
        margin-bottom: 30px;
    }

    .close-btn {
        width: 50px;
        height: 50px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 2rem;
        color: var(--text-main);
        background: #f1f5f9 !important;
        border: none;
        border-radius: 50%;
        cursor: pointer;
        padding: 0 !important;
        line-height: 1;
        transition: 0.3s;
    }

    .nav-link {
        font-size: 1.3rem;
        font-weight: 800;
        padding: 24px 0;
        border-bottom: 1px solid #f1f5f9;
        width: 100%;
        display: block;
        color: var(--text-main) !important;
        text-align: left;
        opacity: 1 !important;
        filter: none !important;
    }
}

/* Navigation Overlay - High Contrast for Readability */
.menu-overlay-bg {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.7);
    /* Dark semi-transparent overlay */
    z-index: 9000;
    /* Just below menu (9999) */
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: none !important;
    /* Disabling blur to fix menu clarity */
}

.menu-overlay-bg.active {
    opacity: 1;
    visibility: visible;
}

/* 6. Hero Section */
.hero-section {
    background: linear-gradient(rgba(15, 23, 42, 0.75), rgba(15, 23, 42, 0.75)),
        url('https://www.gtai.de/resource/image/780676/64x15/1920/450/59ed96f15332a0986fdf37a8109edfba/5A4BBC8357736E1D4D6023B64FCA3BA7/rf-adobe-235840443-rz.jpg');
    background-size: cover;
    background-position: center;
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    padding: 80px 20px;
    width: 100%;
}

.hero-content {
    max-width: 800px;
}

.hero-title {
    font-size: clamp(2rem, 8vw, 4rem);
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 20px;
}

.hero-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    margin-bottom: 40px;
    opacity: 0.9;
}

/* 7. Grid Layouts - Mobile First */
.about-grid,
.why-grid,
.testimonial-grid,
.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

@media (min-width: 768px) {
    .why-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .about-grid {
        grid-template-columns: 1fr 1fr;
        align-items: center;
    }

    .why-grid {
        grid-template-columns: repeat(3, 1fr);
    }

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

    .footer-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* 8. Specific Sections Branding */
.about-img {
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
}

.why-card {
    background: white;
    padding: 32px;
    border-radius: 16px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.why-card:hover {
    transform: translateY(-5px);
}

.card-icon {
    font-size: 2rem;
    margin-bottom: 16px;
}

/* FAQ Styling */
.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: var(--bg-alt);
    margin-bottom: 12px;
    border-radius: 8px;
    overflow: hidden;
}

.faq-question {
    padding: 20px 24px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-answer {
    padding: 0 24px 20px;
    display: none;
    color: var(--text-muted);
}

.faq-item.active .faq-answer {
    display: block;
}

/* 9. Footer Styling */
.main-footer {
    background-color: #0f172a;
    color: #f1f5f9;
    padding-top: 60px;
}

.footer-heading {
    color: white;
    margin-bottom: 20px;
    font-weight: 700;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-link:hover {
    color: var(--primary-color);
}

.footer-bottom {
    margin-top: 60px;
    padding: 40px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
}

.footer-disclaimer-box {
    background: rgba(255, 255, 255, 0.03);
    padding: 20px;
    border-radius: 8px;
    font-size: 0.85rem;
    color: #94a3b8;
    margin-bottom: 16px;
    border-left: 3px solid var(--accent-color);
}

/* 10. Popups & Modals */
.cookie-popup {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    max-width: 440px;
    background: white;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    z-index: 5000;
    display: none;
}

.cookie-btns {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.btn-cookie-accept {
    flex: 1;
    background: var(--primary-color);
    color: white;
    padding: 10px;
    border: none;
    border-radius: 6px;
    font-weight: 700;
    cursor: pointer;
}

.btn-cookie-reject {
    flex: 1;
    background: #f1f5f9;
    color: var(--text-main);
    padding: 10px;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
}

/* Modals Overlay */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(10px);
    z-index: 6000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-content {
    background: white;
    width: 100%;
    max-width: 800px;
    max-height: 85vh;
    border-radius: 16px;
    padding: 40px;
    position: relative;
    overflow-y: auto;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #f1f5f9;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 10;
}

.legal-scroll-box {
    max-height: 60vh;
    overflow-y: auto;
    padding-right: 15px;
    margin-top: 10px;
}

.legal-scroll-box::-webkit-scrollbar {
    width: 6px;
}

.legal-scroll-box::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 10px;
}

.legal-scroll-box::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

/* Specific centering/stacking fix for screenshot issue */
@media (max-width: 1023px) {
    .about-text-content {
        text-align: center;
    }

    .about-image-wrapper {
        margin-top: 20px;
    }
}