/* Global Styles */
:root {
    --primary-color: #2563eb;
    --secondary-color: #7c3aed;
    --accent-color: #06b6d4;
    --dark-bg: #0f172a;
    --light-bg: #f8fafc;
    --text-dark: #1e293b;
    --text-light: #64748b;
    --border-color: #e2e8f0;
    --success-color: #10b981;
    --warning-color: #f59e0b;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: #ffffff;
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

header .container {
    max-width: 1400px;
}

/* Header & Navigation */
header {
    background-color: var(--dark-bg);
    color: white;
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    gap: 2rem;
}

.logo {
    flex-shrink: 0;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background: white;
    border-radius: 3px;
    transition: all 0.3s;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

.logo h1 {
    font-size: 2rem;
    color: white;
    /* Gradient effect - may not work in all browsers, falls back to white */
    background: linear-gradient(135deg, #60a5fa, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Fallback for browsers that don't support background-clip */
@supports not (background-clip: text) {
    .logo h1 {
        color: white;
    }
}

.tagline {
    font-size: 0.85rem;
    color: #94a3b8;
    margin-top: -5px;
    font-weight: 400;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    align-items: center;
    flex-wrap: nowrap;
}

.nav-menu a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
    white-space: nowrap;
    font-size: 0.95rem;
}

.nav-menu a:hover {
    color: var(--accent-color);
}

.nav-menu a.nav-highlight {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s;
}

.nav-menu a.nav-highlight:hover {
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--dark-bg) 0%, #1e293b 100%);
    color: white;
    padding: 6rem 0;
    text-align: center;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #fff, var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.3rem;
    color: var(--text-light);
    margin-bottom: 3rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 4rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-number {
    font-size: 3rem;
    font-weight: bold;
    color: var(--accent-color);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Buttons */
.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 0.9rem 2rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    border: 2px solid transparent;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(37, 99, 235, 0.3);
}

.btn-secondary {
    background: transparent;
    color: white;
    border-color: white;
}

.btn-secondary:hover {
    background: white;
    color: var(--primary-color);
}

/* Overview Section */
.overview {
    padding: 5rem 0;
    background-color: var(--light-bg);
}

.overview h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1.5rem;
    color: var(--dark-bg);
}

.intro-text {
    font-size: 1.2rem;
    text-align: center;
    max-width: 900px;
    margin: 0 auto 3rem;
    color: var(--text-light);
    line-height: 1.8;
}

.key-benefits {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.benefit-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.benefit-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.benefit-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.benefit-card h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--dark-bg);
}

.benefit-card p {
    color: var(--text-light);
}

/* Phases Overview */
.phases-overview {
    padding: 5rem 0;
}

.phases-overview h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1rem;
}

.section-intro {
    text-align: center;
    font-size: 1.1rem;
    color: var(--text-light);
    margin-bottom: 3rem;
}

.phases-flow {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.phase-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    flex: 1;
    min-width: 200px;
    transition: all 0.3s;
    border: 2px solid transparent;
}

.phase-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.2);
}

.phase-number {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.phase-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.8rem;
    color: var(--dark-bg);
}

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

.learn-more {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}

.learn-more:hover {
    color: var(--secondary-color);
}

.flow-arrow {
    font-size: 2rem;
    color: var(--primary-color);
    font-weight: bold;
}

.feedback-loop {
    text-align: center;
    margin-top: 2rem;
    padding: 1.5rem;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1), rgba(124, 58, 237, 0.1));
    border-radius: 12px;
}

.feedback-loop p {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
}

/* Pillars Overview */
.pillars-overview {
    padding: 5rem 0;
    background-color: var(--light-bg);
}

.pillars-overview h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1rem;
}

.pillars-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1.5rem;
}

.pillar-card {
    background: white;
    padding: 1.75rem 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    text-align: center;
    transition: all 0.3s;
    border: 2px solid transparent;
}

.pillar-card:hover {
    border-color: var(--secondary-color);
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(124, 58, 237, 0.2);
}

.pillar-icon {
    font-size: 2.75rem;
    margin-bottom: 0.75rem;
}

.pillar-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    color: var(--dark-bg);
}

.pillar-card p {
    color: var(--text-light);
    line-height: 1.5;
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}

/* Execution Modes */
.execution-modes {
    padding: 5rem 0;
}

.execution-modes h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1rem;
}

.modes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.mode-card {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.05), rgba(124, 58, 237, 0.05));
    padding: 2rem;
    border-radius: 12px;
    border-left: 4px solid var(--primary-color);
}

.mode-card h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--dark-bg);
}

.mode-use {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    font-style: italic;
}

.mode-flow {
    background: white;
    padding: 1rem;
    border-radius: 8px;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    color: var(--primary-color);
    text-align: center;
}

/* Comparison Section */
.comparison {
    padding: 5rem 0;
    background-color: var(--light-bg);
}

.comparison h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
}

.comparison-table {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.comparison-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    border-bottom: 1px solid var(--border-color);
}

.comparison-row:last-child {
    border-bottom: none;
}

.comparison-row.header {
    background: var(--dark-bg);
    color: white;
    font-weight: 600;
}

.comparison-cell {
    padding: 1.5rem;
    border-right: 1px solid var(--border-color);
}

.comparison-cell:last-child {
    border-right: none;
}

.comparison-row:not(.header) .comparison-cell:last-child {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.05), rgba(124, 58, 237, 0.05));
    font-weight: 500;
    color: var(--primary-color);
}

/* CTA Section */
.cta-section {
    padding: 5rem 0;
    background: linear-gradient(135deg, var(--dark-bg), #1e293b);
    color: white;
    text-align: center;
}

.cta-section h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-section p {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-bottom: 2rem;
}

/* Footer */
footer {
    background-color: var(--dark-bg);
    color: var(--text-light);
    padding: 2rem 0;
    text-align: center;
}

.sources {
    font-size: 0.85rem;
    margin-top: 0.5rem;
    font-style: italic;
}

/* Responsive Design */
@media (min-width: 1400px) {
    .nav-menu {
        gap: 2rem;
    }

    .nav-menu a {
        font-size: 1rem;
    }
}

@media (max-width: 1024px) {
    .container {
        padding: 0 15px;
    }

    .nav-menu {
        gap: 1.2rem;
    }

    .nav-menu a {
        font-size: 0.9rem;
    }

    .key-benefits {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    }

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

    .modes-grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    }
}

@media (max-width: 768px) {
    body {
        overflow-x: hidden;
        max-width: 100vw;
    }

    .container {
        padding: 0 10px;
        max-width: 100%;
    }

    /* Mobile Navigation */
    .menu-toggle {
        display: flex;
        z-index: 1001;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        max-width: 80vw;
        height: 100vh;
        background: var(--dark-bg);
        flex-direction: column;
        padding-top: 80px;
        padding-bottom: 2rem;
        gap: 0;
        align-items: stretch;
        transition: right 0.3s ease;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.3);
        overflow-y: auto;
        z-index: 999;
    }

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

    .nav-menu li {
        width: 100%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .nav-menu a {
        display: block;
        padding: 1rem 2rem;
    }

    .nav-menu a.nav-highlight {
        margin: 0.5rem 1rem;
        width: calc(100% - 2rem);
    }

    /* Hero Section */
    .hero {
        padding: 4rem 0;
    }

    .hero h1 {
        font-size: 2rem;
        line-height: 1.2;
    }

    .hero-subtitle {
        font-size: 1rem;
        padding: 0 10px;
    }

    .hero-stats {
        gap: 1.5rem;
        padding: 0 10px;
    }

    .stat-number {
        font-size: 2.5rem;
    }

    .stat-label {
        font-size: 0.8rem;
    }

    /* Sections */
    .overview,
    .phases-overview,
    .pillars-overview,
    .execution-modes,
    .comparison,
    .cta-section {
        padding: 3rem 0;
    }

    .overview h2,
    .phases-overview h2,
    .pillars-overview h2,
    .execution-modes h2,
    .comparison h2,
    .cta-section h2 {
        font-size: 1.8rem;
    }

    .intro-text {
        font-size: 1rem;
        padding: 0 10px;
    }

    /* Cards and Grids */
    .key-benefits,
    .pillars-grid,
    .modes-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .benefit-card,
    .pillar-card,
    .mode-card {
        padding: 1.5rem;
    }

    /* Phases Flow */
    .phases-flow {
        flex-direction: column;
    }

    .phase-card {
        min-width: 100%;
    }

    .flow-arrow {
        transform: rotate(90deg);
        margin: 0.5rem 0;
    }

    /* Comparison Table */
    .comparison-table {
        overflow-x: auto;
        display: block;
    }

    .comparison-row {
        min-width: 600px;
    }

    /* Buttons */
    .cta-buttons {
        flex-direction: column;
        width: 100%;
        padding: 0 20px;
        gap: 1rem;
    }

    .btn {
        width: 100%;
        text-align: center;
        padding: 0.8rem 1.5rem;
    }

    .phase-navigation .btn {
        display: block;
        margin: 0.5rem 0;
    }
}

@media (max-width: 480px) {
    .logo h1 {
        font-size: 1.5rem;
    }

    .tagline {
        font-size: 0.75rem;
    }

    .hero h1 {
        font-size: 1.6rem;
    }

    .hero-subtitle {
        font-size: 0.9rem;
    }

    .overview h2,
    .phases-overview h2,
    .pillars-overview h2,
    .execution-modes h2,
    .comparison h2,
    .cta-section h2 {
        font-size: 1.5rem;
    }

    .phase-number {
        font-size: 2rem;
    }

    .phase-card h3 {
        font-size: 1.2rem;
    }

    .benefit-icon,
    .pillar-icon {
        font-size: 2.5rem;
    }
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.mb-3 { margin-bottom: 3rem; }

/* Touch-friendly improvements for mobile */
@media (hover: none) and (pointer: coarse) {
    /* Increase touch target sizes */
    .btn,
    .nav-menu a,
    .phase-card,
    .pillar-card,
    .benefit-card,
    .learn-more {
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* Remove hover effects on touch devices */
    .benefit-card:hover,
    .phase-card:hover,
    .pillar-card:hover {
        transform: none;
    }

    /* Better tap highlights */
    * {
        -webkit-tap-highlight-color: rgba(37, 99, 235, 0.2);
    }
}

/* Smooth scrolling for all devices */
html {
    scroll-behavior: smooth;
}

/* Better focus states for accessibility */
a:focus,
button:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Prevent text size adjustment on orientation change */
html {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

/* Section Link Wrapper */
.section-link-wrapper {
    text-align: center;
    margin: 1.5rem 0 2.5rem 0;
}

.section-cta-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.05rem;
    padding: 0.875rem 1.75rem;
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    transition: all 0.3s ease;
    background-color: transparent;
}

.section-cta-link:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.25);
}

/* Comparison Image Link */
.comparison-image-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    transition: all 0.3s ease;
    margin-bottom: 2rem;
}

.comparison-image-link:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

/* Image Modal Popup */
.image-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    overflow: auto;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.image-modal-content {
    display: block;
    margin: 2rem auto;
    max-width: 95%;
    max-height: 90vh;
    object-fit: contain;
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from {
        transform: scale(0.7);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.image-modal-close {
    position: fixed;
    top: 20px;
    right: 40px;
    color: #ffffff;
    font-size: 48px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10000;
    background-color: rgba(0, 0, 0, 0.5);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    line-height: 1;
}

.image-modal-close:hover,
.image-modal-close:focus {
    color: var(--primary-color);
    background-color: rgba(0, 0, 0, 0.8);
    transform: rotate(90deg);
}

.image-modal-caption {
    text-align: center;
    color: #ffffff;
    padding: 1rem;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 2rem;
}

/* Responsive modal adjustments */
@media (max-width: 768px) {
    .image-modal-content {
        max-width: 98%;
        margin: 1rem auto;
    }

    .image-modal-close {
        top: 10px;
        right: 15px;
        font-size: 36px;
        width: 40px;
        height: 40px;
    }

    .image-modal-caption {
        font-size: 1rem;
        padding: 0.75rem;
    }
}