@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700&display=swap');

:root {
    /* GIZ Corporate Identity */
    --bg-main: #ffffff;
    --bg-alt: #ffffff;
    --primary: #E4003A; /* GIZ Red */
    --secondary: #27427D; /* GIZ Blue */
    --text-main: #1F1F1F;
    --text-dim: #666666;
    --border: 1px solid #dddddd;
    
    /* Spacing */
    --space-xs: 0.5rem;
    --space-s: 1rem;
    --space-m: 2rem;
    --space-l: 4rem;
    
    /* Effects */
    --radius: 4px; /* More corporate, less rounded */
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Light mode is now the only mode, but we'll keep variables compatible */
body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Navigation & Dropdowns */
header nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #ffffff;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 100;
    border-radius: var(--radius);
    border: var(--border);
    top: 100%;
    left: 0;
    margin-top: 0.5rem;
}

.dropdown-content a {
    color: var(--text-main);
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-size: 0.9rem;
    transition: background 0.2s;
}

.dropdown-content a:hover {
    color: var(--primary);
}

.dropdown:hover .dropdown-content {
    display: block;
}

.nav-link {
    color: var(--text-dim);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

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

/* Background Elements */
.bg-glow {
    display: none; /* Removed for professional look */
}

.glow-top-right { top: -200px; right: -200px; }
.glow-bottom-left { bottom: -200px; left: -200px; opacity: 0.5; }

/* Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-s);
}

header {
    background: var(--bg-main);
    padding: var(--space-s) 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid var(--primary); /* GIZ underline style */
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--secondary); /* GIZ Blue for logo */
}

/* Institutional Cards */
.card {
    background: #ffffff;
    border: var(--border);
    border-radius: var(--radius);
    padding: var(--space-m);
    box-shadow: var(--shadow);
    transition: box-shadow 0.3s ease;
}

.card:hover {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

/* Buttons */
.btn {
    padding: 0.8rem 2rem;
    border-radius: 50px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: var(--primary);
    color: #ffffff;
}

.btn-primary:hover {
    background: #c10031;
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--secondary);
    color: var(--secondary);
}

.btn-outline:hover {
    background: var(--secondary);
    color: #ffffff;
}

/* Forms */
.form-group {
    margin-bottom: var(--space-s);
}

input, select, textarea {
    width: 100%;
    padding: 1rem;
    background: #ffffff;
    border: var(--border);
    border-radius: var(--radius);
    color: var(--text-main);
    font-family: inherit;
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 5px rgba(228, 0, 58, 0.3);
}

/* Hero Section */
.hero {
    padding: var(--space-l) 0;
    text-align: center;
    background: var(--bg-alt);
    margin: var(--space-m) calc(-1 * var(--space-s));
    padding: var(--space-l) var(--space-s);
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: var(--space-s);
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-dim);
    max-width: 800px;
    margin: 0 auto var(--space-m);
}

.hero h1 span {
    /* No specific color here, allowing inline style or direct class to apply */
}

/* Grid System */
.grid {
    display: grid;
    gap: var(--space-m);
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fade {
    animation: fadeIn 0.8s ease forwards;
}

/* --- Core Integration Principle & Accessibility Additions --- */
.badge-sector {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.badge-trade { background: #e3f2fd; color: #0d47a1; border: 1px solid #90caf9; }
.badge-creative { background: #f3e5f5; color: #4a148c; border: 1px solid #ce93d8; }
.badge-mfg { background: #fff3e0; color: #e65100; border: 1px solid #ffb74d; }
.badge-agri { background: #e8f5e9; color: #1b5e20; border: 1px solid #a5d6a7; }
.badge-green { background: #e0f2f1; color: #004d40; border: 1px solid #80cbc4; }

.badge-champion {
    background: linear-gradient(135deg, #ffd700, #ffb300);
    color: #1a1a1a;
    font-size: 0.75rem;
    font-weight: 800;
    padding: 0.3rem 0.7rem;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    box-shadow: 0 2px 5px rgba(255, 179, 0, 0.4);
}

.badge-pwd {
    background: #ede7f6;
    color: #512da8;
    border: 1px solid #b39ddb;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.6rem;
    border-radius: 12px;
}

/* Accessibility Toolbar */
.a11y-bar {
    background: #f8f9fa;
    border-bottom: 1px solid #e0e0e0;
    padding: 0.4rem 1rem;
    font-size: 0.85rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.a11y-controls {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}
.a11y-btn {
    background: #ffffff;
    border: 1px solid #cccccc;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-main);
    transition: all 0.2s;
}
.a11y-btn:hover {
    background: #f0f0f0;
    border-color: var(--primary);
}

/* High Contrast Mode */
body.high-contrast {
    background-color: #000000 !important;
    color: #ffff00 !important;
}
body.high-contrast header,
body.high-contrast .main-header,
body.high-contrast .a11y-drawer,
body.high-contrast .nav-menu,
body.high-contrast .card,
body.high-contrast .step-card,
body.high-contrast .mentor-profile-card,
body.high-contrast .sector-box,
body.high-contrast .diag-card,
body.high-contrast .result-box,
body.high-contrast .dropdown-content,
body.high-contrast table,
body.high-contrast th,
body.high-contrast td {
    background-color: #000000 !important;
    color: #ffffff !important;
    border-color: #ffff00 !important;
}
body.high-contrast a,
body.high-contrast .nav-link,
body.high-contrast h1,
body.high-contrast h2,
body.high-contrast h3 {
    color: #ffff00 !important;
}
body.high-contrast .btn-primary {
    background: #ffff00 !important;
    color: #000000 !important;
    font-weight: bold !important;
}
body.high-contrast .btn-outline {
    border-color: #ffff00 !important;
    color: #ffff00 !important;
}

/* Large Text Mode */
body.large-text {
    font-size: 1.25rem !important;
}
body.large-text h1 { font-size: 4.5rem !important; }
body.large-text h2 { font-size: 3rem !important; }
body.large-text p, body.large-text a, body.large-text span { font-size: 1.2rem !important; }

/* Dyslexia Friendly Mode */
body.dyslexia-font {
    font-family: Arial, Helvetica, sans-serif !important;
    letter-spacing: 0.8px !important;
    word-spacing: 2px !important;
    line-height: 2 !important;
}

/* Pulse animation for voice input */
@keyframes voicePulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(228, 0, 58, 0.7); }
    70% { transform: scale(1.05); box-shadow: 0 0 0 10px rgba(228, 0, 58, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(228, 0, 58, 0); }
}
.recording-active {
    animation: voicePulse 1.5s infinite;
    background-color: #E4003A !important;
    color: #ffffff !important;
}

/* Callout banner */
.principle-banner {
    background: linear-gradient(135deg, rgba(39, 66, 125, 0.08), rgba(228, 0, 58, 0.08));
    border-left: 5px solid var(--secondary);
    border-radius: var(--radius);
    padding: 1.5rem;
    margin-bottom: 2rem;
}

/* Data Table Styling */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    margin-top: 1rem;
    border-radius: var(--radius);
    border: var(--border);
}
.data-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.9rem;
}
.data-table th, .data-table td {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid #eeeeee;
}
.data-table th {
    background: #f8f9fa;
    color: var(--secondary);
    font-weight: 700;
}
.data-table tr:hover {
    background: #fbfbfb;
}

/* Metric KPI Card */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}
.kpi-card {
    background: #ffffff;
    border: var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    border-top: 4px solid var(--primary);
    box-shadow: var(--shadow);
}
.kpi-num {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--secondary);
    margin: 0.25rem 0;
}
.kpi-sub {
    font-size: 0.8rem;
    color: var(--text-dim);
}

/* ========================================================
   GLOBAL MOBILE RESPONSIVENESS & BREAKING STYLES
   ======================================================== */
@media (max-width: 768px) {
    /* Container & Spacing */
    .container {
        padding: 0 1rem !important;
    }

    /* Hero Typography */
    .hero-section {
        padding: 3rem 1rem !important;
    }
    .hero-title {
        font-size: 2.1rem !important;
        line-height: 1.25 !important;
    }
    .hero-subtitle {
        font-size: 1.05rem !important;
        margin-bottom: 2rem !important;
    }

    /* Grids & Flex Containers */
    .grid, .steps-container, .mentor-grid, .sector-box-grid, .kpi-grid {
        grid-template-columns: 1fr !important;
        gap: 1.25rem !important;
    }

    /* Forms */
    .booking-card, .diag-card, .card {
        padding: 1.5rem 1rem !important;
    }
    .form-grid-2col {
        grid-template-columns: 1fr !important;
    }

    /* Interactive diagnostic / assessment */
    .diag-wrapper {
        margin: 1.5rem auto !important;
        padding: 0 1rem !important;
    }
    .diag-header h1 {
        font-size: 1.75rem !important;
    }
    .sector-tabs {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    /* Tables */
    .table-responsive {
        border-radius: 4px;
        -webkit-overflow-scrolling: touch;
    }

    /* Buttons */
    .btn {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .sector-tabs {
        grid-template-columns: 1fr !important;
    }
    .hero-title {
        font-size: 1.85rem !important;
    }
}
