/* Design System Tokens */
:root {
    --bg-white: #ffffff;
    --bg-offwhite: #f7f7f7;
    --text-primary: #111111;
    --text-secondary: #111111; /* Changed from gray to near-black */
    --border-light: #eaeaea;
    --accent-beige: #f5f5f0;
    --transition-smooth: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-white);
    color: var(--text-primary);
    overflow-x: hidden;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-smooth);
}

ul {
    list-style: none;
}

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

.thin {
    font-weight: 200;
}

/* Preloader */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-white);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 1s ease-in-out;
}

.preloader-content {
    text-align: center;
    width: 300px;
}

.preloader-logo {
    height: 40px;
    margin-bottom: 30px;
    opacity: 0;
    animation: fadeIn 1s forwards;
}

.loader-bar {
    width: 100%;
    height: 1px;
    background: var(--border-light);
    overflow: hidden;
    margin-bottom: 15px;
}

.loader-progress {
    width: 0%;
    height: 100%;
    background: var(--text-primary);
}

.loader-text {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--text-secondary);
    font-weight: 300;
}

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

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 80px;
    display: flex;
    align-items: center;
    z-index: 1000;
    transition: var(--transition-smooth);
    border-bottom: 1px solid transparent;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    height: 70px;
    border-bottom: 1px solid var(--border-light);
}

.logo img {
    height: 80px; /* Increased further */
    width: auto;
    display: block;
}

.nav-container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-links {
    display: flex;
    gap: 40px;
}

.nav-links a {
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    opacity: 0.7;
}

.nav-links a:hover {
    opacity: 1;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
}

.menu-toggle span {
    width: 24px;
    height: 1px;
    background: var(--text-primary);
    transition: var(--transition-smooth);
}

/* Hero Section */
.hero {
    height: 100vh;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0.15;
    z-index: -1;
    transform: scale(1.1);
}

.hero-content {
    text-align: center;
}

.hero-logo-large {
    height: 120px; /* Increased from 80px */
    width: auto;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(30px);
}

.hero-subtitle {
    font-size: 1.1rem;
    font-weight: 300;
    letter-spacing: 4px;
    text-transform: uppercase;
    margin-bottom: 40px;
    opacity: 0;
    transform: translateY(30px);
}

.cta-button {
    display: inline-block;
    padding: 15px 40px;
    border: 1px solid var(--text-primary);
    font-size: 0.8rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: var(--transition-smooth);
    opacity: 0;
    transform: translateY(30px);
}

.cta-button:hover {
    background: var(--text-primary);
    color: var(--bg-white);
}

/* Cinematic Sequence Section */
.experience-section {
    height: 400vh; /* Adjust for scroll length */
    position: relative;
    background: var(--bg-white);
}

.canvas-container {
    position: sticky;
    top: 0;
    height: 100vh;
    width: 100%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

#sequence-canvas {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.overlay-text-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.overlay-text {
    position: absolute;
    font-size: clamp(1.5rem, 4vw, 3rem);
    font-weight: 200;
    letter-spacing: 8px;
    text-transform: uppercase;
    opacity: 0;
    transform: translateY(50px);
    text-align: center;
    width: fit-content;
    padding: 0 20px;
    background-color: rgba(255, 255, 255, 0.508);
}

/* Counter Section */
.counter-section {
    padding: 150px 0;
    background: var(--bg-white);
}

.counter-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    text-align: center;
}

.counter-number {
    display: block;
    font-size: 4rem;
    font-weight: 200;
    margin-bottom: 10px;
}

.counter-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-secondary);
}

/* About Section */
.about-section {
    padding: 150px 0;
    background: var(--bg-offwhite);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 100px;
    align-items: center;
}

.about-image img {
    width: 100%;
    height: 600px;
    object-fit: cover;
    filter: grayscale(1);
    transition: var(--transition-smooth);
}

.about-image:hover img {
    filter: grayscale(0);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 200;
    letter-spacing: 4px;
    margin-bottom: 40px;
    text-transform: uppercase;
}

.premium-text {
    font-size: 1.25rem;
    font-weight: 300;
    margin-bottom: 30px;
    color: var(--text-primary);
}

.secondary-text {
    font-size: 1rem;
    font-weight: 300;
    color: var(--text-secondary);
}

/* Work Section (Features + Gallery) */
.work-section {
    padding: 150px 0;
    background: var(--bg-white);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-bottom: 150px;
}

.feature-card {
    padding: 40px;
    border: 1px solid var(--border-light);
    transition: var(--transition-smooth);
}

.feature-card:hover {
    box-shadow: 0 20px 40px rgba(0,0,0,0.03);
    transform: translateY(-10px);
}

.feature-card h3 {
    font-size: 1.2rem;
    font-weight: 400;
    margin-bottom: 20px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.feature-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 300;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.gallery-item {
    overflow: hidden;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 500px;
    object-fit: cover;
    transition: var(--transition-smooth);
}

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

/* CTA Section */
.cta-section {
    padding: 150px 0;
    background: var(--bg-white);
    text-align: center;
}

.cta-content h2 {
    font-size: 2.5rem;
    font-weight: 200;
    letter-spacing: 6px;
    margin-bottom: 50px;
    text-transform: uppercase;
}

.cta-button-alt {
    display: inline-block;
    padding: 20px 60px;
    background: var(--text-primary);
    color: var(--bg-white);
    font-size: 0.9rem;
    letter-spacing: 3px;
    text-transform: uppercase;
}

/* Contact Section */
.contact-section {
    padding: 150px 0;
    background: var(--bg-offwhite);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 100px;
}

.form-group {
    position: relative;
    margin-bottom: 40px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px 0;
    background: transparent;
    border: none;
    border-bottom: 1px solid #ccc;
    font-size: 1rem;
    color: var(--text-primary);
    outline: none;
    transition: var(--transition-smooth);
}

.form-group label {
    position: absolute;
    top: 15px;
    left: 0;
    pointer-events: none;
    transition: var(--transition-smooth);
    color: var(--text-secondary);
    font-weight: 300;
    letter-spacing: 1px;
}

.form-group input:focus ~ label,
.form-group input:not(:placeholder-shown) ~ label,
.form-group textarea:focus ~ label,
.form-group textarea:not(:placeholder-shown) ~ label {
    top: -20px;
    font-size: 0.75rem;
    color: var(--text-primary);
}

.form-group input:focus,
.form-group textarea:focus {
    border-bottom: 1px solid var(--text-primary);
}

.submit-btn {
    width: 100%;
    padding: 20px;
    background: var(--text-primary);
    color: var(--bg-white);
    border: none;
    font-size: 0.9rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    cursor: pointer;
    transition: var(--transition-smooth);
}

/* Footer */
.footer {
    padding: 80px 0;
    background: var(--bg-white);
    border-top: 1px solid var(--border-light);
}

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

.footer-logo img {
    height: 100px; /* Increased significantly */
    width: auto;
}

.footer-links a {
    margin-left: 30px;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
}

.footer-copy {
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-weight: 300;
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    z-index: 2000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.98);
    align-items: center;
    justify-content: center;
}

.lightbox-content {
    max-width: 80%;
    max-height: 80%;
    object-fit: contain;
    animation: zoomIn 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.lightbox-close {
    position: absolute;
    top: 40px;
    right: 40px;
    font-size: 2rem;
    cursor: pointer;
    font-weight: 100;
}

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

/* Responsive */
@media (max-width: 1024px) {
    .about-grid, .contact-grid {
        grid-template-columns: 1fr;
        gap: 60px;
    }
    
    .counter-grid, .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background: var(--bg-white);
        flex-direction: column;
        padding: 40px;
        gap: 30px;
        border-bottom: 1px solid var(--border-light);
        text-align: center;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .menu-toggle {
        display: flex;
    }

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

    .menu-toggle.open span:nth-child(2) {
        transform: rotate(-45deg) translate(0px, 0px);
    }
    
    .hero-title {
        letter-spacing: 8px;
    }
    
    .counter-grid, .features-grid, .gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .container {
        padding: 0 20px;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 30px;
        text-align: center;
    }
    
    .footer-links a {
        margin: 0 15px;
    }
}

/* Reveal Animations */
.reveal {
    opacity: 0;
    transform: translateY(40px);
}
