* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #fff;
    --secondary: #a3a3a3;
    --bg: #0a0a0a;
    --bg-light: #151515;
    --accent: #ff8c42;
    --card: rgba(255, 255, 255, 0.04);
    --border: rgba(255, 255, 255, 0.12);
    /* Same horizontal rhythm as project pages (.container) */
    --page-pad-x: clamp(2rem, 4vw, 4rem);
    --radius-lg: 18px;
    --radius-md: 14px;
    --radius-sm: 12px;
}

body {
    font-family: 'Inter', sans-serif;
    background: radial-gradient(circle at 15% 20%, rgba(255, 140, 66, 0.12) 0%, transparent 40%), var(--bg);
    color: var(--primary);
    overflow-x: hidden;
    line-height: 1.6;
}

/* Navigation */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 2.5rem var(--page-pad-x);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    background: rgba(10, 10, 10, 0.85);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
}

nav .logo {
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 3px;
    font-family: 'Syne', sans-serif;
    text-transform: uppercase;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 4rem;
}

nav a {
    text-decoration: none;
    color: var(--primary);
    font-size: 0.9rem;
    transition: all 0.3s cubic-bezier(0.33, 1, 0.68, 1);
    position: relative;
    font-weight: 500;
    letter-spacing: 0.5px;
}

nav ul a {
    font-family: 'Inter', sans-serif;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.4s cubic-bezier(0.33, 1, 0.68, 1);
}

nav a:hover::after {
    width: 100%;
}

nav .logo a {
    text-decoration: none;
    color: inherit;
    font-size: inherit;
    font-family: inherit;
    font-weight: inherit;
    letter-spacing: inherit;
    text-transform: inherit;
}

nav .logo a::after {
    display: none;
}

/* Project subpages: same nav + secondary actions */
nav.nav--project-page {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
}

nav.nav--project-page .nav-main-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

nav.nav--project-page .nav-sub-ctas {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: flex-end;
    align-items: center;
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    width: 100%;
}

nav.nav--project-page .nav-sub-ctas a {
    text-decoration: none;
}

nav.nav--project-page .nav-sub-ctas .cta-secondary {
    display: inline-block;
    text-align: center;
}

nav.nav--project-page .nav-sub-ctas a::after {
    display: none;
}

.project-card[id],
#portfolio,
#about,
#contact {
    scroll-margin-top: 6.5rem;
}

/* Portfolio Grid — align with project-page section rhythm */
.portfolio {
    padding: 8rem var(--page-pad-x);
    width: 100%;
    max-width: none;
    margin: 0 auto;
    box-sizing: border-box;
}

.portfolio h2 {
    font-family: 'Syne', sans-serif;
    font-size: clamp(1.4rem, 3vw, 2rem);
    font-weight: 700;
    margin-bottom: 2rem;
    letter-spacing: -0.5px;
}

.grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-bottom: 0;
    align-items: stretch;
}

.project-card {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    display: block;
    text-decoration: none;
    color: inherit;
}

.project-image {
    width: 100%;
    background: linear-gradient(145deg, #181818 0%, #101010 55%, #141227 100%);
    display: block;
    font-size: 10.5rem;
    transition: border-color 0.25s cubic-bezier(0.33, 1, 0.68, 1);
    position: relative;
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
}

.project-image img {
    width: 100%;
    height: auto;
    display: block;
    transform: scale(1);
    transition: transform 0.6s cubic-bezier(0.33, 1, 0.68, 1);
    border-radius: inherit;
}

.project-media-video {
    width: 100%;
    height: auto;
    display: none;
    vertical-align: top;
    border-radius: inherit;
}

/* WAND VOLDMORT: portrait 1080x1920px - forcer format portrait */
.project-card--wand-portrait .project-image {
    display: block;
    position: relative;
    height: 320px;
    width: 180px;
    margin: 0 auto;
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
}

.project-card--wand-portrait .project-portrait-slot {
    display: block;
    width: 100%;
    height: 100%;
    aspect-ratio: 9/16;
}

.project-card--wand-portrait .project-portrait-slot img,
.project-card--wand-portrait .project-portrait-slot .project-media-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transform: scale(1);
    transition: transform 0.6s cubic-bezier(0.33, 1, 0.68, 1);
}

/* PIANO: hauteur fixe pour alignement parfait avec Wand */
.project-card--piano-emphasis .project-image {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 500px;
    width: 100%;
    overflow: hidden;
}

.project-card--piano-emphasis .project-image img,
.project-card--piano-emphasis .project-media-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.12);
    transform-origin: center center;
    transition: transform 0.6s cubic-bezier(0.33, 1, 0.68, 1);
}

.project-card:hover .project-image {
    border-color: rgba(196, 181, 253, 0.45);
}

/* Hover interactions:
   - Image: slight zoom to show interactivity
   - Video: JS plays the video; no blur / no text / no extra effects */
.project-card:hover .project-image > img {
    transform: scale(1.06);
}

.project-card--wand-portrait:hover .project-portrait-slot img,
.project-card--wand-portrait:hover .project-portrait-slot .project-media-video {
    transform: scale(1.03);
}

.project-card--piano-emphasis:hover .project-image img,
.project-card--piano-emphasis:hover .project-media-video {
    transform: scale(1.16);
}

.project-image::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.08) 0%, transparent 70%);
    transition: all 0.6s ease;
    pointer-events: none;
}

.project-card:hover .project-image::before {
    top: 0;
    right: 0;
}

.project-overlay {
    display: none;
}

.project-info {
    display: flex;
    flex-direction: row;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem 1.5rem;
    padding: 0.85rem 1.1rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-top: none;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

.project-title {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 0;
    font-family: 'Space Grotesk', sans-serif;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.92);
    text-align: left;
    min-width: 0;
}

.project-category {
    font-size: 0.7rem;
    color: rgba(163, 163, 163, 0.85);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    font-weight: 500;
    text-align: right;
    flex-shrink: 0;
    white-space: nowrap;
}


/* About Section — three-column layout: skills | image | text */
.about {
    padding: clamp(2rem, 3.5vw, 3.5rem) var(--page-pad-x);
    width: 100%;
    max-width: none;
    margin: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(180px, 280px) minmax(0, 1.1fr);
    gap: clamp(1rem, 2.5vw, 2rem);
    align-items: center;
    box-sizing: border-box;
}

.about-content {
    min-width: 0;
    max-width: 62ch;
    margin: 0;
    grid-column: 1;
    align-self: center;
    position: relative;
    z-index: 3;
    grid-row: 2;
}

.about-skills {
    grid-column: 3;
    grid-row: 2;
    min-width: 0;
}

.about-content h2 {
    font-family: 'Syne', sans-serif;
    font-size: clamp(1.4rem, 3vw, 2rem);
    font-weight: 700;
    margin-bottom: 1.25rem;
    letter-spacing: -0.5px;
}

.about-content p {
    color: #cfcfcf;
    line-height: 1.55;
    margin-bottom: 1rem;
    font-size: 1rem;
    max-width: none;
}

.about-content p em {
    font-style: italic;
    color: rgba(255, 255, 255, 0.95);
}

/* About heading centered at the top of the section */
.about h2 {
    grid-column: 1 / -1;
    justify-self: center;
    text-align: center;
    grid-row: 1;
    margin-bottom: 1rem;
}

/* Make section headings uppercase and more prominent */
.about-content h2,
.portfolio h2 {
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: clamp(1.6rem, 4vw, 2.6rem);
}

.skills {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--border);
}

.skills h3 {
    font-size: 0.78rem;
    margin-bottom: 1rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--secondary);
    font-weight: 700;
}

.skill-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.skill-tag {
    padding: 0.45rem 0.75rem;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 0.84rem;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
}

.skill-tag:hover {
    background: rgba(255, 140, 66, 0.15);
    border-color: rgba(255, 140, 66, 0.45);
    transform: translateY(-2px);
}

.about-image {
    margin: 0;
    padding: 0;
    border: 1px solid var(--border);
    background: radial-gradient(circle at 100% 100%, rgba(255, 140, 90, 0.32) 100%, transparent 100%), var(--bg);
    overflow: hidden;
    transition: border-color 0.6s ease, transform 0.6s ease;
    border-radius: var(--radius-lg);
    align-self: center;
    grid-column: 2;
    justify-self: center;
    max-width: clamp(180px, 22vw, 280px);
    width: 100%;
    aspect-ratio: 11 / 16;
    height: auto;
    grid-row: 2;
}

.about-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.about-image:hover {
    transform: scale(1.03);
    border-color: rgba(196, 181, 253, 0.2);
}

/* Footer */
footer {
    border-top: 1px solid var(--border);
    padding: 2.25rem var(--page-pad-x);
    background: rgba(0, 0, 0, 0.5);
    box-sizing: border-box;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-bottom: 1.75rem;
    text-align: center;
    max-width: none;
    margin-left: auto;
    margin-right: auto;
}

.footer-column h4 {
    font-family: 'Syne', sans-serif;
    font-size: clamp(1.4rem, 3vw, 2rem);
    margin-bottom: 0.75rem;
    letter-spacing: -0.5px;
    text-transform: uppercase;
    color: var(--primary);
    font-weight: 700;
}

.footer-column p {
    color: var(--secondary);
    margin-bottom: 1rem;
    font-size: 1.05rem;
    line-height: 1.6;
}

.footer-column a {
    display: block;
    color: var(--secondary);
    text-decoration: none;
    margin-bottom: 0.75rem;
    transition: all 0.3s ease;
    font-size: 1.05rem;
}

.footer-column a:hover {
    color: var(--accent);
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 1.5rem;
    margin-top: 1.25rem;
    justify-content: center;
}

.social-links a {
    display: inline-flex;
    width: auto;
    height: auto;
    background: transparent;
    border: none;
    border-radius: 0;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    text-decoration: none;
    color: white;
    padding: 0;
}

.social-links a svg {
    width: 32px;
    height: 32px;
    fill: white;
    opacity: 1;
    transition: all 0.3s ease;
}

.social-links a:hover svg {
    opacity: 1;
    filter: drop-shadow(0 0 8px rgba(196, 181, 253, 0.6));
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    color: var(--secondary);
    font-size: 1rem;
}

.footer-bottom p {
    margin-bottom: 0;
}

/* Responsive */
@media (max-width: 768px) {
    nav {
        padding: 1.5rem var(--page-pad-x);
        flex-direction: column;
        gap: 1.5rem;
    }

    nav ul {
        gap: 2rem;
        justify-content: center;
    }

    section.hero {
        padding: 2rem var(--page-pad-x);
        padding-top: 8rem;
    }

    section.hero h1 {
        font-size: clamp(1.85rem, 8vw, 2.6rem);
    }

    nav.nav--project-page .nav-main-row {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
        width: 100%;
    }

    nav.nav--project-page .nav-sub-ctas {
        justify-content: center;
    }

    .cta-group {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
    }

    .cta-button, .cta-secondary {
        width: 100%;
        text-align: center;
    }

    .grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .portfolio {
        padding: 4rem var(--page-pad-x);
        width: 100%;
    }

    .portfolio h2 {
        font-size: clamp(1.35rem, 4vw, 1.85rem);
    }

    .featured-container {
        grid-template-columns: 1fr;
    }

    .featured-image {
        order: 1;
    }

    .featured-content {
        order: 2;
    }

    .about {
        grid-template-columns: 1fr;
        padding: 4rem var(--page-pad-x);
        width: 100%;
        gap: 2rem;
    }

    .about-skills,
    .about-image,
    .about-content {
        grid-column: auto;
        grid-row: auto;
        justify-self: stretch;
    }

    .about-skills { order: 1; }
    .about-image {
        order: 2;
        max-width: min(72vw, 300px);
        justify-self: center;
        margin-left: auto;
        margin-right: auto;
    }
    .about-content { order: 3; }

    .about-content h2 {
        font-size: clamp(1.35rem, 4vw, 1.85rem);
        text-align: center;
    }

    .about-content p {
        text-align: left;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
}

@media (max-width: 480px) {
    .about-image {
        max-width: 200px;
    }
}

@media (max-width: 1100px) and (min-width: 769px) {
    .about {
        grid-template-columns: minmax(0, 1fr) minmax(180px, 240px);
        gap: 1.5rem;
    }

    .about-content {
        grid-column: 1;
    }

    .about-image {
        grid-column: 2;
    }

    .about-skills {
        grid-column: 1 / -1;
        grid-row: 3;
    }
}

/* Large screens: constrain and center the About section for 2K displays */
@media (min-width: 1600px) {
    .about {
        max-width: 1400px;
        margin-left: auto;
        margin-right: auto;
        grid-template-columns: 1fr minmax(200px, 360px) 1fr;
        gap: clamp(1rem, 2.5vw, 3rem);
    }

    .about-content {
        justify-self: start;
        padding-left: 2rem;
        align-self: center;
    }

    .about-skills {
        justify-self: end;
        padding-right: 2rem;
        align-self: center;
        text-align: left;
    }

    .about-image {
        max-width: 320px;
        height: 380px;
    }

    .about h2 {
        margin-top: 0;
    }
}

/* Smooth scroll */
html {
    scroll-behavior: smooth;
}

/* Loading animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.8s ease-out;
}

/* Floating animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

.float {
    animation: float 3s ease-in-out infinite;
}
