/* =================================================================
   IMPROVED CSS - COMPREHENSIVE OPTIMIZATION
   Author: Kilo Code
   Purpose: Enhanced version with improved readability, performance,
            best practices, and error handling
   ================================================================= */

/* CSS CASCADE LAYERS - Proper layer organization for better specificity management */
@layer reset, base, components, utilities, animations, themes;

/* =================================================================
   LAYER 1: RESET & NORMALIZE
   ================================================================= */
@layer reset {
    /* Enhanced CSS Reset with modern best practices */
    *, *::before, *::after {
        box-sizing: border-box;
        margin: 0;
        padding: 0;
    }

    /* Remove default focus outline for mouse users, keep for keyboard */
    *:focus:not(:focus-visible) {
        outline: none;
    }

    /* Improve text rendering across platforms */
    html {
        font-synthesis: none;
        text-rendering: optimizeLegibility;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
        font-feature-settings: "kern" 1;
    }

    /* Remove built-in form styling */
    input, button, textarea, select {
        font: inherit;
        color: inherit;
        background: transparent;
        border: none;
        outline: none;
    }

    /* Media elements */
    img, picture, video, canvas, svg {
        display: block;
        max-width: 100%;
        height: auto;
    }

    /* Typography improvements */
    body {
        line-height: 1.5;
        -webkit-text-size-adjust: 100%;
    }

    /* List improvements */
    ul[role="list"], ol[role="list"] {
        list-style: none;
    }

    /* Form elements */
    input, button, textarea, select {
        font: inherit;
    }
}

/* =================================================================
   LAYER 2: CSS CUSTOM PROPERTIES & BASE
   ================================================================= */
@layer base {
    :root {
        /* === MODERN CSS CUSTOM PROPERTIES === */
        
        /* Semantic Color System with better naming */
        --color-primary: #0a192f;
        --color-primary-light: #233554;
        --color-primary-dark: #061422;
        
        --color-secondary: #e6f1ff;
        --color-secondary-light: #f0f8ff;
        --color-secondary-dark: #c7d9f2;
        
        --color-accent: #00b894;
        --color-accent-light: #52cca7;
        --color-accent-lighter: #a8f0df;
        --color-accent-dark: #009e7a;
        --color-accent-darker: #007f65;
        
        --color-error: #e74c3c;
        --color-warning: #f39c12;
        --color-success: #27ae60;
        --color-info: #3498db;
        
        /* Neutral color system */
        --color-neutral-50: #fafafa;
        --color-neutral-100: #f4f4f5;
        --color-neutral-200: #e4e4e7;
        --color-neutral-300: #d4d4d8;
        --color-neutral-400: #a1a1aa;
        --color-neutral-500: #71717a;
        --color-neutral-600: #52525b;
        --color-neutral-700: #3f3f46;
        --color-neutral-800: #27272a;
        --color-neutral-900: #18181b;
        
        /* Semantic aliases and legacy compatibility */
        --color-background: var(--color-neutral-50);
        --color-surface: #ffffff;
        --color-surface-variant: var(--color-neutral-100);
        --color-border: var(--color-neutral-200);
        --color-text: var(--color-neutral-900);
        --color-text-secondary: var(--color-neutral-600);
        --color-text-muted: var(--color-neutral-500);
        
        /* Legacy Variables for Backward Compatibility */
        --primary: #0a192f;
        --secondary: #e6f1ff;
        --accent: #00b894;
        --accent-hover: #52cca7;
        --accent-light: #a8f0df;
        
        /* Background Colors */
        --bg: var(--color-background);
        --bg-light: var(--color-surface);
        --bg-dark: var(--color-neutral-100);
        --card-bg: var(--color-surface);
        
        /* Text Colors */
        --text-color: var(--color-text);
        --text-muted: var(--color-text-muted);
        --text-light: var(--color-neutral-400);
        --text-white: #ffffff;
        
        /* Border Colors */
        --border-color: var(--color-border);
        --border-light: var(--color-neutral-100);
        --border-dark: var(--color-neutral-300);
        
        /* === MODERN SPACING SYSTEM === */
        --space-unit: 0.25rem; /* 4px base unit */
        --space-0: 0;
        --space-1: calc(var(--space-unit) * 1);     /* 4px */
        --space-2: calc(var(--space-unit) * 2);     /* 8px */
        --space-3: calc(var(--space-unit) * 3);     /* 12px */
        --space-4: calc(var(--space-unit) * 4);     /* 16px */
        --space-5: calc(var(--space-unit) * 6);     /* 24px */
        --space-6: calc(var(--space-unit) * 8);     /* 32px */
        --space-8: calc(var(--space-unit) * 12);    /* 48px */
        --space-10: calc(var(--space-unit) * 16);   /* 64px */
        --space-12: calc(var(--space-unit) * 20);   /* 80px */
        --space-16: calc(var(--space-unit) * 24);   /* 96px */
        --space-20: calc(var(--space-unit) * 32);   /* 128px */
        --space-24: calc(var(--space-unit) * 40);   /* 160px */
        --space-32: calc(var(--space-unit) * 48);   /* 192px */
        --space-40: calc(var(--space-unit) * 64);   /* 256px */
        
        /* Legacy Spacing Variables */
        --space-xs: var(--space-1);     /* 4px */
        --space-sm: var(--space-2);     /* 8px */
        --space-md: var(--space-4);     /* 16px */
        --space-lg: var(--space-6);     /* 24px */
        --space-xl: var(--space-8);     /* 32px */
        --space-2xl: var(--space-12);   /* 48px */
        --space-3xl: var(--space-16);   /* 64px */
        --space-4xl: var(--space-24);   /* 96px */
        --space-5xl: var(--space-32);   /* 128px */
        
        /* === MODERN TYPOGRAPHY SCALE === */
        --font-family-base: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
        --font-family-display: 'Playfair Display', Georgia, serif;
        --font-family-mono: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;
        
        --font-size-xs: 0.75rem;     /* 12px */
        --font-size-sm: 0.875rem;    /* 14px */
        --font-size-base: 1rem;      /* 16px */
        --font-size-lg: 1.125rem;    /* 18px */
        --font-size-xl: 1.25rem;     /* 20px */
        --font-size-2xl: 1.5rem;     /* 24px */
        --font-size-3xl: 1.875rem;   /* 30px */
        --font-size-4xl: 2.25rem;    /* 36px */
        --font-size-5xl: 3rem;       /* 48px */
        --font-size-6xl: 3.75rem;    /* 60px */
        --font-size-7xl: 4.5rem;     /* 72px */

        /* Fluid Typography Scale - Responsive font sizes using clamp() */
        --font-size-fluid-hero: clamp(2.5rem, 5vw + 1rem, 4rem);
        --font-size-fluid-h1: clamp(2rem, 4vw + 0.5rem, 3rem);
        --font-size-fluid-h2: clamp(1.5rem, 3vw + 0.5rem, 2.25rem);
        --font-size-fluid-h3: clamp(1.25rem, 2vw + 0.5rem, 1.5rem);
        --font-size-fluid-body: clamp(1rem, 1vw + 0.5rem, 1.125rem);
        --font-size-fluid-small: clamp(0.875rem, 0.5vw + 0.5rem, 0.9375rem);

        /* Service-specific accent colors for visual differentiation */
        --color-service-training: #00b894;
        --color-service-training-dark: #009e7a;
        --color-service-powerpoint: #3498db;
        --color-service-powerpoint-dark: #2980b9;
        --color-service-mentoring: #9b59b6;
        --color-service-mentoring-dark: #8e44ad;

        /* Legacy Typography Variables */
        --text-xs: var(--font-size-xs);
        --text-sm: var(--font-size-sm);
        --text-base: var(--font-size-base);
        --text-lg: var(--font-size-lg);
        --text-xl: var(--font-size-xl);
        --text-2xl: var(--font-size-2xl);
        --text-3xl: var(--font-size-3xl);
        --text-4xl: var(--font-size-4xl);
        --text-5xl: var(--font-size-5xl);
        
        --line-height-none: 1;
        --line-height-tight: 1.25;
        --line-height-snug: 1.375;
        --line-height-normal: 1.5;
        --line-height-relaxed: 1.625;
        --line-height-loose: 2;
        
        /* Legacy Line Heights */
        --leading-tight: var(--line-height-tight);
        --leading-snug: var(--line-height-snug);
        --leading-normal: var(--line-height-normal);
        --leading-relaxed: var(--line-height-relaxed);
        --leading-loose: var(--line-height-loose);
        
        --font-weight-light: 300;
        --font-weight-normal: 400;
        --font-weight-medium: 500;
        --font-weight-semibold: 600;
        --font-weight-bold: 700;
        --font-weight-extrabold: 800;
        --font-weight-black: 900;
        
        /* === MODERN BORDER RADIUS SYSTEM === */
        --radius-none: 0;
        --radius-sm: 0.125rem;    /* 2px */
        --radius-base: 0.25rem;   /* 4px */
        --radius-md: 0.375rem;    /* 6px */
        --radius-lg: 0.5rem;      /* 8px */
        --radius-xl: 0.75rem;     /* 12px */
        --radius-2xl: 1rem;       /* 16px */
        --radius-3xl: 1.5rem;     /* 24px */
        --radius-full: 9999px;
        
        /* Legacy Border Radius Variables */
        --border-radius-sm: var(--radius-sm);
        --border-radius-md: var(--radius-md);
        --border-radius-lg: var(--radius-lg);
        --border-radius-xl: var(--radius-xl);
        --border-radius-full: var(--radius-full);
        
        /* === ENHANCED SHADOW SYSTEM === */
        --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.05);
        --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
        --shadow-base: 0 4px 6px rgba(0, 0, 0, 0.05), 0 2px 4px rgba(0, 0, 0, 0.06);
        --shadow-md: 0 10px 15px rgba(0, 0, 0, 0.1), 0 4px 6px rgba(0, 0, 0, 0.05);
        --shadow-lg: 0 20px 25px rgba(0, 0, 0, 0.1), 0 10px 10px rgba(0, 0, 0, 0.04);
        --shadow-xl: 0 25px 50px rgba(0, 0, 0, 0.25);
        --shadow-2xl: 0 50px 100px rgba(0, 0, 0, 0.25);
        
        /* Legacy Shadow Variables */
        --shadow-subtle: var(--shadow-sm);
        --shadow-elevated: var(--shadow-lg);
        --shadow-floating: var(--shadow-xl);
        --card-shadow: var(--shadow-md);
        
        /* === Z-INDEX SCALE === */
        --z-hide: -1;
        --z-auto: auto;
        --z-base: 0;
        --z-docked: 10;
        --z-dropdown: 1000;
        --z-sticky: 1100;
        --z-banner: 1200;
        --z-overlay: 1300;
        --z-modal: 1400;
        --z-popover: 1500;
        --z-skipLink: 1600;
        --z-toast: 1700;
        --z-tooltip: 1800;
        
        /* === TRANSITION SYSTEM === */
        --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
        --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
        --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
        --transition-slower: 1000ms cubic-bezier(0.4, 0, 0.2, 1);
        
        /* Legacy Transition Variable */
        --transition: var(--transition-base);
        
        /* === LAYOUT DIMENSIONS === */
        --container-sm: 640px;
        --container-md: 768px;
        --container-lg: 1024px;
        --container-xl: 1280px;
        --container-2xl: 1536px;
        --container-max-width: 1200px;
        
        --header-height: 4rem;        /* 64px */
        --header-height-mobile: 3.75rem; /* 60px */
        
        /* Legacy Layout Variables */
        --max-width: var(--container-max-width);
        --spacing-base: var(--space-md);
        --container-padding: var(--space-md);
        --section-padding: var(--space-4xl);
        --mobile-header-height: var(--header-height-mobile);
        
        /* === BREAKPOINTS === */
        --breakpoint-sm: 640px;
        --breakpoint-md: 768px;
        --breakpoint-lg: 1024px;
        --breakpoint-xl: 1280px;
        --breakpoint-2xl: 1536px;
        
        /* === ASPECT RATIOS === */
        --aspect-ratio-square: 1;
        --aspect-ratio-landscape: 4/3;
        --aspect-ratio-portrait: 3/4;
        --aspect-ratio-wide: 16/9;
        --aspect-ratio-ultra-wide: 21/9;
        
        /* === CONTAINER QUERIES === */
        --container-name-sm: sm;
        --container-name-md: md;
        --container-name-lg: lg;
        --container-name-xl: xl;
    }

    /* === BROWSER FEATURE SUPPORT === */
    @supports not (font-synthesis: none) {
        html { font-synthesis: weight; }
    }
    
    @supports not (container-type: inline-size) {
        .container { contain: layout style; }
    }

    /* === CONTAINER QUERY SETUP === */
    @container (min-width: 0) {
        :root { --container-name-sm: 1; }
    }
    
    @container (min-width: 768px) {
        :root { --container-name-md: 1; }
    }
    
    @container (min-width: 1024px) {
        :root { --container-name-lg: 1; }
    }
    
    @container (min-width: 1280px) {
        :root { --container-name-xl: 1; }
    }

    /* === BODY STYLES === */
    body {
        font-family: var(--font-family-base);
        font-size: var(--font-size-base);
        line-height: var(--line-height-normal);
        color: var(--color-text);
        background-color: var(--color-background);
        
        /* Performance optimizations */
        contain: layout style;
        font-kerning: normal;
        font-variant-ligatures: contextual;
        font-feature-settings: "kern" 1;
        
        /* Accessibility improvements */
        scroll-behavior: smooth;
        text-rendering: optimizeLegibility;
        -webkit-font-smoothing: antialiased;
        
        /* Layout */
        min-height: 100dvh;
        margin: 0;
        padding: 0;
        padding-top: var(--header-height);
        
        /* Transitions */
        transition: background-color var(--transition-base),
                   color var(--transition-base);
    }
}

/* Skip Navigation Links for Accessibility */
.skip-nav {
    position: absolute;
    top: -100px;
    left: 0;
    background: var(--primary);
    color: var(--secondary);
    padding: 8px 16px;
    z-index: 9999;
    text-decoration: none;
    border-radius: 0 0 4px 0;
    font-weight: 600;
    font-size: 0.9rem;
    transition: top 0.3s ease;
}

.skip-nav:focus {
    top: 0;
}

/* Enhanced Focus Indicators */
*:focus {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Remove default focus outline for mouse users */
*:focus:not(:focus-visible) {
    outline: none;
}

*:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Basic Reset & Box Sizing */
*, *::before, *::after {
    box-sizing: border-box;
}

a {
    color: var(--accent); /* Use accent color for links */
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #52cca7; /* Slightly darker accent on hover */
}

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

/* Blog cards (local JSON-rendered) */
.blog-card {
    background: var(--card-bg);
    border-radius: 10px;
    box-shadow: var(--card-shadow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.blog-card-media img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.blog-card-body {
    padding: 16px;
}

.blog-card-title {
    margin: 0 0 8px 0;
    font-size: 1.1rem;
    color: var(--primary);
}

.blog-card-title a {
    color: inherit;
}

.blog-card-desc {
    margin: 0;
    color: var(--text-color);
    opacity: 0.9;
    font-size: 0.95rem;
    line-height: 1.5;
    /* Clamp to 3 lines with ellipsis (best-effort cross-browser) */
    display: -webkit-box;
    display: box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    max-height: calc(1.5em * 3);
}

.blog-card-footer {
    padding: 0 16px 16px 16px;
    margin-top: auto;
}

.blog-card-cta {
    display: inline-block;
    padding: 10px 14px;
    background: var(--accent);
    color: #fff;
    border-radius: 6px;
    font-weight: 600;
}

.blog-card-cta:hover {
    opacity: 0.92;
}

.container {
    width: 90%;
    max-width: var(--max-width);
    margin: 0 auto; /* Changed from 'auto' to '0 auto' for clarity */
    padding: 40px 20px; /* Increased vertical padding */
}

/* Header Styles */
body > header {
    background: var(--primary);
    color: var(--secondary);
    padding: 16px 0;
    position: fixed;
    width: 100%;
    top: 0;
    left: 0; /* Ensure it spans full width */
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    font-family: 'Inter', sans-serif;
    font-weight: 500;
}

/* Reset header styles inside cards */
article header,
.spotlight-card header,
.package-card header {
    background: transparent;
    color: inherit;
    padding: 0;
    position: static;
    width: auto;
    box-shadow: none;
    z-index: auto;
}

body > header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    padding: 0 20px; /* Remove vertical padding from header container */
    max-width: var(--max-width); /* Ensure header container respects max-width */
    margin: 0 auto; /* Center header container */
}

body > header .logo h1 { /* Added a logo class for better structure */
    font-size: 1.5rem;
    margin: 0;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    color: var(--secondary); /* Ensure logo text color is correct */
}

body > header .logo a { /* Ensure logo link inherits color */
    color: inherit;
    text-decoration: none;
}


body > header nav {
    display: flex;
    align-items: center;
    gap: 28px;
}

body > header nav ul {
    display: flex;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 24px;
}

body > header nav ul li {
    margin-left: 0;
}

body > header nav ul li a {
    color: var(--secondary);
    text-decoration: none;
    font-size: 1rem;
    padding: 8px 0;
    transition: color 0.3s ease;
    position: relative; /* For underline effect */
}

body > header nav ul li a:hover {
    color: var(--accent);
}

body > header nav ul li.current a { /* Style for the current page link */
    color: var(--accent);
    font-weight: 600;
}

body > header nav ul li.current a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--accent);
}

.menu-toggle {
    display: none; /* Hidden by default, shown in media query */
    background: none;
    border: none;
    color: var(--secondary);
    font-size: 1.8rem; /* Slightly larger */
    cursor: pointer;
    transition: color 0.3s ease;
    padding: 5px; /* Add some padding */
    line-height: 1; /* Prevent extra space */
}

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

/* Section Styling */
section {
    padding: 60px 0; /* Standard vertical padding for sections */
}

section:nth-of-type(even) { /* Optional alternating background */
    background-color: #fdfdfd; /* Slightly off-white for visual separation */
}

h2.section-title { /* Consistent section titles */
    text-align: center;
    font-family: 'Playfair Display', serif;
    font-size: clamp(2rem, 5vw, 2.8rem); /* Responsive font size */
    margin-bottom: 40px;
    color: var(--primary);
    position: relative;
    padding-bottom: 10px;
}

h2.section-title::after { /* Underline effect for titles */
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--accent);
}


/* Showcase Section (Home Page Specific) */
#showcase {
    background: linear-gradient(135deg, rgba(10, 25, 47, 0.94), rgba(10, 25, 47, 0.82));
    padding: 140px 0 110px;
    margin-top: -68px;
    color: var(--secondary);
}

#showcase .container {
    padding: 0 20px;
}

.hero-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    align-items: center;
    gap: 48px;
}

.hero-copy {
    display: flex;
    flex-direction: column;
    gap: 24px;
    text-align: left;
}

#showcase h1 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2.8rem, 6vw, 4.2rem);
    margin: 0;
    font-weight: 700;
    line-height: 1.15;
}

#showcase p {
    font-size: clamp(1.05rem, 2.6vw, 1.3rem);
    max-width: 560px;
    margin: 0;
    line-height: 1.7;
    opacity: 0.92;
}


.hero-copy .hero-actions {
    justify-content: flex-start;
}

.hero-trustband {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 16px;
    color: rgba(230, 241, 255, 0.78);
}

.hero-trustband span {
    background: rgba(230, 241, 255, 0.12);
    border: 1px solid rgba(230, 241, 255, 0.2);
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 0.85rem;
    letter-spacing: 0.4px;
}

.hero-points {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hero-points li {
    display: flex;
    gap: 12px;
    align-items: center;
    color: rgba(230, 241, 255, 0.82);
    font-weight: 500;
}

.hero-points li::before {
    content: '✓';
    display: inline-flex;
    width: 24px;
    height: 24px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(0, 184, 148, 0.18);
    color: var(--secondary);
    font-size: 0.8rem;
}

.hero-visual {
    position: relative;
    justify-self: center;
    max-width: 380px;
}

.hero-image-frame {
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 25px 55px rgba(10, 25, 47, 0.35);
    position: relative;
}

.hero-image-frame::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(10, 25, 47, 0) 0%, rgba(10, 25, 47, 0.45) 100%);
}

.hero-visual img {
    width: 100%;
    display: block;
    filter: saturate(1.05);
}

.hero-metric {
    position: absolute;
    bottom: -26px;
    left: 20px;
    background: #fff;
    color: var(--primary);
    padding: 20px 24px;
    border-radius: 16px;
    box-shadow: 0 18px 45px rgba(10, 25, 47, 0.18);
    display: inline-flex;
    flex-direction: column;
    gap: 4px;
    min-width: 180px;
}

.hero-metric .metric-value {
    font-size: 1.6rem;
    font-weight: 700;
}

.hero-metric .metric-label {
    font-size: 0.9rem;
    color: rgba(10, 25, 47, 0.7);
}

/* Enhanced CTA Button Styles for Conversion Optimization */
.cta-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%);
    color: #fff;
    border: none;
    padding: 14px 32px;
    border-radius: var(--border-radius-md);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(0, 184, 148, 0.3);
    letter-spacing: 0.3px;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.cta-button:hover::before {
    left: 100%;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 184, 148, 0.4);
    background: linear-gradient(135deg, var(--accent-hover) 0%, var(--accent) 100%);
}

.cta-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(0, 184, 148, 0.3);
}

.cta-button:focus-visible {
    outline: 3px solid rgba(0, 184, 148, 0.5);
    outline-offset: 2px;
}

/* Secondary CTA Button */
.cta-button.cta-secondary {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
    box-shadow: none;
}

.cta-button.cta-secondary:hover {
    background: var(--primary);
    color: var(--secondary);
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(10, 25, 47, 0.2);
}

/* Hero-specific CTA adjustments */
#showcase .cta-button {
    padding: 16px 36px;
    font-size: 1.1rem;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%);
}

#showcase .cta-button.cta-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--secondary);
    border-color: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
}

#showcase .cta-button.cta-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: var(--secondary);
    color: var(--secondary);
}

/* Conversion Optimization Elements */
.conversion-indicator {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 184, 148, 0.1);
    border: 1px solid rgba(0, 184, 148, 0.2);
    border-radius: var(--border-radius-full);
    padding: 6px 12px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--accent);
    margin-top: 12px;
}

.conversion-indicator::before {
    content: '⚡';
    font-size: 0.9rem;
}

.trust-signal {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(10, 25, 47, 0.08);
    border-radius: var(--border-radius-full);
    padding: 4px 10px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--primary);
    margin: 4px;
}

.trust-signal::before {
    content: '✓';
    color: var(--accent);
    font-weight: 700;
}

/* Urgency Element */
.urgency-element {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
    border-radius: var(--border-radius-full);
    padding: 4px 12px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.urgency-element::before {
    content: '🔥';
    font-size: 0.9rem;
}

/* Enhanced Social Proof */
.social-proof-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--card-bg);
    border: 1px solid rgba(10, 25, 47, 0.1);
    border-radius: var(--border-radius-lg);
    padding: 12px 16px;
    box-shadow: var(--shadow-subtle);
    margin: 8px;
}

.social-proof-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent);
}

.social-proof-text {
    font-size: 0.85rem;
    color: var(--text-color);
    line-height: 1.3;
}

.social-proof-author {
    font-weight: 600;
    color: var(--primary);
}

/* Portfolio-specific button styles */
#portfolio-projects .card-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(10, 25, 47, 0.08);
}

#portfolio-projects .cta-button {
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    color: var(--accent);
    border: 1px solid var(--accent);
    padding: 10px 20px;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    text-transform: none;
    letter-spacing: normal;
}

#portfolio-projects .cta-button:hover {
    background: rgba(100, 255, 218, 0.1);
    color: var(--secondary);
    border-color: var(--secondary);
}

#portfolio-projects .view-details-button {
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    color: var(--primary);
    border: 1px solid var(--primary);
    padding: 10px 20px;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

#portfolio-projects .view-details-button:hover {
    background: rgba(10, 25, 47, 0.05);
    color: var(--accent);
    border-color: var(--accent);
}

/* Placeholder Styles */
.placeholder-section {
    text-align: center;
    padding: 40px 20px;
    background-color: #eee;
    border: 1px dashed #ccc;
    border-radius: 8px;
    margin-bottom: 40px;
}

.placeholder-section p {
    color: #666;
    font-style: italic;
}

.placeholder-image {
    background-color: #ddd;
    border: 1px solid #ccc;
    color: #888;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 0.9rem;
    min-height: 150px; /* Example height */
    width: 100%;
    margin-bottom: 15px;
}

/* Grid Styles (Used in Portfolio, Services, About) */
.grid {
    display: grid;
    gap: 30px; /* Consistent gap */
}

.grid-cols-2 {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); /* Responsive 2-ish columns */
}

.grid-cols-3 {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); /* Responsive 3-ish columns */
}

/* Card Style (Used for Projects, Services, etc.) */
.card {
    background: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
    border: 1px solid rgba(10, 25, 47, 0.08);
    display: flex; /* Use flexbox for content alignment */
    flex-direction: column; /* Stack content vertically */
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    border-color: var(--accent);
}

.card-image img {
    width: 100%;
    height: 220px; /* Consistent image height */
    object-fit: cover;
    transition: transform 0.3s ease;
}

.card:hover .card-image img {
    transform: scale(1.03);
}

.card-content {
    padding: 24px;
    flex-grow: 1; /* Allow content to fill space */
    display: flex;
    flex-direction: column;
}

.card-content h3, .card-content h4 {
    margin-top: 0;
    font-size: 1.25rem;
    margin-bottom: 12px;
    color: var(--primary);
    font-weight: 600;
}

.card-content p {
    margin-bottom: 16px; /* Space below paragraph */
    color: var(--text-color);
    opacity: 0.85;
    font-size: 0.95rem;
    line-height: 1.6;
    flex-grow: 1; /* Push actions to bottom */
}

.card-actions {
    margin-top: auto; /* Push actions to the bottom */
    padding-top: 16px;
}


/* --- Portfolio Specific Styles --- */
#portfolio-filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    background: var(--card-bg);
    padding: 16px 20px;
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    position: sticky;
    top: 20px;
    z-index: 30;
}

.filter-button {
    appearance: none;
    background: #f3f6fb;
    color: var(--primary);
    border: 1px solid rgba(10, 25, 47, 0.12);
    padding: 10px 18px;
    border-radius: 999px;
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.3px;
    cursor: pointer;
    transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.filter-button:hover,
.filter-button:focus {
    background: rgba(0, 184, 148, 0.12);
    border-color: rgba(0, 184, 148, 0.4);
    color: var(--primary);
    outline: none;
    box-shadow: 0 6px 18px rgba(10, 25, 47, 0.08);
}

.filter-button.active {
    background: var(--primary);
    color: var(--secondary);
    border-color: var(--primary);
    box-shadow: 0 10px 24px rgba(10, 25, 47, 0.18);
}

.project-category-label {
    display: inline-block;
    background-color: var(--accent);
    color: #fff;
    font-size: 0.75rem;
    padding: 3px 8px;
    border-radius: 12px;
    margin-bottom: 10px;
    font-weight: 500;
}

/* Style the link *inside* the label for contrast */
.card-content .project-category-label a,
.project-category-label a {
    color: #fff !important; /* White text to contrast with accent background */
    text-decoration: none;
}

.card-content .project-category-label a:hover,
.project-category-label a:hover {
    color: #e6f1ff !important; /* Slightly lighter on hover */
    text-decoration: underline;
}

/* Ensure project cards handle display toggling for filtering */
.projects-grid .project {
    display: flex; /* Assuming card uses flex direction column */
    flex-direction: column;
     /* If not using flex, ensure it's at least display: block; for show/hide */
     /* The JavaScript will set display: none; when filtered out */
}


/* Skills Section (About Page) */
#skills ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
    padding: 0;
    list-style-type: none;
    max-width: 800px;
    margin: 40px auto 0; /* Add margin top */
}

#skills li {
    background: var(--card-bg);
    padding: 10px 20px; /* Adjusted padding */
    border-radius: 30px;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
    border: 1px solid rgba(10, 25, 47, 0.1);
    font-size: 0.9rem;
    color: var(--primary);
    font-weight: 500;
}

#skills li:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
    border-color: var(--accent);
    color: var(--accent);
    background-color: rgba(100, 255, 218, 0.05); /* Subtle background on hover */
}

/* Contact Section/Page */
#contact-section, /* Renamed from #contact */
.contact-page { /* Class for the contact page body/main container */
    background-color: var(--primary);
    color: var(--secondary);
    padding: 80px 0;
}

#contact-section .container,
.contact-page .container {
    text-align: center;
    max-width: 960px;
}

#contact-section h2,
.contact-page h2.section-title {
    color: var(--secondary); /* Override default section title color */
}

#contact-section h2::after,
.contact-page h2.section-title::after {
    background-color: var(--accent); /* Ensure underline uses accent */
}


#contact-section p,
.contact-page p {
    margin-bottom: 25px; /* Consistent spacing */
    font-size: 1.1rem;
    line-height: 1.6;
}

#contact-section a,
.contact-page a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    word-break: break-word; /* Prevent long links overflowing */
}

#contact-section a:hover,
.contact-page a:hover {
    text-decoration: underline;
}

/* Contact Cards */
.contact-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    max-width: 900px;
    margin: 0 auto;
}

.contact-card {
    background: rgba(230, 241, 255, 0.08);
    border: 1px solid rgba(230, 241, 255, 0.15);
    border-radius: 16px;
    padding: 40px 30px;
    text-align: center;
    text-decoration: none;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.contact-card:hover {
    background: rgba(230, 241, 255, 0.12);
    border-color: var(--accent);
    transform: translateY(-5px);
    text-decoration: none;
}

.contact-card-icon {
    width: 70px;
    height: 70px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    transition: transform 0.3s ease;
}

.contact-card:hover .contact-card-icon {
    transform: scale(1.1);
}

.contact-card-icon i {
    font-size: 1.8rem;
    color: var(--primary);
}

.contact-card h3 {
    color: var(--secondary);
    font-size: 1.3rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.contact-card p {
    color: rgba(230, 241, 255, 0.8);
    font-size: 0.95rem;
    margin-bottom: 15px;
    word-break: break-word;
}

.contact-card-action {
    color: var(--accent);
    font-weight: 500;
    font-size: 0.9rem;
    margin-top: auto;
    transition: color 0.3s ease;
}

.contact-card:hover .contact-card-action {
    color: var(--secondary);
}

/* Basic Form Styles (Contact Page) */
.contact-form {
    margin-top: 40px;
    text-align: left;
}

.form-banner {
    background: rgba(0, 184, 148, 0.12);
    border: 1px solid rgba(0, 184, 148, 0.25);
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 20px;
    color: rgba(10, 25, 47, 0.75);
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--secondary); /* Label color on dark background */
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border-radius: 4px;
}

/* PDF Modal Styles */
.pdf-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    overflow: auto;
    transition: opacity 0.3s ease;
    backdrop-filter: blur(4px);
    /* Ensure modal is always scrollable from top */
    padding-top: 20px;
    padding-bottom: 20px;
    box-sizing: border-box;
}

.pdf-modal-content {
    background-color: var(--card-bg);
    margin: 0 auto;
    padding: 20px;
    border-radius: 12px;
    width: 90%;
    max-width: 1000px;
    max-height: 85vh;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
    position: relative;
    animation: modalFadeIn 0.3s ease;
    overflow: hidden;
    /* Ensure content stays visible */
    margin-top: 20px;
    margin-bottom: 20px;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: translateY(-20px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.pdf-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
    background: var(--bg-light);
    margin: -20px -20px 20px -20px;
    padding: 20px;
    border-radius: 12px 12px 0 0;
}

.pdf-modal-header h2 {
    margin: 0;
    color: var(--primary);
    font-size: 1.4rem;
    font-weight: 600;
}

.close-modal {
    color: var(--primary);
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    background: none;
    border: none;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.1);
}

.close-modal:hover {
    color: var(--accent);
    background-color: rgba(0, 184, 148, 0.1);
    transform: scale(1.1);
}

.pdf-modal-body {
    width: 100%;
    height: calc(100% - 80px);
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Enhanced PDF iframe styles for better security and viewability */
#pdf-iframe {
    width: 100%;
    height: 600px;
    border: none;
    background-color: white;
    /* Prevent right-click context menu on iframe */
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Prevent text selection and context menu on the modal itself */
.pdf-modal {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.pdf-modal * {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Allow text selection in header */
.pdf-modal-header,
.pdf-modal-header * {
    -webkit-user-select: text;
    -khtml-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}

/* Mobile responsiveness for PDF modal */
@media (max-width: 768px) {
    .pdf-modal-content {
        width: 95%;
        margin: 10px auto;
        max-height: 90vh;
    }
    
    .pdf-modal-header {
        margin: -20px -20px 15px -20px;
        padding: 15px 20px;
    }
    
    .pdf-modal-header h2 {
        font-size: 1.2rem;
    }
    
    .close-modal {
        width: 36px;
        height: 36px;
        font-size: 24px;
    }
    
    #pdf-iframe {
        height: 500px;
    }
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    background-color: rgba(230, 241, 255, 0.1);
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

.form-actions {
    text-align: center; /* Center the submit button */
    margin-top: 30px;
}

/* Footer Styles */
footer {
    background-color: var(--primary);
    color: rgba(230, 241, 255, 0.7); /* Lighter text for footer */
    text-align: center;
    padding: 30px 20px;
    margin-top: auto; /* Push footer to bottom if content is short */
    font-size: 0.9rem;
}

footer p {
    margin: 0;
}

footer a {
    color: var(--accent);
}

footer a:hover {
    text-decoration: underline;
}

/* Social Media Links (Placeholder) */
.social-links {
    margin-top: 20px;
    padding: 0;
    list-style: none;
    display: flex;
    justify-content: center;
    gap: 20px;
}

/* Impact Metrics Section */
.metric-card {
    background: var(--card-bg);
    border-radius: 8px;
    padding: 25px 20px; /* Adjusted padding */
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
    border: 1px solid rgba(10, 25, 47, 0.1);
    position: relative; /* Needed for pseudo-element */
    overflow: hidden; /* Hide overflow from pseudo-element */
    border-left: 5px solid var(--accent); /* Add accent border */
}

.metric-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    border-color: var(--accent);
}

.metric-value {
    font-size: clamp(2rem, 5vw, 2.5rem); /* Responsive font size */
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 8px; /* Adjusted margin */
    line-height: 1.1;
}
/* Style for the units added in HTML (e.g., /5, %) */
.metric-value span {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-color);
    opacity: 0.7;
    margin-left: 2px;
}

.metric-label {
    font-size: 0.95rem; /* Slightly smaller label */
    color: var(--text-color);
    opacity: 0.85;
    position: relative; /* Ensure label is above pseudo-element */
    z-index: 2;
}

/* Visual Fill for Score/Percentage Cards */
.metric-card[data-type="score"]::before,
.metric-card[data-type="percentage"]::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: rgba(0, 184, 148, 0.1); /* Accent color with low opacity */
    z-index: 1;
    transition: height 0.5s ease-out;
}

/* Specific heights based on current values */
.metric-card[data-value="4.8"][data-max="5"]::before { height: calc(4.8 / 5 * 100%); }
.metric-card[data-value="85"][data-max="100"]::before { height: 85%; }
.metric-card[data-value="42"][data-max="100"]::before { height: 42%; }
.metric-card[data-value="35"][data-max="100"]::before { height: 35%; }
.metric-card[data-value="28"][data-max="100"]::before { height: 28%; }

.grid-cols-4 {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
}

/* Social Media Links */
.social-links li a {
    color: var(--secondary);
    font-size: 1.5rem; /* Icon size */
    transition: color 0.3s ease;
}

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


/* Enhanced Mobile Navigation Styles */
@media (max-width: 768px) {
    /* Base Mobile Adjustments */
    body {
        padding-top: var(--mobile-header-height);
    }

    body > header {
        padding: var(--space-sm) 0;
        backdrop-filter: blur(10px);
        background: rgba(10, 25, 47, 0.95);
    }

    body > header .container {
        padding: 0 var(--space-md);
    }

    /* Enhanced Header Main Layout */
    .header-main {
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
        position: relative;
    }

    /* Enhanced Logo Responsiveness */
    .logo h1 {
        font-size: var(--text-xl);
        line-height: var(--leading-tight);
    }

    /* Enhanced Mobile Menu Toggle */
    .menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 44px; /* Better touch target */
        height: 44px;
        background: rgba(255, 255, 255, 0.1);
        border: 2px solid rgba(255, 255, 255, 0.2);
        border-radius: var(--radius-md);
        color: var(--secondary);
        font-size: 1.5rem;
        cursor: pointer;
        transition: all 0.3s ease;
        position: relative;
        z-index: 1001;
    }

    .menu-toggle:hover,
    .menu-toggle:focus-visible {
        background: rgba(255, 255, 255, 0.2);
        border-color: var(--accent);
        transform: scale(1.05);
    }

    .menu-toggle:active {
        transform: scale(0.95);
    }

    /* Animated Hamburger Icon */
    .menu-toggle::before {
        content: '☰';
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .menu-toggle[aria-expanded="true"]::before {
        content: '✕';
        transform: rotate(180deg);
    }

    /* Enhanced Mobile Navigation Panel */
    body > header nav {
        width: 100%;
        display: none;
        background: rgba(10, 25, 47, 0.98);
        position: fixed;
        top: var(--mobile-header-height);
        left: 0;
        right: 0;
        bottom: 0;
        padding: var(--space-2xl) var(--space-md);
        margin: 0;
        border-top: 1px solid rgba(230, 241, 255, 0.1);
        box-shadow: var(--shadow-xl);
        backdrop-filter: blur(20px);
        z-index: 1000;
        overflow-y: auto;
        animation: slideDownMobile 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    body > header nav.active {
        display: block;
        animation: slideInMobile 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* Mobile Navigation List */
    body > header nav ul {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 0;
        margin: 0;
        list-style: none;
    }

    body > header nav ul li {
        margin: 0;
        width: 100%;
        border-bottom: 1px solid rgba(230, 241, 255, 0.08);
        transform: translateX(-20px);
        opacity: 0;
        animation: slideInListItems 0.3s ease forwards;
    }

    body > header nav ul li:nth-child(1) { animation-delay: 0.1s; }
    body > header nav ul li:nth-child(2) { animation-delay: 0.15s; }
    body > header nav ul li:nth-child(3) { animation-delay: 0.2s; }
    body > header nav ul li:nth-child(4) { animation-delay: 0.25s; }
    body > header nav ul li:nth-child(5) { animation-delay: 0.3s; }
    body > header nav ul li:nth-child(6) { animation-delay: 0.35s; }

    body > header nav ul li:last-child {
        border-bottom: none;
    }

    /* Enhanced Mobile Navigation Links */
    body > header nav ul li a {
        display: block;
        padding: var(--space-md) var(--space-sm);
        width: 100%;
        color: var(--secondary);
        text-decoration: none;
        font-size: var(--text-lg);
        font-weight: 500;
        border-radius: var(--radius-md);
        transition: all 0.3s ease;
        position: relative;
        min-height: 44px; /* Minimum touch target */
        display: flex;
        align-items: center;
    }

    body > header nav ul li a:hover,
    body > header nav ul li a:focus-visible {
        background: rgba(0, 184, 148, 0.15);
        color: var(--accent);
        transform: translateX(8px);
        box-shadow: var(--shadow-md);
    }

    body > header nav ul li.current a {
        background: var(--accent);
        color: #fff;
        font-weight: 600;
    }

    body > header nav ul li.current a::after {
        display: none;
    }

    /* Enhanced Mobile CTA Button */
    body > header nav .header-cta {
        display: flex;
        margin: var(--space-2xl) 0 0;
        text-align: center;
        justify-content: center;
        align-items: center;
        padding: var(--space-md) var(--space-xl);
        background: linear-gradient(135deg, var(--accent), var(--accent-hover));
        color: white;
        border-radius: var(--radius-full);
        font-weight: 600;
        font-size: var(--text-lg);
        box-shadow: var(--shadow-lg);
        transform: translateY(20px);
        opacity: 0;
        animation: slideInCTA 0.5s ease 0.4s forwards;
        border: none;
        text-decoration: none;
    }

    body > header nav .header-cta:hover {
        transform: translateY(-2px);
        box-shadow: var(--shadow-xl);
    }

    /* Mobile Animations */
    @keyframes slideInMobile {
        from {
            transform: translateX(100%);
            opacity: 0;
        }
        to {
            transform: translateX(0);
            opacity: 1;
        }
    }

    @keyframes slideDownMobile {
        from {
            transform: translateY(-20px);
            opacity: 0;
        }
        to {
            transform: translateY(0);
            opacity: 1;
        }
    }

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

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

    /* Mobile Overlay */
    .mobile-nav-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        backdrop-filter: blur(4px);
        z-index: 999;
    }

    .mobile-nav-overlay.active {
        display: block;
        animation: fadeIn 0.3s ease;
    }

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

    /* Enhanced Mobile Layout Adjustments */
    .footer-cta {
        flex-direction: column;
        align-items: stretch;
        gap: var(--space-lg);
        padding: var(--space-2xl) var(--space-md);
        text-align: center;
        border-radius: var(--radius-lg);
        margin-bottom: var(--space-lg);
    }

    .footer-cta .cta-button {
        width: 100%;
        padding: var(--space-md) var(--space-lg);
    }

    #showcase {
        padding: var(--space-4xl) 0 var(--space-2xl);
        margin-top: calc(-1 * var(--mobile-header-height));
    }

    .hero-grid {
        grid-template-columns: 1fr;
        gap: var(--space-xl);
    }

    .hero-copy {
        text-align: center;
        align-items: center;
        gap: var(--space-lg);
    }

    .hero-copy .hero-actions {
        justify-content: center;
        flex-direction: column;
        gap: var(--space-md);
    }

    .hero-actions .cta-button {
        width: 100%;
        max-width: 280px;
    }

    .hero-points {
        align-items: center;
        text-align: left;
    }

    .hero-visual {
        max-width: 320px;
        margin: 0 auto;
    }

    .hero-metric {
        left: var(--space-sm);
        right: var(--space-sm);
        bottom: calc(-1 * var(--space-md));
        align-items: center;
        text-align: center;
        padding: var(--space-md);
    }

    .grid-cols-2, .grid-cols-3 {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }

    .card-image img {
        height: 200px;
    }

    .card-content {
        padding: var(--space-lg);
    }

    #skills ul {
        justify-content: center;
        gap: var(--space-sm);
    }

    #skills li {
        padding: var(--space-sm) var(--space-md);
        font-size: var(--text-sm);
    }

    #contact-section,
    .contact-page {
        padding: var(--space-2xl) 0;
    }

    .contact-cards {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .contact-card {
        padding: 30px 25px;
    }

    .contact-card-icon {
        width: 60px;
        height: 60px;
    }

    .contact-card-icon i {
        font-size: 1.5rem;
    }

    footer {
        padding: var(--space-lg) var(--space-md);
        font-size: var(--text-sm);
    }

    /* Touch-Friendly Spacing */
    button,
    a,
    input,
    textarea {
        min-height: 44px;
        min-width: 44px;
    }

    /* Enhanced Mobile Typography */
    h1 {
        font-size: clamp(var(--text-3xl), 8vw, var(--text-4xl));
        line-height: var(--leading-tight);
    }

    h2 {
        font-size: clamp(var(--text-2xl), 6vw, var(--text-3xl));
        line-height: var(--leading-snug);
    }

    p {
        font-size: var(--text-base);
        line-height: var(--leading-relaxed);
    }
}

/* Force 3 columns for projects grid on larger screens */
@media (min-width: 769px) {
    #portfolio-projects .projects-grid { /* Target the specific grid */
        grid-template-columns: repeat(3, 1fr); /* Force exactly 3 columns */
    }
}

/* Dark Mode (Optional - can be toggled via JS) */
body.dark-mode {
    --primary: #e6f1ff; /* Light primary for dark mode */
    --secondary: #0a192f; /* Dark secondary for dark mode */
    --accent: #ffab70; /* Different accent for dark mode */
    --bg: #0a192f; /* Dark background */
    --text-color: #e6f1ff; /* Light text */
    --card-bg: #112240; /* Darker card background */
    --card-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    --table-header-bg: #1a3a6e;
    --table-header-text: #e6f1ff;
    --table-first-col-bg: #112240;
    --table-first-col-text: #e6f1ff;
}

body.dark-mode header {
    background: var(--secondary); /* Use dark secondary for header */
    color: var(--primary); /* Use light primary for header text */
}

body.dark-mode header nav ul li a {
    color: var(--primary);
}

body.dark-mode header nav ul li a:hover,
body.dark-mode header nav ul li.current a {
    color: var(--accent);
}

body.dark-mode header nav ul li.current a::after {
     background: var(--accent);
}

body.dark-mode .menu-toggle {
    color: var(--primary);
}
body.dark-mode .menu-toggle:hover {
    color: var(--accent);
}

body.dark-mode h2.section-title {
    color: var(--primary);
}

body.dark-mode h2.section-title::after {
     background-color: var(--accent);
}

body.dark-mode section:nth-of-type(even) {
    background-color: #112240; /* Slightly lighter dark background */
}

body.dark-mode #showcase {
     background: linear-gradient(rgba(10, 25, 47, 0.95), rgba(10, 25, 47, 0.85)), url('../images/dafghif_cover.png') no-repeat center center/cover; /* Darker overlay */
     color: var(--primary);
}

body.dark-mode .cta-button {
    color: var(--accent);
    border-color: var(--accent);
}

body.dark-mode .cta-button:hover {
    background: rgba(255, 171, 112, 0.1); /* Use dark mode accent color */
    color: var(--primary);
    border-color: var(--primary);
}

body.dark-mode .card {
    background: var(--card-bg);
    border-color: rgba(230, 241, 255, 0.1);
}

body.dark-mode .card:hover {
     border-color: var(--accent);
}

body.dark-mode .card-content h3,
body.dark-mode .card-content h4 {
    color: var(--primary);
}

body.dark-mode .card-content p {
    color: var(--primary);
    opacity: 0.8;
}

body.dark-mode #skills li {
    background: var(--card-bg);
    border-color: rgba(230, 241, 255, 0.1);
    color: var(--primary);
}

body.dark-mode #skills li:hover {
    border-color: var(--accent);
    color: var(--accent);
    background-color: rgba(255, 171, 112, 0.05);
}

body.dark-mode #contact-section,
body.dark-mode .contact-page {
    background-color: var(--secondary); /* Dark background */
    color: var(--primary); /* Light text */
}

body.dark-mode #contact-section h2,
body.dark-mode .contact-page h2.section-title {
    color: var(--primary);
}

body.dark-mode #contact-section h2::after,
body.dark-mode .contact-page h2.section-title::after {
    background-color: var(--accent);
}

body.dark-mode #contact-section a,
body.dark-mode .contact-page a {
    color: var(--accent);
}

body.dark-mode .contact-card {
    background: rgba(10, 25, 47, 0.3);
    border-color: rgba(10, 25, 47, 0.4);
}

body.dark-mode .contact-card:hover {
    background: rgba(10, 25, 47, 0.5);
    border-color: var(--accent);
}

body.dark-mode .contact-card h3 {
    color: var(--primary);
}

body.dark-mode .contact-card p {
    color: rgba(10, 25, 47, 0.7);
}

body.dark-mode .form-group label {
    color: var(--primary);
}

body.dark-mode .form-group input[type="text"],
body.dark-mode .form-group input[type="email"],
body.dark-mode .form-group textarea {
    border-color: rgba(230, 241, 255, 0.2);
    background-color: rgba(10, 25, 47, 0.3); /* Darker input background */
    color: var(--primary);
}

body.dark-mode .form-group input[type="text"]:focus,
body.dark-mode .form-group input[type="email"]:focus,
body.dark-mode .form-group textarea:focus {
    border-color: var(--accent);
    background-color: rgba(10, 25, 47, 0.5);
}

body.dark-mode footer {
    background-color: var(--secondary);
    color: rgba(230, 241, 255, 0.6);
}

body.dark-mode footer a {
    color: var(--accent);
}

body.dark-mode .social-links li a {
    color: var(--primary);
}

body.dark-mode .social-links li a:hover {
    color: var(--accent);
}

/* Modal styles - Extracted and slightly refactored */
.modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(10, 25, 47, 0.7); /* Use primary color with alpha */
    padding-top: 5vh; /* Add padding top */
}

.modal-content {
    background-color: var(--bg);
    margin: 0 auto; /* Center horizontally */
    padding: 32px;
    border: none;
    width: 90%;
    max-width: 800px; /* Limit max width */
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(10, 25, 47, 0.2);
    position: relative; /* Needed for close button positioning */
    max-height: 90vh; /* Limit height */
    overflow-y: auto; /* Allow scrolling within modal */
}

.modal-header { /* Simplified modal header */
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(10, 25, 47, 0.1);
    margin-bottom: 24px;
}

.modal-header h2 {
    margin: 0;
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    color: var(--primary);
    line-height: 1.3;
}

.modal .close {
    color: var(--primary);
    font-size: 2rem; /* Larger close button */
    font-weight: bold;
    transition: all 0.3s ease;
    background: none; /* Remove potential background */
    border: none; /* Remove potential border */
    padding: 0 8px; /* Adjust padding */
    line-height: 1; /* Ensure proper alignment */
    cursor: pointer;
}

.modal .close:hover,
.modal .close:focus {
    color: var(--accent);
    transform: scale(1.1);
}

.modal-body {
    display: flex;
    flex-direction: column;
    gap: 24px;
    color: var(--text-color); /* Ensure body text color is correct */
}

/* Styles for project detail sections within modal */
.program-phase {
    background-color: rgba(10, 25, 47, 0.03);
    padding: 20px;
    border-radius: 8px;
    border: 1px solid rgba(10, 25, 47, 0.1);
}

.program-phase h3 {
    color: var(--primary);
    margin-top: 0;
    margin-bottom: 16px;
    font-size: 1.3rem;
}

.phase-content {
    display: grid; /* Use grid for side-by-side layout */
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); /* Responsive columns */
    gap: 20px;
}

.phase-section h4 {
    color: var(--primary);
    font-weight: 600;
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1rem;
}

.phase-section ul {
    padding-left: 20px;
    margin: 0;
    list-style-type: disc; /* Ensure bullets are visible */
}

.phase-section li {
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: var(--text-color);
    opacity: 0.9;
}

.phase-section a { /* Link styling within modal */
    color: var(--accent);
    text-decoration: underline;
}

.phase-section a:hover {
    color: #52cca7;
}

/* Dark mode modal adjustments */
body.dark-mode .modal {
     background-color: rgba(10, 25, 47, 0.85);
}

body.dark-mode .modal-content {
    background-color: var(--card-bg); /* Use dark card background */
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

body.dark-mode .modal-header {
    border-bottom-color: rgba(230, 241, 255, 0.15);
}

body.dark-mode .modal-header h2 {
    color: var(--primary);
}

body.dark-mode .modal .close {
    color: var(--primary);
}

body.dark-mode .modal .close:hover,
body.dark-mode .modal .close:focus {
    color: var(--accent);
}

body.dark-mode .modal-body {
    color: var(--primary);
}

body.dark-mode .program-phase {
    background-color: rgba(10, 25, 47, 0.3); /* Darker phase background */
    border-color: rgba(230, 241, 255, 0.1);
}

body.dark-mode .program-phase h3 {
    color: var(--primary);
}

body.dark-mode .phase-section h4 {
    color: var(--primary);
}

body.dark-mode .phase-section li {
    color: var(--primary);
    opacity: 0.85;
}

body.dark-mode .phase-section a {
    color: var(--accent);
}

body.dark-mode .phase-section a:hover {
    color: #ffc799; /* Lighter accent for dark mode hover */
}


/* Enhanced Micro-Interactions & Scroll Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes shimmer {
    0% {
        background-position: -200px 0;
    }
    100% {
        background-position: calc(200px + 100%) 0;
    }
}

/* Scroll Animation Classes */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

.animate-fade-left {
    opacity: 0;
    transform: translateX(-30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-fade-left.animated {
    opacity: 1;
    transform: translateX(0);
}

.animate-fade-right {
    opacity: 0;
    transform: translateX(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-fade-right.animated {
    opacity: 1;
    transform: translateX(0);
}

.animate-scale {
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-scale.animated {
    opacity: 1;
    transform: scale(1);
}

/* Staggered Animation Delays */
.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }
.animate-delay-4 { animation-delay: 0.4s; }
.animate-delay-5 { animation-delay: 0.5s; }

/* Enhanced Card Hover Effects */
.card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--accent);
}

.card:hover .card-image img {
    transform: scale(1.05);
}

/* Floating Animation for Hero Elements */
.hero-float {
    animation: float 6s ease-in-out infinite;
}

.hero-float-delayed {
    animation: float 6s ease-in-out infinite;
    animation-delay: 3s;
}

/* Loading States */
.loading-shimmer {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200px 100%;
    animation: shimmer 1.5s infinite;
}

/* Interactive Elements */
.interactive-element {
    transition: all 0.2s ease;
    cursor: pointer;
}

.interactive-element:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.interactive-element:active {
    transform: translateY(0);
    transition-duration: 0.1s;
}

/* Button Ripple Effect */
.btn-ripple {
    position: relative;
    overflow: hidden;
}

.btn-ripple::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s;
}

.btn-ripple:active::after {
    width: 300px;
    height: 300px;
}

/* Scroll Progress Indicator */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(90deg, var(--accent), var(--accent-light));
    z-index: 9999;
    transition: width 0.1s ease;
}

/* Parallax Effect */
.parallax-element {
    transform: translateZ(0);
    will-change: transform;
}

/* Image Zoom on Hover */
.image-zoom {
    overflow: hidden;
    position: relative;
}

.image-zoom img {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* Text Gradient Animation */
.gradient-text {
    background: linear-gradient(-45deg, var(--accent), var(--accent-light), var(--primary), var(--secondary));
    background-size: 400% 400%;
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 8s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Intersection Observer Classes */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal-left.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal-right.active {
    opacity: 1;
    transform: translateX(0);
}

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

.mb-1 { margin-bottom: var(--space-sm); }
.mb-2 { margin-bottom: var(--space-md); }
.mb-3 { margin-bottom: var(--space-lg); }
.mb-4 { margin-bottom: var(--space-xl); }
.mb-5 { margin-bottom: var(--space-2xl); }
.mt-1 { margin-top: var(--space-sm); }
.mt-2 { margin-top: var(--space-md); }
.mt-3 { margin-top: var(--space-lg); }
.mt-4 { margin-top: var(--space-xl); }
.mt-5 { margin-top: var(--space-2xl); }

.p-1 { padding: var(--space-sm); }
.p-2 { padding: var(--space-md); }
.p-3 { padding: var(--space-lg); }
.p-4 { padding: var(--space-xl); }
.p-5 { padding: var(--space-2xl); }

.px-1 { padding-left: var(--space-sm); padding-right: var(--space-sm); }
.px-2 { padding-left: var(--space-md); padding-right: var(--space-md); }
.px-3 { padding-left: var(--space-lg); padding-right: var(--space-lg); }
.px-4 { padding-left: var(--space-xl); padding-right: var(--space-xl); }

.py-1 { padding-top: var(--space-sm); padding-bottom: var(--space-sm); }
.py-2 { padding-top: var(--space-md); padding-bottom: var(--space-md); }
.py-3 { padding-top: var(--space-lg); padding-bottom: var(--space-lg); }
.py-4 { padding-top: var(--space-xl); padding-bottom: var(--space-xl); }

/* --- Collaboration Brands Section --- */
#brands .brand-logos-container {
    display: flex;         /* Arrange logos in a row */
    flex-wrap: wrap;       /* Allow logos to wrap */
    justify-content: center; /* Center logos horizontally */
    align-items: center;   /* Align logos vertically */
    gap: 30px;             /* Space between logos */
    padding: 20px 0;       /* Vertical padding */
    /* Override placeholder styles */
    background-color: transparent;
    border: none;
    margin-bottom: 0;
    text-align: center;
}

#brands .brand-logos-container img {
    max-width: 150px;      /* Max width */
    height: auto;          /* Maintain aspect ratio */
    object-fit: contain;   /* Fit logo within bounds */
    /* margin: 0 15px; */ /* Optional: Adjust if 'gap' isn't sufficient */
}
/* --- Shared Section Heading & Links --- */
.section-heading {
    text-align: center;
    max-width: 760px;
    margin: 0 auto 48px;
}

.section-heading p {
    margin-top: 12px;
    color: rgba(0, 0, 0, 0.68);
    font-size: 1.05rem;
}

.section-heading a {
    color: inherit;
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 4px;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 24px;
}

.link-subtle {
    color: inherit;
    font-weight: 500;
    text-decoration: underline;
    text-underline-offset: 6px;
}

.link-subtle:hover {
    color: var(--accent);
}

.header-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 22px;
    background: var(--accent);
    color: #fff;
    border-radius: 999px;
    font-weight: 600;
    box-shadow: 0 12px 28px rgba(0, 184, 148, 0.25);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.header-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 32px rgba(0, 184, 148, 0.28);
    color: #fff;
}

#services-preview {
    padding: 100px 0 90px;
}

/* --- Services Preview Cards --- */
.footer-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 36px 40px;
    background: rgba(230, 241, 255, 0.1);
    border-radius: 20px;
    margin-bottom: 32px;
}

.footer-cta-copy h2 {
    margin: 0 0 8px;
    color: var(--secondary);
}

.footer-cta-copy p {
    margin: 0;
    color: rgba(230, 241, 255, 0.8);
}

.footer-meta {
    border-top: 1px solid rgba(230, 241, 255, 0.2);
    padding-top: 24px;
    text-align: center;
    color: rgba(230, 241, 255, 0.7);
}

.service-inquiry {
    background: #f5f7fb;
}

.service-inquiry-form {
    background: var(--card-bg);
    border-radius: 18px;
    box-shadow: var(--card-shadow);
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.inquiry-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px 24px;
}

.service-inquiry-form label {
    display: flex;
    flex-direction: column;
    font-size: 0.9rem;
    color: rgba(10, 25, 47, 0.85);
    gap: 8px;
}

.service-inquiry-form input,
.service-inquiry-form select,
.service-inquiry-form textarea {
    padding: 12px 14px;
    border-radius: 10px;
    border: 1px solid rgba(10, 25, 47, 0.12);
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    background: #fff;
    color: var(--primary);
}

.service-inquiry-form input:focus,
.service-inquiry-form select:focus,
.service-inquiry-form textarea:focus {
    outline: 2px solid rgba(0, 184, 148, 0.3);
    border-color: rgba(0, 184, 148, 0.5);
}

.service-inquiry-form textarea {
    resize: vertical;
}

.inquiry-full {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.inquiry-note {
    margin: 0;
    font-size: 0.85rem;
    color: rgba(10, 25, 47, 0.6);
}

.service-inquiry-form .cta-button {
    align-self: flex-start;
}

.services-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}

.service-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(0, 184, 148, 0.16), rgba(230, 241, 255, 0.08));
    border: 1px solid rgba(0, 184, 148, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    letter-spacing: 0.8px;
    color: var(--primary);
    font-size: 0.9rem;
}

.service-icon::before {
    content: attr(data-icon);
}

.service-preview-card {
    background: var(--card-bg);
    border-radius: 18px;
    padding: 32px 28px;
    box-shadow: var(--card-shadow);
    display: flex;
    flex-direction: column;
    gap: 18px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.service-preview-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 24px rgba(10, 25, 47, 0.12);
}

.service-metric-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.4px;
    background: rgba(0, 184, 148, 0.12);
    color: var(--primary);
    padding: 6px 14px;
    border-radius: 999px;
    font-weight: 600;
}

.service-preview-card h3 {
    margin: 0;
    font-size: 1.4rem;
    color: var(--primary);
}

.service-preview-card p {
    margin: 0;
    color: rgba(20, 27, 43, 0.85);
}

.service-highlights {
    list-style: disc;
    padding-left: 18px;
    margin: 0;
    color: rgba(20, 27, 43, 0.8);
}

.service-highlights li { margin-bottom: 8px; }

.service-proof {
    margin: 0;
    font-size: 0.95rem;
    color: rgba(20, 27, 43, 0.7);
    font-style: italic;
}

.service-proof span {
    display: block;
    margin-top: 6px;
    font-weight: 600;
    color: rgba(20, 27, 43, 0.8);
}

.service-card-actions {
    margin-top: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.cta-button.cta-secondary {
    background: var(--primary);
    color: var(--secondary);
    border-color: var(--primary);
}

.cta-button.cta-secondary:hover {
    background: #0f2d54;
    color: var(--secondary);
    border-color: #0f2d54;
}

.section-accent {
    background: var(--primary);
    color: var(--secondary);
    padding: 96px 0;
}

.section-accent .section-title {
    color: var(--secondary);
}

.section-accent .cta-button {
    border-color: var(--secondary);
    color: var(--secondary);
}

.section-accent .cta-button:hover {
    background: rgba(230, 241, 255, 0.12);
}

/* --- Testimonial Slider --- */
#testimonials {
    background: #f5f7fb;
    padding: 110px 0;
}

#brands {
    padding: 90px 0;
}

.testimonial-slider {
    position: relative;
    overflow: hidden;
    padding: 0 48px;
}

.testimonial-actions {
    margin-top: 32px;
    text-align: center;
}

.testimonial-actions .link-subtle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.95rem;
    font-weight: 600;
    padding: 10px 18px;
    border-radius: 999px;
    border: 1px solid rgba(10, 25, 47, 0.12);
    background: #f3f6fb;
    transition: background 0.3s ease, border-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}

.testimonial-actions .link-subtle::after {
    content: '>';
    font-size: 1rem;
}

.testimonial-actions .link-subtle:hover,
.testimonial-actions .link-subtle:focus {
    background: rgba(0, 184, 148, 0.12);
    border-color: rgba(0, 184, 148, 0.4);
    color: var(--primary);
    box-shadow: 0 8px 18px rgba(10, 25, 47, 0.08);
}

.testimonial-archive {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 36px;
}

.testimonial-track {
    display: flex;
    gap: 24px;
    transition: transform 0.6s ease;
}

.testimonial-card {
    flex: 0 0 100%;
    background: var(--card-bg);
    border-radius: 18px;
    box-shadow: var(--card-shadow);
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.testimonial-quote {
    font-size: 1.12rem;
    line-height: 1.7;
    color: rgba(20, 27, 43, 0.9);
    margin: 0;
}

.testimonial-footer {
    display: flex;
    align-items: center;
    gap: 16px;
}

.testimonial-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    background: rgba(10, 25, 47, 0.08);
}

.testimonial-avatar.placeholder {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: var(--primary);
}

.testimonial-name {
    margin: 0;
    font-weight: 600;
    color: var(--primary);
}

.testimonial-role {
    margin: 4px 0 0;
    color: rgba(20, 27, 43, 0.7);
    font-size: 0.95rem;
}

.slider-control {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    box-shadow: 0 10px 20px rgba(15, 31, 50, 0.12);
    color: var(--primary);
    font-size: 1.5rem;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.3s ease;
    z-index: 5;
}

.slider-control:hover {
    background: var(--primary);
    color: var(--secondary);
}

[data-slider-prev] {
    left: 0;
}

[data-slider-next] {
    right: 0;
}

.slider-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 32px;
}

.slider-dots button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: none;
    background: rgba(10, 25, 47, 0.2);
    cursor: pointer;
    transition: transform 0.3s ease, background 0.3s ease;
}

.slider-dots button[aria-current="true"] {
    background: var(--accent);
    transform: scale(1.1);
}

/* --- Service Detail Pages --- */
.service-hero,
.service-overview-hero {
    background: linear-gradient(135deg, rgba(10, 25, 47, 0.05), rgba(0, 184, 148, 0.08));
    padding: 120px 0 80px;
}

.service-hero .container,
.service-overview-hero .container {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.service-eyebrow {
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 0.85rem;
    color: var(--accent);
    font-weight: 600;
}

.lead {
    font-size: 1.15rem;
    color: rgba(20, 27, 43, 0.85);
    max-width: 780px;
}

.service-hero-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    background: var(--card-bg);
    padding: 24px;
    border-radius: 18px;
    box-shadow: var(--card-shadow);
}

.service-hero-meta h2 {
    margin-top: 0;
    font-size: 1.1rem;
    color: var(--primary);
}

.service-hero-meta ul {
    padding-left: 18px;
    margin: 0;
    color: rgba(20, 27, 43, 0.8);
    list-style: disc;
}

.service-trustband {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 16px;
    padding: 10px 16px;
    font-size: 0.9rem;
    color: rgba(10, 25, 47, 0.7);
}

.service-trustband span {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(0, 184, 148, 0.08);
}

.service-impact,
.service-overview-impact {
    background: #f7f9fc;
}

.impact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.impact-card {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 28px;
    text-align: center;
    box-shadow: var(--card-shadow);
}

.impact-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 10px;
}

.impact-label {
    display: block;
    color: rgba(20, 27, 43, 0.7);
    font-size: 0.95rem;
}

.feature-grid,
.case-study-list,
.resource-grid,
.faq-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}

.feature-card,
.case-study-list article,
.resource-grid article,
.faq-list article {
    background: var(--card-bg);
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    padding: 24px;
}

.feature-card h3,
.case-study-list h3,
.resource-grid h3,
.faq-list h3 {
    margin-top: 0;
    color: var(--primary);
}

.approach-steps {
    counter-reset: step;
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 24px;
}

.approach-steps li {
    background: var(--card-bg);
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    padding: 28px;
    position: relative;
}

.approach-steps li::before {
    counter-increment: step;
    content: counter(step, decimal-leading-zero);
    position: absolute;
    top: -18px;
    left: 24px;
    background: var(--accent);
    color: #fff;
    border-radius: 999px;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    box-shadow: 0 10px 18px rgba(0, 184, 148, 0.25);
}

.service-cta,
.service-overview-cta {
    background: linear-gradient(135deg, rgba(10, 25, 47, 0.92), rgba(0, 184, 148, 0.75));
    color: #fff;
    padding: 90px 0;
}

.service-cta .cta-button,
.service-overview-cta .cta-button {
    border-color: #fff;
    color: #fff;
}

.service-cta .cta-button:hover,
.service-overview-cta .cta-button:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* --- Responsive Tweaks --- */
@media (max-width: 768px) {
    .testimonial-slider {
        padding: 0 16px;
    }

    .slider-control {
        width: 38px;
        height: 38px;
        font-size: 1.3rem;
    }

    .service-hero,
    .service-overview-hero {
        padding: 100px 0 60px;
    }

    .service-hero-meta {
        padding: 20px;
    }

    .impact-card,
    .feature-card,
    .case-study-list article,
    .resource-grid article,
    .faq-list article {
        padding: 20px;
    }

    .approach-steps li::before {
        left: 20px;
    }
}

@media (max-width: 576px) {
    body {
        font-size: 16px;
        line-height: 1.7;
    }

    p {
        font-size: 1rem;
    }

    .testimonial-card {
        padding: 24px 20px;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-actions .cta-button,
    .hero-actions .link-subtle {
        text-align: center;
    }

    .service-preview-card {
        padding: 28px 22px;
    }
}







/* Services UI enhancements */
.hero-split {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    align-items: center;
    gap: 40px;
}

.hero-copy {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.hero-media {
    margin: 0;
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
}

.hero-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.services-spotlight {
    background: linear-gradient(135deg, rgba(0, 184, 148, 0.08), rgba(10, 25, 47, 0.08));
    padding: 40px 0;
}

.spotlight-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}

.spotlight-card {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 24px;
    box-shadow: var(--card-shadow);
    display: flex;
    flex-direction: column;
    gap: 16px;
    border: 1px solid rgba(10, 25, 47, 0.08);
}

.spotlight-eyebrow {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent);
    margin: 0 0 4px;
}

.spotlight-card h3 {
    margin: 0;
    color: var(--primary);
    font-size: 1.25rem;
}

.spotlight-price {
    font-size: 1rem;
    color: var(--primary);
    margin: 0;
}

.spotlight-price strong {
    font-size: 1.4rem;
}

.spotlight-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: var(--text-color);
    opacity: 0.92;
}

.spotlight-list li::before {
    content: '\2022';
    color: var(--accent);
    margin-right: 8px;
}

.source-tag {
    background: rgba(10, 25, 47, 0.08);
    border-radius: 999px;
    padding: 2px 10px;
    font-size: 0.75rem;
    color: var(--primary);
    display: inline-block;
}

.service-preview-visual {
    margin: 0 0 16px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    height: 180px;
}

.service-preview-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.services-collage {
    padding: 20px 0 0;
}

.visual-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.visual-card {
    margin: 0;
    background: var(--card-bg);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.visual-card img {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.visual-card figcaption {
    padding: 16px;
    font-size: 0.95rem;
    color: var(--primary);
}

@media (max-width: 768px) {
    .hero-split {
        gap: 24px;
    }
    .hero-media {
        max-height: 260px;
    }
}
/* Package cards */
.service-packages {
    padding: 40px 0;
}

.package-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
    margin-top: 24px;
}

.package-card {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 24px;
    box-shadow: var(--card-shadow);
    border: 1px solid rgba(10, 25, 47, 0.08);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.package-name {
    margin: 0;
    font-size: 1.2rem;
    color: var(--primary);
}

.package-price {
    margin: 0;
    font-size: 1.6rem;
    color: var(--accent);
    font-weight: 600;
}

.package-meta {
    margin: 0;
    font-size: 0.95rem;
    color: rgba(10, 25, 47, 0.75);
}

.package-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: var(--text-color);
}

.package-list li::before {
    content: '\2022';
    color: var(--accent);
    margin-right: 8px;
}

.package-footnote {
    margin-top: 24px;
    font-size: 0.9rem;
    color: rgba(10, 25, 47, 0.75);
}

.service-gallery {
    padding: 20px 0 0;
}
.hero-breadcrumb {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    font-size: 0.85rem;
    margin-bottom: 12px;
}

.hero-breadcrumb a {
    color: var(--primary);
    background: rgba(10, 25, 47, 0.08);
    padding: 4px 12px;
    border-radius: 999px;
    transition: color 0.2s ease, background-color 0.2s ease;
}

.hero-breadcrumb a:hover {
    color: var(--accent);
    background: rgba(10, 25, 47, 0.15);
}

.spotlight-card {
    color: var(--primary);
}

.spotlight-card p,
.spotlight-list {
    color: var(--primary);
}

.spotlight-list li {
    color: rgba(10, 25, 47, 0.85);
}

/* =================================================================
   SERVICES UI/UX ENHANCEMENTS
   ================================================================= */

/* --- Service Preview Card Enhancements --- */
.service-preview-desc {
    margin: 0;
    font-size: 0.95rem;
    color: rgba(20, 27, 43, 0.75);
    line-height: 1.6;
}

.service-preview-card h3 {
    margin: 8px 0;
    font-size: 1.25rem;
    color: var(--primary);
    font-weight: 600;
}

.service-preview-card {
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.service-preview-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(10, 25, 47, 0.15);
}

.service-preview-card:hover .service-preview-visual img {
    transform: scale(1.05);
}

.service-preview-visual {
    overflow: hidden;
}

.service-preview-visual img {
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* --- Enhanced Hero Sections --- */
.service-hero h1,
.service-overview-hero h1 {
    font-family: var(--font-family-display);
    font-size: clamp(2rem, 5vw, 3rem);
    line-height: 1.2;
    color: var(--primary);
    margin: 0 0 16px;
}

.hero-copy .lead {
    font-size: clamp(1rem, 2.5vw, 1.15rem);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 8px;
}

/* Hero media enhanced styling */
.hero-media {
    position: relative;
}

.hero-media::before {
    content: '';
    position: absolute;
    inset: -8px;
    background: linear-gradient(135deg, var(--accent), transparent);
    border-radius: 20px;
    z-index: -1;
    opacity: 0.15;
}

/* --- Package Card Enhancements with Recommended Badge --- */
.package-card {
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.package-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 32px rgba(10, 25, 47, 0.12);
}

.package-card.recommended {
    border: 2px solid var(--accent);
    position: relative;
}

.package-card.recommended::before {
    content: 'Most Popular';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent);
    color: #fff;
    padding: 4px 16px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 12px rgba(0, 184, 148, 0.3);
}

/* --- Spotlight Card Enhancements --- */
.spotlight-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    position: relative;
    overflow: visible;
    border-left: 4px solid transparent;
}

.spotlight-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(10, 25, 47, 0.1);
    border-left-color: var(--accent);
}

/* Ensure spotlight card header content is visible */
.spotlight-card header {
    display: block;
    margin-bottom: 8px;
}

.spotlight-card header .spotlight-eyebrow {
    margin-bottom: 4px;
}

.spotlight-card header h3 {
    margin: 0;
    font-size: 1.25rem;
    line-height: 1.3;
    color: var(--primary);
}

/* --- FAQ Accordion Enhancement --- */
.faq-list article {
    cursor: pointer;
    transition: background 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.faq-list article::after {
    content: '+';
    position: absolute;
    top: 24px;
    right: 24px;
    font-size: 1.5rem;
    color: var(--accent);
    font-weight: 300;
    transition: transform 0.3s ease;
}

.faq-list article.expanded::after {
    transform: rotate(45deg);
}

.faq-list article:hover {
    background: rgba(0, 184, 148, 0.03);
}

.faq-list article h3 {
    padding-right: 40px;
    margin-bottom: 12px;
}

.faq-list article p {
    max-height: 500px;
    opacity: 1;
    transition: max-height 0.4s ease, opacity 0.3s ease;
    margin: 0;
    line-height: 1.7;
}

/* --- Impact Cards Enhancement --- */
.impact-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.impact-card::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--accent), var(--accent-light));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.impact-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(10, 25, 47, 0.1);
}

.impact-card:hover::before {
    transform: scaleX(1);
}

.impact-value {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --- Feature Cards Enhancement --- */
.feature-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-left: 3px solid transparent;
}

.feature-card:hover {
    transform: translateX(6px);
    box-shadow: 0 8px 20px rgba(10, 25, 47, 0.08);
    border-left-color: var(--accent);
}

/* --- Approach Steps Enhancement --- */
.approach-steps li {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.approach-steps li:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(10, 25, 47, 0.1);
}

.approach-steps li::before {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.approach-steps li:hover::before {
    transform: scale(1.1);
    box-shadow: 0 12px 24px rgba(0, 184, 148, 0.35);
}

/* --- Form Enhancements --- */
.service-inquiry-form {
    position: relative;
}

.service-inquiry-form label span {
    font-weight: 500;
    color: var(--primary);
}

.service-inquiry-form input,
.service-inquiry-form select,
.service-inquiry-form textarea {
    transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.2s ease;
}

.service-inquiry-form input:focus,
.service-inquiry-form select:focus,
.service-inquiry-form textarea:focus {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 184, 148, 0.15);
}

.service-inquiry-form input:valid:not(:placeholder-shown),
.service-inquiry-form select:valid,
.service-inquiry-form textarea:valid:not(:placeholder-shown) {
    border-color: var(--accent);
}

.service-inquiry-form .cta-button {
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.service-inquiry-form .cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 184, 148, 0.3);
}

/* --- Visual Cards Enhancement --- */
.visual-card {
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    overflow: hidden;
}

.visual-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 32px rgba(10, 25, 47, 0.12);
}

.visual-card img {
    transition: transform 0.5s ease;
}

.visual-card:hover img {
    transform: scale(1.08);
}

.visual-card figcaption {
    transition: background 0.3s ease;
}

.visual-card:hover figcaption {
    background: rgba(0, 184, 148, 0.05);
}

/* --- Case Study & Resource Links Enhancement --- */
.case-study-list article,
.resource-grid article {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.case-study-list article:hover,
.resource-grid article:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(10, 25, 47, 0.1);
}

.case-study-list h3 a,
.resource-grid h3 a {
    position: relative;
    display: inline-block;
}

.case-study-list h3 a::after,
.resource-grid h3 a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.3s ease;
}

.case-study-list h3 a:hover::after,
.resource-grid h3 a:hover::after {
    width: 100%;
}

/* --- Scroll Reveal Animations --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Animate elements on page load */
.service-hero .hero-copy,
.service-overview-hero .hero-copy {
    animation: fadeInLeft 0.8s ease-out;
}

.service-hero .hero-media,
.service-overview-hero .hero-media {
    animation: fadeInRight 0.8s ease-out 0.2s both;
}

.section-heading {
    animation: fadeInUp 0.6s ease-out;
}

.package-card,
.spotlight-card,
.impact-card,
.feature-card,
.service-preview-card,
.visual-card {
    animation: scaleIn 0.5s ease-out backwards;
}

.package-card:nth-child(1),
.spotlight-card:nth-child(1),
.service-preview-card:nth-child(1) { animation-delay: 0.1s; }
.package-card:nth-child(2),
.spotlight-card:nth-child(2),
.service-preview-card:nth-child(2) { animation-delay: 0.2s; }
.package-card:nth-child(3),
.spotlight-card:nth-child(3),
.service-preview-card:nth-child(3) { animation-delay: 0.3s; }

/* --- CTA Section Enhancement --- */
.service-cta,
.service-overview-cta {
    position: relative;
    overflow: hidden;
}

.service-cta::before,
.service-overview-cta::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 50%);
    animation: pulse 8s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(20%, 20%); }
}

.service-cta .section-title,
.service-overview-cta .section-title {
    color: #fff;
}

/* --- Trustband Enhancement --- */
.service-trustband {
    animation: fadeInUp 0.6s ease-out 0.4s both;
}

.service-trustband span {
    transition: transform 0.3s ease, background 0.3s ease;
}

.service-trustband span:hover {
    transform: translateY(-2px);
    background: rgba(0, 184, 148, 0.15);
}

/* --- Link Subtle Enhancement --- */
.link-subtle {
    position: relative;
    transition: color 0.3s ease;
}

.spotlight-card .link-subtle::after,
.package-card .link-subtle::after {
    content: ' \2192';
    opacity: 0;
    transform: translateX(-4px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    display: inline-block;
}

.spotlight-card:hover .link-subtle::after,
.package-card:hover .link-subtle::after {
    opacity: 1;
    transform: translateX(0);
}

/* --- Enhanced Mobile Responsiveness --- */
@media (max-width: 768px) {
    .service-hero h1,
    .service-overview-hero h1 {
        font-size: 1.75rem;
    }

    .hero-media::before {
        display: none;
    }

    .package-card.recommended::before {
        font-size: 0.7rem;
        padding: 3px 12px;
    }

    .faq-list article::after {
        top: 20px;
        right: 20px;
        font-size: 1.25rem;
    }

    .impact-value {
        font-size: 1.75rem;
    }

    .service-trustband {
        flex-direction: column;
        align-items: flex-start;
    }

    .service-preview-card h3 {
        font-size: 1.1rem;
    }

    .service-preview-desc {
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    .package-grid,
    .spotlight-grid {
        grid-template-columns: 1fr;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-actions .cta-button,
    .hero-actions .link-subtle {
        text-align: center;
        justify-content: center;
    }

    .service-cta,
    .service-overview-cta {
        padding: 60px 0;
    }

    .service-inquiry-form {
        padding: 24px;
    }

    .inquiry-grid {
        grid-template-columns: 1fr;
    }
}

/* --- Scroll Reveal Animation Classes --- */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal-on-scroll.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* --- FAQ Collapsed State --- */
.faq-list article:not(.expanded) p {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

.faq-list article.expanded p {
    max-height: 500px;
    opacity: 1;
}

/* Active breadcrumb link */
.hero-breadcrumb a.active {
    background: var(--accent);
    color: #fff;
}

/* --- Reduced Motion Support --- */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .reveal-on-scroll {
        opacity: 1;
        transform: none;
    }
}
