/* --- 1. CORE VARIABLES & RESET --- */
:root {
    --bg-color: #050a10; /* Deep River Navy */
    --text-main: #e0e6ed;
    --text-muted: #8892b0;
    --accent-gold: #D4AF37; /* Henley Royal Regatta Goldish */
    --accent-soft: #a8b2d1;
    --font-serif: 'Playfair Display', serif;
    --font-sans: 'Space Grotesk', sans-serif;
    --cursor-size: 20px;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    cursor: none; /* Hiding default cursor for custom one */
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-sans);
    overflow-x: hidden;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Noise Texture Overlay */
.noise {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    pointer-events: none;
    z-index: 999;
    opacity: 0.05;
    background: url('data:image/svg+xml;utf8,%3Csvg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"%3E%3Cfilter id="noiseFilter"%3E%3CfeTurbulence type="fractalNoise" baseFrequency="0.65" numOctaves="3" stitchTiles="stitch"/%3E%3C/filter%3E%3Crect width="100%25" height="100%25" filter="url(%23noiseFilter)"/%3E%3C/svg%3E');
}

/* --- 2. CUSTOM CURSOR --- */
.cursor {
    width: var(--cursor-size);
    height: var(--cursor-size);
    border: 1px solid var(--accent-gold);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 1000;
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s, background-color 0.3s;
    mix-blend-mode: difference;
}

.cursor.hovered {
    width: 50px;
    height: 50px;
    background-color: rgba(212, 175, 55, 0.2);
    border-color: transparent;
}

/* --- 3. TYPOGRAPHY & UTILITIES --- */
h1, h2, h3 {
    font-family: var(--font-serif);
    font-weight: 400;
    line-height: 1.1;
}

.outline-text {
    color: transparent;
    -webkit-text-stroke: 1px var(--text-muted);
    opacity: 0.3;
}

.gold { color: var(--accent-gold); }
.italic { font-style: italic; }
.text-muted { color: var(--text-muted); }

.container {
    width: 90%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* --- 4. NAVIGATION --- */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    mix-blend-mode: exclusion;
}

.logo {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    letter-spacing: -0.5px;
}

.menu-btn {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
}
.menu-btn::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 1px;
    background: var(--accent-gold);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.4s ease;
}
.menu-btn:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* --- 5. HERO SECTION --- */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

/* Animated Background Gradient */
.hero-bg {
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle at center, #112240 0%, #050a10 60%);
    animation: pulse 15s infinite alternate;
    z-index: -1;
}

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

.hero-content {
    z-index: 2;
}

h1.hero-title {
    font-size: clamp(3rem, 8vw, 7rem);
    margin-bottom: 2rem;
}

h1.hero-title span {
    display: block;
    opacity: 0;
    transform: translateY(50px);
    animation: reveal 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

h1.hero-title span:nth-child(2) { animation-delay: 0.2s; }
h1.hero-title span:nth-child(3) { animation-delay: 0.4s; }

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

.hero-subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 400px;
    margin-left: auto;
    border-left: 1px solid var(--accent-gold);
    padding-left: 2rem;
    opacity: 0;
    animation: fadeIn 1s ease 1s forwards;
}

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

/* --- 6. PHILOSOPHY SECTION (Scroll Reveal) --- */
.philosophy {
    padding: 10rem 0;
    position: relative;
}

.big-statement {
    font-size: clamp(2rem, 5vw, 4rem);
    line-height: 1.3;
}

.section-label {
    color: var(--accent-gold);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.8rem;
    margin-bottom: 1rem;
}

.highlight-text {
    color: var(--accent-gold);
    position: relative;
    display: inline-block;
}

.divider {
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--text-muted), transparent);
    margin: 4rem 0;
    opacity: 0.2;
}

/* --- 7. THE WORK (Parallax Cards) --- */
.work-section {
    padding: 5rem 0 10rem;
}

.section-header {
    margin-bottom: 5rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 4rem;
}

.project-card {
    position: relative;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.05);
    padding: 2rem;
    transition: transform 0.5s ease, border-color 0.3s ease;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-10px);
    border-color: rgba(212, 175, 55, 0.2);
}

/* NEW: Image Container Logic */
.project-img-container {
    width: 100%;
    height: 600px; /* Fixed height for consistency */
    overflow: hidden; /* Hides the overflow if image zooms */
    margin-bottom: 1.5rem;
    background-color: #0f1c2e; /* Fallback color */
}

.project-img-container img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Key property: Ensures image fills div without stretching */
    transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
    display: block;
}

/* Zoom effect on hover */
.project-card:hover .project-img-container img {
    transform: scale(1.05);
}

.project-number {
    font-family: var(--font-serif);
    font-size: 4rem;
    color: transparent;
    -webkit-text-stroke: 1px rgba(212, 175, 55, 0.3);
    position: absolute;
    top: -2rem;
    right: 1rem;
    z-index: 2;
}

.project-title {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.project-tags {
    font-size: 0.8rem;
    color: var(--accent-gold);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- 8. LOCAL FOCUS (Henley) --- */
.local-focus {
    background: #080f18;
    padding: 8rem 0;
    text-align: center;
}

.river-graphic {
    width: 1px;
    height: 100px;
    background: var(--accent-gold);
    margin: 0 auto 2rem;
}

.local-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.local-text {
    max-width: 600px;
    margin: 0 auto;
    font-size: 1.2rem;
    color: var(--text-muted);
}

/* --- 9. FOOTER --- */
footer {
    padding: 4rem 2rem;
    border-top: 1px solid rgba(255,255,255,0.05);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 2rem;
}

.footer-col {
    flex: 1;
}

.cta-pre {
    color: var(--accent-gold);
    margin-bottom: 1rem;
}

.cta-big {
    font-family: var(--font-serif);
    font-size: 4rem;
    color: var(--text-main);
    text-decoration: none;
    transition: color 0.3s;
}

.cta-big:hover {
    color: var(--accent-gold);
}

.footer-info p {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.copyright {
    opacity: 0.5;
}

.form-error {
    position: absolute;
    bottom: -1.5rem;
    left: 0;
    font-size: 0.75rem;
    color: #d46a6a;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.form-error.active {
    opacity: 1;
}

.bespoke-modal {
    position: fixed;
    inset: 0;
    background: rgba(5,10,16,0.85);
    backdrop-filter: blur(8px);
    display: grid;
    place-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
    z-index: 500;
}

.bespoke-modal.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-panel {
    border: 1px solid rgba(212,175,55,0.3);
    padding: 3rem;
    max-width: 420px;
    background: rgba(8,15,24,0.9);
    transform: translateY(20px);
    transition: transform 0.5s cubic-bezier(0.16,1,0.3,1);
}

.bespoke-modal.active .modal-panel {
    transform: translateY(0);
}

.modal-panel p {
    margin: 1.5rem 0 2.5rem;
    color: var(--text-muted);
}

.modal-btn {
    margin-top: 0;
}

.form-section {
    padding: 8rem 0;
    max-width: 800px;
    margin: 0 auto;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.form-group {
    position: relative;
}

.form-input, .form-textarea {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding: 1rem 0;
    font-family: var(--font-sans);
    font-size: 1.2rem;
    color: var(--text-main);
    transition: border-color 0.3s ease;
    border-radius: 0; /* Remove default styling */
}

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

.form-input:focus, .form-textarea:focus {
    outline: none;
    border-bottom-color: var(--accent-gold);
}

.form-label {
    position: absolute;
    top: 1rem;
    left: 0;
    font-size: 1.2rem;
    color: var(--text-muted);
    pointer-events: none;
    transition: 0.3s ease all;
}

/* Float label up when input has text or focus */
.form-input:focus ~ .form-label,
.form-input:valid ~ .form-label,
.form-textarea:focus ~ .form-label,
.form-textarea:valid ~ .form-label {
    top: -1.2rem;
    font-size: 0.8rem;
    color: var(--accent-gold);
}

.submit-btn {
    background: transparent;
    border: 1px solid var(--accent-gold);
    color: var(--accent-gold);
    padding: 1rem 3rem;
    font-family: var(--font-sans);
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    cursor: none; /* We use custom cursor */
    transition: all 0.3s ease;
    align-self: flex-start;
    margin-top: 2rem;
}

.submit-btn:hover {
    background: var(--accent-gold);
    color: var(--bg-color);
}

/* --- ANIMATION CLASSES --- */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 1s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Mobile Adjustments */
@media (max-width: 768px) {
    h1.hero-title { font-size: 3.5rem; }
    .hero-subtitle { border-left: none; padding-left: 0; margin-left: 0; margin-top: 2rem; }
    .cta-big { font-size: 2.5rem; }
}