/* //! Advanced CSS Architecture - Performance-Optimized Design System */
/* //! Zero-Cost Abstractions via CSS Custom Properties */

:root {
/* //! Color Palette - Modern Brand Identity */
–color-primary: #0052cc;
–color-secondary: #4c8bea;
–color-accent: #00d4ff;
–color-success: #10b981;
–color-warning: #f59e0b;
–color-error: #ef4444;

/* //! Semantic Color System - Light Theme */
–color-background: #ffffff;
–color-surface: #f8fafc;
–color-surface-elevated: #ffffff;
–color-text-primary: #0f172a;
–color-text-secondary: #475569;
–color-text-tertiary: #64748b;
–color-border: #e2e8f0;
–color-border-focus: var(–color-primary);

/* //! Shadow System - Material Design 3.0 Inspired */
–shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.05);
–shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
–shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
–shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
–shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
–shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);

/* //! Typography Scale - Perfect Fourth (1.333) */
–font-size-xs: 0.75rem;    /* 12px */
–font-size-sm: 0.875rem;   /* 14px */
–font-size-base: 1rem;     /* 16px */
–font-size-lg: 1.125rem;   /* 18px */
–font-size-xl: 1.25rem;    /* 20px */
–font-size-2xl: 1.5rem;    /* 24px */
–font-size-3xl: 1.875rem;  /* 30px */
–font-size-4xl: 2.25rem;   /* 36px */
–font-size-5xl: 3rem;      /* 48px */
–font-size-6xl: 3.75rem;   /* 60px */

/* //! Font Weight System */
–font-weight-light: 300;
–font-weight-normal: 400;
–font-weight-medium: 500;
–font-weight-semibold: 600;
–font-weight-bold: 700;
–font-weight-extrabold: 800;

/* //! Spacing Scale - Golden Ratio Inspired */
–space-1: 0.25rem;   /* 4px */
–space-2: 0.5rem;    /* 8px */
–space-3: 0.75rem;   /* 12px */
–space-4: 1rem;      /* 16px */
–space-5: 1.25rem;   /* 20px */
–space-6: 1.5rem;    /* 24px */
–space-8: 2rem;      /* 32px */
–space-10: 2.5rem;   /* 40px */
–space-12: 3rem;     /* 48px */
–space-16: 4rem;     /* 64px */
–space-20: 5rem;     /* 80px */
–space-24: 6rem;     /* 96px */

/* //! Border Radius System */
–radius-sm: 0.375rem;   /* 6px */
–radius-base: 0.5rem;   /* 8px */
–radius-md: 0.75rem;    /* 12px */
–radius-lg: 1rem;       /* 16px */
–radius-xl: 1.5rem;     /* 24px */
–radius-full: 9999px;

/* //! Animation System - Easing Functions */
–ease-in: cubic-bezier(0.4, 0, 1, 1);
–ease-out: cubic-bezier(0, 0, 0.2, 1);
–ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
–ease-bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);

/* //! Transition Duration */
–duration-fast: 150ms;
–duration-base: 300ms;
–duration-slow: 500ms;

/* //! Z-Index Scale */
–z-dropdown: 1000;
–z-sticky: 1020;
–z-fixed: 1030;
–z-modal-backdrop: 1040;
–z-modal: 1050;
–z-popover: 1060;
–z-tooltip: 1070;
–z-toast: 1080;
}

/* //! Dark Theme - Advanced Color Adaptation */
[data-theme=“dark”] {
–color-background: #0f172a;
–color-surface: #1e293b;
–color-surface-elevated: #334155;
–color-text-primary: #f1f5f9;
–color-text-secondary: #cbd5e1;
–color-text-tertiary: #94a3b8;
–color-border: #334155;
–color-border-focus: var(–color-accent);

/* //! Enhanced Shadow System for Dark Mode */
–shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.3);
–shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.4), 0 1px 2px -1px rgb(0 0 0 / 0.4);
–shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.4), 0 2px 4px -2px rgb(0 0 0 / 0.4);
–shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.4), 0 4px 6px -4px rgb(0 0 0 / 0.4);
–shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.4), 0 8px 10px -6px rgb(0 0 0 / 0.4);
–shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.5);
}

/* //! Modern CSS Reset - Performance Optimized */
*,
*::before,
*::after {
box-sizing: border-box;
margin: 0;
padding: 0;
}

html {
font-family: ‘Inter’, -apple-system, BlinkMacSystemFont, ‘Segoe UI’, system-ui, sans-serif;
line-height: 1.6;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-rendering: optimizeLegibility;
scroll-behavior: smooth;
}

body {
background-color: var(–color-background);
color: var(–color-text-primary);
transition: background-color var(–duration-base) var(–ease-out),
color var(–duration-base) var(–ease-out);
font-feature-settings: ‘cv02’, ‘cv03’, ‘cv04’, ‘cv11’;
overflow-x: hidden;
}

/* //! Typography System - Advanced Font Rendering */
h1, h2, h3, h4, h5, h6 {
font-weight: var(–font-weight-bold);
line-height: 1.2;
color: var(–color-text-primary);
letter-spacing: -0.025em;
font-feature-settings: ‘cv02’, ‘cv03’, ‘cv04’, ‘cv11’;
}

h1 { font-size: var(–font-size-5xl); }
h2 { font-size: var(–font-size-4xl); }
h3 { font-size: var(–font-size-3xl); }
h4 { font-size: var(–font-size-2xl); }
h5 { font-size: var(–font-size-xl); }
h6 { font-size: var(–font-size-lg); }

p {
margin-bottom: var(–space-4);
color: var(–color-text-secondary);
line-height: 1.7;
}

/* //! Advanced Link Styling */
a {
color: var(–color-primary);
text-decoration: none;
transition: color var(–duration-fast) var(–ease-out);
position: relative;
}

a:hover {
color: var(–color-secondary);
}

a:focus-visible {
outline: 2px solid var(–color-border-focus);
outline-offset: 2px;
border-radius: var(–radius-sm);
}

/* //! Skip Link - Accessibility Enhancement */
.skip-link {
position: absolute;
top: -100px;
left: var(–space-4);
background: var(–color-primary);
color: white;
padding: var(–space-2) var(–space-4);
border-radius: var(–radius-base);
font-weight: var(–font-weight-medium);
z-index: var(–z-tooltip);
transition: top var(–duration-base) var(–ease-out);
}

.skip-link:focus {
top: var(–space-4);
}

/* //! Error Boundary - User Experience Enhancement */
.error-boundary {
display: flex;
align-items: center;
justify-content: center;
min-height: 100vh;
background: var(–color-background);
}

.error-container {
text-align: center;
padding: var(–space-8);
max-width: 500px;
}

.error-container h1 {
color: var(–color-error);
margin-bottom: var(–space-4);
}

.error-container p {
margin-bottom: var(–space-6);
color: var(–color-text-secondary);
}

.retry-button {
background: var(–color-primary);
color: white;
border: none;
padding: var(–space-3) var(–space-6);
border-radius: var(–radius-base);
font-weight: var(–font-weight-medium);
cursor: pointer;
transition: background-color var(–duration-fast) var(–ease-out);
}

.retry-button:hover {
background: var(–color-secondary);
}

/* //! Loading States - Zero Layout Shift */
.loading-skeleton {
background: linear-gradient(
90deg,
var(–color-surface) 25%,
var(–color-border) 50%,
var(–color-surface) 75%
);
background-size: 200% 100%;
animation: loading-shimmer 1.5s infinite;
border-radius: var(–radius-base);
}

@keyframes loading-shimmer {
0% { background-position: -200% 0; }
100% { background-position: 200% 0; }
}

/* //! Theme Toggle - Advanced Interaction Design */
.theme-toggle {
position: fixed;
top: var(–space-6);
right: var(–space-6);
width: 50px;
height: 50px;
background: var(–color-surface);
border: 2px solid var(–color-border);
border-radius: var(–radius-full);
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
z-index: var(–z-fixed);
transition: all var(–duration-base) var(–ease-bounce);
box-shadow: var(–shadow-lg);
backdrop-filter: blur(10px);
}

.theme-toggle:hover {
transform: rotate(180deg) scale(1.1);
border-color: var(–color-primary);
box-shadow: var(–shadow-xl);
}

.theme-toggle:focus-visible {
outline: 2px solid var(–color-border-focus);
outline-offset: 2px;
}

/* //! Hero Section - Advanced Visual Design */
.hero-section {
position: relative;
background: linear-gradient(135deg, var(–color-primary) 0%, #6366f1 50%, var(–color-accent) 100%);
color: white;
padding: var(–space-24) 0;
overflow: hidden;
min-height: 100vh;
display: flex;
align-items: center;
justify-content: center;
}

.hero-section::before {
content: ‘’;
position: absolute;
top: -50%;
left: -50%;
width: 200%;
height: 200%;
background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
animation: hero-pulse 6s ease-in-out infinite;
pointer-events: none;
}

@keyframes hero-pulse {
0%, 100% {
transform: scale(1) rotate(0deg);
opacity: 0.5;
}
50% {
transform: scale(1.1) rotate(180deg);
opacity: 0.8;
}
}

.hero-content {
position: relative;
z-index: 2;
text-align: center;
max-width: 1200px;
margin: 0 auto;
padding: 0 var(–space-6);
}

.profile-section {
display: flex;
align-items: center;
justify-content: center;
gap: var(–space-8);
margin-bottom: var(–space-12);
flex-wrap: wrap;
}

.profile-avatar {
width: 120px;
height: 120px;
border-radius: var(–radius-full);
border: 4px solid rgba(255,255,255,0.3);
display: flex;
align-items: center;
justify-content: center;
background: rgba(255,255,255,0.1);
backdrop-filter: blur(10px);
font-size: var(–font-size-2xl);
font-weight: var(–font-weight-bold);
transition: all var(–duration-base) var(–ease-bounce);
box-shadow: var(–shadow-2xl);
}

.profile-avatar:hover {
transform: scale(1.1) rotate(5deg);
border-color: var(–color-accent);
}

.hero-title {
font-size: clamp(var(–font-size-4xl), 8vw, var(–font-size-6xl));
font-weight: var(–font-weight-extrabold);
margin-bottom: var(–space-4);
background: linear-gradient(135deg, #ffffff 0%, #e0f2fe 100%);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
text-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

.hero-subtitle {
font-size: clamp(var(–font-size-lg), 4vw, var(–font-size-2xl));
font-weight: var(–font-weight-light);
opacity: 0.9;
margin-bottom: var(–space-8);
}

.contact-links {
display: flex;
justify-content: center;
gap: var(–space-6);
flex-wrap: wrap;
}

.contact-link {
display: flex;
align-items: center;
gap: var(–space-2);
padding: var(–space-2) var(–space-4);
background: rgba(255,255,255,0.1);
backdrop-filter: blur(10px);
border-radius: var(–radius-full);
color: rgba(255,255,255,0.9);
text-decoration: none;
transition: all var(–duration-base) var(–ease-out);
border: 1px solid rgba(255,255,255,0.2);
}

.contact-link:hover {
background: rgba(255,255,255,0.2);
transform: translateY(-2px);
color: white;
box-shadow: var(–shadow-lg);
}

/* //! Card Component System - Modern Material Design */
.card {
background: var(–color-surface);
border: 1px solid var(–color-border);
border-radius: var(–radius-xl);
padding: var(–space-8);
box-shadow: var(–shadow-lg);
transition: all var(–duration-base) var(–ease-out);
position: relative;
overflow: hidden;
}

.card::before {
content: ‘’;
position: absolute;
top: 0;
left: 0;
right: 0;
height: 4px;
background: linear-gradient(90deg, var(–color-primary), var(–color-accent));
transform: scaleX(0);
transition: transform var(–duration-base) var(–ease-out);
}

.card:hover {
transform: translateY(-8px);
box-shadow: var(–shadow-2xl);
border-color: var(–color-primary);
}

.card:hover::before {
transform: scaleX(1);
}

/* //! Skill Badge System - Advanced Micro-Interactions */
.skill-badge {
display: inline-flex;
align-items: center;
padding: var(–space-2) var(–space-4);
background: linear-gradient(135deg, var(–color-primary) 0%, var(–color-secondary) 100%);
color: white;
border-radius: var(–radius-full);
font-size: var(–font-size-sm);
font-weight: var(–font-weight-medium);
transition: all var(–duration-base) var(–ease-bounce);
cursor: pointer;
position: relative;
overflow: hidden;
}

.skill-badge::before {
content: ‘’;
position: absolute;
top: 0;
left: -100%;
width: 100%;
height: 100%;
background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
transition: left var(–duration-slow) var(–ease-out);
}

.skill-badge:hover {
transform: scale(1.05);
box-shadow: 0 8px 25px rgba(0, 82, 204, 0.3);
}

.skill-badge:hover::before {
left: 100%;
}

/* //! Performance Chart - Data Visualization Enhancement */
.performance-chart {
background: var(–color-surface);
border-radius: var(–radius-xl);
padding: var(–space-8);
box-shadow: var(–shadow-lg);
border: 1px solid var(–color-border);
}

.chart-bar {
background: linear-gradient(90deg, var(–color-primary), var(–color-accent));
height: var(–space-3);
border-radius: var(–radius-base);
transition: width var(–duration-slow) var(–ease-out);
position: relative;
overflow: hidden;
}

.chart-bar::before {
content: ‘’;
position: absolute;
top: 0;
left: -100%;
width: 100%;
height: 100%;
background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
animation: chart-shimmer 2s infinite;
}

@keyframes chart-shimmer {
0% { left: -100%; }
100% { left: 100%; }
}

/* //! Grid System - Modern CSS Grid Implementation */
.grid {
display: grid;
gap: var(–space-8);
}

.grid-cols-1 { grid-template-columns: repeat(1, 1fr); }
.grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid-cols-4 { grid-template-columns: repeat(4, 1fr); }

.grid-auto-fit {
grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

/* //! Utility Classes - Atomic Design System */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: var(–space-2); }
.gap-4 { gap: var(–space-4); }
.gap-6 { gap: var(–space-6); }
.gap-8 { gap: var(–space-8); }

.text-center { text-align: center; }
.text-primary { color: var(–color-primary); }
.text-secondary { color: var(–color-text-secondary); }

.bg-surface { background-color: var(–color-surface); }
.bg-primary { background-color: var(–color-primary); }

.rounded-lg { border-radius: var(–radius-lg); }
.rounded-xl { border-radius: var(–radius-xl); }
.rounded-full { border-radius: var(–radius-full); }

.shadow-lg { box-shadow: var(–shadow-lg); }
.shadow-xl { box-shadow: var(–shadow-xl); }

.hidden { display: none; }
.invisible { visibility: hidden; }

/* //! Print Styles - Professional Document Output */
@media print {
:root {
–color-background: #ffffff;
–color-text-primary: #000000;
–color-text-secondary: #333333;
–color-surface: #ffffff;
–color-border: #e5e5e5;
}

.theme-toggle,
.contact-links,
.hero-section::before {
display: none !important;
}

.hero-section {
background: #ffffff !important;
color: #000000 !important;
min-height: auto;
padding: var(–space-8) 0;
}

.card {
break-inside: avoid;
box-shadow: none;
border: 1px solid #e5e5e5;
}

body {
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
}

/* //! Responsive Design - Mobile-First Approach */
@media (max-width: 768px) {
.hero-content {
padding: 0 var(–space-4);
}

.profile-section {
flex-direction: column;
gap: var(–space-6);
}

.contact-links {
flex-direction: column;
align-items: center;
}

.grid-cols-2 {
grid-template-columns: 1fr;
}

.card {
padding: var(–space-6);
}
}

@media (max-width: 480px) {
.theme-toggle {
width: 45px;
height: 45px;
top: var(–space-4);
right: var(–space-4);
}

.hero-section {
padding: var(–space-16) 0;
}

.hero-title {
font-size: var(–font-size-3xl);
}

.hero-subtitle {
font-size: var(–font-size-lg);
}
}

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

@media (prefers-contrast: high) {
:root {
–color-border: #000000;
–color-text-secondary: #000000;
}

[data-theme=“dark”] {
–color-border: #ffffff;
–color-text-secondary: #ffffff;
}
}