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

/* ============================================
   DESIGN SYSTEM 
   ============================================ */
:root {
    /* MASTER SPACING UNIT - Controls entire site rhythm */
    --space-unit: 2rem;
    
    /* Derived spacing values */
    --space-quarter: calc(var(--space-unit) * 0.12);  /* 0.5rem */
    --space-half: calc(var(--space-unit) * .25);      /* 1rem */
    --space-base: var(--space-unit);                  /* 2rem */
    --space-1-5x: calc(var(--space-unit) * 1);      /* 3rem */
    --space-2x: calc(var(--space-unit) * 1.5);          /* 4rem */
    
    /* Grid & Layout */
    --container-max: 1200px;
    --grid-gap: var(--space-base);
    --section-gap: var(--space-2x);
    
    /* Typography Scale */
    --text-xs: 0.875rem;
    --text-sm: 1rem;
    --text-base: 1.125rem;
    --text-md: 1.25rem;
    --text-lg: 1.5rem;
    --text-xl: 1.875rem;
    --text-2xl: 2.25rem;
    --text-3xl: 3rem;
    
    /* Colors */
    --primary: #6366f1;
    --primary-glow: #818cf8;
    --text: #1a1a2e;
    --text-light: #64748b;
    --text-lighter: #94a3b8;
    --surface: #ffffff;
    --surface-alt: #f8f9fa;
    --border: #e5e7eb;
    --bg-gradient: linear-gradient(135deg, #f5f7fa 0%, #e7ebf2 100%);
    
    /* Effects */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 20px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-sm: 0 4px 24px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 8px 32px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.1);
    
    /* Z-index Scale */
    --z-base: 1;
    --z-elevated: 10;
    --z-overlay: 100;
    --z-modal: 1000;
    --z-nav: 1001;
}

/* ============================================
   DOCUMENT FOUNDATION
   ============================================ */
html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: "Diatype Variable", system-ui, -apple-system, sans-serif;
    font-size: var(--text-base);
    line-height: 1.6;
    color: var(--text);
    background: var(--bg-gradient);
    min-height: 100vh;
    overflow-x: hidden;
    font-variation-settings: 'slnt' 0, 'MONO' 0;
}

/* ============================================
   HIERARCHICAL LAYOUT SYSTEM
   Level 1: Page Container
   ============================================ */
.page-content {
    /* Master container - controls ALL primary spacing */
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: var(--space-base);
    padding-top: calc(80px + var(--space-base)); /* Fixed nav height + spacing */
    
    /* Use CSS Grid for consistent section spacing */
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--section-gap);
}

/* ============================================
   Level 2: Section Containers
   ============================================ */
section,
.section,
.hero,
.info-section,
.projects-section {
    /* Sections only define their internal layout, not external spacing */
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--grid-gap);
}

/* ============================================
   Level 3: Content Blocks
   ============================================ */
.section-pill,
.info-grid,
.projects-grid,
.content-block {
    /* Content blocks use internal padding, no margins */
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: var(--space-base);
    border: 1px solid var(--border);
}

/* Grid layouts for cards */
.info-grid,
.projects-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--grid-gap);
    background: transparent;
    border: none;
    padding: 0;
}

/* ============================================
   Level 4: Components
   ============================================ */
.info-card,
.project-card,
.card {
    /* Cards fill their grid cells, no individual margins */
    background: var(--surface);
    border-radius: var(--radius-md);
    padding: var(--space-base);
    border: 1px solid var(--border);
    transition: var(--transition);
}

/* ============================================
   TYPOGRAPHY SYSTEM
   All text elements have NO margins by default
   Spacing comes from parent containers
   ============================================ */
h1, h2, h3, h4, h5, h6, p, ul, ol, li {
    margin: 0;
    padding: 0;
}

h1 {
    font-family: "Monument Grotesk Semi-Mono Variable", system-ui, sans-serif;
    font-size: var(--text-xl);
    line-height: 1.2;
    font-weight: 500;
    font-variation-settings: 'slnt' 0, 'MONO' 0.5;
}

h2 {
    font-family: "Diatype Variable", system-ui, sans-serif;
    font-size: var(--text-lg);
    line-height: 1.3;
    font-weight: 700;
}

h3 {
    font-size: var(--text-md);
    line-height: 1.4;
    font-weight: 700;
}

h4 {
    font-size: var(--text-base);
    font-weight: 600;
}

p {
    font-size: var(--text-base);
    line-height: 1.6;
}

/* Text spacing ONLY when inside content containers */
.content-text > * + * {
    margin-top: var(--space-half);
}

/* ============================================
   NAVIGATION SYSTEM
   Fixed positioning outside of main flow
   ============================================ */
.nav-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 80px;
    z-index: var(--z-nav);
    padding: var(--space-half);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

nav {
    height: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-half);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: "Diatype Semi-Mono Variable", Icons;
    font-size: var(--text-md);
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
    font-variation-settings: 'slnt' 0, 'MONO' 0.5;
	font-style: normal;
}

/* Navigation Links - Using Flexbox Gap */
.nav-links {
    display: flex;
    align-items: center;
    gap: var(--space-half);
    list-style: none;
}

.nav-link {
    padding: var(--space-quarter) var(--space-half);
    color: var(--text);
    text-decoration: none;
    font-family: "Diatype Semi-Mono Variable", Icons;
    font-size: var(--text-base);
    border-radius: var(--radius-sm);
    transition: var(--transition);
	font-style: normal;
	font-weight: 500;
	font-variation-settings: 'slnt' 0, 'MONO' 0.5;
}

/* Mobile Menu */
.mobile-menu-btn {
    display: none;
    width: 32px;
    height: 32px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 4px;
    background: transparent;
    border: none;
    cursor: pointer;
}

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: var(--transition);
}

        .info-card .label {
        	margin-bottom: 1rem; 
}
/* ============================================
   HERO SECTION
   ============================================ */
.hero {
    color: #ffffff;
    border-radius: var(--radius-lg);
    padding: var(--space-2x) var(--space-base);
    position: relative;
    overflow: hidden;
}
        .hero::before {
            content: '';
            position: absolute;
            top: -50%;
            right: -10%;
            width: 400px;
            height: 400px;
            background: linear-gradient( #5D67EB 0%, #E25DEB 100%);
            border-radius: 50%;
            opacity: 0.1;
        }

.hero-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-half);
    position: relative;
    z-index: 2;
}

.hero h1,
.hero .subtitle,
.hero .description {
    color: white;
}

.subtitle {
    font-family: "Monument Grotesk Mono Variable", system-ui, sans-serif;
    font-size: var(--text-base);
    font-weight: 500;
    font-variation-settings: 'slnt' 0, 'MONO' 1;
    text-transform: uppercase;
    opacity: 0.95;
}

.description {
    font-size: var(--text-base);
    line-height: 1.6;
    opacity: 0.9;
}

/* Hero Buttons Container */
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-half);
    margin-top: var(--space-half);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn,
.email-btn,
.resume-btn {
    display: inline-flex;
    align-items: center;
    margin: 0px 1rem;
    gap: var(--space-quarter);
    padding: var(--space-half) var(--space-base);
    border: 2px solid var(--text);
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text);
    font-size: var(--text-base);
    font-weight: 500;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
}

/* ============================================
   LABELS & PILLS
   ============================================ */
.label,
.project-label {
    display: inline-block;
    font-family: "Monument Grotesk Variable", system-ui, sans-serif;
    font-size: var(--text-xs);
    font-weight: 500;
    text-transform: uppercase;
    padding: var(--space-quarter) var(--space-half);
    border-radius: var(--radius-md);
    background: var(--surface-alt);
    color: var(--text-light);
}

.skill-pill,
.pill {
    display: inline-block;
    padding: var(--space-quarter) var(--space-half);
    background: var(--surface-alt);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--text-light);
}

/* Pills container with flex gap */
.pills-container {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-quarter);
}

/* ============================================
   FOOTER
   ============================================ */
footer {
    width: 100%;
    padding: var(--space-2x) var(--space-base);
    border-top: 1px solid var(--border);
    margin-top: var(--space-2x);
    text-align: center;
}
    footer.a{
	align-items: center;
}
/* ============================================
   MOBILE STYLES (Default)
   ============================================ */
@media (max-width: 767px) {
    :root {
        /* Adjust spacing for mobile */
        --space-unit: 1.5rem;
        --section-gap: var(--space-1-5x);
    }
    
    .page-content {
        padding: var(--space-half);
        padding-top: calc(70px + var(--space-half));
    }
    
    /* Mobile navigation */
    .mobile-menu-btn {
        display: flex;
    }
    
    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: var(--surface);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: var(--space-base);
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .nav-links.active {
        transform: translateX(0);
    }
    
    .nav-link {
        font-size: var(--text-md);
        padding: var(--space-half) var(--space-base);
    }
    
    /* Mobile menu animations */
    .mobile-menu-btn.active span:nth-child(1) {
        transform: translateY(6px) rotate(45deg);
    }
    
    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-btn.active span:nth-child(3) {
        transform: translateY(-6px) rotate(-45deg);
    }
    
    /* Hide footer on mobile */
    footer {
        display: none;
    }
}

/* ============================================
   TABLET STYLES
   ============================================ */
@media (min-width: 768px) {
    :root {
        /* Increase text sizes for tablet */
        --text-base: 1.25rem;
        --text-lg: 1.75rem;
        --text-xl: 2.5rem;
        --text-2xl: 3rem;
    }
    
    h1 {
        font-size: var(--text-2xl);
    }
    
    /* Grid layouts become multi-column */
    .info-grid,
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
    
    .hero {
        padding: var(--space-2x);
    }
}

/* ============================================
   DESKTOP STYLES
   ============================================ */
@media (min-width: 1024px) {
    .page-content {
        padding: var(--space-2x);
        padding-top: calc(80px + var(--space-2x));
    }
    
    /* Hover states only on desktop */
    .nav-link:hover {
        background: rgba(99, 102, 241, 0.1);
        color: var(--primary);
    }
    
    .card:hover,
    .info-card:hover,
    .project-card:hover {
        transform: translateY(-4px);
        box-shadow: var(--shadow-md);
    }
    
    .email-btn:hover {
        background: var(--primary);
        color: white;
        border-color: var(--primary);
    }
    
    .resume-btn:hover {
        background: var(--text);
        color: white;
    }
    
    .skill-pill:hover,
    .pill:hover {
        background: var(--border);
        transform: translateY(-2px);
    }
}

/* ============================================
   UTILITIES (Minimal, specific use only)
   ============================================ */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

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

/* ============================================
   ACCESSIBILITY
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

*:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    .nav-container,
    .mobile-menu-btn,
    footer {
        display: none;
    }
    
    .page-content {
        padding: 0;
        max-width: 100%;
    }
    
    * {
        background: white !important;
        color: black !important;
    }
}