/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Color Palette */
    --bg-primary: #F9F9F9;
    --bg-white: #FFFFFF;
    --accent-aqua: #33BDE6;
    --accent-green: #5FC36A;
    --text-primary: #222222;
    --text-secondary: #666666;
    
    /* Typography */
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Open Sans', sans-serif;
    
    /* Grid System */
    --container-max-width: 1200px;
    --grid-gap: 2rem;
    --section-padding: 5rem 0;
    --margin-large: 3rem;
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    letter-spacing: 0.02em;
    overflow-x: hidden;
    position: relative;
}

/* Logo Background */
body::before {
    content: '';
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60vw;
    height: 60vh;
    background-image: url('Cobus Schoeman logo.jpg');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.08;
    z-index: -1;
    pointer-events: none;
}

/* Blueprint Grid Overlay */
.blueprint-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    opacity: 0.03;
    background-image: 
        linear-gradient(rgba(51, 189, 230, 0.3) 1px, transparent 1px),
        linear-gradient(90deg, rgba(51, 189, 230, 0.3) 1px, transparent 1px);
    background-size: 20px 20px;
}

/* Container and Grid System */
.container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    z-index: 2;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--grid-gap);
    align-items: center;
}

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

/* Header */
.header {
    background: var(--bg-white);
    padding: 0.9rem 0;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-img {
    height: 96px;
    width: auto;
    max-height: 96px;
    transition: transform 0.3s ease;
}

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

.nav-list {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    text-decoration: none;
    color: var(--text-primary);
    font-family: var(--font-heading);
    font-weight: 500;
    letter-spacing: 0.05em;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-aqua);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-aqua);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link.special {
    color: var(--accent-green);
}

.nav-link.cta {
    background: var(--accent-aqua);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.nav-link.cta:hover {
    background: var(--accent-green);
    transform: translateY(-2px);
}

.nav-link.cta::after {
    display: none;
}

/* Hero Section */
.hero {
    height: 100vh;
    background: linear-gradient(135deg, var(--bg-white) 0%, var(--bg-primary) 100%);
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="blueprint" patternUnits="userSpaceOnUse" width="10" height="10"><path d="M 10,0 L 0,0 0,10" fill="none" stroke="%2333BDE6" stroke-width="0.5" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23blueprint)"/></svg>');
    opacity: 0.15;
}

.hero-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.hero-logo {
    height: 192px;
    width: auto;
    margin-bottom: 2rem;
    opacity: 0.9;
    animation: fadeInScale 2s ease-out;
}

@keyframes fadeInScale {
    0% {
        opacity: 0;
        transform: scale(0.8) translateY(20px);
    }
    100% {
        opacity: 0.9;
        transform: scale(1) translateY(0);
    }
}

.hero-title {
    font-family: var(--font-heading);
    font-size: 2.8rem;
    font-weight: 300;
    letter-spacing: 0.1em;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    letter-spacing: 0.05em;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 1rem 2rem;
    text-decoration: none;
    font-family: var(--font-heading);
    font-weight: 500;
    letter-spacing: 0.05em;
    border-radius: 4px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: var(--accent-aqua);
    color: white;
    border-color: var(--accent-aqua);
}

.btn-primary:hover {
    background: transparent;
    color: var(--accent-aqua);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(51, 189, 230, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--accent-green);
    border-color: var(--accent-green);
}

.btn-secondary:hover {
    background: var(--accent-green);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(95, 195, 106, 0.3);
}

.btn.full-width {
    width: 100%;
}

/* Sections */
.section {
    padding: var(--section-padding);
    position: relative;
}

.section:nth-child(even) {
    background: var(--bg-white);
}

.section-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 300;
    letter-spacing: 0.1em;
    margin-bottom: 2rem;
    position: relative;
}

.section-title.centered {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--accent-aqua);
}

.section-title.centered::after {
    left: 50%;
    transform: translateX(-50%);
}

.section-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 3rem;
    letter-spacing: 0.02em;
    font-weight: 300;
}

.section-text {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    letter-spacing: 0.02em;
}

/* About Section */
.stats {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 600;
    color: var(--accent-aqua);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    letter-spacing: 0.05em;
}

/* Image Placeholders */
.image-placeholder,
.portfolio-image {
    background: linear-gradient(135deg, var(--bg-primary) 0%, #e0e0e0 100%);
    border: 2px dashed var(--accent-aqua);
    border-radius: 8px;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.image-placeholder:hover,
.portfolio-image:hover {
    border-color: var(--accent-green);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.placeholder-content {
    text-align: center;
    color: var(--text-secondary);
    font-family: var(--font-heading);
    letter-spacing: 0.05em;
}

/* Services */
.service-card {
    background: var(--bg-white);
    padding: 2.5rem;
    border-radius: 8px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

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

.service-icon {
    color: var(--accent-aqua);
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.service-card:hover .service-icon {
    color: var(--accent-green);
    transform: scale(1.1);
}

.service-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 500;
    margin-bottom: 1rem;
    letter-spacing: 0.05em;
}

.service-text {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Portfolio */
.portfolio-item {
    background: var(--bg-white);
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid #e0e0e0;
    margin-bottom: 2rem;
}

.portfolio-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
    border-color: var(--accent-aqua);
}

.portfolio-content {
    padding: 2rem;
}

.portfolio-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 500;
    margin-bottom: 1rem;
    letter-spacing: 0.05em;
    color: var(--text-primary);
}

.portfolio-description {
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.6;
    letter-spacing: 0.02em;
}

/* Contact */
.contact-info {
    margin-top: 2rem;
}

.contact-item {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

.contact-form {
    background: var(--bg-white);
    padding: 2.5rem;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 4px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: all 0.3s ease;
    background: var(--bg-primary);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-aqua);
    background: white;
}

/* Footer */
.footer {
    background: var(--text-primary);
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.footer-logo .logo-img {
    filter: brightness(0) invert(1);
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--accent-aqua);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #444;
    color: var(--text-secondary);
}

/* Responsive Design */
@media (max-width: 768px) {
    .grid-2,
    .grid-3 {
        grid-template-columns: 1fr;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .nav-list {
        flex-direction: column;
        gap: 1rem;
    }
    
    .stats {
        justify-content: center;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Loading Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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