/* =========================================================
   CLEAN MINIMAL PORTFOLIO - Light Mode Only
   Inspired by mattfarley.ca
   ========================================================= */

:root {
    /* Color palette - minimal red accent */
    --red: #E3180D;
    --red-light: #FF4D42;
    --red-subtle: rgba(227, 24, 13, 0.08);
    
    /* Neutrals */
    --white: #FFFFFF;
    --gray-50: #F9FAFB;
    --gray-100: #F3F4F6;
    --gray-200: #E5E7EB;
    --gray-300: #D1D5DB;
    --gray-500: #6B7280;
    --gray-700: #374151;
    --gray-900: #111827;
    
    /* Semantic */
    --text: var(--gray-900);
    --text-muted: var(--gray-500);
    --border: var(--gray-200);
    
    /* Spacing */
    --gap-xl: 120px;
    --gap-lg: 80px;
    --gap-md: 48px;
    --gap-sm: 24px;
}

/* =========================================================
   BASE & RESET
   ========================================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    /* Hide scrollbar for IE, Edge and Firefox */
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
}

/* Hide scrollbar for Chrome, Safari and Opera */
html::-webkit-scrollbar {
    display: none;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', sans-serif;
    background: var(--white);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    max-width: 100%;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 32px;
}

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

/* =========================================================
   HEADER & NAV
   ========================================================= */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--gray-100);
    z-index: 1000;
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
    position: relative;
    z-index: 1001;
}

.brand {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
    position: relative;
    z-index: 1002;
}

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

.nav-links {
    display: flex !important; /* Always flex on desktop */
    list-style: none;
    gap: 32px;
    align-items: center;
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-links a:hover {
    color: var(--red);
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1002;
    position: relative;
}

.burger {
    display: flex;
    flex-direction: column;
    gap: 5px;
    width: 28px;
    height: 24px;
    justify-content: center;
}

.burger-line {
    width: 100%;
    height: 3px;
    background: var(--text);
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
}

.burger.active .burger-line:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.burger.active .burger-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.burger.active .burger-line:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Simple navigation for non-home pages */
.nav-simple {
    display: flex;
    align-items: center;
    gap: 16px;
}

.nav-simple .btn-premium {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.nav-simple .btn-premium svg {
    width: 18px;
    height: 18px;
}

.theme-toggle {
    display: none; /* Removed - light only */
}

/* =========================================================
   SECTIONS WITH GRADIENT TRANSITIONS
   ========================================================= */
section {
    padding: var(--gap-lg) 0;
    position: relative;
}

section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(to bottom, var(--gray-50), transparent);
    pointer-events: none;
}

section:first-of-type::before {
    display: none;
}

section:nth-child(even) {
    background: var(--gray-50);
}

/* Skills and Experience sections share same background */
#skills,
#experience {
    background: var(--gray-50);
}

#skills {
    padding-top: var(--gap-lg);
    padding-bottom: 0;
}

#experience {
    padding-top: 40px;
    padding-bottom: var(--gap-lg);
}

/* =========================================================
   HERO - Clean intro
   ========================================================= */
.premium-hero {
    min-height: 100vh;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    background: var(--white);
}

.premium-hero::before {
    display: none; /* No gradient glow */
}

.premium-hero .container {
    max-width: 800px;
    text-align: center;
    width: 100%;
}

.premium-hero__content-center {
    text-align: center;
    width: 100%;
}

.premium-hero__content-center h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    line-height: 1.15;
    margin-bottom: 24px;
    font-weight: 800;
    color: var(--text);
    text-align: center;
}

.premium-hero__content-center .accent {
    color: var(--red);
}

.premium-hero__content-center .lead {
    font-size: clamp(1.125rem, 2vw, 1.375rem);
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 40px;
    max-width: 600px;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.premium-hero__cta {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* =========================================================
   PAGE HEADER - For non-home pages
   ========================================================= */
.page-header {
    padding: 160px 0 80px;
    background: var(--white);
    text-align: center;
}

.page-header__title {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 800;
    margin-bottom: 16px;
    color: var(--text);
}

.page-header__subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: var(--text-muted);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

.page-section {
    padding: 60px 0 var(--gap-lg);
}

.empty-state {
    text-align: center;
    padding: 80px 20px;
}

.empty-state .muted {
    font-size: 1.125rem;
}

/* =========================================================
   BUTTONS - Minimal
   ========================================================= */
.btn-premium {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    background: var(--red);
    color: white;
    border: 0;
    border-radius: 6px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s;
}

.btn-premium:hover {
    background: var(--red-light);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(227, 24, 13, 0.2);
}

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

.btn-premium--outline:hover {
    border-color: var(--red);
    color: var(--red);
    box-shadow: none;
}

/* Legacy button support - removed @extend which is not valid CSS */

/* =========================================================
   STATS - Inline minimal
   ========================================================= */
.premium-stats {
    display: flex;
    justify-content: center;
    gap: 60px;
    padding: 5px 0;
    flex-wrap: wrap;
}


.premium-section {
    padding: 50px 30px;
}

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

.premium-stat__number {
    font-size: 3rem;
    font-weight: 800;
    color: var(--red);
    line-height: 1;
}

.premium-stat__label {
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-top: 8px;
    font-weight: 600;
}

/* =========================================================
   SECTION HEADERS - Subtle, not explicit
   ========================================================= */
.premium-header {
    text-align: center;
    margin-bottom: var(--gap-md);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.premium-header__title {
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    font-weight: 800;
    margin-bottom: 16px;
    color: var(--text);
}

.premium-header__subtitle {
    font-size: 1.125rem;
    color: var(--text-muted);
    line-height: 1.7;
}

.premium-header__desc {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-top: 12px;
    line-height: 1.6;
    opacity: 0.85;
}

/* =========================================================
   SKILLS - Infinite Marquee Scroll (Fullscreen Seamless)
   ========================================================= */
.skills-marquee {
    overflow: hidden;
    position: relative;
    width: 100%;
    margin: 0;
    padding: 20px 0 80px;
    background: var(--gray-50);
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    max-width: 100vw;
}

.skills-marquee__track {
    display: flex;
    gap: 80px;
    animation: marquee var(--animation-duration, 40s) linear infinite;
    width: max-content;
    padding: 0;
    will-change: transform;
}

.skills-marquee__track:hover {
    animation-play-state: paused;
}

@keyframes marquee {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(calc(-50% - 40px));
    }
}

.skills-marquee__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    min-width: 100px;
}

.skills-marquee__icon {
    width: 80px;
    height: 80px;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: all 0.3s ease;
}

.skills-marquee__item:hover .skills-marquee__icon {
    filter: grayscale(0%);
    opacity: 1;
    transform: scale(1.1);
}

.skills-marquee__icon-placeholder {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--white);
    border: 2px solid var(--border);
    border-radius: 12px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--red);
    text-transform: uppercase;
}

.skills-marquee__name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
    text-align: center;
    white-space: nowrap;
}

/* Legacy skills (keep for backward compatibility) */
.premium-skills {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    max-width: 800px;
    margin: 0 auto;
}

.premium-skill-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: var(--gray-50);
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text);
    transition: all 0.2s;
}

.premium-skill-tag:hover {
    background: var(--red-subtle);
    border-color: var(--red);
}

.premium-skill-tag__icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

/* =========================================================
   EXPERIENCE - Zigzag Timeline (Left-Right Alternating)
   ========================================================= */
.premium-timeline-zigzag {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    padding: 40px 0;
}

.premium-timeline-zigzag::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom, var(--red), var(--red-light), transparent);
    transform: translateX(-50%);
}

.premium-timeline-item {
    padding: 32px 0;
    position: relative;
    width: 45%;
    margin-bottom: 40px;
}

.premium-timeline-item.left {
    margin-left: 0;
    margin-right: auto;
    padding-right: 40px;
    text-align: right;
}

.premium-timeline-item.right {
    margin-left: auto;
    margin-right: 0;
    padding-left: 40px;
    text-align: left;
}

.premium-timeline-item::before {
    content: '';
    position: absolute;
    top: 38px;
    width: 16px;
    height: 16px;
    background: var(--red);
    border-radius: 50%;
    border: 4px solid var(--white);
    box-shadow: 0 0 0 3px var(--red-subtle);
    z-index: 2;
}

.premium-timeline-item.left::before {
    right: -8px;
}

.premium-timeline-item.right::before {
    left: -8px;
}

.premium-timeline-item::after {
    content: '';
    position: absolute;
    top: 46px;
    width: 30px;
    height: 2px;
    background: var(--red-subtle);
}

.premium-timeline-item.left::after {
    right: 8px;
}

.premium-timeline-item.right::after {
    left: 8px;
}

.premium-timeline-item__date {
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--red);
    margin-bottom: 12px;
    font-weight: 600;
}

.premium-timeline-item__title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text);
}

.premium-timeline-item__company {
    font-size: 1.125rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 16px;
}

.premium-timeline-item__desc {
    list-style: none;
    padding: 0;
    margin: 0;
}

.premium-timeline-item.left .premium-timeline-item__desc {
    text-align: right;
}

.premium-timeline-item.right .premium-timeline-item__desc {
    text-align: left;
}

.premium-timeline-item__desc li {
    padding: 6px 0 6px 20px;
    color: var(--text-muted);
    line-height: 1.6;
    position: relative;
}

.premium-timeline-item.left .premium-timeline-item__desc li {
    padding: 6px 20px 6px 0;
}

.premium-timeline-item.right .premium-timeline-item__desc li {
    padding: 6px 0 6px 20px;
}

.premium-timeline-item__desc li::before {
    content: '▸';
    position: absolute;
    color: var(--red);
    font-size: 0.875rem;
}

.premium-timeline-item.left .premium-timeline-item__desc li::before {
    right: 0;
    left: auto;
    content: '◂';
}

.premium-timeline-item.right .premium-timeline-item__desc li::before {
    left: 0;
    content: '▸';
}

/* =========================================================
   PROJECTS - Minimal Horizontal List (No Cards)
   ========================================================= */
.projects-minimal {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 0;
    display: flex;
    gap: 0;
    align-items: stretch;
}

.project-minimal-item {
    flex: 1;
    padding: 0 32px;
    border-right: 2px solid var(--gray-200);
    transition: all 0.3s ease;
    position: relative;
}

.project-minimal-item:last-child {
    border-right: none;
}

.project-minimal-item:first-child {
    padding-left: 0;
}

.project-minimal-item:hover {
    transform: translateY(-8px);
}

.project-minimal-item:hover::after {
    content: '';
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 3px;
    background: var(--red);
}

.project-minimal-item__content {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.project-minimal-item__title {
    font-size: 1.375rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text);
    line-height: 1.3;
    transition: color 0.3s ease;
}

.project-minimal-item:hover .project-minimal-item__title {
    color: var(--red);
}

.project-minimal-item__desc {
    font-size: 0.9375rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 16px;
    flex-grow: 1;
}

.project-minimal-item__stack {
    font-size: 0.8125rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 16px;
    padding: 8px 12px;
    background: var(--gray-50);
    border-radius: 6px;
    border-left: 3px solid var(--red-subtle);
    transition: border-color 0.3s ease;
}

.project-minimal-item:hover .project-minimal-item__stack {
    border-left-color: var(--red);
    background: var(--red-subtle);
}

.project-minimal-item__link {
    display: inline-block;
    margin-top: 16px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--red);
    text-decoration: none;
    transition: all 0.2s ease;
    opacity: 0;
    transform: translateY(4px);
}

.project-minimal-item:hover .project-minimal-item__link {
    opacity: 1;
    transform: translateY(0);
}

.project-minimal-item__link:hover {
    transform: translateX(4px) translateY(0);
}

.project-minimal-item__links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: auto;
}

.project-minimal-item__links a {
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.2s ease;
    position: relative;
    padding-bottom: 2px;
}

.project-minimal-item__links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--red);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.project-minimal-item__links a:hover {
    color: var(--red);
}

.project-minimal-item__links a:hover::after {
    transform: scaleX(1);
}

/* Mobile responsive - stack vertically on small screens */
@media (max-width: 900px) {
    .projects-minimal {
        flex-direction: column;
        gap: 40px;
    }
    
    .project-minimal-item {
        padding: 0;
        border-right: none;
        border-bottom: 2px solid var(--gray-200);
        padding-bottom: 40px;
    }
    
    .project-minimal-item:last-child {
        border-bottom: none;
        padding-bottom: 0;
    }
    
    .project-minimal-item:hover::after {
        display: none;
    }
}

/* =========================================================
   PROJECTS - Split Zigzag + Bento Grid Layout
   ========================================================= */

/* Featured Project: Split Layout */
.premium-project-featured {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    max-width: 1100px;
    margin: 0 auto 80px;
    padding: 40px;
    background: var(--white);
    border-radius: 16px;
    border: 1px solid var(--gray-200);
    transition: all 0.3s ease;
}

.premium-project-featured:hover {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
    border-color: var(--red-subtle);
}

.premium-project-featured__image {
    width: 100%;
    height: 400px;
    border-radius: 12px;
    overflow: hidden;
    background: var(--gray-100);
}

.premium-project-featured__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.premium-project-featured:hover .premium-project-featured__image img {
    transform: scale(1.05);
}

.premium-project-featured__content {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.premium-project-featured__title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text);
    line-height: 1.2;
    margin-top: 8px;
}

.premium-project-featured__desc {
    font-size: 1.0625rem;
    color: var(--text-muted);
    line-height: 1.7;
}

.premium-project-featured__stack {
    padding: 16px;
    background: var(--gray-50);
    border-radius: 8px;
    font-size: 0.9375rem;
    color: var(--text);
}

.premium-project-featured__stack strong {
    color: var(--red);
    font-weight: 600;
}

.premium-project-featured__links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* Bento Grid for Remaining Projects */
.premium-projects-bento {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    max-width: 1100px;
    margin: 0 auto;
}

.premium-bento-card {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    background: var(--gray-900);
    min-height: 300px;
    transition: transform 0.3s ease;
}

.premium-bento-card.large {
    grid-column: span 2;
    grid-row: span 1;
    min-height: 400px;
}

.premium-bento-card:hover {
    transform: translateY(-4px);
}

.premium-bento-card__image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.premium-bento-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease, filter 0.3s ease;
}

.premium-bento-card:hover .premium-bento-card__image img {
    transform: scale(1.1);
    filter: brightness(0.7);
}

.premium-bento-card__overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 32px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95), rgba(0, 0, 0, 0.7), transparent);
    color: white;
    transform: translateY(60%);
    transition: transform 0.3s ease;
}

.premium-bento-card:hover .premium-bento-card__overlay {
    transform: translateY(0);
}

.premium-bento-card__title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: white;
}

.premium-bento-card.large .premium-bento-card__title {
    font-size: 1.75rem;
}

.premium-bento-card__desc {
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.9);
    opacity: 0;
    transition: opacity 0.3s ease 0.1s;
}

.premium-bento-card:hover .premium-bento-card__desc {
    opacity: 1;
}

.premium-bento-card__stack {
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 16px;
    font-weight: 500;
}

.premium-bento-card__links {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    opacity: 0;
    transition: opacity 0.3s ease 0.2s;
}

.premium-bento-card:hover .premium-bento-card__links {
    opacity: 1;
}

.btn-premium--small {
    padding: 8px 16px;
    font-size: 0.8125rem;
}

/* Legacy grid support (keep for backward compatibility) */
.premium-projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 32px;
    max-width: 1000px;
    margin: 0 auto;
}

/* =========================================================
   PROJECTS - Image-First Overlay Gallery (New)
   ========================================================= */
.premium-projects-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 36px;
    max-width: 1150px;
    margin: 0 auto;
}

.gallery-project {
    position: relative;
    height: 380px;
    border-radius: 20px;
    overflow: hidden;
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
    cursor: pointer;
    transition: box-shadow 0.4s ease, transform 0.4s ease, border-color 0.4s;
}

.gallery-project.featured {
    outline: 3px solid var(--red-subtle);
}

.gallery-project:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 42px -10px rgba(0,0,0,0.15);
    border-color: var(--red-subtle);
}

.gallery-project__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.85) saturate(0.9);
    transition: transform 0.6s ease, filter 0.6s ease;
}

.gallery-project:hover .gallery-project__img {
    transform: scale(1.08);
    filter: brightness(0.6) saturate(1.05);
}

.gallery-project__overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 30px 28px 26px;
    background: linear-gradient(to top, rgba(0,0,0,0.92), rgba(0,0,0,0.55), rgba(0,0,0,0));
    color: white;
}

.gallery-project__badge {
    display: inline-block;
    background: var(--red);
    color: white;
    font-size: 0.625rem;
    letter-spacing: 0.08em;
    font-weight: 700;
    padding: 6px 10px;
    border-radius: 4px;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.gallery-project__title {
    font-size: 1.35rem;
    font-weight: 700;
    margin: 0 0 10px;
    line-height: 1.25;
}

.gallery-project.featured .gallery-project__title {
    font-size: 1.5rem;
}

.gallery-project__stack {
    font-size: 0.75rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-weight: 600;
    color: rgba(255,255,255,0.8);
    margin-bottom: 14px;
}

.gallery-project__desc {
    font-size: 0.875rem;
    color: rgba(255,255,255,0.85);
    line-height: 1.55;
    margin: 0 0 16px;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.4s ease 0.05s, max-height 0.45s ease, transform 0.4s ease;
}

.gallery-project:hover .gallery-project__desc {
    max-height: 160px;
    opacity: 1;
    transform: translateY(0);
}

.gallery-project__links {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.35s ease 0.15s, transform 0.35s ease 0.15s;
}

.gallery-project:hover .gallery-project__links {
    opacity: 1;
    transform: translateY(0);
}

.btn-premium--small {
    padding: 8px 16px;
    font-size: 0.75rem;
}

/* Focus accessibility */
.gallery-project:focus-visible {
    outline: 3px solid var(--red);
    outline-offset: 3px;
}

/* Mobile & tablet adjustments */
@media (max-width: 1024px) {
    .gallery-project {
        height: 340px;
    }
    .gallery-project__title {
        font-size: 1.25rem;
    }
    .gallery-project.featured .gallery-project__title {
        font-size: 1.35rem;
    }
}

@media (max-width: 900px) {
    .gallery-project {
        height: 300px;
    }
    .gallery-project__desc,
    .gallery-project__links {
        opacity: 1;
        max-height: none;
        transform: translateY(0);
    }
    .gallery-project__overlay {
        background: linear-gradient(to top, rgba(0,0,0,0.85), rgba(0,0,0,0.5), rgba(0,0,0,0));
    }
}

@media (max-width: 600px) {
    .gallery-project {
        height: 260px;
    }
    .gallery-project__title {
        font-size: 1.1rem;
    }
    .gallery-project__badge {
        font-size: 0.55rem;
        padding: 5px 8px;
    }
}

.premium-project-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--gray-200);
    transition: all 0.3s ease;
}

.premium-project-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
    border-color: var(--red-subtle);
}

.premium-project-card__image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: var(--gray-100);
}

.premium-project-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.premium-project-card:hover .premium-project-card__image img {
    transform: scale(1.05);
}

.premium-project-card__content {
    padding: 24px;
}

.premium-project-card__badge {
    display: inline-block;
    padding: 4px 12px;
    background: var(--red-subtle);
    color: var(--red);
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.premium-project-card__title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text);
    line-height: 1.3;
}

.premium-project-card__desc {
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 16px;
    font-size: 0.9375rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.premium-project-card__meta {
    margin-bottom: 16px;
}

.premium-project-card__stack {
    font-size: 0.875rem;
    color: var(--text-muted);
    padding: 8px 12px;
    background: var(--gray-50);
    border-radius: 6px;
    font-weight: 500;
}

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

.premium-project-card__links .btn-premium {
    padding: 10px 20px;
    font-size: 0.875rem;
}

/* =========================================================
   FILTERS - Minimal pills
   ========================================================= */
.premium-filters {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: var(--gap-md);
}

.premium-filter {
    padding: 8px 16px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 20px;
    color: var(--text);
    font-weight: 500;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s;
}

.premium-filter:hover {
    border-color: var(--red);
    color: var(--red);
}

.premium-filter.active {
    background: var(--red);
    color: white;
    border-color: var(--red);
}

/* =========================================================
   SERVICES - Horizontal Accordion with Red Accents
   ========================================================= */
.services-accordion-horizontal {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.service-accordion-item {
    border-bottom: 2px solid var(--gray-200);
    transition: border-color 0.3s ease;
}

.service-accordion-item:last-child {
    border-bottom: none;
}

.service-accordion-item:hover {
    border-bottom-color: var(--red-subtle);
}

.service-accordion-item__header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    padding: 32px 0;
    background: transparent;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: all 0.3s ease;
    position: relative;
}

.service-accordion-item__header::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 0;
    background: var(--red);
    transition: height 0.3s ease;
}

.service-accordion-item:hover .service-accordion-item__header::before,
.service-accordion-item__header[aria-expanded="true"]::before {
    height: 100%;
}

.service-accordion-item__header:hover {
    padding-left: 16px;
}

.service-accordion-item__info {
    flex: 1;
}

.service-accordion-item__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 8px;
    line-height: 1.3;
    transition: color 0.3s ease, transform 0.3s ease;
    transform: translateX(0);
}

.service-accordion-item:hover .service-accordion-item__title,
.service-accordion-item__header[aria-expanded="true"] .service-accordion-item__title {
    color: var(--red);
    transform: translateX(8px);
}

.service-accordion-item__summary {
    font-size: 0.9375rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin: 0;
    transition: transform 0.3s ease;
    transform: translateX(0);
}

.service-accordion-item:hover .service-accordion-item__summary,
.service-accordion-item__header[aria-expanded="true"] .service-accordion-item__summary {
    transform: translateX(8px);
}

.service-accordion-item__meta {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

.service-accordion-item__price {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--red);
    padding: 8px 16px;
    border: 2px solid var(--red-subtle);
    border-radius: 6px;
    background: var(--red-subtle);
    transition: all 0.3s ease;
}

.service-accordion-item:hover .service-accordion-item__price {
    border-color: var(--red);
    background: var(--white);
}

.service-accordion-item__chevron {
    color: var(--text-muted);
    transition: transform 0.3s ease, color 0.3s ease;
}

.service-accordion-item:hover .service-accordion-item__chevron {
    color: var(--red);
}

.service-accordion-item__chevron.rotate {
    transform: rotate(180deg);
}

.service-accordion-item__content {
    overflow: hidden;
}

.service-accordion-item__inner {
    padding: 0 0 32px 0;
    border-left: 4px solid var(--red-subtle);
    padding-left: 24px;
    margin-left: 0;
}

.service-accordion-item__features {
    list-style: none;
    padding: 0;
    margin: 0 0 24px;
}

.service-accordion-item__features li {
    padding: 8px 0;
    padding-left: 20px;
    position: relative;
    color: var(--text);
    line-height: 1.6;
}

.service-accordion-item__features li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 8px;
    height: 2px;
    background: var(--red);
}

.service-accordion-item__cta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 8px;
}

/* Legacy card grid support */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    max-width: 1100px;
    margin: 0 auto;
}

.service-card {
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 28px;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.service-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
    border-color: var(--red-subtle);
}

.service-card__header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 16px;
}

.service-card__icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-50);
    border-radius: 10px;
    font-size: 1.75rem;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.service-card:hover .service-card__icon {
    background: var(--red-subtle);
    transform: scale(1.05);
}

.service-card__meta {
    flex: 1;
}

.service-card__title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text);
    line-height: 1.3;
}

.service-card__price {
    display: inline-block;
    background: var(--red-subtle);
    color: var(--red);
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 600;
}

.service-card__summary {
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 20px;
    font-size: 0.9375rem;
    flex-grow: 1;
}

.service-card__toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px;
    background: transparent;
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    color: var(--text);
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.service-card__toggle:hover {
    background: var(--gray-50);
    border-color: var(--red);
    color: var(--red);
}

.service-card__toggle svg {
    transition: transform 0.3s ease;
}

.service-card__toggle svg.rotate-180 {
    transform: rotate(180deg);
}

.service-card__details {
    margin-top: 16px;
    padding-top: 20px;
    border-top: 1px solid var(--gray-100);
}

.service-card__features {
    list-style: none;
    padding: 0;
    margin: 0 0 20px;
}

.service-card__features li {
    padding: 8px 0 8px 24px;
    position: relative;
    color: var(--text);
    line-height: 1.5;
    font-size: 0.9375rem;
}

.service-card__features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--red);
    font-weight: 700;
}

.service-card__cta {
    margin-top: 8px;
}

/* Legacy services support */
.premium-services {
    max-width: 800px;
    margin: 0 auto;
}

.premium-service {
    border-bottom: 1px solid var(--gray-100);
}

.premium-service__header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 0;
    border: 0;
    background: transparent;
    color: var(--text);
    text-align: left;
    cursor: pointer;
    gap: 16px;
}

.premium-service__header:hover {
    color: var(--red);
}

.premium-service__icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.premium-service__title {
    font-size: 1.25rem;
    font-weight: 700;
    flex: 1;
}

.premium-service__price {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted);
}

.premium-service__chevron {
    font-size: 1.2rem;
    transition: transform 0.2s;
    color: var(--text-muted);
}

.premium-service__chevron.rot {
    transform: rotate(180deg);
}

.premium-service__content {
    border-top: none;
    overflow: hidden;
}

.premium-service__inner {
    padding: 0 0 32px;
}

.premium-service__summary {
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 20px;
}

.premium-service__features {
    list-style: none;
    padding: 0;
    margin: 0 0 24px;
}

.premium-service__features li {
    padding: 8px 0;
    padding-left: 24px;
    position: relative;
    color: var(--text);
}

.premium-service__features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--red);
    font-weight: 700;
}

.premium-service__cta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.premium-service__price-detail {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* =========================================================
   CONTACT - Enhanced form with better styling
   ========================================================= */
.premium-contact {
    max-width: 700px;
    margin: 0 auto;
    background: var(--gray-50);
    padding: 48px;
    border-radius: 16px;
    border: 1px solid var(--gray-200);
}

.premium-contact__form {
    display: grid;
    gap: 24px;
}

.premium-contact__field {
    display: grid;
    gap: 8px;
}

.premium-contact__label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
}

.premium-contact__input,
.premium-contact__textarea {
    padding: 14px 18px;
    background: var(--white);
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    color: var(--text);
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.3s;
}

.premium-contact__input:focus,
.premium-contact__textarea:focus {
    outline: none;
    border-color: var(--red);
    box-shadow: 0 0 0 3px var(--red-subtle);
}

.premium-contact__textarea {
    resize: vertical;
    min-height: 140px;
}

.premium-contact__info {
    margin-top: 40px;
    padding-top: 40px;
    border-top: 1px solid var(--gray-200);
    text-align: center;
}

.premium-contact__info-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text);
}

.premium-contact__info-text {
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 28px;
    font-size: 0.9375rem;
}

.premium-contact__details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.premium-contact__detail {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px;
    background: var(--white);
    border-radius: 8px;
    transition: all 0.2s;
    text-align: center;
}

.premium-contact__detail:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.premium-contact__detail-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-50);
    border-radius: 8px;
}

.premium-contact__detail-icon svg {
    width: 20px;
    height: 20px;
}

/* Social media brand colors */
.premium-contact__detail-icon.email svg {
    stroke: #EA4335;
}

.premium-contact__detail-icon.github svg {
    stroke: #181717;
    fill: #181717;
}

.premium-contact__detail-icon.linkedin svg {
    stroke: #0A66C2;
    fill: #0A66C2;
}

.premium-contact__detail-icon.upwork svg {
    fill: #14A800;
}

.premium-contact__detail-icon.medium svg {
    fill: #000000;
}

.premium-contact__detail-icon.location,
.premium-contact__detail-icon.response {
    font-size: 1.5rem;
    color: var(--red);
}

.premium-contact__detail-content {
    text-align: center;
}

.premium-contact__detail-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    font-weight: 600;
}

.premium-contact__detail-value {
    font-weight: 600;
    color: var(--text);
    font-size: 0.9375rem;
}

.premium-contact__detail-value a {
    color: var(--red);
    text-decoration: none;
}

.premium-contact__detail-value a:hover {
    text-decoration: underline;
}

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
    background: var(--gray-50);
    padding: 40px 0;
    border-top: 1px solid var(--gray-100);
}

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

.footer-inner p {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.socials {
    display: flex;
    gap: 20px;
}

.socials a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: color 0.2s;
}

.socials a:hover {
    color: var(--red);
}

/* =========================================================
   UTILITY
   ========================================================= */
.back-to-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 48px;
    height: 48px;
    background: var(--red);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.25rem;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s;
    z-index: 999;
}

.back-to-top.show {
    opacity: 1;
    pointer-events: all;
}

.back-to-top:hover {
    background: var(--red-light);
}

#scrollProgress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: var(--red);
    z-index: 9999;
    transition: width 0.1s;
}

.lazy {
    opacity: 0;
    transition: opacity 0.3s;
}

.lazy.loaded {
    opacity: 1;
}

.count {
    /* For countup animation */
    display: inline-block;
}

.hp {
    position: absolute;
    left: -9999px;
}

/* Alpine.js transition utilities for smooth accordion */
.transition-all {
    transition-property: all;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.ease-out {
    transition-timing-function: cubic-bezier(0, 0, 0.2, 1);
}

.ease-in {
    transition-timing-function: cubic-bezier(0.4, 0, 1, 1);
}

.duration-300 {
    transition-duration: 300ms;
}

.duration-500 {
    transition-duration: 500ms;
}

.opacity-0 {
    opacity: 0;
}

.opacity-100 {
    opacity: 1;
}

.max-height-0 {
    max-height: 0;
}

.max-height-full {
    max-height: 1000px;
}

/* Menu transitions */
.transition-menu-enter {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.transition-menu-leave {
    transition: all 0.3s cubic-bezier(0.4, 0, 1, 1);
}

.transform-menu-start {
    transform: translateY(-10px);
}

.transform-menu-end {
    transform: translateY(0);
}

/* =========================================================
   RESPONSIVE
   ========================================================= */

/* Tablet landscape and below */
@media (max-width: 1024px) {
    .container {
        padding: 0 24px;
    }
    
    .premium-hero {
        min-height: 100vh;
        padding: 120px 0 60px;
    }
    
    .premium-hero .container {
        padding: 0 32px;
    }
    
    .page-header {
        padding: 140px 0 60px;
    }
    
    .skills-marquee__track {
        gap: 40px;
        animation: marquee 30s linear infinite;
    }
    
    .skills-marquee__track {
        gap: 40px;
        animation: marquee var(--animation-duration, 30s) linear infinite;
    }
    
    .skills-marquee__item {
        min-width: 80px;
    }
    
    .skills-marquee__icon,
    .skills-marquee__icon-placeholder {
        width: 60px;
        height: 60px;
    }
    
    .skills-marquee__name {
        font-size: 0.8125rem;
    }
    
    /* Services accordion - adjust padding on tablet */
    .service-accordion-item__header {
        padding: 24px 0;
    }
    
    .service-accordion-item__title {
        font-size: 1.25rem;
    }
    
    /* Services grid - 2 columns on tablet */
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
}

/* Tablet portrait and mobile */
@media (max-width: 900px) {
    .container {
        padding: 0 20px;
    }

    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(10px);
        flex-direction: column;
        padding: 0 20px;
        gap: 0;
        border-bottom: 1px solid var(--gray-100);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        transform: translateY(-10px);
        transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    transform 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                    padding 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .nav-links.open {
        max-height: 500px;
        opacity: 1;
        transform: translateY(0);
        padding: 20px;
    }

    .nav-links li {
        width: 100%;
        border-bottom: 1px solid var(--gray-50);
    }

    .nav-links li:last-child {
        border-bottom: none;
        margin-top: 8px;
    }

    .nav-links a {
        display: block;
        padding: 16px 0;
        font-size: 1.125rem;
    }

    .nav-links .btn-premium {
        width: 100%;
        justify-content: center;
        padding: 14px 20px;
    }

    .nav-toggle {
        display: block;
    }
    
    .nav-simple .btn-premium span {
        display: none;
    }
    
    .nav-simple .btn-premium svg {
        width: 20px;
        height: 20px;
    }

    .premium-hero {
        min-height: 100vh;
        padding: 100px 0 60px;
    }
    
    .premium-hero .container {
        padding: 0 24px;
    }
    
    .premium-hero__content-center h1 {
        font-size: clamp(2rem, 6vw, 3rem);
    }
    
    .page-header {
        padding: 120px 0 40px;
    }
    
    .page-header__title {
        font-size: clamp(2rem, 6vw, 2.5rem);
    }

    .premium-stats {
        gap: 40px;
    }

    .premium-projects-grid {
        grid-template-columns: 1fr;
    }

    /* Featured project: stack on mobile */
    .premium-project-featured {
        grid-template-columns: 1fr;
        gap: 32px;
        padding: 24px;
        margin-bottom: 40px;
    }

    .premium-project-featured__image {
        height: 250px;
    }

    .premium-project-featured__title {
        font-size: 1.5rem;
    }

    /* Bento grid: single column on mobile */
    .premium-projects-bento {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .premium-bento-card.large {
        grid-column: span 1;
        min-height: 300px;
    }

    .premium-bento-card__overlay {
        transform: translateY(0);
        padding: 24px;
    }

    .premium-bento-card__desc,
    .premium-bento-card__links {
        opacity: 1;
    }

    /* Featured project: stack on mobile */
    .premium-project-featured {
        grid-template-columns: 1fr;
        gap: 32px;
        padding: 24px;
        margin-bottom: 40px;
    }

    .premium-project-featured__image {
        height: 250px;
    }

    .premium-project-featured__title {
        font-size: 1.5rem;
    }

    /* Bento grid: single column on mobile */
    .premium-projects-bento {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .premium-bento-card.large {
        grid-column: span 1;
        min-height: 300px;
    }

    .premium-bento-card__overlay {
        transform: translateY(0);
        padding: 24px;
    }

    .premium-bento-card__desc,
    .premium-bento-card__links {
        opacity: 1;
    }

    /* Zigzag timeline becomes vertical on mobile */

        /* Bento grid: 2 columns on tablet */
        .premium-projects-bento {
            grid-template-columns: repeat(2, 1fr);
        }

        .premium-bento-card.large {
            grid-column: span 2;
        }
    .premium-timeline-zigzag::before {
        left: 20px;
        transform: none;
    }

    .premium-timeline-item {
        width: 100%;
        margin-left: 0 !important;
        margin-right: 0 !important;
        padding-left: 60px !important;
        padding-right: 0 !important;
        text-align: left !important;
    }

    .premium-timeline-item.left,
    .premium-timeline-item.right {
        text-align: left !important;
    }

    .premium-timeline-item::before {
        left: 13px !important;
        right: auto !important;
    }

    .premium-timeline-item::after {
        left: 29px !important;
        right: auto !important;
    }

    .premium-timeline-item.left .premium-timeline-item__desc,
    .premium-timeline-item.right .premium-timeline-item__desc {
        text-align: left !important;
    }

    .premium-timeline-item.left .premium-timeline-item__desc li,
    .premium-timeline-item.right .premium-timeline-item__desc li {
        padding: 6px 0 6px 20px !important;
    }

    .premium-timeline-item.left .premium-timeline-item__desc li::before,
    .premium-timeline-item.right .premium-timeline-item__desc li::before {
        left: 0 !important;
        right: auto !important;
        content: '▸' !important;
    }
    
    /* Services accordion - stack on mobile */
    .service-accordion-item__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
        padding: 20px 0;
    }
    
    .service-accordion-item__header:hover {
        padding-left: 12px;
    }
    
    .service-accordion-item__title {
        font-size: 1.125rem;
    }
    
    .service-accordion-item__meta {
        width: 100%;
        justify-content: space-between;
    }

    .premium-contact {
        padding: 32px 24px;
    }

    .premium-contact__details {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    :root {
        --gap-xl: 80px;
        --gap-lg: 60px;
        --gap-md: 40px;
    }

    .container {
        padding: 0 16px;
    }

    .premium-hero {
        min-height: 100vh;
        padding: 100px 0 40px;
    }
    
    .premium-hero .container {
        padding: 0 20px;
    }
    
    .premium-hero__content-center h1 {
        font-size: clamp(1.75rem, 8vw, 2.5rem);
    }
    
    .premium-hero__content-center .lead {
        font-size: 1rem;
    }
    
    .premium-hero__cta {
        flex-direction: column;
        width: 100%;
    }
    
    .premium-hero__cta .btn-premium {
        width: 100%;
        justify-content: center;
    }
    
    .page-header {
        padding: 100px 0 40px;
    }
    
    .page-header__title {
        font-size: clamp(1.75rem, 8vw, 2rem);
    }
    
    .page-header__subtitle {
        font-size: 0.9375rem;
    }

    .premium-stats {
        gap: 32px;
        grid-template-columns: repeat(2, 1fr);
    }

    .premium-stat__number {
        font-size: 2.5rem;
    }
    
    /* Services grid - 1 column on mobile */
    .services-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 44px;
        height: 44px;
    }
}

/* =========================================================
   HIDE OLD ELEMENTS
   ========================================================= */
.bg-anim {
    display: none !important;
}

.card {
    background: transparent;
    border: none;
    box-shadow: none;
}

/* =========================================================
   DETAIL PAGES (Services & Projects)
   ========================================================= */
.detail-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 48px;
    align-items: start;
}

.detail-content {
    min-width: 0;
}

.detail-sidebar {
    position: sticky;
    top: 100px;
}

/* Service Detail */
.service-detail {
    background: var(--white);
    border-radius: 12px;
    padding: 48px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.service-detail__icon {
    font-size: 3rem;
    margin-bottom: 24px;
    color: var(--red);
}

.service-detail__section {
    margin-bottom: 40px;
}

.service-detail__section:last-of-type {
    margin-bottom: 0;
}

.detail-section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 16px;
}

.detail-text {
    font-size: 1.0625rem;
    line-height: 1.7;
    color: var(--gray-700);
}

.detail-text.muted {
    color: var(--gray-500);
    font-size: 0.9375rem;
}

.detail-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.detail-features li {
    position: relative;
    padding-left: 28px;
    margin-bottom: 12px;
    font-size: 1.0625rem;
    color: var(--gray-700);
    line-height: 1.6;
}

.detail-features li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10px;
    width: 12px;
    height: 2px;
    background: var(--red);
}

.detail-pricing {
    padding: 24px 0;
}

.price-badge-large {
    display: inline-flex;
    flex-direction: column;
    gap: 8px;
    padding: 24px 32px;
    border: 2px solid var(--red);
    border-radius: 8px;
    background: var(--red-subtle);
    margin-bottom: 16px;
}

.price-badge-large .price-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--gray-600);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.price-badge-large .price-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--red);
}

.service-detail__cta {
    display: flex;
    gap: 16px;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 2px solid var(--gray-100);
}

.btn-premium--large {
    padding: 16px 32px;
    font-size: 1.0625rem;
}

/* Project Detail */
.project-detail {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.project-detail__image {
    width: 100%;
    height: 400px;
    overflow: hidden;
    background: var(--gray-100);
}

.project-detail__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-detail__section {
    padding: 0 48px;
    margin-bottom: 40px;
}

.project-detail__section:first-of-type {
    padding-top: 48px;
}

.project-detail__section:last-of-type {
    margin-bottom: 0;
}

.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.tech-badge {
    display: inline-block;
    padding: 8px 16px;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--gray-700);
    transition: all 0.2s ease;
}

.tech-badge:hover {
    background: var(--red-subtle);
    border-color: var(--red);
    color: var(--red);
}

.role-badge {
    display: inline-block;
    padding: 12px 24px;
    background: var(--red-subtle);
    border-left: 4px solid var(--red);
    border-radius: 4px;
    font-size: 1.0625rem;
    font-weight: 600;
    color: var(--red);
}

.project-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.project-detail__cta {
    padding: 32px 48px 48px;
    border-top: 2px solid var(--gray-100);
}

/* =========================================================
   Masonry Gallery (Pinterest-style)
   ========================================================= */
.masonry-gallery {
    column-count: 3;
    column-gap: 16px;
    margin: 0;
}

@media (max-width: 1024px) {
    .masonry-gallery {
        column-count: 2;
    }
}

@media (max-width: 600px) {
    .masonry-gallery {
        column-count: 1;
    }
}

.masonry-item {
    break-inside: avoid;
    margin-bottom: 16px;
    background: var(--surface);
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.masonry-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.masonry-item:hover .masonry-overlay {
    opacity: 1;
}

.masonry-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 12px;
    color: white;
}

.masonry-img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px;
}

.masonry-caption {
    padding: 12px 16px;
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin: 0;
    font-style: italic;
}

/* Gallery Modal */
.gallery-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 0;
    overflow-y: auto;
}

.gallery-modal--active {
    display: flex !important;
    opacity: 1;
}

.gallery-modal__content {
    max-width: 900px;
    width: 90%;
    max-height: 90vh;
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    margin: auto;
}

.gallery-modal--active .gallery-modal__content {
    transform: scale(1);
}

.gallery-modal__img-wrapper {
    width: 100%;
    max-height: 70vh;
    overflow: hidden;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-modal__img {
    width: 100%;
    height: auto;
    max-height: 70vh;
    object-fit: contain;
    display: block;
}

.gallery-modal__caption {
    color: var(--text);
    font-size: 0.95rem;
    text-align: center;
    padding: 20px 24px;
    line-height: 1.6;
    background: #fff;
    border-top: 1px solid #e9ecef;
    font-style: italic;
    overflow-y: auto;
    max-height: 15vh;
}

.gallery-modal__counter {
    position: absolute;
    top: 16px;
    left: 16px;
    color: #fff;
    font-size: 0.85rem;
    background: rgba(0, 0, 0, 0.7);
    padding: 6px 14px;
    border-radius: 20px;
    font-weight: 600;
    z-index: 10;
    backdrop-filter: blur(10px);
}

.gallery-modal__close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(0, 0, 0, 0.7);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
    backdrop-filter: blur(10px);
}

.gallery-modal__close:hover {
    background: rgba(0, 0, 0, 0.9);
    transform: rotate(90deg);
}

.gallery-modal__nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    color: #333;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.gallery-modal__nav:hover {
    background: #fff;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.gallery-modal__nav--prev {
    left: 20px;
}

.gallery-modal__nav--next {
    right: 20px;
}

@media (max-width: 1200px) {
    .gallery-modal__content {
        max-width: 85%;
    }
}

@media (max-width: 1024px) {
    .gallery-modal__content {
        max-width: 90%;
        width: 90%;
    }
    
    .gallery-modal__nav--prev {
        left: 15px;
    }
    
    .gallery-modal__nav--next {
        right: 15px;
    }
}

@media (max-width: 768px) {
    .gallery-modal__content {
        max-width: 95%;
        width: 95%;
        max-height: 95vh;
        border-radius: 12px;
    }
    
    .gallery-modal__img-wrapper {
        max-height: 65vh;
    }
    
    .gallery-modal__img {
        max-height: 65vh;
    }
    
    .gallery-modal__nav {
        width: 40px;
        height: 40px;
    }
    
    .gallery-modal__nav--prev {
        left: 10px;
    }
    
    .gallery-modal__nav--next {
        right: 10px;
    }
    
    .gallery-modal__close {
        top: 12px;
        right: 12px;
        width: 36px;
        height: 36px;
    }
    
    .gallery-modal__counter {
        top: 12px;
        left: 12px;
        font-size: 0.8rem;
        padding: 5px 12px;
    }
    
    .gallery-modal__caption {
        font-size: 0.85rem;
        padding: 16px 20px;
        max-height: 20vh;
    }
}

/* Sidebar */
.sidebar-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 24px;
}

.related-items {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.related-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: var(--white);
    border: 2px solid var(--gray-100);
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.related-item:hover {
    border-color: var(--red);
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(227, 24, 13, 0.1);
}

.related-item__icon {
    font-size: 1.5rem;
    color: var(--red);
    flex-shrink: 0;
}

.related-item__thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
    flex-shrink: 0;
}

.related-item__content {
    flex: 1;
    min-width: 0;
}

.related-item__title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--gray-900);
    margin: 0 0 4px 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.related-item__price {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--red);
}

.related-item__stack {
    font-size: 0.8125rem;
    color: var(--gray-600);
    display: block;
}

/* Responsive Detail Pages */
@media (max-width: 1024px) {
    .detail-layout {
        grid-template-columns: 1fr 280px;
        gap: 32px;
    }

    .service-detail,
    .project-detail__section {
        padding: 32px;
    }

    .project-detail__cta {
        padding: 24px 32px 32px;
    }

    .detail-sidebar {
        top: 80px;
    }
}

@media (max-width: 900px) {
    .detail-layout {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .detail-sidebar {
        position: static;
    }

    .service-detail,
    .project-detail__section {
        padding: 24px;
    }

    .project-detail__cta {
        padding: 24px;
    }

    .project-detail__image {
        height: 300px;
    }

    .service-detail__cta,
    .project-links {
        flex-direction: column;
    }

    .service-detail__cta .btn-premium,
    .project-links .btn-premium {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 600px) {
    .detail-section-title {
        font-size: 1.25rem;
    }

    .detail-text {
        font-size: 1rem;
    }

    .service-detail__icon {
        font-size: 2.5rem;
    }

    .price-badge-large {
        padding: 20px 24px;
    }

    .price-badge-large .price-value {
        font-size: 1.75rem;
    }

    .project-detail__image {
        height: 240px;
    }

    .related-item {
        padding: 12px;
    }

    .related-item__thumb {
        width: 50px;
        height: 50px;
    }
}

