/* ==========================================================================
   Isotopia Global - Stylesheet (Transparent to White Header + Logo Magic)
   ========================================================================== */

:root {
    --color-primary: #283791;   
    --color-secondary: #9a77b5; 
    --color-bg-light: #F3F5F9;  
    --color-text-main: #333333;
    --color-text-light: #ffffff;
    
    --transition-standard: all 0.4s ease-in-out;
}

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

body { font-family: 'Inter', sans-serif; background-color: var(--color-bg-light); color: var(--color-text-main); line-height: 1.6; overflow-x: hidden; }

.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* Accessibility: Skip to main content (Hidden by default) */
.skip-link { position: absolute; top: -100px; left: 0; background: var(--color-secondary); color: var(--color-text-light); padding: 10px 15px; z-index: 9999; text-decoration: none; font-weight: bold; transition: top 0.2s; }
.skip-link:focus { top: 0; }

/* ==========================================================================
   Header & Navigation (Transparent State)
   ========================================================================== */
.main-header {
    background-color: transparent;
    padding: 25px 0;
    position: fixed; /* Fixes the header to the top, overlapping the hero section */
    width: 100%;
    top: 0;
    left: 0;
    z-index: 1000;
    transition: var(--transition-standard);
}

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

/* --- Logo Filter Magic --- */
/* Turns the logo pure white on the dark transparent header (brightness(0) makes it black, invert(1) makes it white) */
.main-header .logo-image {
    filter: brightness(0) invert(1);
    transition: filter 0.4s ease-in-out;
}

.desktop-nav ul { display: flex; list-style: none; gap: 35px; }

/* Links color when header is transparent (over dark hero) */
.desktop-nav a {
    color: var(--color-text-light);
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    transition: var(--transition-standard);
}

.desktop-nav a:hover, .desktop-nav a:focus { color: var(--color-secondary); }

/* Hamburger Menu (Transparent state) */
.mobile-menu-toggle { display: none; background: transparent; border: none; cursor: pointer; padding: 10px; }

.hamburger { display: block; width: 28px; height: 2px; background-color: var(--color-text-light); position: relative; transition: var(--transition-standard); }
.hamburger::before, .hamburger::after { content: ''; position: absolute; width: 28px; height: 2px; background-color: var(--color-text-light); left: 0; transition: var(--transition-standard); }
.hamburger::before { top: -8px; }
.hamburger::after { top: 8px; }

/* ==========================================================================
   Header Scrolled State (Solid White)
   ========================================================================== */
.main-header.scrolled {
    background-color: #ffffff;
    padding: 15px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

/* Returns the logo to its original colors when scrolled */
.main-header.scrolled .logo-image {
    filter: none;
}

/* Links color when scrolled */
.main-header.scrolled .desktop-nav a {
    color: var(--color-primary);
}

.main-header.scrolled .desktop-nav a:hover, 
.main-header.scrolled .desktop-nav a:focus {
    color: var(--color-secondary);
}

/* Hamburger color when scrolled */
.main-header.scrolled .hamburger,
.main-header.scrolled .hamburger::before,
.main-header.scrolled .hamburger::after {
    background-color: var(--color-primary);
}

/* ==========================================================================
   Off-Canvas Mobile Menu
   ========================================================================== */
.off-canvas-menu { position: fixed; top: 0; right: -320px; width: 320px; height: 100vh; background-color: var(--color-primary); z-index: 2000; transition: right 0.4s cubic-bezier(0.77, 0, 0.175, 1); padding: 30px; display: flex; flex-direction: column; }
.off-canvas-menu.active { right: 0; }
.off-canvas-header { text-align: right; margin-bottom: 40px; }
.close-menu { background: none; border: none; color: var(--color-text-light); font-size: 36px; cursor: pointer; line-height: 1; }
.off-canvas-menu ul { list-style: none; }
.off-canvas-menu li { margin-bottom: 25px; border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 10px; }
.off-canvas-menu a { color: var(--color-text-light); text-decoration: none; font-size: 22px; display: block; transition: var(--transition-standard); }
.off-canvas-menu a:hover { color: var(--color-secondary); }

/* ==========================================================================
   Main Content Sections
   ========================================================================== */
.hero-section { background: linear-gradient(135deg, var(--color-primary) 0%, #1a245e 100%); background-size: cover; background-position: center; min-height: 85vh; display: flex; flex-direction: column; justify-content: center; position: relative; padding: 120px 0 80px 0; }
.hero-content { position: relative; z-index: 2; color: var(--color-text-light); max-width: 800px; margin-bottom: 80px; }
.hero-title { font-size: 4.5rem; line-height: 1.1; margin-bottom: 24px; font-weight: 700; }
.hero-subtitle { font-size: 1.5rem; margin-bottom: 40px; color: #D1D5DB; font-weight: 300; }

.btn { display: inline-block; padding: 16px 36px; background-color: var(--color-secondary); color: var(--color-text-light); text-decoration: none; border-radius: 4px; font-weight: 600; font-size: 16px; transition: var(--transition-standard); border: 1px solid transparent; }
.btn:hover { background-color: transparent; border-color: var(--color-text-light); }

.portfolio-card:hover { transform: translateY(-5px); }

/* Footer */
.main-footer { background-color: #1a245e; color: #A0AABF; padding: 70px 0 20px; }
.footer-container { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 40px; margin-bottom: 50px; }
.footer-col h3 { color: var(--color-text-light); margin-bottom: 25px; font-size: 1.2rem; }
.footer-col p { margin-bottom: 15px; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 12px; }
.footer-col a { color: #A0AABF; text-decoration: none; transition: var(--transition-standard); }
.footer-col a:hover, .footer-col a:focus { color: var(--color-secondary); padding-left: 5px; }
.footer-bottom { text-align: center; border-top: 1px solid rgba(255,255,255,0.1); padding-top: 25px; font-size: 0.9rem; }

/* Responsive */
@media (max-width: 992px) { .hero-title { font-size: 3.5rem; } }
@media (max-width: 768px) {
    .desktop-nav { display: none; }
    .mobile-menu-toggle { display: block; }
    .hero-title { font-size: 2.8rem; }
    .hero-subtitle { font-size: 1.2rem; }
    .hero-section { padding: 100px 0 50px 0; }
}