/**
 * Giro del Mondo Viaggi — custom.css
 * Override Elementor + dettagli fine-tuning
 */

/* =========================================================
   ELEMENTOR — Reset e compatibilità
   CRITICO: l'header fisso sovrasta la hero.
   Non deve esserci nessun offset/padding in cima alla pagina.
   ========================================================= */

/* Body e page wrapper: zero padding-top sempre */
body,
body.elementor-page,
body.elementor-page #page,
body.elementor-page .site-main,
body.elementor-page .elementor-section-wrap {
    padding-top: 0 !important;
    margin-top: 0 !important;
}

/* La prima section Elementor deve partire da y=0 */
.elementor-section-wrap > .elementor-section:first-child,
.elementor > .elementor-inner > .elementor-section:first-child,
.elementor-page .elementor-section-wrap > .elementor-section:first-child {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Full-width sections */
.elementor-section.elementor-section-stretched {
    left: 0 !important;
    width: 100% !important;
}

/* =========================================================
   ELEMENTOR — Colori globali forzati
   ========================================================= */
.e-con,
.elementor-widget-container {
    --e-global-color-primary:   #c9922a;
    --e-global-color-secondary: #1a2744;
    --e-global-color-text:      #4a5568;
    --e-global-color-accent:    #c9922a;
}

/* =========================================================
   HEADER — Gestito inline in header.php + footer.php JS.
   I commenti seguenti sono disabilitati per evitare conflitti.
   ========================================================= */

/* =========================================================
   ELEMENTOR HEADING — Typography override
   ========================================================= */
.elementor-widget-heading .elementor-heading-title,
.elementor-widget-heading h1,
.elementor-widget-heading h2,
.elementor-widget-heading h3 {
    font-family: 'Playfair Display', Georgia, serif !important;
}

.elementor-widget-text-editor p,
.elementor-widget-text-editor {
    font-family: 'Inter', sans-serif !important;
}

/* =========================================================
   ELEMENTOR BUTTON
   ========================================================= */
.elementor-button.gdm-btn-gold {
    background-color: #c9922a !important;
    color: #ffffff !important;
    border-color: #c9922a !important;
    border-radius: 6px !important;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 4px 16px rgba(201,146,42,0.35) !important;
}

.elementor-button.gdm-btn-gold:hover {
    background-color: #a97820 !important;
    border-color: #a97820 !important;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(201,146,42,0.45) !important;
}

/* =========================================================
   ELEMENTOR IMAGE — box-shadow e bordi
   ========================================================= */
.gdm-about-image .elementor-widget-image img {
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(26,39,68,0.16);
}

/* =========================================================
   ELEMENTOR ICON BOX / STAT
   ========================================================= */
.gdm-stat-gold .elementor-icon-box-title span,
.gdm-stat-gold .elementor-counter-number-wrapper {
    color: #c9922a !important;
    font-family: 'Playfair Display', serif !important;
    font-weight: 700 !important;
}

/* =========================================================
   ELEMENTOR TESTIMONIAL
   ========================================================= */
.gdm-testimonial-card {
    background: #f5f0e8 !important;
    border-radius: 12px !important;
}

/* =========================================================
   ELEMENTOR ACCORDION (FAQ)
   ========================================================= */
.elementor-accordion .elementor-accordion-title {
    font-family: 'Inter', sans-serif !important;
    font-weight: 500 !important;
    color: #1a2744 !important;
}

.elementor-accordion .elementor-active .elementor-accordion-title {
    color: #c9922a !important;
}

.elementor-accordion .elementor-tab-content {
    font-size: 0.95rem !important;
    color: #4a5568 !important;
    line-height: 1.8 !important;
}

/* =========================================================
   SEZIONE HERO — garantisce 100vh
   ========================================================= */
.gdm-hero-section.elementor-section {
    min-height: 100vh !important;
    display: flex !important;
    align-items: center !important;
}

.gdm-hero-section .elementor-column-wrap {
    justify-content: center;
}

/* =========================================================
   STATS BAR — Navy background
   ========================================================= */
.gdm-stats-bar.elementor-section {
    background-color: #1a2744 !important;
}

/* =========================================================
   BLOCKQUOTE — Gold border
   ========================================================= */
.elementor-widget-text-editor blockquote {
    border-left: 4px solid #c9922a;
    padding: 16px 24px;
    font-style: italic;
    color: #4a5568;
    margin: 24px 0;
}

/* =========================================================
   PRESS LOGOS
   ========================================================= */
.gdm-press-logo {
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    font-weight: 700;
    color: #a0aec0;
    font-style: italic;
    transition: color 0.3s ease;
}

.gdm-press-logo:hover {
    color: #1a2744;
}

/* =========================================================
   BOOK IMAGE — tilt shadow
   ========================================================= */
.gdm-book-image img {
    box-shadow: 0 20px 60px rgba(0,0,0,0.25) !important;
    border-radius: 4px !important;
    transform: rotate(2deg);
    transition: transform 0.3s ease !important;
}

.gdm-book-image img:hover {
    transform: rotate(0) scale(1.02) !important;
}

/* =========================================================
   CONTACT CARD
   ========================================================= */
.gdm-contact-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 64px 72px;
    box-shadow: 0 24px 80px rgba(0,0,0,0.25);
}

.gdm-contact-card .elementor-field-group label {
    font-weight: 600;
    color: #1a2744;
    font-size: 0.9rem;
    margin-bottom: 6px;
}

.gdm-contact-card .elementor-field {
    background: #f5f0e8 !important;
    border: 1px solid transparent !important;
    border-radius: 6px !important;
    padding: 14px 16px !important;
    font-family: 'Inter', sans-serif !important;
    font-size: 1rem !important;
    transition: border-color 0.3s ease, box-shadow 0.3s ease !important;
}

.gdm-contact-card .elementor-field:focus {
    border-color: #c9922a !important;
    box-shadow: 0 0 0 3px rgba(201,146,42,0.15) !important;
    background: #ffffff !important;
}

.gdm-contact-card .elementor-button {
    width: 100% !important;
    padding: 18px !important;
    background: #c9922a !important;
    border-color: #c9922a !important;
    border-radius: 6px !important;
    font-size: 1.05rem !important;
    font-weight: 600 !important;
}

/* =========================================================
   BLOG CARD
   ========================================================= */
.gdm-blog-card {
    border-radius: 0 !important;
    box-shadow: none !important;
}

.gdm-blog-date {
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.12em !important;
    text-transform: uppercase !important;
    color: #c9922a !important;
}

.gdm-blog-card .elementor-post__title a {
    color: #1a2744 !important;
    font-family: 'Playfair Display', serif !important;
}

.gdm-blog-card .elementor-post__title a:hover {
    color: #c9922a !important;
}

/* =========================================================
   FOOTER DARK
   ========================================================= */
.gdm-footer-section {
    background: #111d36 !important;
}

.gdm-footer-section *,
.gdm-footer-section p,
.gdm-footer-section li a {
    color: rgba(255,255,255,0.6) !important;
}

.gdm-footer-section h4,
.gdm-footer-section h5 {
    color: #ffffff !important;
    font-size: 0.85rem !important;
    letter-spacing: 0.1em !important;
    text-transform: uppercase !important;
    font-family: 'Inter', sans-serif !important;
}

.gdm-footer-section li a:hover {
    color: #d4a843 !important;
}

/* =========================================================
   SEZIONE CREAM BACKGROUND
   ========================================================= */
.gdm-bg-cream {
    background-color: #f5f0e8 !important;
}

.gdm-bg-navy {
    background-color: #1a2744 !important;
}

/* =========================================================
   CARD HOVER EFFECTS
   ========================================================= */
.gdm-proposta-card,
.elementor-post.gdm-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
    border-radius: 12px !important;
    overflow: hidden !important;
}

.gdm-proposta-card:hover,
.elementor-post.gdm-card:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 12px 40px rgba(26,39,68,0.16) !important;
}

/* =========================================================
   MOBILE RESPONSIVE FIXES
   ========================================================= */
@media (max-width: 768px) {
    .gdm-contact-card {
        padding: 40px 24px !important;
    }

    .gdm-hero-section .elementor-heading-title {
        font-size: 2.2rem !important;
    }

    .elementor-section-stretched {
        margin-left: 0 !important;
    }
}

/* =========================================================
   PRINT STYLES
   ========================================================= */
@media print {
    .site-header,
    .site-footer,
    .hero-section,
    .contact-section {
        display: none !important;
    }
}

/* =========================================================
   CONTACT FORM 7 — Stile Giro del Mondo
   Compatibile con il wrapper .gdm-form-card
   ========================================================= */

/* Card contenitore del form */
.gdm-form-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 64px 72px;
    max-width: 820px;
    margin: 0 auto;
    box-shadow: 0 24px 80px rgba(0,0,0,0.12);
}

/* Titolo e sottotitolo */
.gdm-form-card__title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(2rem, 3.5vw, 2.8rem);
    font-weight: 700;
    color: #1a2744;
    text-align: center;
    line-height: 1.2;
    margin-bottom: 16px;
}

.gdm-form-card__sub {
    text-align: center;
    font-size: 1rem;
    color: #4a5568;
    margin-bottom: 48px;
    line-height: 1.7;
}

/* ── Griglia a 2 colonne per nome + email ────────────── */
.gdm-cf7-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

/* Gruppo campo: label + input */
.gdm-cf7-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 24px;
}

.gdm-cf7-group.full-width {
    grid-column: 1 / -1;
}

/* Label */
.gdm-cf7-group label,
.gdm-form-card .wpcf7-form label {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1a2744;
    display: block;
    margin-bottom: 6px;
}

/* Input, select, textarea */
.gdm-form-card .wpcf7-form input[type="text"],
.gdm-form-card .wpcf7-form input[type="email"],
.gdm-form-card .wpcf7-form input[type="tel"],
.gdm-form-card .wpcf7-form input[type="number"],
.gdm-form-card .wpcf7-form input[type="url"],
.gdm-form-card .wpcf7-form select,
.gdm-form-card .wpcf7-form textarea {
    width: 100%;
    padding: 14px 16px;
    background: #f5f0e8;
    border: 1.5px solid transparent;
    border-radius: 8px;
    font-family: 'Inter', -apple-system, sans-serif;
    font-size: 1rem;
    color: #1a2744;
    transition: border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
    outline: none;
    box-sizing: border-box;
    -webkit-appearance: none;
    appearance: none;
}

.gdm-form-card .wpcf7-form input[type="text"]:focus,
.gdm-form-card .wpcf7-form input[type="email"]:focus,
.gdm-form-card .wpcf7-form input[type="tel"]:focus,
.gdm-form-card .wpcf7-form input[type="number"]:focus,
.gdm-form-card .wpcf7-form select:focus,
.gdm-form-card .wpcf7-form textarea:focus {
    border-color: #c9922a;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(201,146,42,0.18);
}

/* Textarea */
.gdm-form-card .wpcf7-form textarea {
    min-height: 148px;
    resize: vertical;
    line-height: 1.65;
}

/* Placeholder */
.gdm-form-card .wpcf7-form input::placeholder,
.gdm-form-card .wpcf7-form textarea::placeholder {
    color: #a0aec0;
}

/* ── Pulsante Invia ─────────────────────────────────── */
.gdm-form-card .wpcf7-form input[type="submit"],
.gdm-form-card .wpcf7-submit {
    width: 100%;
    padding: 18px 32px;
    background: #c9922a;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-family: 'Inter', -apple-system, sans-serif;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 16px rgba(201,146,42,0.35);
    margin-top: 8px;
    letter-spacing: 0.01em;
}

.gdm-form-card .wpcf7-form input[type="submit"]:hover,
.gdm-form-card .wpcf7-submit:hover {
    background: #a97820;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(201,146,42,0.45);
}

.gdm-form-card .wpcf7-form input[type="submit"]:active {
    transform: translateY(0);
}

/* ── Nota privacy sotto il bottone ─────────────────── */
.gdm-form-privacy {
    text-align: center;
    font-size: 0.82rem;
    color: #718096;
    margin-top: 16px;
}

/* ── Messaggi risposta CF7 ──────────────────────────── */
.gdm-form-card .wpcf7-response-output {
    margin-top: 20px;
    padding: 14px 20px;
    border-radius: 8px;
    font-size: 0.95rem;
    text-align: center;
    border: none !important;
}

.gdm-form-card .wpcf7-mail-sent-ok {
    background: #d4edda;
    color: #155724;
    border-left: 4px solid #28a745 !important;
}

.gdm-form-card .wpcf7-validation-errors,
.gdm-form-card .wpcf7-mail-sent-ng,
.gdm-form-card .wpcf7-spam-blocked {
    background: #f8d7da;
    color: #721c24;
    border-left: 4px solid #dc3545 !important;
}

/* Evidenzia campi non validi */
.gdm-form-card .wpcf7-not-valid-tip {
    font-size: 0.8rem;
    color: #dc3545;
    margin-top: 4px;
    display: block;
}

.gdm-form-card .wpcf7-form input.wpcf7-not-valid,
.gdm-form-card .wpcf7-form textarea.wpcf7-not-valid {
    border-color: #dc3545;
    background: #fff5f5;
}

/* ── Wrapper span di CF7 (rimuove display:block inline) */
.gdm-form-card .wpcf7-form span.wpcf7-form-control-wrap {
    display: block;
}

/* ── Responsive ─────────────────────────────────────── */
@media (max-width: 768px) {
    .gdm-form-card {
        padding: 40px 24px 48px;
    }
    .gdm-cf7-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
}
