/* PREVENT TRANSITION FLASH ON LOAD */
.preload * {
    transition: none !important;
}

/* --- GLOBAL VARIABLES --- */
:root {
    /* Light Mode */
    --bg-body: #f8f9fa;
    --bg-card: #ffffff;
    --bg-nav: rgba(255, 255, 255, 0.95);
    --text-primary: #2d3748;
    --text-secondary: #718096;
    --accent-color: #3182ce;
    --accent-light: #ebf8ff;
    --border-color: #e2e8f0;
    --toggle-bg: #e2e8f0;
    
    --font-main: 'Inter', sans-serif;
    --font-display: 'Playfair Display', serif;
    
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
    --radius-md: 8px;
	/* NEW: Specific background for Education Cards (Light Mode) */
    --bg-edu-card: #e1f0fa; 
    --border-edu-card: rgba(0, 242, 254, 0.3);
}

/* DARK MODE */
[data-theme="dark"] {
    --bg-body: #0f172a;
    --bg-card: #1e293b;
    --bg-nav: rgba(15, 23, 42, 0.95);
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --accent-color: #38bdf8;
    --accent-light: rgba(56, 189, 248, 0.1);
    --border-color: #334155;
    --toggle-bg: #334155;
	/* NEW: Specific background for Education Cards (Dark Mode) */
    /* Lighter than the body (#0f172a) to create separation */
    --bg-edu-card: rgba(30, 41, 59, 0.8); 
    --border-edu-card: rgba(255, 255, 255, 0.1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html {
    scroll-behavior: smooth;
    overflow-y: scroll; /* Forces scrollbar to appear on all pages to prevent layout shift */
}

body {
    background-color: var(--bg-body);
    color: var(--text-primary);
    font-family: var(--font-main);
    line-height: 1.7;
    transition: background-color 0.3s, color 0.3s;
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

/* --- NAVIGATION --- */
nav {
    position: fixed;
    top: 0; width: 100%; height: 70px;
    background: var(--bg-nav);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    display: grid;
    grid-template-columns: 200px 1fr 200px; 
    align-items: center;
    padding: 0 5%;
    z-index: 1000;
    transition: background-color 0.3s, border-color 0.3s;
}

.nav-logo {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    justify-self: start;
}

.nav-links { display: flex; gap: 2rem; justify-content: center; }
.nav-links a { font-size: 0.9rem; font-weight: 500; color: var(--text-secondary); }
.nav-links a:hover, .nav-links a.active { color: var(--accent-color); }

.nav-controls { display: flex; gap: 1.5rem; justify-self: end; align-items: center; }

/* --- LANGUAGE SELECTOR --- */
.lang-selector {
    display: flex;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    user-select: none;
}
.lang-opt { cursor: pointer; opacity: 0.6; transition: opacity 0.2s; }
.lang-opt:hover { opacity: 1; color: var(--accent-color); }
.lang-opt.active { opacity: 1; color: var(--accent-color); text-decoration: underline; text-underline-offset: 4px; }

/* --- THEME TOGGLE SWITCH --- */
.theme-toggle {
    display: flex; align-items: center;
    background: var(--toggle-bg);
    border-radius: 20px; padding: 2px;
    position: relative; cursor: pointer;
    width: 110px; height: 32px;
    user-select: none;
}

.theme-btn {
    flex: 1; text-align: center;
    font-size: 0.7rem; font-weight: 600;
    z-index: 2; color: var(--text-secondary);
    transition: color 0.3s;
    text-transform: uppercase; line-height: 32px;
}

.toggle-slider {
    position: absolute; top: 2px; left: 2px;
    width: 50%; height: 28px;
    background: var(--bg-card);
    border-radius: 18px;
    transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    box-shadow: var(--shadow-sm);
}

[data-theme="dark"] .toggle-slider { transform: translateX(98%); }
[data-theme="light"] .theme-btn-light { color: var(--accent-color); }
[data-theme="dark"] .theme-btn-dark { color: var(--accent-color); }

/* --- HEADER --- */
.page-header {
    padding: 140px 5% 60px;
    text-align: center;
    background: var(--bg-body);
    border-bottom: 1px solid var(--border-color);
    transition: background-color 0.3s, border-color 0.3s;
}
.page-header h1 { font-family: var(--font-display); font-size: 3rem; margin-bottom: 0.5rem; color: var(--text-primary); }
.page-header p { color: var(--text-secondary); max-width: 600px; margin: 0 auto; }

/* --- GENERIC SPLIT LAYOUT (Formerly Career Layout) --- */
.split-layout {
    display: grid;
    grid-template-columns: 280px 1fr; 
    gap: 4rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 5% 100px;
    position: relative;
}

/* SIDEBAR NAVIGATION */
.side-nav {
    position: sticky; top: 100px;
    height: fit-content;
    padding-right: 20px;
    border-right: 1px solid var(--border-color);
    transition: border-color 0.3s;
}

.side-nav-title {
    font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px;
    color: var(--text-secondary); margin-bottom: 1rem; font-weight: 700;
}

.side-nav li { margin-bottom: 1rem; }

.side-nav a {
    display: block; padding: 10px 15px;
    border-radius: var(--radius-md);
    font-size: 0.9rem; color: var(--text-secondary);
    border-left: 3px solid transparent;
}

.side-nav a:hover { background: var(--bg-card); color: var(--accent-color); }

.side-nav a.current {
    background: var(--bg-card);
    color: var(--accent-color);
    border-left-color: var(--accent-color);
    box-shadow: var(--shadow-sm);
    font-weight: 600;
}

/* CONTENT FEED */
.feed-container { display: flex; flex-direction: column; gap: 4rem; }

.feed-card {
    background: var(--bg-card);
    padding: 40px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: background-color 0.3s, border-color 0.3s;
}

.card-header {
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
}

.card-meta { color: var(--accent-color); font-weight: 600; font-size: 0.9rem; }
.card-title { font-family: var(--font-display); font-size: 2rem; margin: 0.5rem 0; line-height: 1.2; color: var(--text-primary); }
.card-subtitle { color: var(--text-secondary); font-size: 1.1rem; }
.card-body { font-size: 1.05rem; color: var(--text-primary); opacity: 0.9; text-align: justify; }

footer { text-align: center; padding: 40px; color: var(--text-secondary); border-top: 1px solid var(--border-color); margin-top: auto; transition: border-color 0.3s; }

/* --- PUBLICATIONS SPECIFIC STYLES --- */

/* Group Separation */
.pub-group {
    margin-bottom: 4rem;
    scroll-margin-top: 120px; /* Offset for sticky header */
}

.group-title {
    font-family: var(--font-display);
    font-size: 1.8rem;
    color: var(--accent-color);
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 0.5rem;
    margin-bottom: 2rem;
}

/* List Styling */
.pub-list {
    list-style: none;
    counter-reset: pub-counter; /* Automatic numbering */
}

.pub-item {
    position: relative;
    padding: 0 0 1.5rem 2.5rem; /* Space for number */
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 0.95rem;
    transition: transform 0.3s, opacity 0.3s;
}

.pub-item:last-child { border-bottom: none; }

/* The Number (1., 2., etc) */
.pub-item::before {
    counter-increment: pub-counter;
    content: counter(pub-counter) ".";
    position: absolute;
    left: 0; top: 0;
    color: var(--accent-color);
    font-weight: 700;
    font-family: var(--font-display);
}

/* Text Formatting */
.pub-item strong {
    color: var(--text-primary);
    font-weight: 600;
    display: block; /* Make title stand out on new line? Optional. */
    margin-bottom: 0.2rem;
    font-size: 1.05rem;
}

.pub-item b {
    color: var(--text-primary); /* Authors */
    font-weight: 500;
}

.pub-item em {
    color: var(--text-secondary); /* Venue/Date */
    font-style: italic;
    opacity: 0.8;
}

/* Hover Effect */
.pub-item:hover {
    /* transform: translateX(10px); Simple slide */
}

/* --- RESEARCH SPECIFIC STYLES --- */

/* Project Card specific tweaks */
.project-card {
    position: relative;
    /* Inherits .feed-card styles via HTML class, extra styles here */
}

.project-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

/* The Funding Source Badge */
.funding-badge {
    display: inline-block;
    padding: 4px 12px;
    background-color: var(--accent-light);
    color: var(--accent-color);
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    border: 1px solid transparent;
    transition: all 0.3s;
}

.project-card:hover .funding-badge {
    border-color: var(--accent-color);
    background-color: var(--bg-card);
}

.funds-amount {
    display: block;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px dashed var(--border-color);
    font-family: var(--font-main);
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.funds-amount strong {
    color: var(--text-primary);
}

/* Link button for "More Details" */
.project-link {
    display: inline-block;
    margin-top: 1.5rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent-color);
    text-decoration: none;
    border-bottom: 2px solid transparent;
}

.project-link:hover {
    border-bottom-color: var(--accent-color);
}

/* --- CONSULTING SPECIFIC STYLES --- */

/* Make the card narrower to leave room for the note on the right */
.consulting-card {
    max-width: 80%; /* 20% reduction */
    margin-right: auto; /* Aligns card to the left of its container */
}

/* Prestigious Card Styling */
.consulting-card[data-prestigious="true"] {
    border-color: var(--accent-color);
    background: linear-gradient(to bottom right, var(--bg-card), var(--accent-light));
}

.consulting-card[data-prestigious="true"] .card-title::before {
    content: '★ ';
    color: #f59e0b;
    margin-right: 5px;
}

/* Floating Note Box */
.note-box {
    position: absolute; /* Changed from fixed */
    width: 150px; 
    padding: 0.8rem;
    background: var(--bg-card);
    border: 1px solid var(--accent-color);
    border-radius: var(--radius-md);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    color: var(--text-primary);
    font-size: 0.8rem;
    line-height: 1.4;
    z-index: 2000;
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.note-box.visible {
    opacity: 1;
    transform: scale(1);
}

/* The Canvas for the connecting line */
.connector-canvas {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: 1999; pointer-events: none;
    opacity: 0; transition: opacity 0.3s ease;
}

.connector-canvas.visible { opacity: 1; }

/* --- CONNECT SPECIFIC STYLES --- */

.connect-container {
    min-height: calc(100vh - 140px); /* Full height minus nav/footer */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 5% 60px;
}

.contact-card {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    width: 100%;
    max-width: 1000px;
    background-color: var(--bg-card);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
}

/* Left Column: CV Info */
.contact-info {
    padding: 3rem;
    background-color: var(--bg-body);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.info-title {
    font-family: var(--font-display);
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.info-desc {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-size: 1rem;
}

.update-badge {
    display: inline-block;
    margin-top: 1rem;
    font-size: 0.8rem;
    color: var(--accent-color);
    font-weight: 600;
    background: var(--accent-light);
    padding: 4px 12px;
    border-radius: 20px;
}

/* Download Button */
.btn-download {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 12px 24px;
    background-color: var(--text-primary); /* High contrast */
    color: var(--bg-card);
    font-weight: 600;
    border-radius: var(--radius-md);
    width: fit-content;
    transition: transform 0.2s, opacity 0.2s;
}

.btn-download:hover {
    transform: translateY(-2px);
    opacity: 0.9;
}

/* Right Column: Form */
.contact-form-wrapper {
    padding: 3rem;
    background-color: var(--bg-card);
}

.form-group {
    position: relative;
    margin-bottom: 1.5rem;
}

/* Floating Input Styles */
.form-input, .form-textarea {
    width: 100%;
    padding: 12px 0;
    font-size: 1rem;
    color: var(--text-primary);
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border-color);
    outline: none;
    transition: border-color 0.3s;
    font-family: var(--font-main);
}

.form-textarea {
    resize: vertical;
    min-height: 100px;
}

.form-label {
    position: absolute;
    top: 12px;
    left: 0;
    color: var(--text-secondary);
    font-size: 1rem;
    pointer-events: none;
    transition: 0.3s ease all;
}

/* Active State for Inputs (Focus or Valid) */
.form-input:focus ~ .form-label,
.form-input:not(:placeholder-shown) ~ .form-label,
.form-textarea:focus ~ .form-label,
.form-textarea:not(:placeholder-shown) ~ .form-label {
    top: -10px;
    font-size: 0.8rem;
    color: var(--accent-color);
}

.form-input:focus, .form-textarea:focus {
    border-bottom-color: var(--accent-color);
}

/* Submit Button */
.btn-submit {
    background-color: var(--accent-color);
    color: white;
    border: none;
    padding: 12px 30px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: background-color 0.3s;
    margin-top: 1rem;
}

.btn-submit:hover {
    filter: brightness(1.1);
}

.form-status {
    margin-top: 1rem;
    font-size: 0.9rem;
    min-height: 1.5em;
}

/* Responsive */
@media (max-width: 900px) {
    .contact-card { grid-template-columns: 1fr; }
    .contact-info { border-right: none; border-bottom: 1px solid var(--border-color); text-align: center; align-items: center; }
    .connect-container { padding-top: 100px; padding-bottom: 40px; }
}

/* =========================================
   INDEX PAGE SPECIFIC STYLES
   ========================================= */

/* --- SCROLL ANIMATION UTILITIES --- */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform, opacity;
}

.reveal-on-scroll.active {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered delays */
.delay-100 { transition-delay: 100ms; }
.delay-200 { transition-delay: 200ms; }
.delay-300 { transition-delay: 300ms; }

/* --- HERO SECTION (UPDATED LAYOUT) --- */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 100px 10% 0; /* Added top padding for fixed nav */
    position: relative;
    overflow: hidden;
}

/* 1. Top Centered Header */
.hero-header {
    text-align: center;
    margin-bottom: 3rem;
    z-index: 2;
}

.hero-greeting {
    color: var(--accent-color);
    font-family: var(--font-body);
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(3rem, 6vw, 5rem); /* Large responsive font */
    line-height: 1.1;
    font-weight: 800;
    background: linear-gradient(135deg, var(--text-primary) 30%, var(--accent-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* 2. Split Content (Visual Left/Center, Text Right/Bottom) */
.hero-content {
    max-width: 1200px;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 4rem;
    z-index: 2;
    margin: 0 auto;
}

/* Hero Visual (Orbit + Image) */
.hero-visual {
    position: relative;
    height: 450px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.orbit-ring {
    position: absolute;
    border: 1px dashed var(--border-color);
    border-radius: 50%;
    animation: rotate 60s linear infinite;
}
.orbit-1 { width: 420px; height: 420px; border-color: var(--accent-light); opacity: 0.5; }
.orbit-2 { width: 320px; height: 320px; animation-direction: reverse; animation-duration: 40s; border-color: var(--accent-color); opacity: 0.3; }

/* Profile Image Mask */
.profile-mask {
    width: 280px;
    height: 280px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid var(--accent-color);
    box-shadow: 0 0 30px rgba(0, 242, 254, 0.2);
    position: relative;
    z-index: 10;
}

.profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Hero Text (Role & Desc) */
.hero-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-roles {
    font-size: 1.4rem;
    color: var(--text-secondary);
    min-height: 30px;
    margin-bottom: 1.5rem;
    font-family: var(--font-display);
}

.typewriter {
    color: var(--accent-color);
    border-right: 3px solid var(--accent-color);
    animation: blink 0.75s step-end infinite;
}

.hero-desc {
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    font-size: 1.05rem;
    line-height: 1.6;
}

.cta-group { display: flex; gap: 1rem; }

.btn {
    padding: 12px 30px;
    font-family: var(--font-display);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: var(--radius-md);
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}
.btn-primary { background: var(--accent-color); color: var(--bg-body); }
.btn-primary:hover { box-shadow: 0 0 20px var(--accent-light); transform: translateY(-2px); }
.btn-outline { border: 1px solid var(--accent-color); color: var(--accent-color); }
.btn-outline:hover { background: var(--accent-light); transform: translateY(-2px); }

@keyframes rotate { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes blink { 50% { border-color: transparent; } }


/* --- SECTIONS COMMON --- */
.home-section { padding: 100px 5%; }
.section-header { text-align: center; margin-bottom: 4rem; }
.section-title { font-family: var(--font-display); font-size: 2.5rem; margin-bottom: 1rem; color: var(--text-primary); }
.section-subtitle { color: var(--accent-color); text-transform: uppercase; letter-spacing: 2px; font-size: 0.9rem; }


/* --- CAREER TIMELINE (ZIG ZAG) --- */
.timeline {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px 0;
}
.timeline::after {
    content: ''; position: absolute; width: 2px; background-color: var(--border-color);
    top: 0; bottom: 0; left: 50%; margin-left: -1px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
    box-sizing: border-box;
    margin-bottom: 2rem;
}
.timeline-item.left { left: 0; text-align: right; }
.timeline-item.right { left: 50%; text-align: left; }

.timeline-dot {
    position: absolute; width: 16px; height: 16px;
    background-color: var(--bg-body); border: 3px solid var(--accent-color);
    border-radius: 50%; top: 20px; z-index: 1;
}
.left .timeline-dot { right: -8px; }
.right .timeline-dot { left: -8px; }

.timeline-content {
    padding: 25px;
    background-color: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s;
}
.timeline-content:hover { transform: translateY(-5px); border-color: var(--accent-color); }

.timeline-date {
    color: var(--accent-color); font-weight: 700; font-size: 0.85rem;
    text-transform: uppercase; display: block; margin-bottom: 0.5rem;
}
.timeline-title { font-family: var(--font-display); font-size: 1.2rem; margin-bottom: 0.2rem; line-height: 1.2; }
.timeline-company { font-size: 0.95rem; color: var(--text-secondary); margin-bottom: 1rem; }
.timeline-tag { 
    display: inline-block; padding: 4px 10px; font-size: 0.75rem; 
    background: var(--accent-light); color: var(--accent-color); border-radius: 4px;
}
.view-all-link {
    display: block; text-align: center; margin-top: 3rem; font-size: 0.9rem;
    color: var(--accent-color); text-decoration: underline; text-underline-offset: 4px;
}

/* --- PUBLICATIONS STATS --- */
.stats-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1.5rem; max-width: 1100px; margin: 0 auto;
}
.stat-card {
    background: var(--bg-card); padding: 2rem 1rem; text-align: center;
    border: 1px solid var(--border-color); border-radius: var(--radius-md);
}
.stat-number { font-family: var(--font-display); font-size: 3rem; color: var(--text-primary); display: block; }
.stat-label { color: var(--text-secondary); font-size: 0.85rem; text-transform: uppercase; margin-top: 0.5rem; display: block; }


/* --- RESEARCH PREVIEW (Concise) --- */
.research-preview {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem; max-width: 1200px; margin: 0 auto;
}
.research-preview {
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 2rem; 
    max-width: 1200px; 
    margin: 0 auto;
}

.res-card-concise {
    background: var(--bg-card); border: 1px solid var(--border-color);
    border-radius: var(--radius-md); padding: 1.5rem;
    transition: transform 0.3s; display: flex; flex-direction: column;
}
.res-card-concise:hover { transform: translateY(-5px); border-color: var(--accent-color); }
.res-topic { font-size: 0.75rem; color: var(--accent-color); text-transform: uppercase; margin-bottom: 0.5rem; letter-spacing: 1px; }
.res-title { font-family: var(--font-display); font-size: 1.1rem; line-height: 1.4; margin-bottom: 1.5rem; flex-grow: 1; }
.res-link { font-size: 0.85rem; color: var(--text-secondary); text-decoration: none; border-bottom: 1px solid transparent; align-self: flex-start; transition: 0.3s; }
.res-link:hover { color: var(--accent-color); border-bottom-color: var(--accent-color); }


/* --- CONSULTING LOGOS --- */
.logo-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 4rem;
    align-items: flex-start;
}

.client-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    /* No opacity or cursor changes - strictly static */
}

.client-name {
    font-family: var(--font-display);
    font-size: 1.2rem;
    color: var(--text-secondary);
    font-weight: 700;
    text-align: center;
}

.client-logo {
    height: 80px;
    width: auto;
    max-width: 180px; /* Increased slightly to fit padding */
    object-fit: contain;
    
    /* BACKGROUND FIX */
    background-color: rgba(255, 255, 255, 0.5); /* 50% Transparent White */
    padding: 10px;       /* Space inside the background */
    border-radius: 8px;  /* Smooth corners */
    
    /* Ensure no filters affect the natural colors */
    filter: none; 
}

/* Override any Dark Mode filters since we now have a background */
[data-theme="dark"] .client-logo {
    filter: none;
}



/* =========================================
   EDUCATION PAGE STYLES
   ========================================= */

.education-container {
    min-height: calc(100vh - 140px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 100px 5% 60px;
}

.edu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2.5rem;
    width: 100%;
    max-width: 1400px;
    margin-top: 2rem;
}

/* Premium Card Design */
.edu-card {
    /* CHANGED: Now uses the variable we defined above */
    background: var(--bg-edu-card); 
    border: 1px solid var(--border-edu-card);
    
    border-radius: 20px;
    padding: 3rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease, background-color 0.3s;
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px); /* Safari support */
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Update hover state to be slightly subtler */
.edu-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15); /* Softer shadow for light mode compatibility */
    border-color: var(--accent-cyan);
}

/* Spotlight Effect Layer */
.edu-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: radial-gradient(
        600px circle at var(--mouse-x) var(--mouse-y), 
        rgba(255, 255, 255, 0.06), 
        transparent 40%
    );
    z-index: 1;
    opacity: 0;
    transition: opacity 0.4s;
    pointer-events: none;
}
.edu-card:hover::before { opacity: 1; }

/* Logo Container */
.edu-logo-wrapper {
    width: 120px;
    height: 120px;
    margin-bottom: 2rem;
    position: relative;
    z-index: 2;
    background: #ffffff;
    border-radius: 50%;
    padding: 15px;
    /* Default Shadow (Light Mode) */
    box-shadow: 0 0 20px rgba(0, 242, 254, 0.25); 
}

/* NEW: Stronger glow specifically for Dark Mode */
[data-theme="dark"] .edu-logo-wrapper {
    box-shadow: 0 0 30px rgba(0, 242, 254, 0.6); /* Increased opacity */
}

.edu-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Typography */
.edu-year {
    font-family: var(--font-body);
    color: var(--accent-cyan);
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    letter-spacing: 2px;
    z-index: 2;
}

.edu-degree {
    font-family: var(--font-display);
    font-size: 1.8rem; /* Large and bold */
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    line-height: 1.2;
    z-index: 2;
}

.edu-university {
    font-size: 1.1rem;
    /* Use text-primary for better contrast on the light blue card, 
       or keep text-secondary if it's dark enough in your theme */
    color: var(--text-secondary); 
    margin-bottom: 2rem;
    z-index: 2;
    font-weight: 500; /* Increased weight slightly for readability */
    text-transform: uppercase;
}

/* Ranking Badge - The "Gold" Element */
.ranking-badge {
    margin-top: auto; /* Pushes it to bottom */
    z-index: 2;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
    width: 100%;
}

.rank-val {
    display: block;
    font-family: var(--font-display);
    font-size: 1.4rem;
    color: #fbbf24; /* Academic Gold */
    margin-bottom: 0.25rem;
    text-shadow: 0 0 10px rgba(251, 191, 36, 0.3);
}

.rank-source {
    font-size: 0.85rem;
    color: var(--text-secondary);
    opacity: 0.8;
}

/* =========================================
   EXPERIENCE PAGE STYLES
   ========================================= */

/* Inherits most styles from .consulting-card (defined in previous steps) 
   We just need to add the Badge style */

.card-header {
    position: relative; /* To position the badge absolute inside it */
    padding-right: 120px; /* Make room for the badge so text doesn't overlap */
}

.role-type-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 0.75rem;
    font-family: var(--font-main);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 4px 12px;
    border-radius: 20px;
    border: 1px solid var(--accent-color);
}

/* Style for "Employment" (Solid) */
.role-type-badge.employment {
    background-color: var(--accent-color);
    color: var(--bg-body); /* High contrast text */
}

/* Style for "Consulting" (Outline) */
.role-type-badge.consulting {
    background-color: transparent;
    color: var(--accent-color);
}

/* --- NEW: EDUCATION SUMMARY SECTION --- */
.edu-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.edu-sum-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 2rem;
    text-align: center;
    transition: transform 0.3s, border-color 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.edu-sum-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-color);
    box-shadow: var(--shadow-sm);
}

.edu-sum-logo {
    height: 80px;
    width: auto;
    margin-bottom: 1.5rem;
    filter: grayscale(100%); /* Elegant/Muted look until hover */
    transition: filter 0.3s;
    opacity: 0.8;
}

.edu-sum-card:hover .edu-sum-logo {
    filter: grayscale(0%);
    opacity: 1;
}

.edu-sum-degree {
    font-family: var(--font-display);
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    line-height: 1.3;
}

.edu-sum-school {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Tiny gold bar for prestige indication */
.edu-sum-card::after {
    content: '';
    display: block;
    width: 40px;
    height: 2px;
    background: #fbbf24; /* Gold */
    margin-top: 1.5rem;
    opacity: 0.5;
}


/* --- SCROLL INDICATOR --- */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    opacity: 0.7;
    transition: opacity 0.5s ease;
}

/* Fade out when user starts scrolling (Handled by JS or just CSS hover) */
.hero:hover .scroll-indicator {
    opacity: 1;
}

.mouse {
    width: 30px;
    height: 50px;
    border: 2px solid var(--text-secondary);
    border-radius: 20px;
    position: relative;
}

.wheel {
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 8px;
    background-color: var(--accent-color);
    border-radius: 2px;
    animation: scroll-wheel 1.5s ease-in-out infinite;
}

@keyframes scroll-wheel {
    0% {
        top: 8px;
        opacity: 1;
    }
    50% {
        top: 15px; /* Move down */
        opacity: 1;
    }
    100% {
        top: 25px; /* Fade out at bottom */
        opacity: 0;
    }
}

/* --- FILTER CONTROLS (Experience Page) --- */
.filter-container {
    display: flex;
    justify-content: center;
    margin-bottom: 3rem;
}

.filter-wrapper {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr; /* 3 Equal columns */
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 30px;
    padding: 4px;
    width: 100%;
    max-width: 400px; /* Max width of the whole toggle */
}

/* The sliding background "Pill" */
.filter-pill {
    position: absolute;
    top: 4px;
    left: 4px;
    width: calc(33.33% - 5px); /* 1/3 minus padding */
    height: calc(100% - 8px);
    background: var(--accent-color);
    border-radius: 25px;
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    z-index: 1;
}

/* The clickable buttons */
.filter-btn {
    position: relative;
    z-index: 2;
    background: transparent;
    border: none;
    padding: 10px 0;
    font-family: var(--font-main);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.3s;
    text-align: center;
}

/* Text color when active (on top of the pill) */
.filter-btn.active {
    color: var(--bg-body); /* Dark text on Cyan pill for contrast */
}

/* Responsive Adjustments */
@media (max-width: 600px) {
    .filter-wrapper { max-width: 320px; }
    .filter-btn { font-size: 0.8rem; }
}

/* Responsive tweak for the badge */
@media (max-width: 600px) {
    .card-header { padding-right: 1rem; padding-top: 3rem; } /* Push text down */
    .role-type-badge { top: 0.8rem; left: 1rem; right: auto; } /* Move badge to top left */
}

/* Responsive */
@media (max-width: 1100px) {
    .edu-grid { grid-template-columns: 1fr; max-width: 600px; }
}

/* RESPONSIVE UNIFIED */
@media (max-width: 1000px) {
    /* Nav & Layout */
    nav { grid-template-columns: auto 1fr; flex-wrap: wrap; height: auto; padding: 1rem 5%; }
    .nav-links { order: 3; width: 100%; justify-content: center; margin-top: 1rem; }
    .nav-controls { justify-self: end; }
    .split-layout { grid-template-columns: 1fr; }
    .side-nav { display: none; }
    
    /* Index Specific */
    .hero { padding-top: 120px; justify-content: flex-start; }
    .hero-content { grid-template-columns: 1fr; text-align: center; gap: 2rem; }
    .hero-text { align-items: center; }
    .cta-group { justify-content: center; }
    
    /* Timeline */
    .timeline::after { left: 31px; }
    .timeline-item { width: 100%; padding-left: 70px; padding-right: 25px; text-align: left; }
    .timeline-item.left, .timeline-item.right { left: 0; text-align: left; }
    .left .timeline-dot, .right .timeline-dot { left: 23px; right: auto; }
}