/* ============================================
   ATUL KUMAR PORTFOLIO - MAIN STYLESHEET
   Modern 2026 Design System
   ============================================ */

/* ============================================
   1. CSS VARIABLES & DESIGN TOKENS
   ============================================ */

:root {
    /* Colors - Light Mode */
    --color-primary: #0057FF;
    --color-primary-light: #E8F0FF;
    --color-primary-dark: #0040CC;
    
    --color-secondary: #1a1a2e;
    --color-secondary-light: #16213e;
    
    --color-accent: #FF6B35;
    --color-accent-light: #FFE8D8;
    
    --color-success: #10B981;
    --color-warning: #F59E0B;
    --color-danger: #EF4444;
    
    --color-bg-light: #FFFFFF;
    --color-bg-secondary: #F8FAFC;
    --color-text-dark: #1a1a2e;
    --color-text-secondary: #6B7280;
    --color-text-tertiary: #9CA3AF;
    
    --color-border-light: #E5E7EB;
    --color-border-medium: #D1D5DB;
    
    --color-glass-light: rgba(255, 255, 255, 0.7);
    --color-glass-dark: rgba(26, 26, 46, 0.05);
    
    /* Typography */
    --font-family-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-family-display: 'Poppins', sans-serif;
    
    --font-size-base: 1rem;
    --font-size-sm: 0.875rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.5rem;
    --font-size-3xl: 1.875rem;
    --font-size-4xl: 2.25rem;
    --font-size-5xl: 3rem;
    
    --font-weight-light: 300;
    --font-weight-regular: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    
    --line-height-tight: 1.25;
    --line-height-normal: 1.5;
    --line-height-relaxed: 1.75;
    
    /* Spacing */
    --spacing-unit: 0.5rem;
    --spacing-xs: calc(var(--spacing-unit) * 1);
    --spacing-sm: calc(var(--spacing-unit) * 2);
    --spacing-md: calc(var(--spacing-unit) * 4);
    --spacing-lg: calc(var(--spacing-unit) * 6);
    --spacing-xl: calc(var(--spacing-unit) * 8);
    --spacing-2xl: calc(var(--spacing-unit) * 12);
    --spacing-3xl: calc(var(--spacing-unit) * 16);
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
    --shadow-inset: inset 0 2px 4px 0 rgba(0, 0, 0, 0.05);
    
    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --radius-full: 9999px;
    
    /* Transitions */
    --transition-fast: 150ms;
    --transition-base: 200ms;
    --transition-slow: 300ms;
    --timing-ease: cubic-bezier(0.4, 0, 0.2, 1);
    --timing-ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --timing-ease-in: cubic-bezier(0.95, 0.05, 0.795, 0.035);
    
    /* Z-index */
    --z-dropdown: 1000;
    --z-sticky: 1020;
    --z-fixed: 1030;
    --z-modal-backdrop: 1040;
    --z-modal: 1050;
    --z-popover: 1060;
    --z-tooltip: 1070;
    
    /* Accessibility */
    --focus-outline: 2px solid var(--color-primary);
    --focus-outline-offset: 2px;
}

/* Dark Mode */
html[data-theme="dark"] {
    --color-bg-light: #0f172a;
    --color-bg-secondary: #1a1f3a;
    --color-text-dark: #f1f5f9;
    --color-text-secondary: #cbd5e1;
    --color-text-tertiary: #94a3b8;
    
    --color-border-light: #334155;
    --color-border-medium: #475569;
    
    --color-glass-light: rgba(30, 41, 59, 0.6);
    --color-glass-dark: rgba(255, 255, 255, 0.05);
    
    --color-primary-light: #1e3a8a;
}

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

/* ============================================
   2. BASE STYLES & RESETS
   ============================================ */

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-family-primary);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-regular);
    line-height: var(--line-height-normal);
    color: var(--color-text-dark);
    background-color: var(--color-bg-light);
    transition: background-color var(--transition-base) var(--timing-ease),
                color var(--transition-base) var(--timing-ease);
    overflow-x: hidden;
}

/* ============================================
   3. TYPOGRAPHY
   ============================================ */

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-family-display);
    font-weight: var(--font-weight-bold);
    line-height: var(--line-height-tight);
    margin: 0;
}

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: 0;
    color: var(--color-text-secondary);
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--transition-base) var(--timing-ease);
}

a:hover {
    color: var(--color-primary-dark);
}

strong {
    font-weight: var(--font-weight-semibold);
}

/* ============================================
   4. UTILITY CLASSES
   ============================================ */

.accent {
    color: var(--color-primary);
}

.text-muted {
    color: var(--color-text-tertiary);
}

.text-secondary {
    color: var(--color-text-secondary);
}

.z-index-10 {
    position: relative;
    z-index: 10;
}

.glass-effect {
    background: var(--color-glass-light);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all var(--transition-base) var(--timing-ease);
}

html[data-theme="dark"] .glass-effect {
    background: var(--color-glass-light);
    border-color: rgba(255, 255, 255, 0.1);
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--color-primary);
    color: white;
    padding: var(--spacing-sm) var(--spacing-md);
    text-decoration: none;
    z-index: var(--z-tooltip);
    border-radius: var(--radius-sm);
}

.skip-link:focus {
    top: 0;
}

/* ============================================
   5. SCROLL PROGRESS INDICATOR
   ============================================ */

.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
    width: 0%;
    z-index: var(--z-modal);
    transition: width 0.1s linear;
}

/* ============================================
   6. NAVIGATION BAR
   ============================================ */

.navbar-custom {
    background: var(--color-glass-light);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-base) var(--timing-ease);
}

.navbar-custom.scrolled {
    background: var(--color-glass-light);
    box-shadow: var(--shadow-md);
}

.brand-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px !important;
    height: 32px !important;
    min-width: 32px;
    min-height: 32px;
    margin-right: var(--spacing-sm);
    padding: 0;
    border-radius: 50%;
    overflow: hidden;
    background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
    flex: 0 0 32px;
    position: relative;
}

.brand-icon img {
    width: 100% !important;
    height: 100% !important;
    max-width: none;
    max-height: none;
    object-fit: cover;
    object-position: center;
    display: block;
    margin: 0;
    padding: 0;
    border-radius: 50%;
}

.navbar-brand {
    display: flex;
    align-items: center;
    font-weight: var(--font-weight-bold);
    font-size: var(--font-size-lg);
    transition: transform var(--transition-base) var(--timing-ease);
}

.navbar-brand:hover {
    transform: translateY(-2px);
}

.brand-text {
    background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.brand-dot {
    color: var(--color-accent);
}

.nav-link {
    font-weight: var(--font-weight-medium);
    color: var(--color-text-secondary) !important;
    transition: all var(--transition-base) var(--timing-ease);
    position: relative;
}

.nav-link:after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-primary);
    transition: width var(--transition-base) var(--timing-ease);
}

.nav-link:hover {
    color: var(--color-primary) !important;
}

.nav-link:hover:after {
    width: 100%;
}

.nav-link.active {
    color: var(--color-primary) !important;
}

.nav-link.active:after {
    width: 100%;
}

.theme-toggle-btn {
    width: 40px;
    height: 40px;
    border: 1px solid var(--color-border-light);
    border-radius: var(--radius-full);
    background: transparent;
    color: var(--color-text-dark);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-base) var(--timing-ease);
    position: relative;
    overflow: hidden;
}

.theme-toggle-btn:hover {
    background: var(--color-primary-light);
    border-color: var(--color-primary);
}

.theme-toggle-btn i:last-child {
    display: none;
}

html[data-theme="dark"] .theme-toggle-btn i:first-child {
    display: none;
}

html[data-theme="dark"] .theme-toggle-btn i:last-child {
    display: block;
}

/* ============================================
   7. HERO SECTION
   ============================================ */

.hero-section {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    overflow: hidden;
    margin-top: 70px;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

#canvas-background {
    display: block;
    width: 100%;
    height: 100%;
}

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

.hero-badge {
    display: inline-block;
    padding: var(--spacing-sm) var(--spacing-md);
    background: var(--color-primary-light);
    color: var(--color-primary);
    border-radius: var(--radius-full);
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-semibold);
    animation: slideInUp 0.6s var(--timing-ease-out);
}

.hero-title {
    font-size: var(--font-size-5xl);
    font-weight: var(--font-weight-bold);
    line-height: var(--line-height-tight);
    margin: var(--spacing-md) 0;
    animation: slideInUp 0.8s var(--timing-ease-out) 0.1s both;
}

.hero-title .accent {
    background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: var(--font-size-2xl);
    color: var(--color-text-secondary);
    margin-bottom: var(--spacing-md);
    animation: slideInUp 0.8s var(--timing-ease-out) 0.2s both;
}

.hero-description {
    font-size: var(--font-size-lg);
    color: var(--color-text-secondary);
    line-height: var(--line-height-relaxed);
    margin-bottom: var(--spacing-2xl);
    max-width: 600px;
    animation: slideInUp 0.8s var(--timing-ease-out) 0.3s both;
}

.hero-cta-group {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-md);
    animation: slideInUp 0.8s var(--timing-ease-out) 0.4s both;
}

.hero-scroll-indicator {
    position: absolute;
    bottom: var(--spacing-2xl);
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    animation: bounce 2s infinite;
    z-index: 2;
}

.hero-scroll-indicator span {
    display: block;
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    margin-bottom: var(--spacing-md);
}

.scroll-mouse {
    width: 26px;
    height: 40px;
    border: 2px solid var(--color-text-secondary);
    border-radius: var(--radius-full);
    position: relative;
    margin: 0 auto;
}

.scroll-wheel {
    width: 4px;
    height: 8px;
    background: var(--color-text-secondary);
    border-radius: var(--radius-full);
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 1.5s infinite;
}

/* ============================================
   8. SECTIONS & LAYOUT
   ============================================ */

section {
    position: relative;
    padding: var(--spacing-3xl) 0;
}

section:nth-child(even) {
    background: var(--color-bg-secondary);
}

html[data-theme="dark"] section:nth-child(even) {
    background: #1a1f3a;
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-3xl);
}

.section-title {
    font-size: var(--font-size-4xl);
    font-weight: var(--font-weight-bold);
    margin-bottom: var(--spacing-lg);
    color: var(--color-text-dark);
}

.section-divider {
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
    margin: 0 auto;
    border-radius: var(--radius-full);
}

/* ============================================
   9. BUTTONS
   ============================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-sm) var(--spacing-lg);
    font-weight: var(--font-weight-semibold);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-base) var(--timing-ease);
    border: 1px solid transparent;
    text-decoration: none;
    font-size: var(--font-size-base);
}

.btn:focus {
    outline: var(--focus-outline);
    outline-offset: var(--focus-outline-offset);
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    color: white;
    box-shadow: var(--shadow-lg);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

.btn-primary:active {
    transform: translateY(0);
    box-shadow: var(--shadow-md);
}

.btn-outline-secondary {
    border: 2px solid var(--color-text-secondary);
    color: var(--color-text-dark);
    background: transparent;
}

.btn-outline-secondary:hover {
    background: var(--color-primary-light);
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.btn-lg {
    padding: var(--spacing-md) var(--spacing-xl);
    font-size: var(--font-size-lg);
}

.btn i {
    transition: transform var(--transition-base) var(--timing-ease);
}

.btn:hover i {
    transform: translateX(4px);
}

/* ============================================
   10. CARDS & COMPONENTS
   ============================================ */

/* About Card */
.about-card {
    text-align: center;
    padding: var(--spacing-2xl);
    border-radius: var(--radius-2xl);
}

.about-avatar {
    width: 96px;
    height: 96px;
    margin: 0 auto var(--spacing-md);
    border-radius: 50%;
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
}

.about-profile-image {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    object-position: center;
    border-radius: 50%;
}

.avatar-initials {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
    color: white;
    font-size: var(--font-size-4xl);
    font-weight: var(--font-weight-bold);
    border-radius: var(--radius-full);
}

.about-name {
    font-size: var(--font-size-2xl);
    font-weight: var(--font-weight-bold);
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-xs);
}

.about-title {
    font-size: var(--font-size-lg);
    color: var(--color-primary);
    margin-bottom: var(--spacing-lg);
}

.about-meta {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.meta-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    color: var(--color-text-secondary);
}

.meta-item i {
    color: var(--color-primary);
    font-size: var(--font-size-lg);
}

/* About Section Content */
.about-content {
    padding: var(--spacing-lg);
}

.about-section-title {
    font-size: var(--font-size-2xl);
    font-weight: var(--font-weight-bold);
    margin-bottom: var(--spacing-lg);
    color: var(--color-text-dark);
}

.about-text {
    color: var(--color-text-secondary);
    line-height: var(--line-height-relaxed);
    margin-bottom: var(--spacing-lg);
}

.about-highlights {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    margin-top: var(--spacing-xl);
}

.highlight-item {
    display: flex;
    gap: var(--spacing-md);
    align-items: flex-start;
}

.highlight-item i {
    color: var(--color-success);
    flex-shrink: 0;
    margin-top: 2px;
}

.highlight-item div strong {
    display: block;
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-xs);
}

.highlight-item div span {
    color: var(--color-text-secondary);
    display: block;
}

/* ============================================
   11. SKILLS SECTION
   ============================================ */

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-2xl);
}

.skill-card {
    padding: var(--spacing-2xl);
    border-radius: var(--radius-2xl);
    text-align: center;
    transition: all var(--transition-base) var(--timing-ease);
}

.skill-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.skill-icon {
    font-size: var(--font-size-5xl);
    color: var(--color-primary);
    margin-bottom: var(--spacing-lg);
}

.skill-title {
    font-size: var(--font-size-xl);
    font-weight: var(--font-weight-bold);
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-md);
}

.skill-description {
    color: var(--color-text-secondary);
    line-height: var(--line-height-relaxed);
    margin-bottom: var(--spacing-lg);
}

.skill-list {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
    justify-content: center;
    list-style: none;
}

.skill-tag {
    display: inline-block;
    padding: var(--spacing-xs) var(--spacing-md);
    background: var(--color-primary-light);
    color: var(--color-primary);
    border-radius: var(--radius-full);
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    transition: all var(--transition-base) var(--timing-ease);
}

.skill-tag:hover {
    background: var(--color-primary);
    color: white;
}

/* ============================================
   12. TIMELINE & EXPERIENCE
   ============================================ */

.timeline {
    position: relative;
    padding: var(--spacing-lg) 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--color-primary), var(--color-accent));
}

.timeline-item {
    position: relative;
    margin-bottom: var(--spacing-2xl);
    padding-left: 80px;
}

.timeline-marker {
    position: absolute;
    left: -12px;
    top: 0;
    width: 44px;
    height: 44px;
    background: white;
    border: 3px solid var(--color-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
    font-size: var(--font-size-lg);
    box-shadow: var(--shadow-md);
}

html[data-theme="dark"] .timeline-marker {
    background: #0f172a;
}

.timeline-content {
    padding: var(--spacing-lg);
    border-radius: var(--radius-xl);
    transition: all var(--transition-base) var(--timing-ease);
}

.timeline-content:hover {
    transform: translateX(8px);
    box-shadow: var(--shadow-lg);
}

.timeline-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

.timeline-title {
    font-size: var(--font-size-lg);
    font-weight: var(--font-weight-bold);
    color: var(--color-text-dark);
}

.timeline-badge {
    display: inline-block;
    padding: var(--spacing-xs) var(--spacing-md);
    background: var(--color-success);
    color: white;
    border-radius: var(--radius-full);
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-semibold);
}

.timeline-company {
    color: var(--color-text-secondary);
    font-size: var(--font-size-sm);
    margin-bottom: var(--spacing-sm);
}

.timeline-date {
    color: var(--color-text-tertiary);
    font-size: var(--font-size-sm);
    margin-bottom: var(--spacing-md);
}

.timeline-date i {
    margin-right: var(--spacing-xs);
}

.timeline-description {
    color: var(--color-text-secondary);
    line-height: var(--line-height-relaxed);
}

/* ============================================
   13. EDUCATION SECTION
   ============================================ */

.education-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-2xl);
}

.education-card {
    padding: var(--spacing-2xl);
    border-radius: var(--radius-2xl);
    text-align: center;
    transition: all var(--transition-base) var(--timing-ease);
    border-left: 4px solid var(--color-primary);
}

.education-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.education-icon {
    font-size: var(--font-size-4xl);
    color: var(--color-primary);
    margin-bottom: var(--spacing-lg);
}

.education-degree {
    font-size: var(--font-size-lg);
    font-weight: var(--font-weight-bold);
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-sm);
}

.education-university {
    color: var(--color-text-secondary);
    font-size: var(--font-size-sm);
    margin-bottom: var(--spacing-lg);
}

.education-details {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    text-align: left;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-md);
    background: var(--color-bg-secondary);
    border-radius: var(--radius-md);
}

html[data-theme="dark"] .detail-item {
    background: rgba(255, 255, 255, 0.05);
}

.detail-label {
    color: var(--color-text-secondary);
    font-weight: var(--font-weight-semibold);
}

.detail-value {
    color: var(--color-primary);
    font-weight: var(--font-weight-semibold);
}

/* ============================================
   14. PROJECTS SECTION
   ============================================ */

.project-showcase {
    padding: var(--spacing-2xl);
    border-radius: var(--radius-2xl);
    transition: all var(--transition-base) var(--timing-ease);
    border-left: 4px solid var(--color-accent);
}

.project-showcase:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.project-header {
    display: flex;
    gap: var(--spacing-lg);
    align-items: flex-start;
    margin-bottom: var(--spacing-lg);
}

.project-icon {
    font-size: var(--font-size-4xl);
    color: var(--color-accent);
    flex-shrink: 0;
}

.project-title-section {
    flex-grow: 1;
}

.project-title {
    font-size: var(--font-size-xl);
    font-weight: var(--font-weight-bold);
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-sm);
}

.project-date {
    color: var(--color-text-tertiary);
    font-size: var(--font-size-sm);
}

.project-date i {
    margin-right: var(--spacing-xs);
}

.project-description {
    color: var(--color-text-secondary);
    line-height: var(--line-height-relaxed);
    margin-bottom: var(--spacing-lg);
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
}

.tag {
    display: inline-block;
    padding: var(--spacing-xs) var(--spacing-md);
    background: var(--color-accent-light);
    color: var(--color-accent);
    border-radius: var(--radius-full);
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
}

html[data-theme="dark"] .tag {
    background: rgba(255, 107, 53, 0.1);
}

/* ============================================
   15. SERVICES & LANGUAGES
   ============================================ */

.services-grid,
.languages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-2xl);
}

.service-card,
.language-card {
    padding: var(--spacing-2xl);
    border-radius: var(--radius-2xl);
    text-align: center;
    transition: all var(--transition-base) var(--timing-ease);
}

.service-card:hover,
.language-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.service-icon,
.language-icon {
    font-size: var(--font-size-4xl);
    color: var(--color-primary);
    margin-bottom: var(--spacing-lg);
}

.service-title,
.language-name {
    font-size: var(--font-size-lg);
    font-weight: var(--font-weight-bold);
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-md);
}

.service-description,
.language-level {
    color: var(--color-text-secondary);
    line-height: var(--line-height-relaxed);
}

/* ============================================
   16. CONTACT SECTION
   ============================================ */

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

.contact-description {
    font-size: var(--font-size-lg);
    color: var(--color-text-secondary);
    line-height: var(--line-height-relaxed);
    margin-bottom: var(--spacing-2xl);
}

.contact-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-2xl);
}

.contact-button {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md) var(--spacing-xl);
    border-radius: var(--radius-lg);
    text-decoration: none;
    font-weight: var(--font-weight-semibold);
    transition: all var(--transition-base) var(--timing-ease);
    font-size: var(--font-size-lg);
}

.contact-button:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.contact-button i {
    font-size: var(--font-size-2xl);
}

.contact-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-lg);
}

.info-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    color: var(--color-text-secondary);
}

.info-item i {
    color: var(--color-primary);
    font-size: var(--font-size-lg);
}

/* ============================================
   17. FOOTER
   ============================================ */

.footer {
    background: var(--color-secondary);
    color: white;
    padding: var(--spacing-2xl) 0;
    margin-top: var(--spacing-3xl);
}

html[data-theme="dark"] .footer {
    background: #0f172a;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--spacing-lg);
}

.footer-text {
    flex: 1;
    min-width: 250px;
}

.footer-copyright,
.footer-credit {
    color: rgba(255, 255, 255, 0.8);
    margin: 0;
    font-size: var(--font-size-sm);
}

.footer-copyright {
    margin-bottom: var(--spacing-sm);
}

.footer-social {
    display: flex;
    gap: var(--spacing-md);
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-full);
    color: white;
    transition: all var(--transition-base) var(--timing-ease);
}

.social-link:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    transform: translateY(-4px);
}

/* ============================================
   18. BACK TO TOP BUTTON
   ============================================ */

.back-to-top {
    position: fixed;
    bottom: var(--spacing-xl);
    right: var(--spacing-xl);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
    color: white;
    border: none;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    transition: all var(--transition-base) var(--timing-ease);
    z-index: var(--z-sticky);
    font-size: var(--font-size-lg);
}

.back-to-top.show {
    display: flex;
}

.back-to-top:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.back-to-top:active {
    transform: translateY(-4px);
}

/* ============================================
   19. ANIMATIONS & KEYFRAMES
   ============================================ */

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-8px);
    }
    60% {
        transform: translateX(-50%) translateY(-4px);
    }
}

@keyframes scroll {
    0% {
        opacity: 1;
        top: 8px;
    }
    100% {
        opacity: 0;
        top: 20px;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* AOS Custom Animations */
[data-aos="fade-up"].aos-animate {
    animation: slideInUp 0.8s var(--timing-ease-out);
}

[data-aos="fade-right"].aos-animate {
    animation: slideInRight 0.8s var(--timing-ease-out);
}

[data-aos="fade-left"].aos-animate {
    animation: slideInLeft 0.8s var(--timing-ease-out);
}

[data-aos="zoom-in"].aos-animate {
    animation: scaleIn 0.8s var(--timing-ease-out);
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ============================================
   20. CONTAINER & GRID
   ============================================ */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

.container-fluid {
    padding: 0 var(--spacing-lg);
}

.row {
    display: flex;
    flex-wrap: wrap;
    margin-right: calc(var(--spacing-md) * -1);
    margin-left: calc(var(--spacing-md) * -1);
}

.row > * {
    flex-shrink: 0;
    width: 100%;
    max-width: 100%;
    padding-right: var(--spacing-md);
    padding-left: var(--spacing-md);
}

.gap-5 {
    gap: var(--spacing-xl);
}

/* Print Styles */
@media print {
    body {
        background: white;
        color: black;
    }
    
    .navbar-custom,
    .scroll-progress,
    .back-to-top,
    .hero-scroll-indicator {
        display: none;
    }
}

/* ============================================
   MODERN POLISH LAYER
   ============================================ */

:root {
    --surface-elevated: rgba(255, 255, 255, 0.82);
    --surface-border: rgba(15, 23, 42, 0.08);
    --hero-glow: rgba(0, 87, 255, 0.12);
    --ease-smooth: cubic-bezier(0.22, 1, 0.36, 1);
}

html[data-theme="dark"] {
    --surface-elevated: rgba(15, 23, 42, 0.72);
    --surface-border: rgba(255, 255, 255, 0.09);
    --hero-glow: rgba(74, 125, 255, 0.15);
}

body {
    background-image:
        radial-gradient(circle at 10% 10%, var(--hero-glow), transparent 28rem),
        radial-gradient(circle at 90% 35%, rgba(255, 107, 53, 0.055), transparent 24rem);
}

section {
    scroll-margin-top: 76px;
}

.navbar-custom {
    padding: 0.85rem 0;
    border-bottom-color: var(--surface-border);
}

.navbar-custom.scrolled {
    background: color-mix(in srgb, var(--color-bg-light) 82%, transparent);
    backdrop-filter: blur(18px) saturate(150%);
    -webkit-backdrop-filter: blur(18px) saturate(150%);
}

.navbar-brand,
.nav-link,
.theme-toggle-btn,
.btn,
.contact-button,
.social-link {
    will-change: transform;
}

.theme-toggle-btn:hover {
    transform: translateY(-2px) rotate(8deg);
}

.hero-section {
    isolation: isolate;
    background:
        radial-gradient(circle at var(--pointer-x, 50%) var(--pointer-y, 40%), rgba(0, 87, 255, 0.09), transparent 24rem);
}

.hero-background {
    opacity: 0.9;
    pointer-events: none;
}

.hero-content {
    max-width: 880px;
}

.hero-badge {
    border: 1px solid rgba(0, 87, 255, 0.14);
    box-shadow: 0 10px 30px rgba(0, 87, 255, 0.06);
}

.hero-title {
    letter-spacing: -0.045em;
    text-wrap: balance;
}

.hero-subtitle {
    letter-spacing: -0.02em;
}

.hero-description {
    max-width: 680px;
}

.btn-primary,
.contact-button {
    transform: translate3d(var(--mx, 0), var(--my, 0), 0);
}

.btn-primary {
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(110deg, transparent 20%, rgba(255,255,255,.22) 50%, transparent 80%);
    transform: translateX(-130%);
    transition: transform 650ms var(--ease-smooth);
}

.btn-primary:hover::before {
    transform: translateX(130%);
}

.glass-effect {
    background: var(--surface-elevated);
    border: 1px solid var(--surface-border);
    box-shadow: 0 12px 40px rgba(15, 23, 42, 0.055);
}

.skill-card,
.education-card,
.service-card,
.project-showcase,
.timeline-content {
    transform: perspective(1000px) rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg));
    transition: transform 450ms var(--ease-smooth), box-shadow 350ms var(--ease-smooth), border-color 350ms ease, background-color 350ms ease;
}

.skill-card:hover,
.education-card:hover,
.service-card:hover,
.project-showcase:hover,
.timeline-content:hover {
    box-shadow: 0 22px 60px rgba(15, 23, 42, 0.10);
    border-color: rgba(0, 87, 255, 0.20);
}

[data-reveal] {
    opacity: 0;
    transform: translate3d(0, 28px, 0) scale(.985);
    transition: opacity 700ms var(--ease-smooth), transform 700ms var(--ease-smooth);
    transition-delay: calc(var(--reveal-index, 0) * 60ms);
}

[data-reveal][data-aos="fade-right"],
[data-reveal].reveal-right {
    transform: translate3d(-32px, 0, 0) scale(.985);
}

[data-reveal][data-aos="fade-left"],
[data-reveal].reveal-left {
    transform: translate3d(32px, 0, 0) scale(.985);
}

[data-reveal].is-visible {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
}

.section-header {
    max-width: 760px;
    margin-inline: auto;
}

.section-title {
    letter-spacing: -0.035em;
}

.section-divider {
    box-shadow: 0 4px 18px rgba(0, 87, 255, 0.18);
}

.skill-tag,
.tag,
.timeline-badge {
    transition: transform 200ms ease, background-color 200ms ease, color 200ms ease;
}

.skill-tag:hover,
.tag:hover {
    transform: translateY(-2px);
}

.back-to-top {
    transform: translateY(12px) scale(.9);
    opacity: 0;
    pointer-events: none;
    transition: opacity 250ms ease, transform 350ms var(--ease-smooth), background-color 200ms ease;
}

.back-to-top.show {
    transform: translateY(0) scale(1);
    opacity: 1;
    pointer-events: auto;
}

.social-link:hover {
    transform: translateY(-3px);
}

:focus-visible {
    outline: 3px solid color-mix(in srgb, var(--color-primary) 70%, white);
    outline-offset: 3px;
}

@supports not (color-mix(in srgb, black, white)) {
    .navbar-custom.scrolled { background: var(--color-bg-light); }
}

@media (max-width: 991.98px) {
    .navbar-custom {
        padding: .7rem 0;
    }
    .navbar-collapse {
        margin-top: .65rem;
        border: 1px solid var(--surface-border);
        border-radius: 1rem;
        padding: .6rem;
        box-shadow: 0 18px 50px rgba(15, 23, 42, .12);
    }
    .hero-section {
        margin-top: 60px;
    }
}

@media (max-width: 575.98px) {
    .hero-title {
        font-size: clamp(2.4rem, 12vw, 3.3rem);
    }
    .hero-subtitle {
        font-size: 1.15rem;
        line-height: 1.45;
    }
    .hero-description {
        font-size: 1rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    [data-reveal],
    [data-reveal][data-aos="fade-right"],
    [data-reveal][data-aos="fade-left"] {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
    .btn-primary,
    .contact-button,
    .skill-card,
    .education-card,
    .service-card,
    .project-showcase,
    .timeline-content {
        transform: none !important;
    }
}


/* Festive posts */
.section-festive-posts { padding: 6rem 0; }
.festive-intro {
    max-width: 720px; margin: 1rem auto 0;
    color: var(--color-text-secondary); text-align: center; line-height: 1.7;
}
.festive-posts-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
    gap: 1.25rem; margin-top: 2.5rem;
}
.festive-post-card {
    height: 100%; padding: 1.5rem; border: 1px solid var(--surface-border);
    border-radius: 1.25rem; background: var(--surface-elevated);
    box-shadow: 0 12px 32px rgba(15, 23, 42, .07);
    transition: transform .2s ease, box-shadow .2s ease;
}
.festive-post-card:hover { transform: translateY(-4px); box-shadow: 0 18px 38px rgba(15, 23, 42, .12); }
.festive-post-emoji {
    display: grid; place-items: center; width: 3.5rem; height: 3.5rem;
    margin-bottom: 1rem; border-radius: 1rem; background: rgba(0, 87, 255, .1); font-size: 1.8rem;
}
.festive-post-category {
    display: inline-block; margin-bottom: .65rem; color: var(--color-primary);
    font-size: .75rem; font-weight: 700; letter-spacing: .07em; text-transform: uppercase;
}
.festive-post-title { margin-bottom: .75rem; font-size: 1.2rem; font-weight: 700; line-height: 1.4; }
.festive-post-message { margin: 0; color: var(--color-text-secondary); line-height: 1.75; }
.festive-manage-wrap { margin-top: 2rem; text-align: center; }
.festive-manage-note {
    max-width: 680px; margin: 0 auto 1rem; color: var(--color-text-secondary);
    font-size: .9rem; line-height: 1.65;
}
.festive-loading, .festive-empty { grid-column: 1 / -1; padding: 1.5rem; text-align: center; opacity: .8; }
@media (prefers-reduced-motion: reduce) {
    .festive-post-card { transition: none; }
    .festive-post-card:hover { transform: none; }
}


.festive-article-details { margin-top: 1rem; border-top: 1px solid var(--surface-border); padding-top: .85rem; }
.festive-article-details summary { cursor: pointer; color: var(--color-primary); font-weight: 700; padding: .4rem 0; }
.festive-article-body { padding-top: .5rem; }
.festive-article-part { padding: .9rem 0; border-bottom: 1px solid var(--surface-border); }
.festive-article-part:last-child { border-bottom: 0; }
.festive-article-part h4 { font-size: 1.05rem; line-height: 1.5; margin-bottom: .45rem; color: var(--color-text-dark); }
.festive-article-part p { line-height: 1.8; white-space: normal; }

.festive-post-image {
    display: block; width: 100%; max-height: 340px; object-fit: cover;
    object-position: center; border-radius: .9rem; margin-bottom: 1.25rem;
    border: 1px solid var(--surface-border); background: #17142c;
}
.festive-article-details[open] summary { margin-bottom: .35rem; }
