/* Global Styles */
:root {
    /* Edinburgh-inspired palette: Sandstone, North Sea, Highland, Limestone */
    --primary-color: #C85A3D; /* Edinburgh sandstone / burnt terracotta */
    --secondary-color: #3A7A95; /* North Sea teal - BRIGHTENED for contrast */
    --dark-color: #1A1A1A; /* Charcoal */
    --light-color: #F5EFE0; /* Edinburgh limestone cream - BRIGHTENED for contrast */
    --white-color: #FFFFFF; /* Pure White */
    --black-color: #0A0A0A; /* Deep black */
    --accent-color: #4D8A68; /* Scottish highland green - BRIGHTENED for contrast */
    --highlight-color: #E8A57C; /* Warm sandstone highlight - BRIGHTENED for contrast */
    --font-family-heading: 'Bebas Neue', sans-serif;
    --font-family-body: 'Space Mono', monospace;
}

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

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

body {
    font-family: var(--font-family-body);
    line-height: 1.6;
    color: var(--light-color);
    background: var(--dark-color);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden; /* Prevent horizontal scroll from glitch effects */
}



.container {
    width: 90%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 60px 0;
    position: relative;
    z-index: 10; /* Well above background (z:0) */
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-family-heading);
    margin-bottom: 25px;
    color: var(--primary-color);
    font-weight: normal; /* Bebas Neue is inherently bold */
    text-transform: uppercase;
    letter-spacing: 3px;
}

h1 {
    font-size: 6em; /* Massive H1 */
    line-height: 0.9;
    text-shadow: 3px 3px var(--secondary-color); /* More subtle glitch effect */
}

h2 {
    font-size: 4em; /* Massive H2 */
    text-align: center;
    margin-bottom: 80px; /* More space below H2 */
    position: relative;
    letter-spacing: 5px;
    color: var(--secondary-color);
}

h2::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -30px; /* Adjust position */
    transform: translateX(-50%) skewX(-10deg); /* Less skewed underline */
    width: 150px; /* Wider underline */
    height: 6px; /* Thicker underline */
    background: var(--accent-color); /* Accent color underline */
    border-radius: 0; /* Sharp corners */
}

p {
    margin-bottom: 30px;
    font-size: 1.1em;
    line-height: 1.8;
    color: var(--light-color);
}

a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--highlight-color);
    text-decoration: none;
}

.btn {
    display: inline-block;
    background: var(--primary-color);
    color: var(--dark-color);
    padding: 18px 40px; /* Larger buttons */
    border-radius: 0; /* Sharp corners */
    text-transform: uppercase;
    font-weight: normal;
    font-family: var(--font-family-heading);
    font-size: 1.2em;
    transition: background 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    border: 3px solid var(--primary-color); /* Border for brutalist feel */
    cursor: pointer;
    letter-spacing: 2px;
    box-shadow: 3px 3px 0px var(--secondary-color); /* More subtle offset shadow */
}

.btn:hover {
    background: var(--dark-color);
    color: var(--accent-color);
    transform: translate(1px, 1px); /* Less shift on hover */
    box-shadow: 2px 2px 0px var(--accent-color);
    border-color: var(--accent-color);
}

/* Header - MESH GRADIENT BACKGROUND */
.main-header {
    background: var(--white-color); /* Fallback */
    color: var(--dark-color);
    padding: 20px 0; /* Increased padding for mobile */
    border-bottom: 5px solid var(--primary-color); /* Sandstone bar */
    position: sticky;
    top: 0;
    z-index: 1000; /* High z-index for header and dropdown */
    transition: padding 0.3s ease, opacity 0.3s ease;
    overflow: visible; /* Allow dropdown to show */
}

.main-header > * {
    position: relative;
    z-index: 2; /* Above mesh gradient canvas */
}

.main-header.scrolled {
    padding: 8px 0; /* Even smaller when scrolled */
    opacity: 0.95;
}

.main-header.scrolled .logo {
    font-size: 2em; /* Slightly smaller when scrolled */
}

.main-header.scrolled .main-nav ul li a {
    font-size: 1.1em; /* Slightly smaller when scrolled */
}

.main-header .container {
    display: flex;
    justify-content: space-between; /* Space between burger and nav */
    align-items: center;
    padding: 0 5%;
    position: relative; /* Needed for absolute positioning of dropdown */
}

/* ... existing logo styles ... */

.menu-toggle {
    display: none; /* Hidden on desktop */
    background: var(--primary-color);
    border: 2px solid var(--primary-color);
    color: var(--white-color);
    font-family: var(--font-family-heading);
    font-size: 1.1em; /* Reduced by ~1px equivalent */
    padding: 6px 16px; /* Reduced padding */
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 2px;
}

.menu-toggle:hover {
    background: var(--dark-color);
    border-color: var(--dark-color);
    color: var(--white-color);
}

.main-nav {
    /* Desktop default */
}

.main-nav ul {
    list-style: none;
    display: flex;
}

.main-nav ul li {
    margin-left: 40px; /* More spacing */
}

.main-nav ul li a {
    color: var(--dark-color);
    font-weight: normal;
    font-family: var(--font-family-heading);
    font-size: 1.2em;
    transition: all 0.3s ease;
    position: relative;
    letter-spacing: 1px;
}

.main-nav ul li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px;
    background: var(--primary-color);
    left: 0;
    bottom: -8px;
    transition: width 0.3s ease;
}

.main-nav ul li a:hover::after {
    width: 100%;
}

.main-nav ul li a:hover {
    color: var(--primary-color);
}

/* --- Timeline Section --- */
.timeline-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    max-width: 800px;
    margin: 0 auto;
    position: relative;
}

.timeline-grid::before {
    content: '';
    position: absolute;
    left: 20px; /* Align with left side on mobile default */
    top: 0;
    height: 100%;
    width: 4px;
    background: var(--primary-color);
}

.timeline-item {
    position: relative;
    padding-left: 60px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 12px;
    top: 0;
    width: 20px;
    height: 20px;
    background: var(--secondary-color);
    border: 4px solid var(--dark-color); /* Gap effect */
    transform: rotate(45deg); /* Diamond shape */
}

.timeline-year {
    font-family: var(--font-family-heading);
    font-size: 2.5em;
    color: var(--secondary-color);
    line-height: 1;
    margin-bottom: 10px;
}

.timeline-content h3 {
    font-size: 1.8em;
    color: var(--white-color);
    margin-bottom: 10px;
}

.timeline-content p {
    color: var(--light-color);
    font-size: 1em;
}

@media (min-width: 768px) {
    .timeline-grid::before {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .timeline-item {
        width: 50%;
        padding-left: 0;
    }
    
    .timeline-item:nth-child(odd) {
        margin-right: auto;
        padding-right: 50px;
        text-align: right;
    }
    
    .timeline-item:nth-child(even) {
        margin-left: auto;
        padding-left: 50px;
        text-align: left;
    }
    
    .timeline-item:nth-child(odd)::before {
        left: auto;
        right: -12px;
    }

    .timeline-item:nth-child(even)::before {
        left: -8px;
    }
}

/* --- Skills Grid --- */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
}

.skill-card {
    border: 3px solid var(--white-color);
    padding: 30px;
    text-align: center;
    transition: transform 0.3s ease, background 0.3s ease;
}

.skill-card:hover {
    transform: translateY(-10px);
    background: rgba(255,255,255,0.1);
}

.skill-value {
    font-family: var(--font-family-heading);
    font-size: 4em;
    color: var(--secondary-color);
    margin-bottom: 10px;
}

.skill-card h3 {
    color: var(--white-color);
    font-size: 1.5em;
}

.skill-bar-container {
    flex: 1;
    height: 34px; /* Adjusted for border+padding */
    background: #0a0a0a; /* Dark backing for contrast */
    border: 4px solid var(--accent-color); /* Third color */
    border-radius: 20px;
    padding: 3px; /* Visible gap between inner bar and border */
    box-shadow: 0 4px 0 rgba(0,0,0,0.5); /* Depth for container */
}

.skill-bar {
    height: 100%;
    border-radius: 15px; /* Matches container inner radius */
    /* Rich Metallic/Glassy Gradient */
    background: linear-gradient(
        120deg, 
        var(--secondary-color) 0%, 
        var(--highlight-color) 40%, 
        #ffffff 50%, 
        var(--highlight-color) 60%, 
        var(--secondary-color) 100%
    );
    background-size: 200% auto;
    background-position: 0% center;
    transition: width 1.5s cubic-bezier(0.22, 1, 0.36, 1);
    /* Inner highlight + Outer Glow */
    box-shadow: inset 0 2px 0 rgba(255,255,255,0.3), 0 0 15px var(--secondary-color);
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 15px;
}

.skill-value-text {
    color: var(--secondary-color);
    text-shadow: 0px 0px 2px rgba(255,255,255,0.8); 
    font-weight: bold;
    font-family: var(--font-family-body);
    font-size: 0.9em;
    white-space: nowrap;
}

@media (min-width: 768px) {
    .skill-row {
        flex-direction: column-reverse;
        align-items: flex-start;
        gap: 10px;
    }
    .skill-bar-container {
        width: 100%;
    }
    .skill-info {
        flex: auto;
        width: 100%;
    }
}

/* Hero Section - BOLD SANDSTONE BACKGROUND */
.hero-section {
    background-color: var(--primary-color);
    color: var(--white-color);
    text-align: center;
    padding: 180px 0 220px 0; /* Extra bottom padding for SVG cutout */
    min-height: 50vh;
    max-height: 75vh; /* Max height constraint */
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
    overflow: hidden; /* Contain the gradient */
}

.hero-section.page-header {
    min-height: 50vh; /* Reduced height for sub-pages */
    padding: 100px 0 180px 0; /* Increased bottom padding */
}


.hero-section > .container {
    position: relative;
    z-index: 4;
}

.star-pattern-section > canvas {
    z-index: 2;
}

/* ORGANIC TRANSITION: Diagonal cut with noise */
.hero-section:not(.page-header)::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 80px;
    background: var(--black-color);
    clip-path: polygon(0 50%, 100% 0, 100% 100%, 0 100%);
    z-index: 2;
}

.hero-experience {
    position: absolute;
    top: 120px;
    right: 100px;
    text-align: right;
    z-index: 0; /* Behind main heading */
    opacity: 0.15; /* Subtle background element */
}

.experience-number {
    display: block;
    font-family: var(--font-family-heading);
    font-size: 200px;
    line-height: 0.8;
    color: var(--white-color);
    font-weight: normal;
}

.experience-label {
    display: block;
    font-family: var(--font-family-heading);
    font-size: 24px;
    letter-spacing: 8px;
    color: var(--white-color);
}

.hero-section .container {
    z-index: 1;
    position: relative;
    padding-left: 5vw;
    padding-right: 5vw;
}

.glitch-effect-container {
    position: relative;
    display: block; /* Full width for asymmetric layout */
    text-align: left; /* BREAK THE CENTER - push left */
    margin-left: -50px; /* Break container bounds */
    margin-right: auto;
    max-width: 90%;
    z-index: 10; /* Above canvas so text is clickable */
    pointer-events: auto; /* Text and buttons are interactive */
}

.hero-section h1 {
    color: var(--white-color);
    margin-bottom: 40px;
    font-size: 12vw; /* MASSIVE - 30-40% of viewport */
    line-height: 0.9;
    text-shadow: 8px 8px 0 var(--black-color), -3px -3px 0 var(--secondary-color); /* BOLD dual shadow */
    letter-spacing: -0.02em; /* Tight tracking for impact */
}

.hero-section .hero-subtitle {
    font-family: var(--font-family-heading);
    font-size: 4vw; /* 3x smaller than H1 (12vw) */
    color: var(--white-color);
    margin-top: -20px;
    margin-bottom: 30px;
    line-height: 1;
    text-shadow: 3px 3px 0 var(--black-color), -1px -1px 0 var(--secondary-color); /* Scaled down shadow */
}

.hero-section .tagline {
    font-family: var(--font-family-body); /* Use Space Mono - Bebas Neue is all-caps only */
    font-size: 1.1em; /* Adjusted for body font */
    margin-bottom: 50px;
    max-width: 800px;
    margin-left: 0; /* Left-aligned */
    margin-right: auto;
    font-weight: 400;
    line-height: 1.7;
    color: var(--white-color);
    text-transform: none !important; /* Force remove all caps */
    letter-spacing: 0.5px;
    text-align: left; /* Explicitly left-aligned */
}

.hero-section .tagline strong {
    color: #FFD700; /* Yellow/gold for better contrast on pink/orange bg */
    text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.8); /* Sharp black drop shadow */
    text-transform: none !important; /* Force remove any parent text-transform */
    font-weight: normal; /* Remove bold */
}

/* About Section - BLACK BACKGROUND */
.about-section {
    padding: 120px 0 200px 0; /* Extra bottom for transition */
    background: var(--black-color); /* BOLD BLACK */
    text-align: center;
    position: relative;
    overflow: visible;
}

/* ORGANIC TRANSITION: Angled cut opposite direction */
.about-section::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 100px;
    background: var(--primary-color); /* Next section color */
    clip-path: polygon(0 0, 100% 40%, 100% 100%, 0 100%);
    z-index: 2;
}

.about-section .container {
    position: relative;
    z-index: 10; /* Above transition */
}

.about-content-grid {
    max-width: 900px;
    margin: 0 auto;
    text-align: left;
}

.about-content-grid .about-text {
    /* Full width, centered */
}

/* Services Section - SANDSTONE BACKGROUND */
.services-section {
    padding: 120px 0 200px 0; /* Extra bottom for transition */
    background: var(--primary-color); /* BOLD SANDSTONE */
    position: relative;
    overflow: visible;
    z-index: 1;
}

/* ORGANIC TRANSITION: Jagged diagonal */
.services-section::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 90px;
    background: var(--black-color); /* Next section color */
    clip-path: polygon(0 60%, 15% 40%, 30% 50%, 50% 30%, 70% 45%, 85% 25%, 100% 35%, 100% 100%, 0 100%);
    z-index: 2;
}

.services-section .container {
    position: relative;
    z-index: 10; /* Above transition */
}

.services-section h2,
.services-section h3 {
    color: var(--white-color); /* White on sandstone */
}

.services-section p {
    color: var(--white-color); /* Better contrast on sandstone */
}

.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 50px; /* More gap */
    text-align: center;
}

.service-item {
    background: var(--black-color);
    padding: 60px;
    border-radius: 0;
    box-shadow: 5px 5px 0px var(--black-color);
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.3s ease;
    border: 3px solid var(--secondary-color); /* Thicker border */
}

/* UNIQUE COLORS: Rotate through Edinburgh palette */
.service-item:nth-child(1) { border-color: var(--secondary-color); }
.service-item:nth-child(2) { border-color: var(--accent-color); }
.service-item:nth-child(3) { border-color: var(--highlight-color); }
.service-item:nth-child(4) { border-color: var(--secondary-color); }
.service-item:nth-child(5) { border-color: var(--accent-color); }
.service-item:nth-child(6) { border-color: var(--highlight-color); }

.service-item:hover {
    transform: translate(3px, 3px);
    box-shadow: 7px 7px 0px rgba(0,0,0,0.5);
    border-width: 4px; /* Thicken on hover */
}

.service-item h3 {
    color: var(--white-color);
    font-size: 2.5em;
    margin-bottom: 25px;
    -webkit-text-stroke: 1px var(--secondary-color); /* OUTLINED TEXT */
}

.service-item:nth-child(1) h3 { -webkit-text-stroke-color: var(--secondary-color); }
.service-item:nth-child(2) h3 { -webkit-text-stroke-color: var(--accent-color); }
.service-item:nth-child(3) h3 { -webkit-text-stroke-color: var(--highlight-color); }
.service-item:nth-child(4) h3 { -webkit-text-stroke-color: var(--secondary-color); }
.service-item:nth-child(5) h3 { -webkit-text-stroke-color: var(--accent-color); }
.service-item:nth-child(6) h3 { -webkit-text-stroke-color: var(--highlight-color); }

.service-item p {
    font-size: 1.1em;
    color: var(--light-color);
}

/* Portfolio Section - WHITE BACKGROUND */
.portfolio-section {
    padding: 120px 0 200px 0;
    background: var(--light-color); /* BOLD WHITE/CREAM */
    color: var(--dark-color);
    position: relative;
    overflow: visible;
    z-index: 1;
}

/* ORGANIC TRANSITION: Wave-like cut */
.portfolio-section::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 100px;
    background: var(--dark-color); /* Process section color */
    clip-path: polygon(0 30%, 25% 50%, 50% 35%, 75% 55%, 100% 40%, 100% 100%, 0 100%);
    z-index: 1;
}

.portfolio-section h2 {
    color: var(--primary-color);
}

.portfolio-section h2::after {
    background: var(--primary-color);
}

.portfolio-section .container {
    position: relative;
    z-index: 10; /* Above transition */
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr)); /* Even larger items */
    gap: 50px;
}

.portfolio-item {
    background: var(--white-color);
    border-radius: 0;
    overflow: hidden;
    box-shadow: 8px 8px 0px var(--primary-color); /* Bold sandstone shadow */
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    position: relative;
    border: 3px solid var(--black-color);
}

.portfolio-item:hover {
    transform: translate(4px, 4px);
    box-shadow: 4px 4px 0px var(--secondary-color);
    border-color: var(--accent-color);
}

.portfolio-item img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.5s ease;
    filter: grayscale(100%) contrast(1.1);
}

.portfolio-image-wrapper {
    width: 100%;
    padding-top: 100%; /* Makes the height equal to the width */
    position: relative;
    overflow: hidden; /* Ensures image does not overflow during hover effects */
}

.portfolio-item-divider {
    width: 100%;
    height: 5px;
    background: var(--primary-color); /* Default color */
    margin-top: 0; /* Attached to image */
    position: relative;
    z-index: 2;
}

/* Specific accent colors for portfolio items */
.portfolio-item:nth-child(1) .portfolio-item-divider { background: var(--secondary-color); }
.portfolio-item:nth-child(2) .portfolio-item-divider { background: var(--accent-color); }
.portfolio-item:nth-child(3) .portfolio-item-divider { background: var(--highlight-color); }

.portfolio-item:hover img {
    transform: scale(1.03); /* Less pronounced zoom */
    filter: grayscale(0%) contrast(1); /* Color on hover */
}

.portfolio-info {
    padding: 30px;
    position: relative;
    z-index: 2;
}

.portfolio-item h3 {
    color: var(--primary-color);
    font-size: 2em;
    margin-bottom: 15px;
}

.portfolio-item p {
    color: var(--dark-color);
    font-size: 1.1em;
    line-height: 1.6;
}

.portfolio-item strong {
    color: var(--secondary-color);
}

/* Testimonials Section */
.testimonials-section {
    padding: 120px 0;
    background: var(--dark-color);
    border-bottom: 3px solid var(--secondary-color);
    text-align: center;
}

.testimonials-section h2 {
    color: var(--secondary-color);
}

.testimonial-slider {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.testimonial-slide {
    padding: 40px;
    background: var(--black-color);
    border: 2px solid var(--primary-color);
    box-shadow: 5px 5px 0px var(--accent-color); /* More subtle shadow */
    margin-bottom: 50px;
}

.testimonial-slide blockquote {
    font-size: 1.5em;
    font-style: italic;
    line-height: 1.5;
    margin-bottom: 30px;
    color: var(--light-color);
    position: relative;
    z-index: 1; /* Ensure text is above quote mark */
}

.testimonial-slide blockquote::before {
    content: '“';
    font-size: 10em; /* 2.5x bigger */
    color: var(--secondary-color);
    position: absolute;
    left: -120px; /* Much further left */
    top: -90px; /* Sitting over the corner */
    opacity: 0.3; /* Slightly more subtle due to size */
    line-height: 1;
    z-index: -1; /* Behind text */
}

.testimonial-slide .author {
    font-size: 1.2em;
    font-weight: bold;
    color: var(--primary-color);
    text-shadow: 1px 1px var(--secondary-color);
}


/* Process Section - WHITE BACKGROUND */
.process-section {
    padding: 120px 0 200px 0; /* Extra bottom for transition */
    background: var(--white-color);
    position: relative;
    overflow: visible;
    z-index: 1;
}

/* ORGANIC TRANSITION */
.process-section::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 90px;
    background: var(--dark-color); /* Testimonials section color */
    clip-path: polygon(0 45%, 20% 30%, 40% 50%, 60% 25%, 80% 40%, 100% 30%, 100% 100%, 0 100%);
    z-index: 1;
}

.process-section .container {
    position: relative;
    z-index: 10;
}

.process-section h2 {
    color: var(--primary-color);
}

.process-section h2::after {
    background: var(--primary-color);
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px;
}

.process-step {
    background: var(--light-color); /* Cream background */
    padding: 40px;
    border: 3px solid var(--black-color);
    position: relative;
    box-shadow: 6px 6px 0px var(--secondary-color);
    transition: all 0.3s ease;
}

.process-step:hover {
    box-shadow: 10px 10px 0px var(--primary-color);
}

.step-number {
    font-family: var(--font-family-heading);
    font-size: 5em;
    color: var(--primary-color);
    opacity: 0.15;
    position: absolute;
    top: 10px;
    right: 20px;
    line-height: 1;
}

.process-step h3 {
    color: var(--primary-color);
    font-size: 2em;
    margin-bottom: 15px;
}

.process-step p {
    color: var(--dark-color);
}

/* Contact Section - STRONG CTA */
.contact-section {
    padding: 80px 0; /* Compact */
    background: var(--primary-color);
    color: var(--white-color);
}

.contact-section h2 {
    color: var(--white-color);
    text-align: center;
    margin-bottom: 20px;
}

/* Fix for green border bar being too far down */
.contact-section h2::after {
    bottom: -10px;
}

.contact-intro {
    text-align: center;
    color: var(--white-color);
    font-size: 16px;
    margin-bottom: 60px;
    text-transform: uppercase;
    letter-spacing: 3px;
}

.contact-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 80px;
    max-width: 1200px;
    margin: 0 auto;
    align-items: start;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: var(--white-color); /* White background as requested */
    padding: 40px; /* Inner spacing */
    border: 3px solid var(--black-color); /* Brutalist border */
    box-shadow: 10px 10px 0 var(--dark-color); /* Depth shadow */
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 18px 24px;
    border: 3px solid var(--black-color);
    background: var(--white-color);
    color: var(--dark-color);
    font-family: var(--font-family-body);
    font-size: 16px;
    transition: all 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 5px 5px 0 var(--black-color);
}

.contact-form button {
    background: var(--black-color);
    color: var(--white-color);
    border: 3px solid var(--black-color);
    padding: 20px 50px;
    font-size: 1.4em;
    cursor: pointer;
    box-shadow: 6px 6px 0 var(--secondary-color);
    transition: all 0.3s ease;
}

.contact-form button:hover {
    transform: translate(3px, 3px);
    box-shadow: 3px 3px 0 var(--secondary-color);
    background: var(--secondary-color);
    color: var(--black-color);
}

.contact-details {
    text-align: left;
}

.contact-item {
    margin-bottom: 40px;
}

.contact-item h3 {
    color: var(--white-color);
    font-size: 1.2em;
    margin-bottom: 10px;
}

.contact-item a {
    color: var(--white-color);
    font-size: 1.1em;
    display: block;
    margin-bottom: 8px;
}

.contact-item a:hover {
    color: var(--black-color);
}

.contact-item p {
    color: var(--white-color);
    font-size: 1.1em;
}

.social-links-inline {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.social-links-inline a {
    color: var(--white-color);
    font-size: 1em;
}

/* Footer - WHITE BACKGROUND */
.main-footer {
    background: var(--white-color);
    color: var(--dark-color);
    padding: 50px 0;
    text-align: center;
    border-top: 5px solid var(--primary-color);
}

.main-footer p {
    margin-bottom: 0;
    font-size: 11px; /* TINY footer - extreme scale contrast */
    color: var(--dark-color);
    letter-spacing: 2px;
    text-transform: uppercase;
}

.main-footer .social-links {
    margin-top: 25px;
}

.main-footer .social-links a {
    color: var(--light-color);
    font-size: 2em; /* Larger icons */
    margin: 0 15px;
    transition: color 0.3s ease, transform 0.2s ease, text-shadow 0.3s ease;
}

.main-footer .social-links a:hover {
    color: var(--accent-color);
    transform: translateY(-3px) rotate(3deg); /* Less aggressive transform */
    text-shadow: 0 0 15px var(--accent-color); /* More subtle glow */
}

/* Content Transition Animation */
#content-wrapper {
    transition: opacity 0.8s ease-in-out, transform 0.8s ease-in-out; /* Slower and more pronounced */
    transform-style: preserve-3d;
    perspective: 2000px; /* Even stronger perspective */
}

.content-transition-out {
    opacity: 0;
    transform: rotateX(20deg) rotateY(40deg) scale(0.8) translateY(80px); /* Less extreme 3D effect */
}

.content-transition-in {
    opacity: 1;
    transform: rotateX(0deg) rotateY(0deg) scale(1) translateY(0);
}



.service-grid .reveal-item:nth-child(1) { transition-delay: 0.1s; }
.service-grid .reveal-item:nth-child(2) { transition-delay: 0.2s; }
.service-grid .reveal-item:nth-child(3) { transition-delay: 0.3s; }
.service-grid .reveal-item:nth-child(4) { transition-delay: 0.4s; }
.service-grid .reveal-item:nth-child(5) { transition-delay: 0.5s; }
.service-grid .reveal-item:nth-child(6) { transition-delay: 0.6s; }


.portfolio-grid .reveal-item:nth-child(1) { transition-delay: 0.1s; }
.portfolio-grid .reveal-item:nth-child(2) { transition-delay: 0.2s; }
.portfolio-grid .reveal-item:nth-child(3) { transition-delay: 0.3s; }

/* Content Slide Animations */
.content-slide-left {
    opacity: 0;
    transform: translateX(-100%);
    transition: opacity 1s ease-out, transform 1s ease-out;
}

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

.content-slide-right {
    opacity: 0;
    transform: translateX(100%);
    transition: opacity 1s ease-out, transform 1s ease-out;
}

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

/* Responsive Design */
@media (max-width: 1200px) {
    h1 {
        font-size: 5em;
    }
    h2 {
        font-size: 3.5em;
    }
    .hero-section h1 {
        font-size: 6em;
    }
}

@media (max-width: 992px) {
    .main-nav ul li {
        margin-left: 25px;
    }
    h1 {
        font-size: 4em;
    }
    h2 {
        font-size: 3em;
    }
    .hero-section h1 {
        font-size: 5em;
    }
    .hero-section .tagline {
        font-size: 1.5em;
    }
    .about-content-grid {
        grid-template-columns: 1fr; /* Stack columns */
        text-align: center;
    }
    .about-content-grid .about-text {
        padding-right: 0;
    }
    .abstract-visual-element {
        height: 200px; /* Smaller on mobile */
        transform: rotate(0deg); /* No rotation on mobile */
    }
    .service-grid, .portfolio-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .main-header .container {
        padding: 0 5%;
        flex-wrap: wrap;
    }

    .main-nav {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        max-height: 0;
        overflow: hidden;
        background: var(--white-color);
        box-shadow: 0 5px 15px rgba(0,0,0,0.3);
        transition: max-height 0.4s ease;
        z-index: 999; /* Way above everything */
        border-top: 3px solid var(--primary-color);
    }

    .main-nav.active {
        max-height: 500px;
        overflow-y: auto;
    }

    .main-nav ul {
        flex-direction: column;
        text-align: left;
        width: 100%;
        padding: 10px 0;
    }

    .main-nav ul li {
        margin: 0;
        border-bottom: 1px solid #eee;
    }

    .main-nav ul li:last-child {
        border-bottom: none;
    }

    .main-nav ul li a {
        font-size: 1.2em;
        padding: 15px 5%;
        display: block;
        width: 100%;
    }

    .main-nav ul li a::after {
        display: none;
    }

    h1 {
        font-size: 3em;
    }
    h2 {
        font-size: 2.5em;
    }

    .hero-section {
        padding: 80px 0;
        min-height: auto;
        max-height: 80vh;
        overflow: hidden;
    }

    .hero-section h1 {
        font-size: 4.5em; /* 1.5x increase from 3em */
        text-shadow: -2px -2px 0 var(--secondary-color);
    }

    /* Smaller drop shadows for subpage headers on mobile */
    .hero-section.page-header h1 {
        text-shadow: 4px 4px 0 var(--black-color), -1.5px -1.5px 0 var(--secondary-color);
    }

    .hero-section .hero-subtitle {
        font-size: 2em;
        text-shadow: -1px -1px 0 var(--secondary-color);
        margin-top: -15px;
    }

    .hero-section .tagline {
        font-size: 1.2em;
    }

    /* Left align home header on mobile */
    .glitch-effect-container {
        margin-left: 0;
        text-align: left;
    }

    /* Portfolio page - remove staggered padding on mobile for full width */
    .project-row {
        padding-left: 0 !important;
    }
    
    .btn {
        padding: 15px 30px;
        font-size: 1.1em;
    }

    .service-grid, .portfolio-grid {
        grid-template-columns: 1fr;
    }
    
    .service-item, .portfolio-item {
        padding: 40px;
    }
    
    .contact-form {
        padding: 20px;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .hero-experience {
        display: none;
    }

    .glitch-effect-container {
        margin-left: 0;
        text-align: center;
    }

    /* WordPress Grid collapse for mobile */
    .wordpress-grid {
        grid-template-columns: 1fr !important;
    }
    .wordpress-grid .wp-item {
        border-right: none !important;
        border-bottom: 4px solid var(--dark-color) !important;
    }
    .wordpress-grid .wp-item:last-child {
        border-bottom: none !important;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2.5em;
    }
    h2 {
        font-size: 2em;
    }
    .hero-section h1 {
        font-size: 3.5em;
    }
    .hero-section .hero-subtitle {
        font-size: 1.5em;
    }
    .hero-section .tagline {
        font-size: 1em;
    }
    .main-footer .social-links a {
        font-size: 1.8em;
    }
}

/* Hide reCAPTCHA Badge */
.grecaptcha-badge {
    visibility: hidden;
}