/*
 * Old Spirit Gospel Singers
 * Fonts: DM Serif Display (headline) + Outfit (body)
 * Palette: White + Grey + Gold accent
 */

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

:root {
    --white: #FFFFFF;
    --grey-50: #FAFAFA;
    --grey-100: #F4F4F4;
    --grey-200: #E5E5E5;
    --grey-400: #999999;
    --grey-600: #666666;
    --grey-800: #333333;
    --black: #1A1A1A;
    --gold: #B8A456;
    --gold-light: #D4C882;
    --font-display: 'DM Serif Display', 'Georgia', serif;
    --font-body: 'Outfit', 'Helvetica Neue', sans-serif;
    --max-width: 1320px;
    --gutter: 2rem;
}

html { font-size: 16px; scroll-behavior: smooth; }

body {
    font-family: var(--font-body);
    font-weight: 300;
    color: var(--black);
    background: var(--white);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--gold); text-decoration: none; transition: color .2s; }
a:hover { color: var(--black); }

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

/* ========== TYPOGRAPHY ========== */
h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 400;
    line-height: 1.2;
    color: var(--black);
}

h1 { font-size: clamp(2.4rem, 5vw, 4rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.8rem); letter-spacing: -0.01em; }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.6rem); }

p { max-width: 68ch; }
p + p { margin-top: 1em; }

.label {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--gold);
}

/* ========== HEADER / NAV ========== */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255,255,255,0.97);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--grey-200);
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100px;
}

.site-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.site-logo img {
    height: 80px;
    width: auto;
}

.site-logo span {
    font-family: var(--font-display);
    font-size: 1.1rem;
    color: var(--black);
    display: none;
}

nav { display: flex; align-items: center; gap: 0; flex-wrap: nowrap; }

nav a {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 0.88rem;
    color: var(--grey-600);
    padding: 0.5rem 0.85rem;
    transition: color .2s;
    white-space: nowrap;
}

nav a:hover,
nav a.active { color: var(--black); }

.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--black);
    margin: 5px 0;
    transition: .3s;
}

/* ========== HERO (Home) ========== */
.hero {
    position: relative;
    overflow: hidden;
    background: var(--grey-100);
}

.hero-image {
    width: 100%;
    height: clamp(400px, 50vw, 640px);
    object-fit: cover;
    object-position: center 40%;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    padding: 3rem var(--gutter);
    background: linear-gradient(to bottom, rgba(26,26,26,0.75) 0%, transparent 100%);
    color: var(--white);
}

.hero-overlay h1 {
    color: var(--white);
    margin-bottom: 0.3rem;
}

.hero-overlay p {
    font-size: 1.1rem;
    font-weight: 300;
    color: rgba(255,255,255,0.85);
    max-width: 50ch;
}

/* ========== SECTIONS ========== */
.section {
    padding: 5rem 0;
}

.section--alt {
    background: var(--grey-50);
}

.section-header {
    margin-bottom: 3rem;
}

.section-header h2 {
    margin-top: 0.4rem;
}

/* ========== BUTTONS ========== */
.btn {
    display: inline-block;
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 0.85rem;
    padding: 0.75rem 2rem;
    border: 1px solid var(--black);
    color: var(--black);
    background: transparent;
    cursor: pointer;
    transition: all .25s;
    letter-spacing: 0.03em;
}

.btn:hover {
    background: var(--black);
    color: var(--white);
}

.btn--gold {
    border-color: var(--gold);
    color: var(--gold);
}

.btn--gold:hover {
    background: var(--gold);
    color: var(--white);
}

/* ========== INTRO BLOCK (Home) ========== */
.intro {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.intro-text p {
    margin-bottom: 1.5rem;
    color: var(--grey-600);
    font-size: 1.05rem;
}

.intro-image img {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
}

/* ========== NEWS CARDS ========== */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}

.news-card {
    background: var(--white);
    border: 1px solid var(--grey-200);
    transition: border-color .2s;
}

.news-card:hover {
    border-color: var(--grey-400);
}

.news-card-image {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    background: var(--grey-100);
}

.news-card-body {
    padding: 1.5rem;
}

.news-card-date {
    font-size: 0.8rem;
    color: var(--grey-400);
    margin-bottom: 0.5rem;
}

.news-card-body h3 {
    margin-bottom: 0.6rem;
    line-height: 1.3;
}

.news-card-body h3 a {
    color: var(--black);
}

.news-card-body h3 a:hover {
    color: var(--gold);
}

.news-card-body p {
    font-size: 0.9rem;
    color: var(--grey-600);
    line-height: 1.6;
}

/* ========== NEWS DETAIL ========== */
.article-header {
    padding: 4rem 0 2rem;
    text-align: center;
}

.article-header h1 {
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

.article-header .date {
    color: var(--grey-400);
    font-size: 0.9rem;
}

.article-image {
    width: 100%;
    max-height: 480px;
    object-fit: cover;
    margin-bottom: 3rem;
}

.article-body {
    max-width: 720px;
    margin: 0 auto;
    padding: 0 var(--gutter) 4rem;
    font-size: 1.05rem;
    line-height: 1.8;
}

.article-body p + p { margin-top: 1.2em; }

.article-body h2 {
    margin: 2rem 0 1rem;
}

/* ========== EVENTS ========== */
.events-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.event-card {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 2rem;
    padding: 1.5rem;
    border: 1px solid var(--grey-200);
    align-items: center;
    transition: border-color .2s;
}

.event-card:hover {
    border-color: var(--gold);
}

.event-date-box {
    text-align: center;
    padding: 1rem;
    background: var(--grey-50);
}

.event-date-box .day {
    font-family: var(--font-display);
    font-size: 2.4rem;
    line-height: 1;
    color: var(--black);
}

.event-date-box .month {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--gold);
    margin-top: 0.2rem;
}

.event-card-image {
    width: 120px;
    height: 120px;
    object-fit: cover;
    background: var(--grey-100);
}

.event-info h3 {
    margin-bottom: 0.3rem;
}

.event-info p {
    font-size: 0.9rem;
    color: var(--grey-600);
}

.event-location {
    font-size: 0.85rem;
    color: var(--grey-400);
}

/* ========== ABOUT (single column) ========== */
.about-single-col {
    /* container normale, stessa larghezza delle altre pagine */
}

.about-full-image {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    margin-bottom: 2.5rem;
}

.about-block {
    max-width: 840px;
    margin: 0 auto 3.5rem;
}

.about-block h2 {
    margin-bottom: 1.5rem;
}

.about-block p {
    color: var(--grey-600);
    font-size: 1.05rem;
    margin-bottom: 1em;
    line-height: 1.8;
}

.about-block .label {
    margin-bottom: 0.4rem;
}

/* Members grid */
.members-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

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

.member-photo {
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: cover;
    background: var(--grey-100);
    margin-bottom: 0.75rem;
}

.member-card h4 {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 0.9rem;
}

.member-card .role {
    font-size: 0.8rem;
    color: var(--grey-400);
}

/* Voice section */
.voice-section {
    margin-bottom: 3rem;
}

.voice-section h3 {
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--grey-200);
}

.member-photo .initial {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    font-family: var(--font-display);
    font-size: 2rem;
    color: var(--grey-400);
    background: var(--grey-100);
}

/* ========== CONTACTS ========== */
.contacts-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-form label {
    display: block;
    font-size: 0.85rem;
    font-weight: 400;
    margin-bottom: 0.3rem;
    color: var(--grey-600);
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    font-family: var(--font-body);
    font-size: 0.95rem;
    padding: 0.75rem 1rem;
    border: 1px solid var(--grey-200);
    background: var(--white);
    margin-bottom: 1.2rem;
    transition: border-color .2s;
    outline: none;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--gold);
}

.contact-form textarea { resize: vertical; min-height: 140px; }

.contact-info h3 { margin-bottom: 1.5rem; }

.contact-detail {
    margin-bottom: 1.5rem;
}

.contact-detail .label { margin-bottom: 0.3rem; }

.contact-detail p {
    color: var(--grey-600);
    font-size: 0.95rem;
}

.contact-detail a {
    color: var(--grey-600);
}

.contact-detail a:hover {
    color: var(--gold);
}

.socials {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.socials a {
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--grey-600);
    padding: 0.5rem 1rem;
    border: 1px solid var(--grey-200);
    transition: all .2s;
}

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

/* ========== FOOTER ========== */
.site-footer {
    background: var(--black);
    color: var(--grey-400);
    padding: 3rem 0;
    margin-top: 4rem;
    font-size: 0.85rem;
}

.site-footer.no-gap {
    margin-top: 0;
}

/* CTA block flush with footer */
.section--cta {
    padding: 4rem 0;
    margin-bottom: 0;
}

.section--cta + .site-footer {
    margin-top: 0;
}

.section--cta h2,
.section--cta .label,
.section--cta p {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.section--cta .btn {
    display: inline-block;
}

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

.footer-inner a {
    color: var(--grey-400);
}

.footer-inner a:hover {
    color: var(--gold-light);
}

/* ========== PAGINATION ========== */
.pagination {
    display: flex;
    gap: 0.5rem;
    margin-top: 3rem;
    justify-content: center;
}

.pagination a,
.pagination span {
    display: inline-block;
    padding: 0.5rem 1rem;
    border: 1px solid var(--grey-200);
    font-size: 0.85rem;
    color: var(--grey-600);
}

.pagination .current {
    background: var(--black);
    color: var(--white);
    border-color: var(--black);
}

/* ========== FLASH MESSAGES ========== */
.flash {
    padding: 1rem 1.5rem;
    margin-bottom: 2rem;
    font-size: 0.9rem;
}

.flash--success { background: #e8f5e9; color: #2e7d32; }
.flash--error { background: #fbe9e7; color: #c62828; }

/* ========== PLACEHOLDER ========== */
.placeholder-img {
    background: var(--grey-100);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--grey-400);
    font-size: 0.8rem;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
    :root { --gutter: 1.25rem; }

    .site-header .container { height: 76px; }
    .site-logo img { height: 56px; }

    nav {
        display: none;
        position: absolute;
        top: 76px;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        border-bottom: 1px solid var(--grey-200);
        padding: 1rem 0;
    }

    nav.open { display: flex; }

    nav a {
        padding: 0.75rem var(--gutter);
        font-size: 1rem;
    }

    .nav-toggle { display: block; }

    .hero-image { height: 360px; }

    .intro,
    .about-hero,
    .contacts-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .about-images {
        grid-template-columns: 1fr 1fr;
        order: -1;
    }

    .about-images img:first-child {
        grid-row: auto;
        aspect-ratio: 3/4;
    }

    .event-card {
        grid-template-columns: 90px 1fr;
        gap: 1rem;
        padding: 1rem;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }

    .members-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 1rem;
    }

    .section { padding: 3rem 0; }
}

@media (prefers-reduced-motion: reduce) {
    * { transition: none !important; }
    html { scroll-behavior: auto; }
}

/* ========== SOCIAL ICONS (HEADER) ========== */
.header-social {
    position: fixed;
    top: 1rem;
    right: 1.25rem;
    z-index: 101;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.header-social a {
    color: var(--grey-400);
    display: flex;
    align-items: center;
    transition: color .2s;
}

.header-social a:hover { color: var(--gold); }

/* ========== SOCIAL ICONS (NAV - mobile only) ========== */
.nav-social {
    display: none;
}

/* ========== VIDEO GRID ========== */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 2rem;
}

.video-grid--3col {
    grid-template-columns: repeat(3, 1fr);
}

.video-embed {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    background: var(--grey-100);
}

.video-embed iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
}

.video-card h3 {
    margin-top: 0.75rem;
    font-size: 1rem;
}

/* ========== NEWS 2 COLUMNS ========== */
.news-grid--2col {
    grid-template-columns: repeat(2, 1fr);
}

/* ========== MASONRY GALLERY ========== */
.masonry {
    columns: 3;
    column-gap: 0.75rem;
}

.masonry-item {
    break-inside: avoid;
    margin-bottom: 0.75rem;
    overflow: hidden;
    cursor: pointer;
    position: relative;
}

.masonry-item img {
    width: 100%;
    display: block;
    transition: transform .3s;
}

.masonry-item:hover img {
    transform: scale(1.03);
}

.masonry-caption {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 0.5rem 0.75rem;
    background: rgba(26,26,26,0.7);
    color: var(--white);
    font-size: 0.8rem;
    opacity: 0;
    transition: opacity .3s;
}

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

.masonry-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--grey-100);
    color: var(--grey-400);
    font-size: 0.85rem;
    min-height: 220px;
}

.masonry-placeholder.tall { min-height: 340px; }
.masonry-placeholder.wide { min-height: 180px; }

/* ========== LIGHTBOX ========== */
.lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(0,0,0,0.9);
    cursor: pointer;
    align-items: center;
    justify-content: center;
}

.lightbox.open {
    display: flex;
}

.lightbox img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
}

/* ========== WEDDING IMAGES ========== */
.wedding-images {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.wedding-images img,
.wedding-images .placeholder-img {
    width: 100%;
    aspect-ratio: 16/10;
    object-fit: cover;
}

/* ========== RESPONSIVE ADDITIONS ========== */
@media (max-width: 768px) {
    .video-grid, .video-grid--3col { grid-template-columns: 1fr; }
    .news-grid--2col { grid-template-columns: 1fr; }
    .masonry { columns: 2; }
    .wedding-images { grid-template-columns: 1fr; }

    .nav-social {
        justify-content: center;
        padding: 0.75rem 0;
        border-top: 1px solid var(--grey-200);
    }
}

@media (max-width: 480px) {
    .masonry { columns: 1; }
}

/* ========== FOOTER SOCIAL ========== */
.footer-social {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.footer-social a {
    color: var(--grey-400);
    display: flex;
    align-items: center;
}

.footer-social a:hover { color: var(--gold-light); }

.footer-social a:last-child {
    font-size: 0.85rem;
}

#fabyoo-signature div {
    text-align: left !important;
    padding: 5px 0 0 0 !important;
}

/* ========== INSTAGRAM EMBED ========== */
.instagram-embed {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
    justify-items: center;
}

.instagram-embed iframe {
    max-width: 100% !important;
}

.instagram-placeholder {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    background: var(--grey-100);
    color: var(--grey-400);
    font-size: 0.95rem;
}

.instagram-placeholder a { color: var(--gold); }

/* ========== HEADER SOCIAL RESPONSIVE ========== */
@media (max-width: 768px) {
    .header-social {
        position: static;
        flex-direction: row;
        gap: 1rem;
        padding: 0;
        margin-right: 3rem;
    }
}

/* ========== YOUTUBE CHANNEL GRID ========== */
.youtube-channel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.video-item {
    display: flex;
    flex-direction: column;
}

.video-item iframe {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 6px;
    background: var(--grey-100);
}

.video-title {
    margin-top: 0.5rem;
    font-size: 0.9rem;
    font-weight: 400;
    color: var(--grey-800);
    line-height: 1.4;
}

@media (max-width: 768px) {
    .youtube-channel-grid {
        grid-template-columns: 1fr;
    }
}

/* ========== COOKIE BANNER ========== */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: var(--black);
    color: var(--grey-400);
    padding: 1.25rem var(--gutter);
    box-shadow: 0 -2px 12px rgba(0,0,0,0.15);
}

.cookie-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.cookie-inner p {
    font-size: 0.85rem;
    line-height: 1.5;
    max-width: none;
}

.cookie-actions {
    display: flex;
    gap: 0.75rem;
    flex-shrink: 0;
}

.cookie-btn {
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 400;
    padding: 0.5rem 1.25rem;
    border: 1px solid var(--grey-600);
    cursor: pointer;
    transition: all .2s;
    white-space: nowrap;
}

.cookie-btn--accept {
    background: var(--gold);
    color: var(--white);
    border-color: var(--gold);
}

.cookie-btn--accept:hover {
    background: var(--gold-light);
    border-color: var(--gold-light);
}

.cookie-btn--decline {
    background: transparent;
    color: var(--grey-400);
}

.cookie-btn--decline:hover {
    color: var(--white);
    border-color: var(--white);
}

@media (max-width: 768px) {
    .cookie-inner {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    .cookie-actions {
        width: 100%;
        justify-content: center;
    }
}
