/* ========================================
   VARIABILI CSS
   ======================================== */
:root {
    --main-color: #90ac94;
    --gold-color: #daa520;
    --bg-color: #faf9f6;

    /* Dimensioni fluide responsive */
    --base-font-size: clamp(14px, 3vw, 18px);
    --title-font-size: clamp(2rem, 5vw, 3.5rem);
    --date-font-size: clamp(3rem, 7vw, 4.5rem);
    --decorative-font-size: clamp(3rem, 6vw, 4.5rem);
    --spacing-base: clamp(1rem, 3vw, 2rem);
}

/* ========================================
   RESET E STILI BASE
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    color: var(--main-color);
}

body {
    font-family: Arial, sans-serif;
    font-size: var(--base-font-size);
    line-height: 1.6;
    color: #333;
    background-color: var(--main-color);
}

/* ========================================
   TIPOGRAFIA
   ======================================== */
.italianno-regular {
    font-family: "Italianno", cursive;
    font-weight: 400;
    font-style: normal;
    font-size: var(--decorative-font-size);
    line-height: 72%;
    color: var(--main-color);
}

.inria-serif-bold {
    font-family: "Inria Serif", serif;
    font-weight: 700;
    font-style: normal;
}

.small-white-text {
    font-size: var(--decorative-font-size);
    color: white;
}

/* ========================================
   CLASSI UTILITY
   ======================================== */
.flex-column {
    display: flex;
    flex-direction: column;
}

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

.justify-top {
    justify-content: top;
}

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

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

.line-height-80 {
    line-height: 80%;
}

.width-60 {
    width: min(60%, 100%);
}

.responsive-img {
    width: 100%;
    height: auto;
    display: block;
}

/* ========================================
   LAYOUT PRINCIPALE
   ======================================== */
.container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: min(100%, 800px);
    margin: clamp(1rem, 3vw, 2rem) auto 0;
    background-color: white;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);

    /* Rimuovi aspect-ratio fisso sui mobile */
    min-height: 100vh;
}

.body-container {
    width: 100%;
    flex: 8;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: clamp(1rem, 4vw, 2rem);
    padding-bottom: clamp(4rem, 10vw, 8rem);

    background-image: url(/images/background-body.png);

    background-size: 60%;
    background-position: bottom left;
    background-repeat: no-repeat;
    background-color: white;
}

.header-cover {
    width: 100%;
    flex: 2;
    padding: var(--spacing-base) clamp(1.5rem, 5vw, 3rem);
    background-image: url(/images/background.png);
    background-size: 50% auto;
    background-position: top right;
    background-repeat: no-repeat;
}

/* ========================================
   COMPONENTI
   ======================================== */
.title {
    padding: var(--spacing-base);
    text-align: left;
    color: var(--main-color);
}

#save-the-date {
    font-size: var(--title-font-size);
}

#date {
    font-size: var(--date-font-size);
}

#foto-cover {
    width: 100%;
    height: auto;
    display: block;
}

.main-btn {
    font-size: clamp(1.2rem, 3vw, 2rem);
    padding: clamp(0.8rem, 2vw, 1.2rem) clamp(0.8rem, 2vw, 1rem);
    width: min(90%, 600px);
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 2px solid var(--main-color);
    border-radius: 100px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.main-btn:hover {
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.separator-svg {
    width: 300px;
    height: 30px;
    background: var(--main-color);
    -webkit-mask: url("/images/separator.svg") center / contain no-repeat;
    mask: url("/images/separator.svg") center / contain no-repeat;
    margin-bottom: 1.5rem;
    margin-top: 1rem;
}

/* ========================================
   MEDIA QUERIES SEMPLIFICATE
   ======================================== */
/* Mobile - Fullscreen senza margini */
@media (max-width: 767px) {
    .container {
        width: 100%;
        max-width: 100%;
        margin: 0;
        min-height: 100vh;
        box-shadow: none;
        /* Rimuovi aspect-ratio su mobile */
        aspect-ratio: auto;
    }

    body {
        margin: 0;
        padding: 0;
    }

    .separator-svg {
        width: 200px;
        height: 25px;
        margin-bottom: 1.5rem;
        margin-top: 0rem;
    }
}

/* Tablet e desktop - Ripristina aspect-ratio */
@media (min-width: 768px) {
    .container {
        aspect-ratio: 1240 / 1748;
        max-width: 800px;
        margin: clamp(1rem, 3vw, 2rem) auto 0;
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    }
}

/* Desktop large */
@media (min-width: 1200px) {
    .container {
        max-width: 1000px;
    }
}

/* Gestione orientamento landscape mobile */
@media (max-height: 600px) and (orientation: landscape) {
    .container {
        min-height: 100vh;
        margin: 0;
    }

    .body-container {
        padding-bottom: 2rem;
        gap: 1rem;
    }
}
