/* =========================================================
   Federico Corradini — Clean Pro CSS (single design system)
   ========================================================= */

/* 1) Tokens */
:root {
    --bg: #050505;
    --text: rgba(255, 255, 255, 0.92);
    --muted: rgba(255, 255, 255, 0.72);
    --muted2: rgba(255, 255, 255, 0.56);

    --line: rgba(255, 255, 255, 0.10);
    --line2: rgba(255, 255, 255, 0.16);

    --surface: rgba(14, 14, 14, 0.58);
    --surface2: rgba(14, 14, 14, 0.38);
    --surface3: rgba(255, 255, 255, 0.04);

    --font: 'Montserrat', system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
    --fs-0: 0.82rem;
    --fs-1: 0.95rem;
    --fs-2: 1.15rem;
    --fs-3: clamp(2.15rem, 3.1vw, 3.05rem);
    --lh: 1.6;

    --s-1: 8px;
    --s-2: 12px;
    --s-3: 16px;
    --s-4: 20px;
    --s-5: 28px;
    --s-6: 36px;
    --s-7: 48px;
    --s-8: 72px;

    --r-1: 12px;
    --r-2: 18px;
    --r-pill: 999px;

    --shadow: 0 18px 60px rgba(0, 0, 0, 0.55);

    --ease: cubic-bezier(0.16, 1, 0.3, 1);
    --t-fast: 140ms var(--ease);
    --t-med: 220ms var(--ease);

    --container: 980px;
}

/* 2) Reset */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    background: var(--bg);
}

body {
    font-family: var(--font);
    color: var(--text);
    background: var(--bg);
    line-height: var(--lh);
    overflow-x: hidden;
    min-height: 100vh;
    text-rendering: geometricPrecision;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

::selection {
    background: rgba(255, 255, 255, 0.14);
}

/* 3) Background */
.hero-bg {
    position: fixed;
    inset: 0;
    background-image: url('../images/background.png');
    background-size: cover;
    background-position: center;
    z-index: -2;
    opacity: 0.6;
}

.hero-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(5, 5, 5, 0.18) 0%, rgba(5, 5, 5, 1) 90%);
}

/* 4) Layout helpers */
.container {
    max-width: var(--container);
    margin: 0 auto;
    width: 100%;
    padding: 0 var(--s-4);
}

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

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.flex-column {
    flex-direction: column;
}

/* 5) Typography */
h1 {
    font-size: var(--fs-3);
    letter-spacing: -0.03em;
    font-weight: 600;
    margin-bottom: var(--s-3);
    background: linear-gradient(to right, #fff, rgba(255, 255, 255, 0.72));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

h2 {
    font-size: 1.05rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    font-weight: 500;
    color: var(--muted2);
}

h3 {
    font-size: var(--fs-2);
    font-weight: 600;
    letter-spacing: -0.01em;
    margin: var(--s-2) 0 var(--s-1);
}

p {
    font-size: var(--fs-1);
    color: var(--muted);
    max-width: 60ch;
    margin: 0 auto var(--s-3);
}

/* 6) Hero */
.hero {
    position: relative;
    padding: var(--s-8) 0 var(--s-6);
    border-radius: calc(var(--r-2) + 8px);
    z-index: 1;
}

.hero::before {
    content: "";
    position: absolute;
    inset: -18px -18px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: calc(var(--r-2) + 8px);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: var(--shadow);
    z-index: -1;
}

.hero-copy {
    margin-bottom: var(--s-4);
}

.profile-img {
    width: 112px;
    height: 112px;
    border-radius: var(--r-pill);
    object-fit: cover;
    border: 1px solid var(--line2);
    box-shadow: 0 14px 50px rgba(0, 0, 0, 0.55);
    margin-bottom: var(--s-4);
    filter: grayscale(12%) contrast(1.08);
    transition: transform var(--t-med), filter var(--t-med), border-color var(--t-med);
}

.profile-img:hover {
    transform: scale(1.03);
    filter: grayscale(0%) contrast(1);
    border-color: rgba(255, 255, 255, 0.25);
}

/* Hero CTA + Social */
.hero-cta {
    display: flex;
    gap: 14px;
    margin-top: var(--s-4);
    flex-wrap: wrap;
}

.social-links {
    display: flex;
    gap: 14px;
    margin-top: var(--s-5);
}

/* 7) Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: var(--r-pill);
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.06);
    color: var(--text);
    font-size: 0.86rem;
    text-transform: uppercase;
    letter-spacing: 0.10em;
    transition: transform var(--t-fast), background var(--t-fast), border-color var(--t-fast);
    cursor: pointer;
    user-select: none;
}

.btn:hover {
    transform: translateY(-1px);
    background: rgba(255, 255, 255, 0.10);
    border-color: var(--line2);
}

.btn:active {
    transform: translateY(0px);
}

.btn:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.30);
    outline-offset: 3px;
}

.btn-primary {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.22);
}

.btn-ghost {
    background: transparent;
    border-color: rgba(255, 255, 255, 0.14);
}

.btn-small {
    padding: 10px 14px;
    font-size: 0.78rem;
}

/* 8) Icon buttons */
.btn-icon {
    width: 46px;
    height: 46px;
    border-radius: var(--r-pill);
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.06);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform var(--t-fast), background var(--t-fast), border-color var(--t-fast);
}

.btn-icon:hover {
    transform: translateY(-1px);
    background: rgba(255, 255, 255, 0.10);
    border-color: var(--line2);
}

.btn-icon:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.30);
    outline-offset: 3px;
}

.btn-icon svg {
    width: 22px;
    height: 22px;
    fill: rgba(255, 255, 255, 0.88);
}

/* 9) Divider */
.divider {
    height: 1px;
    width: 100%;
    margin: var(--s-6) 0;
    background: linear-gradient(90deg, transparent, var(--line), transparent);
}

/* 10) Featured Works header row */
.section-head {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    /* PATCH: left aligned */
    gap: var(--s-3);
    margin-top: var(--s-6);
    margin-bottom: var(--s-4);
}

.section-title {
    margin: 0;
}

/* 11) Works cards + embeds */
#works {
    padding-top: var(--s-2);
}

.work-card {
    border: 1px solid var(--line);
    background: var(--surface2);
    border-radius: var(--r-2);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
    padding: var(--s-5) var(--s-4);
    margin: var(--s-4) 0;
    transition: transform var(--t-med), border-color var(--t-med), background var(--t-med);
}

.work-card:hover {
    transform: translateY(-2px);
    border-color: var(--line2);
    background: rgba(255, 255, 255, 0.035);
}

.artist-name {
    display: block;
    font-size: var(--fs-0);
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: var(--muted2);
    margin-bottom: var(--s-1);
}

.work-card p {
    color: var(--muted2);
    margin-bottom: var(--s-4);
}

/* Embeds — playlist sized (PATCH) */
.embed-container {
    max-width: 860px;
    /* più largo, meno “card dentro card” */
    margin: var(--s-4) auto;
}

.embed-container iframe {
    width: 100%;
    display: block;
    height: clamp(420px, 58vh, 620px);
    /* riempie “la zona arancione” */
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, .06);
    box-shadow: 0 10px 30px rgba(0, 0, 0, .35);
    background: #0b0b0b;
    /* evita flash / buchi neri fuori tema */
}


/* 12) Catalog */
.catalog-section-title {
    margin-top: var(--s-7);
    margin-bottom: var(--s-5);
    text-align: center;
}

.catalog-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--s-3);
    width: 100%;
}

.catalog-card {
    border: 1px solid var(--line);
    background: var(--surface3);
    border-radius: var(--r-2);
    padding: var(--s-4);
    display: flex;
    flex-direction: column;
    transition: transform var(--t-med), border-color var(--t-med), background var(--t-med);
    height: 100%;
}

.catalog-card:hover {
    transform: translateY(-2px);
    border-color: var(--line2);
    background: rgba(255, 255, 255, 0.06);
}

.catalog-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--s-2);
    margin-bottom: var(--s-3);
}

.catalog-info h4 {
    font-size: 1.06rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    margin-bottom: 4px;
    color: var(--text);
}

.catalog-info .artist {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--muted2);
}

.type-badge {
    font-size: 0.62rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    padding: 6px 10px;
    border: 1px solid var(--line);
    border-radius: var(--r-pill);
    color: var(--muted2);
    background: rgba(255, 255, 255, 0.04);
    white-space: nowrap;
}

.catalog-desc {
    font-size: 0.92rem;
    color: var(--muted2);
    line-height: 1.55;
    margin-bottom: var(--s-4);
    flex-grow: 1;
}

.catalog-actions {
    margin-top: auto;
}

/* 13) Footer */
.site-footer {
    padding: var(--s-8) 0 var(--s-6);
    font-size: 0.8rem;
    text-align: center;
    opacity: 0.6;
}

/* 14) Animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(16px);
    animation: fadeInUp 900ms var(--ease) forwards;
}

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

.delay-100 {
    animation-delay: 100ms;
}

.delay-150 {
    animation-delay: 150ms;
}

.delay-200 {
    animation-delay: 200ms;
}

.delay-300 {
    animation-delay: 300ms;
}

/* 15) Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        scroll-behavior: auto !important;
    }

    .fade-in-up {
        animation: none;
        opacity: 1;
        transform: none;
    }

    .btn,
    .btn-icon,
    .work-card,
    .catalog-card,
    .profile-img {
        transition: none;
    }
}

/* 16) Responsive */
@media (max-width: 820px) {
    .catalog-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .section-head {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
}

@media (max-width: 520px) {
    .container {
        padding: 0 var(--s-3);
    }

    .hero {
        padding: 56px 0 28px;
    }

    .hero::before {
        inset: -12px -12px;
    }

    .work-card {
        padding: var(--s-4) var(--s-3);
    }
}