/* ===== Awwwards-Level Enhancement Styles ===== */

/* Text Reveal Animation */
h1,
h2,
h3 {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* Hero title/subtitle use their own animations, not text-reveal */
.hero-title,
.hero-subtitle {
    opacity: 1;
    transform: none;
}

/* Archive cards should be visible without JS animation trigger */
.archive-card h3,
.archive-hero h1,
.archive-hero h2 {
    opacity: 1;
    transform: none;
}

.text-revealed {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* Awwwards Badge */
.awwwards-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    margin: 16px 0;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1), rgba(255, 165, 0, 0.05));
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 24px;
    color: #FFD700;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.02em;
    text-decoration: none;
    transition: all 0.3s ease;
}

.awwwards-badge:hover {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.2), rgba(255, 165, 0, 0.1));
    border-color: rgba(255, 215, 0, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(255, 215, 0, 0.2);
}

.awwwards-badge .badge-icon {
    font-size: 14px;
}

.awwwards-badge .badge-text {
    opacity: 0.9;
}

/* Awwwards Link in meta */
.awwwards-link {
    color: #FFD700 !important;
    text-decoration: none;
    transition: all 0.3s ease;
}

.awwwards-link:hover {
    color: #FFF !important;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

/* Magnetic Button Effect */
.btn-primary,
.btn-secondary {
    position: relative;
    transition: transform 0.3s var(--transition-ease);
}

/* Enhanced Project Card Hover */
.project-card {
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(0, 209, 255, 0.1),
            transparent);
    transition: left 0.5s ease;
    z-index: 1;
    pointer-events: none;
}

.project-card:hover::before {
    left: 100%;
}

/* Glow Effect on Hover */
.project-card:hover {
    box-shadow: 0 15px 35px rgba(0, 209, 255, 0.2),
        inset 0 0 20px rgba(0, 209, 255, 0.1),
        0 0 40px rgba(147, 51, 234, 0.1);
}

/* Smooth Scroll Indicator */
.scroll-indicator {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--gradient-secondary);
    z-index: var(--z-tooltip);
    transition: width 0.1s ease;
}

/* Loading Animation for Images */
img[loading="lazy"] {
    background: linear-gradient(90deg,
            var(--background-medium) 0%,
            var(--background-light) 50%,
            var(--background-medium) 100%);
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
}

img[loading="lazy"].loaded {
    animation: none;
    background: none;
}

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

    100% {
        background-position: -200% 0;
    }
}

/* Enhanced Focus States */
a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--secondary-color);
    outline-offset: 4px;
    border-radius: var(--border-radius-sm);
}

/* Smooth Page Transitions */
body {
    transition: opacity 0.3s ease;
}

/* Performance Optimizations */
.project-image,
.hobby-image {
    will-change: transform;
    backface-visibility: hidden;
    transform: translateZ(0);
}

/* Reduced Motion Override */
@media (prefers-reduced-motion: reduce) {

    .custom-cursor,
    .custom-cursor-follower,
    .text-revealed,
    .project-card::before {
        animation: none !important;
        transition: none !important;
    }
}


/* ══════════════════════════════════════════════════════════
   ULTRA PREMIUM TYPOGRAPHY
   ═══════════════════════════════════════════════════════════ */

:root {
    --font-display: 'Outfit', sans-serif !important;
}

h1,
h2,
h3,
h4,
h5,
h6,
.title-massive,
.heading-colossal,
.heading-large,
.heading-refined,
.heading-massive-centered,
.hero-title {
    font-family: var(--font-display);
    letter-spacing: -0.03em;
}

.title-massive,
.heading-colossal,
.hero-title {
    background: linear-gradient(180deg, #FFFFFF 0%, rgba(255, 255, 255, 0.5) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0px 4px 24px rgba(255, 255, 255, 0.15));
}

.hero-subtitle {
    font-weight: 300;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.7);
}

/* Enhancing standard project cards to have an ultra-smooth hover */
.archive-card {
    border: 1px solid rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(8px);
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1), box-shadow 0.6s ease, border-color 0.6s ease, background 0.6s ease !important;
}

.archive-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 255, 255, 0.12);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6), 0 0 40px rgba(74, 158, 255, 0.05);
    background: rgba(255, 255, 255, 0.04) !important;
}

.capability-item {
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.capability-item:hover {
    transform: translateY(-5px);
}

.capability-item h4 {
    font-family: var(--font-display);
}

/* ══════════════════════════════════════════════════════════
   SUB-PAGE HEADER & NAVIGATION FIXES
   ═══════════════════════════════════════════════════════════ */

/* Ensure the header container on project pages has proper padding and spacing */
.project-detail-page .header-container {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 24px;
    padding: 0 40px !important;
    /* Ensure consistent padding on all screen sizes */
}

/* Force the Back arrow to always be strictly on the left of the Logo */
.project-detail-page .main-nav {
    position: static;
    top: auto;
    left: auto;
    right: auto;
    z-index: auto;
    padding: 0;
    background: transparent;
    border: none;
    order: -1;
}

/* Keep the logo left-aligned next to the arrow */
.project-detail-page .logo-link {
    order: 0;
}

/* Back Link Styling - Arrow + Text */
.nav-link.back-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--star-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    letter-spacing: 0.02em;
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1), background 0.4s ease, border-color 0.4s ease, color 0.3s ease !important;
}

.nav-link.back-link:hover {
    transform: translateX(-4px);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    color: var(--star-primary);
}

.nav-link.back-link i {
    font-size: 14px;
    transition: transform 0.3s ease;
}

.nav-link.back-link:hover i {
    transform: translateX(-3px);
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .project-detail-page .header-container {
        padding: 0 24px !important;
        gap: 20px;
    }

    .nav-link.back-link {
        width: 40px;
        height: 40px;
    }
}

/* ══════════════════════════════════════════════════════════
   LANGUAGE DROP-DOWN (i18n)
   ═══════════════════════════════════════════════════════════ */
.lang-dropdown {
    position: relative;
    display: inline-block;
    margin-left: 16px;
    z-index: 1000;
}

.lang-selector-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--star-primary);
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-family: var(--font-display);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.05em;
    backdrop-filter: blur(10px);
    transition: background 0.3s ease, border-color 0.3s ease;
}

.lang-selector-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
}

.lang-selector-btn i {
    font-size: 12px;
    transition: transform 0.3s ease;
}

.lang-dropdown.active .lang-selector-btn i {
    transform: rotate(180deg);
}

.lang-options {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    background: rgba(10, 10, 10, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 8px 0;
    min-width: 140px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    backdrop-filter: blur(20px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8), 0 0 20px rgba(255, 255, 255, 0.02);
}

.lang-dropdown.active .lang-options {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
    /* Ensure clicks are registered */
}

.lang-option {
    display: block;
    width: 100%;
    text-align: left;
    background: transparent;
    border: none;
    color: var(--star-secondary);
    padding: 10px 20px;
    font-size: 14px;
    font-family: var(--font-body);
    cursor: pointer;
    transition: color 0.2s ease, background 0.2s ease;
}

.lang-option:hover {
    color: var(--star-primary);
    background: rgba(255, 255, 255, 0.05);
}

.lang-option.active {
    color: #4a9eff;
    font-weight: 600;
    background: rgba(74, 158, 255, 0.05);
}

/* Translucent Fade Utility for Translations */
[data-i18n] {
    transition: opacity 0.3s ease-in-out;
}