/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    /* Header height + a little breathing room. Kept in a variable so the
       anchor-scroll JS and `scroll-padding` can never drift apart. */
    --header-height: 88px;
    scroll-padding-top: var(--header-height);
    /* `clip` (not `hidden`) stops the page from scrolling sideways without
       creating a scroll container - `hidden` breaks position: sticky/fixed
       children on iOS. */
    overflow-x: clip;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: clip;
    width: 100%;
    max-width: 100%;
    -webkit-tap-highlight-color: transparent;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color var(--transition-base), color var(--transition-base);
}

img,
svg,
video,
canvas {
    max-width: 100%;
}

img {
    height: auto;
    display: block;
}

/* Grid/flex children default to min-width:auto, which is the #1 cause of
   horizontal overflow on mobile. */
.container,
.hero-content,
.about-content,
.contact-content,
.services-grid,
.projects-grid,
.skills-grid,
.footer-content,
.form-row,
.carousel-track,
.project-card,
.service-card,
.testimonial-card,
.contact-item {
    min-width: 0;
}

:root {
    /* Colors */
    --primary-color: #D4AF37;
    --primary-light: #FFD700;
    --primary-dark: #B8860B;
    --bg-dark: #0A0A0A;
    --bg-light: #1A1A1A;
    --text-primary: #FFFFFF;
    --text-secondary: #CCCCCC;
    --text-muted: #AAAAAA;
    --border-color: rgba(212, 175, 55, 0.2);

    /* Spacing */
    --section-padding: 120px;
    --container-padding: 32px;

    /* Transitions */
    --transition-base: 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --transition-smooth: 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);

    /* Shadows */
    --shadow-sm: 0 8px 32px rgba(212, 175, 55, 0.1);
    --shadow-md: 0 16px 48px rgba(212, 175, 55, 0.15);
    --shadow-lg: 0 24px 64px rgba(212, 175, 55, 0.2);
    --shadow-xl: 0 32px 80px rgba(212, 175, 55, 0.25);
}

/* Light Theme */
body.light-theme {
    --bg-dark: #FFFFFF;
    --bg-light: #F5F5F5;
    --text-primary: #0A0A0A;
    --text-secondary: #333333;
    --text-muted: #666666;
    --border-color: rgba(212, 175, 55, 0.3);
}

/* ============================================================
   ANIMATION BASELINE (anti-FOUC)  ·  replaces the dead .gsap-fouc rule
   ------------------------------------------------------------
   The `js` class is added by an inline <script> in <head>, BEFORE the first
   paint, so these elements are already hidden on frame 1 - no flash.
   If JS/GSAP never runs, `html.js` is removed (script.js) or
   `html.anim-fallback` is added (inline safety net) and everything becomes
   visible again. Elements are never left invisible.

   NOTE: only `opacity` is pre-hidden - never `transform` - so GSAP, CSS
   `:hover` and the magnetic effect cannot fight over the same property.
   ============================================================ */
html.js .hero-intro,
html.js .hero-title,
html.js .hero-subtitle,
html.js .hero-description,
html.js .hero-buttons,
html.js .hero-social,
html.js .scroll-indicator,
html.js .section-header,
html.js .about-content,
html.js .skills-container,
html.js .service-card,
html.js .project-card,
html.js .contact-intro,
html.js .contact-item,
html.js .form,
html.js .footer-content {
    opacity: 0;
}

html.js .hero-line {
    transform: scaleX(0);
}

html.anim-fallback .hero-intro,
html.anim-fallback .hero-title,
html.anim-fallback .hero-subtitle,
html.anim-fallback .hero-description,
html.anim-fallback .hero-buttons,
html.anim-fallback .hero-social,
html.anim-fallback .scroll-indicator,
html.anim-fallback .section-header,
html.anim-fallback .about-content,
html.anim-fallback .skills-container,
html.anim-fallback .service-card,
html.anim-fallback .project-card,
html.anim-fallback .contact-intro,
html.anim-fallback .contact-item,
html.anim-fallback .form,
html.anim-fallback .footer-content {
    opacity: 1 !important;
}

html.anim-fallback .hero-line {
    transform: none !important;
}

/* Reduced motion: nothing is hidden, nothing moves. */
@media (prefers-reduced-motion: reduce) {
    html.js .hero-intro,
    html.js .hero-title,
    html.js .hero-subtitle,
    html.js .hero-description,
    html.js .hero-buttons,
    html.js .hero-social,
    html.js .scroll-indicator,
    html.js .section-header,
    html.js .about-content,
    html.js .skills-container,
    html.js .service-card,
    html.js .project-card,
    html.js .contact-intro,
    html.js .contact-item,
    html.js .form,
    html.js .footer-content {
        opacity: 1;
    }

    html.js .hero-line {
        transform: none;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-light);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(to bottom, var(--primary-color), var(--primary-dark));
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(to bottom, var(--primary-light), var(--primary-color));
}

/* Selection Color */
::selection {
    background: rgba(212, 175, 55, 0.3);
    color: var(--primary-color);
}

/* Progress Bar */
.progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    z-index: 10001;
    transition: width 0.3s ease;
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--container-padding);
    width: 100%;
}

/* Typography */
.gradient-text {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light), var(--primary-dark));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    background-size: 200% 200%;
    animation: gradientShift 3s ease-in-out infinite;
}

@keyframes gradientShift {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 18px 36px;
    border-radius: 60px;
    font-weight: 600;
    text-decoration: none;
    transition: all var(--transition-smooth);
    border: none;
    cursor: pointer;
    font-size: 16px;
    position: relative;
    overflow: hidden;
    font-family: inherit;
    z-index: 1;
    transform-origin: center center;
    touch-action: manipulation;
}

.btn::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 0.6s;
    z-index: -1;
}

.btn:hover::before {
    left: 100%;
}

.btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: inherit;
    border-radius: inherit;
    opacity: 0;
    transition: opacity var(--transition-base);
    z-index: -1;
}

.btn:hover::after {
    opacity: 0.1;
}

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

.btn-primary:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    background: transparent;
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: var(--bg-dark);
    transform: translateY(-3px) scale(1.02);
    box-shadow: var(--shadow-lg);
}

.btn-icon {
    transition: transform var(--transition-base);
}

.btn:hover .btn-icon {
    transform: translateX(6px);
}

/* Loading Screen */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--bg-dark), var(--bg-light));
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 1;
    transition: opacity 0.8s ease;
}

.loading-content {
    text-align: center;
    width: 100%;
    max-width: 320px;
    padding: 0 20px;
}

.loading-logo {
    margin-bottom: 32px;
}

.logo-svg {
    animation: rotateLogo 3s linear infinite;
    width: 100%;
    height: auto;
    max-width: 200px;
}

@keyframes rotateLogo {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.logo-circle {
    stroke-dasharray: 565;
    stroke-dashoffset: 565;
    animation: drawCircle 2s ease-out forwards;
}

@keyframes drawCircle {
    to {
        stroke-dashoffset: 0;
    }
}

.logo-text-svg {
    font-size: 48px;
    font-weight: 800;
    fill: var(--primary-color);
    font-family: 'Playfair Display', serif;
    opacity: 0;
    animation: fadeIn 1s ease-out 1s forwards;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

.loading-progress-container {
    width: 100%;
    max-width: 300px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin: 0 auto 24px;
}

.loading-progress {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    border-radius: 2px;
    width: 0%;
}

.loading-subtitle {
    color: var(--text-muted);
    font-size: 16px;
    letter-spacing: 2px;
    text-transform: uppercase;
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.5s forwards;
}

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Custom Cursor */
.cursor,
.cursor-follower {
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    mix-blend-mode: difference;
    transition: transform 0.2s ease;
}

.cursor {
    width: 8px;
    height: 8px;
    background: var(--primary-color);
    left: 0;
    top: 0;
}

.cursor-follower {
    width: 32px;
    height: 32px;
    border: 2px solid var(--primary-color);
    left: 0;
    top: 0;
    opacity: 0.5;
}

@media (max-width: 768px) {

    .cursor,
    .cursor-follower {
        display: none !important;
    }
}

/* Header */
/* Higher than the mobile overlay (1200) on purpose: the hamburger turns
   into the "X" and has to stay clickable while the menu is open. */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1300;
    padding: 24px 0;
    padding-top: calc(24px + env(safe-area-inset-top));
    transition: transform 0.35s ease, background-color 0.35s ease, padding 0.35s ease,
        box-shadow 0.35s ease;
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    will-change: transform;
}

.header.scrolled {
    background: rgba(10, 10, 10, 0.95);
    padding: 16px 0;
    padding-top: calc(16px + env(safe-area-inset-top));
    box-shadow: var(--shadow-md);
}

/* Replaces `gsap.to(header, { y: -100 })`: a CSS class is cheaper, and it
   never leaves an inline transform behind (which used to trap the fixed
   mobile menu inside the header). */
.header.is-hidden {
    transform: translateY(-100%);
}

.light-theme .header.scrolled {
    background: rgba(255, 255, 255, 0.95);
}

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

.logo-text {
    font-size: 28px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-family: 'Playfair Display', serif;
    letter-spacing: -1px;
    text-decoration: none;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: clamp(18px, 3.2vw, 48px);
    align-items: center;
    min-width: 0;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: all var(--transition-base);
    padding: 8px 0;
    font-size: 15px;
    letter-spacing: 0.5px;
}

.nav-link::before {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    color: var(--primary-color);
    overflow: hidden;
    width: 0;
    transition: width var(--transition-smooth);
}

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

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    transition: width var(--transition-smooth);
}

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

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

/* Theme Toggle */
.theme-toggle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.1);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-base);
    margin-left: 24px;
    touch-action: manipulation;
}

.theme-toggle:hover {
    background: var(--primary-color);
    transform: rotate(180deg);
}

.theme-toggle:hover svg {
    color: var(--bg-dark);
}

.theme-toggle svg {
    width: 24px;
    height: 24px;
    color: var(--primary-color);
    transition: all var(--transition-base);
}

.sun-icon {
    display: block;
}

.moon-icon {
    display: none;
}

.light-theme .sun-icon {
    display: none;
}

.light-theme .moon-icon {
    display: block;
}

/* ============================================================
   MOBILE MENU  (rebuilt)
   ------------------------------------------------------------
   What was broken before:
   · The panel was animated with GSAP `right` + `opacity` inline styles.
     Once it had been closed once, the inline `opacity: 0` / `right:-100%`
     stuck and never got cleared, so opening it a second time showed a
     blank (or completely off-screen) panel.
   · It lived inside <header>, which is `position: fixed` + `backdrop-filter`
     + GSAP-transformed. Any of those makes the header the containing block
     for `position: fixed` children, so the "full screen" panel was clipped.
   · Menu items were animated by BOTH CSS transitions and a GSAP stagger.
   The rebuild below is 100% CSS driven: no inline styles to get stuck.
   ============================================================ */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    width: 48px;
    height: 48px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1201;
    padding: 8px;
    margin-left: 8px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.hamburger {
    width: 26px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    display: block;
    transition: transform var(--transition-base), opacity var(--transition-base);
    transform-origin: center;
}

/* Open state: hamburger -> X (CSS only, replaces the GSAP tweens) */
.mobile-menu-btn[aria-expanded="true"] .hamburger:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.mobile-menu-btn[aria-expanded="true"] .hamburger:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.mobile-menu-btn[aria-expanded="true"] .hamburger:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

.mobile-menu {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    max-height: 100dvh;
    background: rgba(10, 10, 10, 0.98);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1200;
    /* Hidden by default WITHOUT using `right: -100%` (no off-canvas maths,
       no horizontal scrollbar risk). `visibility` also removes it from the
       tab order and stops it from blocking taps. */
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.35s ease, visibility 0.35s ease;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    padding: calc(var(--header-height) + 16px) 20px calc(24px + env(safe-area-inset-bottom));
}

.light-theme .mobile-menu {
    background: rgba(255, 255, 255, 0.98);
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.mobile-menu-inner {
    width: 100%;
    max-width: 420px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
    margin: auto;
}

.mobile-nav-menu {
    list-style: none;
    text-align: center;
    padding: 0;
    width: 100%;
}

.mobile-nav-menu li {
    margin: 0;
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.mobile-menu.active .mobile-nav-menu li {
    opacity: 1;
    transform: translateY(0);
}

.mobile-menu.active .mobile-nav-menu li:nth-child(1) {
    transition-delay: 0.06s;
}

.mobile-menu.active .mobile-nav-menu li:nth-child(2) {
    transition-delay: 0.12s;
}

.mobile-menu.active .mobile-nav-menu li:nth-child(3) {
    transition-delay: 0.18s;
}

.mobile-menu.active .mobile-nav-menu li:nth-child(4) {
    transition-delay: 0.24s;
}

.mobile-menu.active .mobile-nav-menu li:nth-child(5) {
    transition-delay: 0.3s;
}

.mobile-nav-link {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 28px;
    font-weight: 600;
    font-family: 'Playfair Display', serif;
    transition: color var(--transition-base);
    /* 44px+ touch target */
    display: block;
    padding: 12px 8px;
    line-height: 1.4;
    touch-action: manipulation;
}

.mobile-nav-link:active,
.mobile-nav-link:focus-visible {
    color: var(--primary-color);
}

.mobile-menu-footer {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
    width: 100%;
    border-top: 1px solid var(--border-color);
    padding-top: 24px;
}

.mobile-menu-mail,
.mobile-menu-wa {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    padding: 10px 12px;
    border-radius: 8px;
    word-break: break-word;
    touch-action: manipulation;
}

.mobile-menu-wa {
    color: var(--primary-color);
    font-weight: 600;
}

/* Never show the overlay on desktop, even if a class gets left behind */
@media (min-width: 901px) {
    .mobile-menu {
        display: none;
    }
}

/* Hero Section */
.hero-section {
    min-height: 100vh;
    /* `svh` = smallest viewport height: stable while the mobile URL bar
       collapses, so ScrollTrigger never re-refreshes mid-scroll. */
    min-height: 100svh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding-top: calc(var(--header-height) + 24px);
    padding-bottom: 128px;
    background: radial-gradient(ellipse at center, var(--bg-light) 0%, var(--bg-dark) 100%);
    width: 100%;
}

.hero-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    width: 100%;
    height: 100%;
}

.grid-bg {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(212, 175, 55, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(212, 175, 55, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: gridMove 20s linear infinite;
    width: 100%;
    height: 100%;
}

@keyframes gridMove {
    from {
        transform: translate(0, 0);
    }

    to {
        transform: translate(50px, 50px);
    }
}

.floating-element {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.1;
    animation: float 8s ease-in-out infinite;
    pointer-events: none;
}

.floating-1 {
    top: 10%;
    left: 10%;
    width: 400px;
    height: 400px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    animation-delay: 0s;
}

.floating-2 {
    bottom: 10%;
    right: 10%;
    width: 500px;
    height: 500px;
    background: linear-gradient(135deg, #8B4513, #CD853F);
    animation-delay: 2s;
}

.floating-3 {
    top: 50%;
    left: 50%;
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, #2F4F4F, #708090);
    transform: translate(-50%, -50%);
    animation-delay: 4s;
}

.floating-4 {
    top: 20%;
    right: 30%;
    width: 250px;
    height: 250px;
    background: linear-gradient(135deg, #4B0082, #8A2BE2);
    animation-delay: 6s;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px) rotate(0deg) scale(1);
    }

    33% {
        transform: translateY(-30px) rotate(120deg) scale(1.1);
    }

    66% {
        transform: translateY(15px) rotate(240deg) scale(0.9);
    }
}

@media (max-width: 1024px) {
    .floating-1 {
        width: 280px;
        height: 280px;
        top: 8%;
        left: 8%;
    }

    .floating-2 {
        width: 350px;
        height: 350px;
        bottom: 8%;
        right: 8%;
    }

    .floating-3 {
        width: 220px;
        height: 220px;
    }

    .floating-4 {
        width: 180px;
        height: 180px;
        top: 25%;
        right: 25%;
    }
}

@media (max-width: 768px) {
    .hero-section {
        padding-top: 100px;
    }

    .floating-1 {
        width: 200px;
        height: 200px;
        top: 5%;
        left: 5%;
        filter: blur(60px);
    }

    .floating-2 {
        width: 240px;
        height: 240px;
        bottom: 5%;
        right: 5%;
        filter: blur(60px);
    }

    .floating-3 {
        width: 160px;
        height: 160px;
        filter: blur(50px);
    }

    .floating-4 {
        width: 140px;
        height: 140px;
        top: 30%;
        right: 20%;
        filter: blur(50px);
    }
}

@media (max-width: 480px) {
    .floating-1 {
        width: 160px;
        height: 160px;
        top: 0;
        left: 0;
        transform: translate(-20%, -20%);
        filter: blur(50px);
        opacity: 0.08;
    }

    .floating-2 {
        width: 200px;
        height: 200px;
        bottom: 0;
        right: 0;
        transform: translate(20%, 20%);
        filter: blur(50px);
        opacity: 0.08;
    }

    .floating-3 {
        width: 140px;
        height: 140px;
        filter: blur(40px);
        opacity: 0.06;
    }

    .floating-4 {
        width: 120px;
        height: 120px;
        top: 35%;
        right: 15%;
        filter: blur(40px);
        opacity: 0.06;
    }
}

/* Particles Canvas */
.particles-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.hero-content {
    text-align: center;
    z-index: 10;
    position: relative;
    max-width: 900px;
    padding: 0 var(--container-padding);
    width: 100%;
}

@media (max-width: 768px) {
    .hero-content {
        padding: 0 20px;
    }
}

@media (max-width: 480px) {
    .hero-content {
        padding: 0 16px;
    }
}

.hero-intro {
    margin-bottom: 20px;
}

.hero-greeting {
    font-size: 18px;
    color: var(--primary-color);
    font-weight: 500;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.hero-title {
    margin-bottom: 24px;
}

.hero-title h1 {
    font-size: clamp(2.4rem, 8vw, 6rem);
    font-weight: 900;
    line-height: 1.05;
    font-family: 'Playfair Display', serif;
    letter-spacing: -1px;
    position: relative;
    z-index: 1;
    margin: 0;
    overflow-wrap: break-word;
    hyphens: auto;
}

.hero-subtitle {
    margin-bottom: 30px;
}

.typing-text {
    font-size: clamp(1.4rem, 4vw, 2.2rem);
    color: var(--text-secondary);
    font-weight: 300;
    margin-bottom: 20px;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-line {
    width: 100px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    margin: 0 auto;
    border-radius: 2px;
    /* transform is owned by the `html.js` baseline + GSAP (see top of file),
       otherwise a failed GSAP load leaves the line permanently invisible */
    transform-origin: left center;
}

.hero-description {
    margin-bottom: 40px;
}

.hero-description p {
    font-size: 18px;
    color: var(--text-muted);
    line-height: 1.6;
    max-width: 620px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .hero-description p {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .hero-description p {
        font-size: 15px;
    }
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: center;
    align-items: center;
    margin-bottom: 56px;
}

@media (max-width: 480px) {
    .hero-buttons {
        flex-direction: column;
        gap: 14px;
        align-items: stretch;
        margin-bottom: 48px;
    }

    .hero-buttons .btn {
        width: 100%;
        justify-content: center;
        padding: 16px 24px;
        font-size: 15px;
    }
}

@media (max-width: 768px) {
    .hero-buttons {
        max-width: none;
        width: 100%;
    }

    .btn {
        width: auto;
    }
}

.hero-social {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 40px;
}

@media (max-width: 480px) {
    .hero-social {
        gap: 14px;
        margin-bottom: 32px;
    }

    .hero-social .social-link {
        width: 48px;
        height: 48px;
    }

    .hero-social .social-link svg {
        width: 20px;
        height: 20px;
    }
}

.social-link {
    width: 56px;
    height: 56px;
    background: rgba(212, 175, 55, 0.1);
    border: 2px solid var(--border-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    text-decoration: none;
    transition: all var(--transition-smooth);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
    transform-origin: center center;
    touch-action: manipulation;
}

.social-link::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--primary-color);
    transform: scale(0);
    transition: transform var(--transition-smooth);
    border-radius: 50%;
}

.social-link:hover::before {
    transform: scale(1);
}

.social-link:hover {
    color: var(--bg-dark);
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.social-link svg {
    position: relative;
    z-index: 1;
}

.scroll-indicator {
    position: absolute;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    animation: bounce 2s infinite;
}

@media (max-width: 768px) {
    .scroll-indicator {
        bottom: 32px;
        gap: 10px;
    }

    .scroll-line {
        height: 60px;
    }

    .scroll-text {
        font-size: 11px;
    }
}

@media (max-width: 480px) {
    .scroll-indicator {
        bottom: 24px;
        gap: 8px;
    }

    .scroll-line {
        height: 50px;
    }

    .scroll-text {
        font-size: 10px;
        letter-spacing: 1px;
    }
}

.scroll-line {
    width: 2px;
    height: 80px;
    background: linear-gradient(to bottom, var(--primary-color), transparent);
    border-radius: 1px;
}

.scroll-text {
    color: var(--text-muted);
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
    writing-mode: vertical-rl;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateX(-50%) translateY(0);
    }

    40% {
        transform: translateX(-50%) translateY(-10px);
    }

    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

/* Section Styles */
section {
    padding: var(--section-padding) 0;
    position: relative;
    width: 100%;
}

.section-header {
    text-align: center;
    margin-bottom: 80px;
    position: relative;
    max-width: 100%;
}

.section-number {
    font-size: clamp(64px, 14vw, 120px);
    font-weight: 900;
    color: rgba(212, 175, 55, 0.05);
    position: absolute;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    font-family: 'Playfair Display', serif;
    z-index: -1;
    pointer-events: none;
}

.section-title {
    font-size: clamp(2rem, 6vw, 5rem);
    overflow-wrap: break-word;
    font-weight: 800;
    margin-bottom: 32px;
    font-family: 'Playfair Display', serif;
    letter-spacing: -1px;
    line-height: 1.1;
}

.section-line {
    width: 100px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    margin: 0 auto 40px;
    border-radius: 2px;
}

.section-description {
    font-size: 20px;
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.8;
}

/* About Section */
.about-section {
    background: linear-gradient(135deg, rgba(26, 26, 26, 0.5), rgba(10, 10, 10, 0.8));
    backdrop-filter: blur(10px);
    /* The rotating profile ring/dots sit outside .profile-image (-30px inset).
       `clip` keeps them from widening the document without creating a scroll
       container or clipping the section's own content. */
    overflow: clip;
}

.light-theme .about-section {
    background: linear-gradient(135deg, rgba(245, 245, 245, 0.5), rgba(255, 255, 255, 0.8));
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: start;
    margin-bottom: 80px;
}

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

.profile-image {
    position: relative;
    width: 350px;
    height: 350px;
    margin: 0 auto 40px;
}

.profile-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    border-radius: 50%;
    filter: blur(30px);
    opacity: 0.3;
    animation: pulse 3s ease-in-out infinite;
}

.profile-circle {
    position: relative;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #2A2A2A, #1A1A1A);
    border-radius: 50%;
    border: 3px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.light-theme .profile-circle {
    background: linear-gradient(135deg, #F5F5F5, #FFFFFF);
}

.profile-initials {
    font-size: 100px;
    font-weight: 900;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-family: 'Playfair Display', serif;
}

.profile-ring {
    position: absolute;
    inset: -10px;
    border: 2px solid transparent;
    border-radius: 50%;
    background: linear-gradient(45deg, var(--primary-color), transparent, var(--primary-light), transparent) border-box;
    -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: destination-out;
    mask-composite: exclude;
    animation: rotate 10s linear infinite;
}

.profile-dots {
    position: absolute;
    inset: -30px;
    animation: rotate 20s linear infinite reverse;
}

.profile-dots .dot {
    position: absolute;
    width: 8px;
    height: 8px;
    background: var(--primary-color);
    border-radius: 50%;
}

.profile-dots .dot:nth-child(1) {
    top: 0;
    left: 50%;
    transform: translateX(-50%);
}

.profile-dots .dot:nth-child(2) {
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.profile-dots .dot:nth-child(3) {
    left: 0;
    top: 50%;
    transform: translateY(-50%);
}

.profile-dots .dot:nth-child(4) {
    right: 0;
    top: 50%;
    transform: translateY(-50%);
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 0.3;
        transform: scale(1);
    }

    50% {
        opacity: 0.5;
        transform: scale(1.05);
    }
}

.about-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 24px;
    font-family: 'Playfair Display', serif;
}

.about-text p {
    color: var(--text-secondary);
    font-size: 18px;
    line-height: 1.8;
    margin-bottom: 24px;
    text-align: left;
}

.about-highlights {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: clamp(12px, 2vw, 24px);
    margin-top: 40px;
}

.highlight-item {
    text-align: center;
    padding: 24px;
    background: rgba(212, 175, 55, 0.05);
    border-radius: 16px;
    border: 1px solid var(--border-color);
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.highlight-item::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    opacity: 0;
    transition: opacity var(--transition-base);
}

.highlight-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.highlight-item:hover::before {
    opacity: 0.1;
}

.highlight-number {
    display: block;
    font-size: 32px;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 8px;
    font-family: 'Playfair Display', serif;
    position: relative;
}

.highlight-text {
    font-size: 14px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
}

.skills-container {
    padding-left: 40px;
}

.skills-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 40px;
    text-align: left;
    color: var(--primary-color);
    font-family: 'Playfair Display', serif;
}

.skills-grid {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.skill-category {
    background: rgba(212, 175, 55, 0.05);
    padding: 32px;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.skill-category::before {
    content: '';
    position: absolute;
    top: -100%;
    left: -100%;
    width: 300%;
    height: 300%;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.1) 0%, transparent 70%);
    transition: all 0.5s ease;
    opacity: 0;
}

.skill-category:hover::before {
    top: -150%;
    left: -150%;
    opacity: 1;
}

.skill-category:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.skill-category-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.skill-tag {
    padding: 8px 16px;
    background: rgba(212, 175, 55, 0.1);
    color: var(--primary-color);
    font-size: 14px;
    border-radius: 25px;
    border: 1px solid var(--border-color);
    transition: all var(--transition-base);
    font-weight: 500;
    position: relative;
    overflow: hidden;
    touch-action: manipulation;
}

.skill-tag::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--primary-color);
    transform: translateX(-100%);
    transition: transform var(--transition-base);
}

.skill-tag:hover::before {
    transform: translateX(0);
}

.skill-tag:hover {
    color: var(--bg-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

/* Services Section */
.services-section {
    background: linear-gradient(135deg, rgba(10, 10, 10, 0.8), rgba(26, 26, 26, 0.5));
}

.light-theme .services-section {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.8), rgba(245, 245, 245, 0.5));
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.service-card {
    position: relative;
    padding: 48px 32px;
    background: rgba(26, 26, 26, 0.8);
    border-radius: 24px;
    border: 1px solid var(--border-color);
    transition: all var(--transition-smooth);
    overflow: hidden;
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
}

.light-theme .service-card {
    background: rgba(255, 255, 255, 0.8);
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    transform: translateX(-100%);
    transition: transform var(--transition-smooth);
}

.service-card:hover::before {
    transform: translateX(0);
}

.service-card:hover {
    border-color: rgba(212, 175, 55, 0.5);
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.service-number {
    position: absolute;
    top: 24px;
    right: 24px;
    font-size: 48px;
    font-weight: 900;
    color: rgba(212, 175, 55, 0.1);
    font-family: 'Playfair Display', serif;
}

.service-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 32px;
    transition: all var(--transition-smooth);
    position: relative;
    flex-shrink: 0;
}

.service-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: var(--shadow-lg);
}

.service-icon svg {
    color: var(--bg-dark);
    position: relative;
    z-index: 1;
}

.service-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 20px;
    transition: color var(--transition-base);
    font-family: 'Playfair Display', serif;
}

.service-card:hover .service-title {
    color: var(--primary-color);
}

.service-description {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 32px;
    font-size: 16px;
    flex: 1;
}

.service-features {
    list-style: none;
}

.service-features li {
    display: flex;
    align-items: center;
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 12px;
    transition: all var(--transition-base);
    position: relative;
    padding-left: 24px;
}

.service-features li::before {
    content: '';
    position: absolute;
    left: 0;
    width: 8px;
    height: 8px;
    background: var(--primary-color);
    border-radius: 50%;
    transition: all var(--transition-base);
}

.service-card:hover .service-features li {
    color: var(--text-secondary);
    transform: translateX(4px);
}

.service-card:hover .service-features li::before {
    background: var(--primary-light);
    transform: scale(1.2);
}

.service-hover-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.05), rgba(255, 215, 0, 0.05));
    border-radius: 24px;
    opacity: 0;
    transition: opacity var(--transition-smooth);
}

.service-card:hover .service-hover-bg {
    opacity: 1;
}

/* Projects Section */
.project-filters {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 60px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 12px 24px;
    background: transparent;
    border: 2px solid var(--border-color);
    border-radius: 30px;
    color: var(--text-secondary);
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-base);
    font-size: 14px;
    touch-action: manipulation;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary-color);
    color: var(--bg-dark);
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-bottom: 80px;
}

.project-card {
    position: relative;
    background: rgba(26, 26, 26, 0.8);
    border-radius: 24px;
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    /* NO opacity/transform here - the pre-hide now lives in the
       `html.js` baseline block at the top of this file. */
    display: flex;
    flex-direction: column;
    height: 100%;
}

.light-theme .project-card {
    background: rgba(255, 255, 255, 0.8);
}

.project-card.show {
    opacity: 1;
    transform: translateY(0);
}

.project-card.hidden {
    display: none;
}

.project-card:hover {
    border-color: rgba(212, 175, 55, 0.5);
    transform: translateY(-12px);
    box-shadow: var(--shadow-xl);
}

.project-image {
    position: relative;
    /* aspect-ratio instead of a fixed 250px height: the image keeps its 16:9
       shape on every screen and never squashes. */
    aspect-ratio: 16 / 9;
    width: 100%;
    overflow: hidden;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.03);
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.project-card:hover .project-image img {
    transform: scale(1.1);
}

.project-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(10, 10, 10, 0.9), transparent);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-smooth);
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-links {
    display: flex;
    gap: 16px;
    transform: translateY(20px);
    transition: transform var(--transition-smooth);
}

.project-card:hover .project-links {
    transform: translateY(0);
}

.project-link {
    width: 56px;
    height: 56px;
    background: var(--primary-color);
    color: var(--bg-dark);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
    transform-origin: center center;
    touch-action: manipulation;
}

.project-link::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--primary-light);
    transform: scale(0);
    transition: transform var(--transition-base);
    border-radius: 50%;
}

.project-link:hover::before {
    transform: scale(1);
}

.project-link:hover {
    transform: scale(1.1);
}

.project-link svg {
    position: relative;
    z-index: 1;
}

.project-link:nth-child(2) {
    background: rgba(26, 26, 26, 0.9);
    color: var(--text-primary);
    border: 2px solid var(--primary-color);
}

.project-link:nth-child(2):hover {
    background: var(--primary-color);
    color: var(--bg-dark);
}

.featured-badge {
    position: absolute;
    top: 20px;
    left: 20px;
    padding: 8px 20px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: var(--bg-dark);
    font-size: 12px;
    font-weight: 700;
    border-radius: 25px;
    text-transform: uppercase;
    letter-spacing: 1px;
    animation: pulse 2s ease-in-out infinite;
    z-index: 10;
}

.project-content {
    padding: 32px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.project-category {
    color: var(--primary-color);
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 12px;
}

.project-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
    transition: color var(--transition-base);
    font-family: 'Playfair Display', serif;
}

.project-card:hover .project-title {
    color: var(--primary-color);
}

.project-description {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.7;
    margin-bottom: 24px;
    flex: 1;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tech-tag {
    padding: 6px 16px;
    background: rgba(212, 175, 55, 0.1);
    color: var(--primary-color);
    font-size: 12px;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    font-weight: 500;
    transition: all var(--transition-base);
}

.tech-tag:hover {
    background: var(--primary-color);
    color: var(--bg-dark);
    transform: translateY(-2px);
}

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

/* Testimonials Section - Horizontal Carousel */
.testimonials-section {
    position: relative;
    background: linear-gradient(135deg, rgba(26, 26, 26, 0.5), rgba(10, 10, 10, 0.8));
    overflow: hidden;
    padding: var(--section-padding) 0;
}

.light-theme .testimonials-section {
    background: linear-gradient(135deg, rgba(245, 245, 245, 0.5), rgba(255, 255, 255, 0.8));
}

.carousel-container {
    width: 100%;
    overflow: hidden;
    margin-top: 10px;
}

.carousel-track {
    display: flex;
    gap: 32px;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 20px;
    scroll-snap-type: x mandatory;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    scroll-padding-inline: 0;
}

.carousel-track::-webkit-scrollbar {
    display: none;
}

.testimonial-card {
    flex: 0 0 auto;
    /* 3 visible on desktop: (100% - 2 gaps) / 3 */
    width: calc((100% - 64px) / 3);
    background: rgba(26, 26, 26, 0.8);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 40px 32px;
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow-lg);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-height: 420px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    scroll-snap-align: start;
}

.light-theme .testimonial-card {
    background: rgba(255, 255, 255, 0.85);
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: rgba(212, 175, 55, 0.5);
}

.avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: var(--bg-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 20px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-md);
}

.quote {
    color: var(--text-secondary);
    font-size: 17px;
    line-height: 1.7;
    font-style: italic;
    margin-bottom: 28px;
    max-width: 280px;
    letter-spacing: 0.2px;
}

.client-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.client-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary-color);
    font-family: 'Playfair Display', serif;
    letter-spacing: -0.5px;
}

.client-role {
    font-size: 13px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 600;
}

.carousel-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-top: 40px;
}

.carousel-buttons button.prev-btn,
.carousel-buttons button.next-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.1);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-base);
    color: var(--primary-color);
    font-size: 20px;
    font-weight: 700;
    line-height: 1;
    touch-action: none;
}

.carousel-buttons button.prev-btn:hover,
.carousel-buttons button.next-btn:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--bg-dark);
    transform: scale(1.1);
}

/* NOTE: the prev button used to have `transform: rotate(180deg)` because it
   contained the literal "<" character. The buttons now use proper chevron
   SVGs, so no rotation is needed. */
.carousel-buttons button.prev-btn:hover {
    transform: scale(1.1);
}

.carousel-dots {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: center;
}

.carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border-color);
    border: none;
    cursor: pointer;
    transition: all var(--transition-base);
    padding: 0;
    touch-action: none;
}

.carousel-dot.active {
    background: var(--primary-color);
    width: 24px;
    border-radius: 5px;
}

.carousel-dot:hover {
    background: var(--primary-color);
}

@media (max-width: 1024px) {
    .testimonial-card {
        width: calc((100% - 32px) / 2);
        min-height: 400px;
    }
}

@media (max-width: 768px) {
    .testimonial-card {
        width: 100%;
        min-height: 380px;
    }
}

/* Contact Section */
.contact-section {
    background: linear-gradient(135deg, rgba(26, 26, 26, 0.5), rgba(10, 10, 10, 0.8));
}

.light-theme .contact-section {
    background: linear-gradient(135deg, rgba(245, 245, 245, 0.5), rgba(255, 255, 255, 0.8));
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
}

.contact-intro h3 {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 24px;
    font-family: 'Playfair Display', serif;
}

.contact-intro p {
    color: var(--text-secondary);
    font-size: 18px;
    line-height: 1.8;
    margin-bottom: 40px;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-bottom: 48px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 24px;
    background: rgba(26, 26, 26, 0.8);
    border-radius: 20px;
    border: 1px solid var(--border-color);
    text-decoration: none;
    transition: all var(--transition-smooth);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
    touch-action: manipulation;
}

.light-theme .contact-item {
    background: rgba(255, 255, 255, 0.8);
}

.contact-item::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.1), rgba(255, 215, 0, 0.1));
    transform: translateX(-100%);
    transition: transform var(--transition-smooth);
}

.contact-item:hover::before {
    transform: translateX(0);
}

.contact-item:hover {
    border-color: rgba(212, 175, 55, 0.5);
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.contact-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform var(--transition-base);
    position: relative;
    flex-shrink: 0;
}

.contact-item:hover .contact-icon {
    transform: scale(1.1) rotate(5deg);
}

.contact-icon svg {
    color: var(--bg-dark);
    position: relative;
    z-index: 1;
}

.contact-label {
    color: var(--text-muted);
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.contact-value {
    color: var(--text-primary);
    font-weight: 600;
    font-size: 16px;
}

.social-links {
    margin-top: 40px;
}

.social-title {
    color: var(--text-muted);
    margin-bottom: 20px;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.social-icons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.social-icons .social-link {
    width: 56px;
    height: 56px;
    background: rgba(26, 26, 26, 0.8);
    border: 2px solid var(--border-color);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    text-decoration: none;
    transition: all var(--transition-smooth);
    transform-origin: center center;
    touch-action: manipulation;
}

.light-theme .social-icons .social-link {
    background: rgba(255, 255, 255, 0.8);
}

.social-icons .social-link:hover {
    border-color: var(--primary-color);
    background: var(--primary-color);
    color: var(--bg-dark);
    transform: translateY(-4px) rotate(5deg);
}

/* Contact Form */
.contact-form {
    padding-left: 40px;
}

.form {
    background: rgba(26, 26, 26, 0.8);
    padding: 48px;
    border-radius: 24px;
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
}

.light-theme .form {
    background: rgba(255, 255, 255, 0.8);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.form-group {
    margin-bottom: 32px;
    position: relative;
}

.form-group label {
    display: block;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 12px;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 20px 0;
    background: transparent;
    border: none;
    border-bottom: 2px solid var(--border-color);
    color: var(--text-primary);
    font-size: 16px;
    transition: all var(--transition-base);
    resize: none;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-bottom-color: var(--primary-color);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

.form-line {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    transition: width var(--transition-base);
}

.form-group input:focus+.form-line,
.form-group textarea:focus+.form-line {
    width: 100%;
}

.submit-btn {
    width: 100%;
    justify-content: center;
    margin-top: 24px;
}

/* Footer */
.footer {
    position: relative;
    background: linear-gradient(135deg, var(--bg-dark), var(--bg-light));
    border-top: 1px solid var(--border-color);
    padding: 80px 0 32px;
    overflow: hidden;
}

.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 25px;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    border: none;
    border-radius: 50%;
    color: var(--bg-dark);
    cursor: pointer;
    transition: all var(--transition-smooth);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    z-index: 1000;
    touch-action: manipulation;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-lg);
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 64px;
    margin-bottom: 48px;
}

.footer-logo {
    font-size: 36px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
    font-family: 'Playfair Display', serif;
}

.footer-brand p {
    color: var(--text-muted);
    line-height: 1.8;
    margin-bottom: 32px;
}

.newsletter h4 {
    color: var(--primary-color);
    margin-bottom: 16px;
    font-size: 18px;
    font-weight: 600;
}

.newsletter-form {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.newsletter-form input {
    flex: 1;
    min-width: 200px;
    padding: 12px 16px;
    background: rgba(26, 26, 26, 0.8);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
}

.light-theme .newsletter-form input {
    background: rgba(255, 255, 255, 0.8);
}

.newsletter-form input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.newsletter-form button {
    padding: 12px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    border: none;
    border-radius: 8px;
    color: var(--bg-dark);
    cursor: pointer;
    transition: all var(--transition-base);
    touch-action: manipulation;
}

.newsletter-form button:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-sm);
}

.footer-links h3 {
    color: var(--primary-color);
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 24px;
    font-family: 'Playfair Display', serif;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    transition: all var(--transition-base);
    font-size: 15px;
    position: relative;
    display: inline-block;
    touch-action: manipulation;
}

.footer-links a::before {
    content: '';
    position: absolute;
    left: -20px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width var(--transition-base);
}

.footer-links a:hover {
    color: var(--primary-color);
    padding-left: 20px;
}

.footer-links a:hover::before {
    width: 12px;
}

.footer-contact h3 {
    color: var(--primary-color);
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 24px;
    font-family: 'Playfair Display', serif;
}

.footer-contact-info p {
    color: var(--text-muted);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    flex-wrap: wrap;
}

.footer-contact-info svg {
    color: var(--primary-color);
    flex-shrink: 0;
}

.footer-divider {
    height: 1px;
    background: linear-gradient(to right, transparent, var(--border-color), transparent);
    margin-bottom: 32px;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 24px;
}

.footer-bottom p {
    color: var(--text-muted);
    font-size: 14px;
}

.footer-social {
    display: flex;
    gap: 16px;
}

.footer-social a {
    width: 40px;
    height: 40px;
    background: rgba(26, 26, 26, 0.8);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    text-decoration: none;
    transition: all var(--transition-base);
    transform-origin: center center;
    touch-action: manipulation;
}

.light-theme .footer-social a {
    background: rgba(255, 255, 255, 0.8);
}

.footer-social a:hover {
    background: var(--primary-color);
    color: var(--bg-dark);
    transform: translateY(-2px);
}

.footer-love {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 14px;
}

.heart-icon {
    color: #FF6B6B;
    animation: heartbeat 2s ease-in-out infinite;
}

@keyframes heartbeat {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

.footer-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, #000000, transparent);
    pointer-events: none;
    opacity: 0.5;
}

/* Magnetic Effect */
[data-magnetic] {
    transform-origin: center center;
    touch-action: manipulation;
}

/* ============================================================================
   RESPONSIVE DESIGN  (rebuilt)
   ----------------------------------------------------------------------------
   Breakpoints
     ≤ 1200px  tablet landscape / small laptop   (content stacks)
     ≤ 1024px  tablet                             (2 columns)
     ≤  900px  phone nav switches to the hamburger
     ≤  768px  phone                              (1 column)
     ≤  480px  small phone
   Everything is written mobile-safe: fluid `clamp()` type, fluid gaps and
   `min-width: 0` on flex/grid children so nothing can push the page wider
   than the viewport.
   ============================================================================ */

/* ---------- ≤ 1200px : stack the two-column sections ---------- */
@media (max-width: 1200px) {
    :root {
        --section-padding: 80px;
        --container-padding: 24px;
    }

    .about-content,
    .contact-content {
        grid-template-columns: 1fr;
        gap: 48px;
        text-align: center;
    }

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

    .skills-container {
        padding-left: 0;
    }

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

    .contact-form {
        padding-left: 0;
    }

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

    .footer-content {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 40px;
    }
}

/* ---------- ≤ 1024px : tablets ---------- */
@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 24px;
    }

    .projects-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 24px;
    }

    .project-card {
        height: auto;
        min-height: 0;
    }

    .testimonial-card {
        width: calc((100% - 32px) / 2);
        min-height: 400px;
    }

    .footer-content {
        gap: 40px;
    }
}

/* ---------- ≤ 900px : phone navigation ---------- */
@media (max-width: 900px) {

    .nav-menu {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
    }

    .theme-toggle {
        width: 44px;
        height: 44px;
        margin-left: 8px;
    }
}

/* ---------- ≤ 768px : phones ---------- */
@media (max-width: 767.98px) {
    :root {
        --section-padding: 64px;
        --container-padding: 20px;
        --header-height: 76px;
    }

    /* Hero */
    .hero-section {
        padding-top: calc(var(--header-height) + 32px);
        padding-bottom: 80px;
    }

    .hero-greeting {
        font-size: 13px;
        letter-spacing: 1.5px;
    }

    .hero-title h1 {
        font-size: clamp(2.25rem, 10vw, 3.5rem);
        line-height: 1.08;
    }

    .hero-subtitle {
        margin-bottom: 24px;
    }

    .typing-text {
        font-size: clamp(1.15rem, 4.5vw, 1.6rem);
        min-height: 44px;
        margin-bottom: 16px;
    }

    .hero-description p {
        font-size: 16px;
        padding: 0 4px;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        gap: 12px;
        margin-bottom: 40px;
    }

    .hero-buttons .btn {
        width: 100%;
        justify-content: center;
        padding: 16px 24px;
        font-size: 15px;
    }

    .hero-social {
        gap: 14px;
        margin-bottom: 32px;
    }

    .social-link {
        width: 48px;
        height: 48px;
    }

    .scroll-indicator {
        bottom: 20px;
    }

    .scroll-line {
        height: 48px;
    }

    /* Sections */
    .section-header {
        margin-bottom: 44px;
    }

    .section-title {
        font-size: clamp(1.9rem, 8vw, 2.6rem);
        margin-bottom: 20px;
    }

    .section-description {
        font-size: 16px;
        line-height: 1.7;
    }

    .section-line {
        margin-bottom: 24px;
    }

    /* About */
    .about-content {
        gap: 40px;
        margin-bottom: 48px;
    }

    .profile-image {
        width: min(280px, 72vw);
        height: min(280px, 72vw);
        margin-bottom: 28px;
    }

    .profile-initials {
        font-size: clamp(56px, 16vw, 80px);
    }

    .profile-dots {
        inset: -18px;
    }

    .about-title {
        font-size: 24px;
    }

    .about-text p {
        font-size: 16px;
        line-height: 1.75;
    }

    .about-highlights {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
        gap: 12px;
    }

    .highlight-item {
        padding: 18px 12px;
    }

    .highlight-number {
        font-size: 26px;
    }

    .highlight-text {
        font-size: 12px;
    }

    .skills-title {
        font-size: 26px;
        margin-bottom: 24px;
    }

    .skills-grid {
        gap: 20px;
    }

    .skill-category {
        padding: 24px 20px;
    }

    .skill-tags {
        gap: 8px;
    }

    .skill-tag {
        padding: 7px 14px;
        font-size: 13px;
    }

    /* Services */
    .services-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .service-card {
        padding: 32px 24px;
    }

    .service-number {
        font-size: 36px;
        top: 18px;
        right: 18px;
    }

    .service-icon {
        width: 64px;
        height: 64px;
        margin-bottom: 24px;
    }

    .service-title {
        font-size: 21px;
        margin-bottom: 14px;
    }

    .service-description {
        font-size: 15px;
        margin-bottom: 24px;
    }

    /* Projects */
    .project-filters {
        gap: 10px;
        margin-bottom: 32px;
    }

    .filter-btn {
        padding: 10px 18px;
        font-size: 13px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
        gap: 24px;
        margin-bottom: 48px;
    }

    .project-content {
        padding: 24px 20px;
    }

    .project-title {
        font-size: 21px;
    }

    .project-description {
        font-size: 15px;
    }

    /* Testimonials: one card per view + native snap */
    .testimonial-card {
        width: 100%;
        min-height: 0;
        padding: 32px 24px;
    }

    .quote {
        font-size: 16px;
    }

    .carousel-buttons {
        margin-top: 28px;
    }

    /* Contact */
    .contact-content {
        gap: 40px;
    }

    .contact-intro h3 {
        font-size: 24px;
    }

    .contact-intro p {
        font-size: 16px;
        margin-bottom: 28px;
    }

    .contact-details {
        gap: 14px;
        margin-bottom: 32px;
    }

    .contact-item {
        padding: 16px;
        gap: 14px;
        text-align: left;
    }

    .contact-icon {
        width: 48px;
        height: 48px;
    }

    .contact-value {
        font-size: 15px;
        word-break: break-word;
    }

    .form {
        padding: 28px 20px;
        border-radius: 18px;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .form-group {
        margin-bottom: 22px;
    }

    .form-group label {
        font-size: 12px;
    }

    .form-group input,
    .form-group textarea {
        /* 16px min font-size stops iOS Safari from zooming on focus */
        font-size: 16px;
        padding: 14px 0;
    }

    /* Footer */
    .footer {
        padding: 56px 0 calc(24px + env(safe-area-inset-bottom));
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 32px;
        text-align: center;
        margin-bottom: 32px;
    }

    .footer-brand p {
        margin-bottom: 24px;
    }

    .newsletter-form {
        justify-content: center;
    }

    .footer-contact-info p {
        justify-content: center;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
        gap: 16px;
    }

    .footer-links a {
        padding: 6px 0;
        display: inline-block;
    }

    /* Cursor / hover-only effects */
    .cursor,
    .cursor-follower {
        display: none !important;
    }

    .scroll-to-top {
        width: 48px;
        height: 48px;
        right: 16px;
        bottom: calc(16px + env(safe-area-inset-bottom));
    }

    .scroll-to-top svg {
        width: 18px;
        height: 18px;
    }

    /* Background blobs: cheaper on mobile GPUs */
    .floating-element {
        filter: blur(60px);
    }
}

/* ---------- ≤ 480px : small phones ---------- */
@media (max-width: 479.98px) {
    :root {
        --section-padding: 48px;
        --container-padding: 16px;
        --header-height: 68px;
    }

    .logo-text {
        font-size: 20px;
        letter-spacing: -0.5px;
    }

    .header {
        padding: 16px 0;
    }

    .header.scrolled {
        padding: 10px 0;
    }

    .hero-title h1 {
        font-size: clamp(1.85rem, 10.5vw, 2.75rem);
    }

    .hero-greeting {
        font-size: 12px;
    }

    .hero-description p {
        font-size: 15px;
    }

    .section-title {
        font-size: clamp(1.75rem, 8.5vw, 2.2rem);
    }

    .section-description {
        font-size: 15px;
    }

    .btn {
        padding: 15px 26px;
        font-size: 14px;
    }

    .service-card,
    .skill-category {
        padding: 24px 18px;
        border-radius: 18px;
    }

    .project-content {
        padding: 20px 16px;
    }

    .filter-btn {
        flex: 1 1 auto;
        padding: 9px 14px;
        font-size: 12px;
        min-width: 0;
    }

    .form {
        padding: 22px 16px;
    }

    .footer-logo {
        font-size: 24px;
    }

    .newsletter-form {
        flex-direction: column;
        gap: 10px;
    }

    .newsletter-form input {
        width: 100%;
        min-width: 0;
    }

    .newsletter-form button {
        width: 100%;
        padding: 14px;
    }

    .mobile-nav-link {
        font-size: 24px;
    }
}

/* ---------- Short viewports (landscape phones) ---------- */
@media (max-height: 520px) and (max-width: 900px) {
    .hero-section {
        min-height: 0;
        padding-top: calc(var(--header-height) + 24px);
        padding-bottom: 56px;
    }

    .mobile-menu {
        align-items: flex-start;
        padding-top: calc(var(--header-height) + 12px);
    }

    .mobile-menu-inner {
        gap: 16px;
    }

    .mobile-nav-menu li {
        margin: 0;
    }

    .mobile-nav-link {
        font-size: 20px;
        padding: 8px;
    }

    .scroll-indicator {
        display: none;
    }
}

/* ---------- Touch devices: no sticky hover states ---------- */
@media (hover: none), (pointer: coarse) {
    .service-card:hover,
    .project-card:hover,
    .contact-item:hover,
    .skill-category:hover,
    .highlight-item:hover,
    .testimonial-card:hover,
    .btn:hover,
    .social-link:hover {
        transform: none;
        box-shadow: none;
    }

    .project-card:hover .project-image img {
        transform: none;
    }

    /* Keep the card's link always reachable on touch (there is no hover) */
    .project-overlay {
        background: linear-gradient(to top, rgba(10, 10, 10, 0.75), transparent 55%);
    }

    .project-links {
        opacity: 1;
        transform: none;
    }
}

/* ---------- Scroll lock used by the mobile menu ---------- */
.no-scroll,
body.no-scroll {
    overflow: hidden !important;
    height: 100%;
    touch-action: none;
}

/* ---------- Focus styles (keyboard) ---------- */
:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 3px;
    border-radius: 4px;
}

/* Accessibility */
@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;
    }

    .floating-element {
        animation: none;
    }

    .gradient-text {
        animation: none;
    }

    .hero-surname {
        animation: none;
    }

    .grid-bg {
        animation: none;
    }

    .profile-ring,
    .profile-dots {
        animation: none;
    }

    .featured-badge {
        animation: none;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .btn-primary {
        border: 2px solid var(--text-primary);
    }

    .service-card,
    .project-card,
    .contact-item {
        border-width: 2px;
    }

    .form-group input,
    .form-group textarea {
        border-bottom-width: 3px;
    }
}

/* Print styles */
@media print {

    .loading-screen,
    .cursor,
    .cursor-follower,
    .header,
    .scroll-indicator,
    .scroll-to-top,
    .theme-toggle,
    .mobile-menu-btn,
    .progress-bar,
    .floating-element,
    .particles-canvas,
    .grid-bg {
        display: none !important;
    }

    body {
        background: white !important;
        color: black !important;
    }

    .gradient-text {
        color: black !important;
        -webkit-text-fill-color: black !important;
    }

    section {
        page-break-inside: avoid;
        padding: 20px 0;
    }

    .btn {
        border: 1px solid black;
        color: black;
    }
}

/* Loading states */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.skeleton {
    background: linear-gradient(90deg,
            rgba(212, 175, 55, 0.1) 0%,
            rgba(212, 175, 55, 0.2) 50%,
            rgba(212, 175, 55, 0.1) 100%);
    background-size: 200% 100%;
    animation: skeleton 1.5s ease-in-out infinite;
}

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

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

/* Utility classes */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}