/* ================================================
           THOPOS - STILI UNIFICATI CONTATTI
        ================================================ */

/* Reset e Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

/* ================================================
           HEADER E NAVIGAZIONE
        ================================================ */

.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(26, 51, 38, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    transition: all 0.3s ease;
    border-bottom: 1px solid white;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

.logo {
    height: 40px;
    filter: drop-shadow(0 0 10px rgba(0, 255, 136, 0.3));
    transition: all 0.3s ease;
}

.logo:hover {
    filter: drop-shadow(0 0 15px rgba(0, 255, 136, 0.5));
    transform: scale(1.05);
}

.nav-container a {
    text-decoration: none;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
    position: relative;
}

.nav-menu a:hover {
    color: #00ff88;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #00ff88, #00cc66);
    transition: width 0.3s ease;
}

.nav-menu a:hover::after {
    width: 100%;
}

/* Menu Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 5px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: white;
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

/* ================================================
           HERO SECTION GENERALE
        ================================================ */

.hero {
    min-height: 100vh;
    padding-top: 80px;
    padding-bottom: 2rem;
    background: linear-gradient(135deg, #1a3326 0%, #2d5942 50%, #0f4c2e 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path d="M0,0 L50,50 L100,0 Z" fill="none" stroke="%23ffffff10" stroke-width="0.5"/><path d="M0,50 L50,100 L100,50 Z" fill="none" stroke="%23ffffff10" stroke-width="0.5"/></svg>') repeat;
    opacity: 0.1;
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    50% {
        transform: translateY(-20px) rotate(2deg);
    }
}

.hero-content {
    text-align: center;
    color: white;
    z-index: 2;
    max-width: 900px;
    padding: 0 2rem;
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 0.5rem;
    margin-top: -2rem;
    background: linear-gradient(45deg, #00ff88, #ffffff, #00cc66);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: glow 3s ease-in-out infinite alternate;
    font-weight: bold;
    font-style: italic;
}

@keyframes glow {
    from {
        filter: drop-shadow(0 0 20px rgba(0, 255, 136, 0.5));
    }
    to {
        filter: drop-shadow(0 0 30px rgba(0, 255, 136, 0.8));
    }
}

.hero p {
    font-size: 1.4rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 3rem;
    font-style: italic;
    opacity: 0.8;
}

/* ================================================
           HERO SECTION CONTATTI SPECIFICA
        ================================================ */

.contacts-hero {
    background: linear-gradient(135deg, #1a3326 0%, #2d5942 50%, #0f4c2e 100%);
    color: white;
    padding: 6rem 0 4rem;
    margin-top: 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contacts-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path d="M0,0 L50,50 L100,0 Z" fill="none" stroke="%23ffffff10" stroke-width="0.5"/><path d="M0,50 L50,100 L100,50 Z" fill="none" stroke="%23ffffff10" stroke-width="0.5"/></svg>') repeat;
    opacity: 0.1;
    animation: float 20s ease-in-out infinite;
}

.contacts-hero-content {
    text-align: center;
    color: white;
    z-index: 10;
    max-width: 800px;
    padding: 0 2rem;
    position: relative;
    width: 100%;
    margin: 0 auto;
}

.hero-icon {
    font-size: 4rem;
    margin-bottom: 2rem;
    color: #00ff88;
    display: block;
    filter: drop-shadow(0 0 20px rgba(0, 255, 136, 0.5));
    animation: glow 3s ease-in-out infinite alternate;
}

.contacts-hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, #00ff88, #ffffff, #00cc66);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: bold;
    line-height: 1.2;
}

.contacts-hero p {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    opacity: 0.9;
    line-height: 1.6;
}

.contacts-hero .hero-subtitle {
    font-size: 1.1rem;
    font-style: italic;
    opacity: 0.8;
    line-height: 1.4;
}

/* ================================================
           PULSANTI
        ================================================ */

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 2.5rem;
    flex-wrap: wrap;
}

.hero-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: 30px;
    font-weight: bold;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    background: linear-gradient(45deg, #00b366, #008a4d);
    color: white;
    min-width: 160px;
}

.hero-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(0, 179, 102, 0.4);
    background: linear-gradient(45deg, #00cc73, #009955);
}

/* ================================================
           LAYOUT GENERALE
        ================================================ */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section {
    padding: 6rem 0;
}

.section-alt {
    background: #f8f9fa;
}

.section-title {
    text-align: center;
    font-size: 3rem;
    margin-bottom: 3rem;
    color: #2d5942;
}

/* ================================================
           FEATURE SECTIONS
        ================================================ */

.feature-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    margin-bottom: 6rem;
}

.feature-section:nth-child(even) {
    direction: rtl;
}

.feature-section:nth-child(even) > * {
    direction: ltr;
}

.feature-content {
    padding: 2rem 0;
}

.feature-content h2 {
    font-size: 2.5rem;
    color: #2d5942;
    margin-bottom: 1.5rem;
}

.feature-content p {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 2rem;
    line-height: 1.7;
}

.feature-button {
    display: inline-block;
    padding: 1rem 2rem;
    background: linear-gradient(45deg, #00ff88, #00cc66);
    color: white;
    text-decoration: none;
    border-radius: 30px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 255, 136, 0.3);
    margin-right: 1rem;
    margin-bottom: 1rem;
}

.feature-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 255, 136, 0.5);
}

.feature-image,
.video-container {
    width: 100%;
    height: 300px;
    background: linear-gradient(135deg, #2d5942, #1a3326);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    font-weight: bold;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
}

.video-container:hover,
.feature-image:hover {
    transform: scale(1.02);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
}

.video-thumbnail,
.feature-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 15px;
}

.play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: rgba(0, 255, 136, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    transition: all 0.3s ease;
}

.play-button:hover {
    background: rgba(0, 255, 136, 1);
    transform: translate(-50%, -50%) scale(1.1);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
    color: #00ff88;
}

.feature-icon img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

/* ================================================
           SEZIONI CONTATTI SPECIFICHE
        ================================================ */

/* Sezione informazioni di contatto principali */
.contact-info-main {
    padding: 6rem 0;
    background: white;
}

.contact-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.contact-card {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    text-align: center;
    transition: all 0.3s ease;
    border-top: 4px solid #00ff88;
    position: relative;
    overflow: hidden;
}

.contact-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 255, 136, 0.1), transparent);
    transition: left 0.5s ease;
}

.contact-card:hover::before {
    left: 100%;
}

.contact-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.contact-icon {
    color: #00ff88;
    margin-bottom: 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.contact-card h3 {
    color: #2d5942;
    margin-bottom: 1rem;
    font-size: 1.4rem;
    font-weight: bold;
}

.contact-card p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.contact-card a {
    color: #00ff88;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
}

.contact-card a:hover {
    text-decoration: underline;
    color: #00cc66;
}

.contact-hours {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
    font-size: 0.95rem;
}

/* Sezione mappa */
.map-section {
    padding: 4rem 0;
    background: #f8f9fa;
}

.map-container {
    margin-top: 2rem;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
    height: 400px;
    background: white;
    position: relative;
}

.bing-map {
    width: 100%;
    height: 100%;
    border-radius: 15px;
}

/* Form contatti */
.contact-form-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 6rem 0;
}

.contact-form-wrapper {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
}

.contact-form-intro {
    text-align: center;
    margin-bottom: 3rem;
}

.contact-form-intro h2 {
    color: #2d5942;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: bold;
}

.contact-form-intro p {
    color: #666;
    font-size: 1.2rem;
    line-height: 1.6;
}

.contact-form {
    background: white;
    padding: 3rem;
    border-radius: 15px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.contact-form::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(0, 255, 136, 0.05), transparent);
    animation: shimmer 4s ease-in-out infinite;
}

@keyframes shimmer {
    0%, 100% { transform: rotate(0deg); }
    50% { transform: rotate(1deg); }
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: bold;
    color: #2d5942;
    position: relative;
    z-index: 1;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: inherit;
    position: relative;
    z-index: 1;
    background: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #00ff88;
    box-shadow: 0 0 0 3px rgba(0, 255, 136, 0.1);
    transform: translateY(-2px);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
    font-size: 0.95rem;
    line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid #ddd;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
    margin-top: 2px;
    background: white;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
    background: #00ff88;
    border-color: #00ff88;
    transform: scale(1.1);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
    content: '✓';
    color: white;
    font-weight: bold;
    font-size: 14px;
}

.privacy-group {
    margin: 2rem 0;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 10px;
    border-left: 4px solid #00ff88;
}

.privacy-group .checkbox-label {
    color: #666;
}

.submit-btn {
    width: 100%;
    padding: 1.2rem 2rem;
    background: linear-gradient(45deg, #00ff88, #00cc66);
    color: white;
    border: none;
    border-radius: 30px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 255, 136, 0.3);
}

.submit-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.submit-btn:hover::before {
    left: 100%;
}

.submit-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(0, 255, 136, 0.4);
}

.submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.submit-btn.loading {
    background: #6c757d;
}

.btn-loading {
    display: none;
}

/* Sezioni servizi e social */
.services-section,
.social-contact-section {
    padding: 6rem 0;
}

.services-intro {
    text-align: center;
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 3rem;
    line-height: 1.6;
}

.services-grid,
.social-contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.service-card,
.social-contact-card {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border-top: 4px solid #00ff88;
    position: relative;
    overflow: hidden;
}

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

.social-contact-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    text-decoration: none;
    color: inherit;
    border-left: 4px solid #ddd;
    border-top: none;
}

.service-card::before,
.social-contact-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 255, 136, 0.1), transparent);
    transition: left 0.5s ease;
}

.service-card:hover::before,
.social-contact-card:hover::before {
    left: 100%;
}

.service-card:hover,
.social-contact-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    text-decoration: none;
    color: inherit;
}

.social-contact-card:hover {
    border-left-color: #00ff88;
}

.service-icon {
    color: #00ff88;
    margin-bottom: 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.service-card h3,
.social-content h3 {
    color: #2d5942;
    margin-bottom: 1rem;
    font-size: 1.3rem;
    font-weight: bold;
}

.service-card p,
.social-content p {
    color: #666;
    line-height: 1.6;
    margin: 0;
}

.social-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.social-icon.youtube {
    background: rgba(255, 0, 0, 0.1);
    color: #ff0000;
}

.social-icon.facebook {
    background: rgba(24, 119, 242, 0.1);
    color: #1877f2;
}

.social-icon.telegram {
    background: rgba(0, 136, 204, 0.1);
    color: #0088cc;
}

.social-contact-card:hover .social-icon.youtube {
    background: #ff0000;
    color: white;
    transform: scale(1.1);
}

.social-contact-card:hover .social-icon.facebook {
    background: #1877f2;
    color: white;
    transform: scale(1.1);
}

.social-contact-card:hover .social-icon.telegram {
    background: #0088cc;
    color: white;
    transform: scale(1.1);
}

/* ================================================
           YOUTUBE SECTION
        ================================================ */

.youtube-section {
    background: linear-gradient(135deg, #2d5942, #1a3326);
    color: white;
    text-align: center;
    padding: 6rem 0;
}

.youtube-button {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: #ff0000;
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: bold;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 8px 25px rgba(255, 0, 0, 0.3);
}

.youtube-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(255, 0, 0, 0.5);
}

.youtube-icon {
    font-size: 1.25rem;
}

/* ================================================
           MESSAGGI POPUP
        ================================================ */

.messaggio-popup {
    position: fixed;
    top: 100px;
    right: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    transform: translateX(400px);
    transition: all 0.3s ease;
    max-width: 400px;
    min-width: 300px;
}

.messaggio-popup.mostra {
    transform: translateX(0);
}

.messaggio-contenuto {
    padding: 1.5rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.messaggio-icona {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.messaggio-successo .messaggio-icona {
    background: #00ff88;
    color: white;
}

.messaggio-errore .messaggio-icona {
    background: #ff4757;
    color: white;
}

.messaggio-testo {
    flex: 1;
    line-height: 1.5;
    color: #333;
}

.messaggio-chiudi {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #999;
    padding: 0;
    width: 25px;
    height: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: color 0.3s ease;
}

.messaggio-chiudi:hover {
    color: #666;
}

.messaggio-successo {
    border-left: 4px solid #00ff88;
}

.messaggio-errore {
    border-left: 4px solid #ff4757;
}

/* ================================================
           FOOTER
        ================================================ */

.footer {
    background: #1a3326;
    color: white;
    padding: 3rem 0 1rem;
    text-align: center;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin: 2rem 0;
}

.social-links a {
    color: rgba(255, 255, 255, 0.7);
    transition: all 0.3s ease;
    padding: 0.5rem;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
}

.social-links a:hover {
    color: #00ff88;
    background: rgba(0, 255, 136, 0.1);
    transform: translateY(-2px);
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: #00ff88;
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.footer-links a:hover {
    opacity: 0.8;
}

.copyright {
    font-size: 1.1rem;
    font-weight: bold;
    color: #00ff88;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(0, 255, 136, 0.3);
}

/* ================================================
           ANIMAZIONI
        ================================================ */

.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ================================================
           MEDIA QUERIES - RESPONSIVE DESIGN
        ================================================ */

/* Tablet */
@media (max-width: 1024px) {
    .contacts-hero {
        padding: 5rem 0 3rem;
        min-height: 55vh;
    }
    
    .hero-icon {
        font-size: 3.5rem;
    }
    
    .contacts-hero h1 {
        font-size: 3rem;
    }

    .contact-cards-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 1.5rem;
    }

    .map-container {
        height: 350px;
    }
}

/* Mobile medio */
@media (max-width: 768px) {
    /* Menu Mobile */
    .nav-menu {
        position: fixed;
        top: 77px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 77px);
        background: rgba(26, 51, 38, 0.98);
        backdrop-filter: blur(10px);
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        gap: 2rem;
        padding-top: 3rem;
        transition: left 0.3s ease;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu li {
        opacity: 0;
        transform: translateX(-50px);
        transition: all 0.3s ease;
    }

    .nav-menu.active li {
        opacity: 1;
        transform: translateX(0);
    }

    .nav-menu.active li:nth-child(1) { transition-delay: 0.1s; }
    .nav-menu.active li:nth-child(2) { transition-delay: 0.2s; }
    .nav-menu.active li:nth-child(3) { transition-delay: 0.3s; }
    .nav-menu.active li:nth-child(4) { transition-delay: 0.4s; }
    .nav-menu.active li:nth-child(5) { transition-delay: 0.5s; }
    .nav-menu.active li:nth-child(6) { transition-delay: 0.6s; }

    .nav-menu a {
        font-size: 1.5rem;
        padding: 1rem;
    }

    .hamburger {
        display: flex;
    }

    /* Hero generale responsive */
    .hero {
        padding-top: 90px;
        padding-bottom: 2rem;
        min-height: 100vh;
        min-height: 100dvh;
    }

    .hero-content {
        padding: 0 1rem;
        display: flex;
        flex-direction: column;
        justify-content: center;
        min-height: calc(100vh - 140px);
    }

    .hero h1 {
        font-size: 2.2rem;
        margin-top: 0;
        line-height: 1.1;
        margin-bottom: 1rem;
    }

    .hero p {
        font-size: 1.1rem;
        margin-bottom: 1.5rem;
    }

    .hero-subtitle {
        font-size: 1rem;
        margin-bottom: 2rem;
    }

    /* Contacts Hero responsive */
    .contacts-hero {
        padding: 6rem 0 3rem;
        min-height: 60vh;
        margin-top: 77px;
    }
    
    .contacts-hero-content {
        padding: 0 1rem;
    }
    
    .hero-icon {
        font-size: 2.8rem;
        margin-bottom: 1.5rem;
    }
    
    .contacts-hero h1 {
        font-size: 2.2rem;
        margin-bottom: 1rem;
        line-height: 1.1;
    }
    
    .contacts-hero p {
        font-size: 1.1rem;
        margin-bottom: 1rem;
    }
    
    .contacts-hero .hero-subtitle {
        font-size: 0.95rem;
        margin-bottom: 1.5rem;
    }
    
    /* Layout responsive */
    .container {
        padding: 0 1rem;
    }

    .section {
        padding: 4rem 0;
    }

    .section-title {
        font-size: 1.8rem;
        margin-bottom: 2rem;
    }

    /* Feature sections responsive */
    .feature-section {
        grid-template-columns: 1fr;
        gap: 2rem;
        margin-bottom: 4rem;
    }

    .feature-section:nth-child(even) {
        direction: ltr;
    }

    .feature-content {
        padding: 1rem 0;
    }

    .feature-content h2 {
        font-size: 1.8rem;
        margin-bottom: 1rem;
    }

    .feature-content p {
        font-size: 1rem;
        line-height: 1.6;
    }

    .feature-image,
    .video-container {
        height: 250px;
    }

    /* Pulsanti responsive */
    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
        margin-top: 2rem;
    }

    .hero-btn {
        width: 100%;
        max-width: 250px;
        font-size: 0.95rem;
        padding: 0.8rem 1.5rem;
        min-width: auto;
    }

    .feature-button {
        display: block;
        width: 100%;
        max-width: 200px;
        text-align: center;
        margin: 0 auto 1rem;
    }

    /* Contatti responsive */
    .contact-cards-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .contact-form {
        padding: 2rem;
    }

    .contact-form-intro h2 {
        font-size: 1.8rem;
    }

    .contact-form-intro p {
        font-size: 1rem;
    }
    
    .map-container {
        height: 300px;
    }
    
    .services-grid,
    .social-contact-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .social-contact-card {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    /* Footer responsive */
    .social-links {
        gap: 1rem;
        margin: 1.5rem 0;
    }

    .social-links a {
        width: 35px;
        height: 35px;
    }

    .footer-links {
        gap: 1rem;
        flex-direction: column;
        margin-bottom: 1.5rem;
    }

    .copyright {
        font-size: 1rem;
        margin-top: 1.5rem;
        padding-top: 1.5rem;
    }
}

/* Mobile piccolo */
@media (max-width: 480px) {
    /* Hero generale smartphone */
    .hero {
        padding-top: 80px;
        padding-bottom: 1.5rem;
    }

    .hero h1 {
        font-size: 1.8rem;
        margin-bottom: 0.8rem;
    }

    .hero p {
        font-size: 1rem;
        margin-bottom: 1rem;
    }

    .hero-subtitle {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
    }

    /* Contacts Hero smartphone */
    .contacts-hero {
        padding: 5rem 0 2.5rem;
        min-height: 65vh;
    }
    
    .hero-icon {
        font-size: 2.2rem;
        margin-bottom: 1rem;
    }
    
    .contacts-hero h1 {
        font-size: 1.8rem;
        line-height: 1.1;
    }
    
    .contacts-hero p {
        font-size: 1rem;
        margin-bottom: 0.8rem;
    }
    
    .contacts-hero .hero-subtitle {
        font-size: 0.85rem;
        margin-bottom: 1rem;
    }

    /* Layout smartphone */
    .container {
        padding: 0 0.8rem;
    }

    .section {
        padding: 3rem 0;
    }

    .section-title {
        font-size: 1.6rem;
        margin-bottom: 1.5rem;
    }

    .feature-content h2 {
        font-size: 1.6rem;
    }

    .feature-content p {
        font-size: 0.95rem;
    }

    .feature-image,
    .video-container {
        height: 200px;
        font-size: 1rem;
    }

    /* Pulsanti smartphone */
    .hero-btn {
        font-size: 0.9rem;
        padding: 0.7rem 1.2rem;
        max-width: 220px;
    }

    .feature-button {
        font-size: 0.9rem;
        padding: 0.8rem 1.5rem;
        max-width: 180px;
    }

    /* Form contatti smartphone */
    .contact-form {
        padding: 1.5rem;
    }

    .contact-form-intro h2 {
        font-size: 1.6rem;
    }

    .contact-form-intro p {
        font-size: 0.95rem;
    }

    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 0.8rem;
        font-size: 0.95rem;
    }

    .submit-btn {
        padding: 1rem 1.5rem;
        font-size: 1rem;
    }
    
    /* Messaggi popup smartphone */
    .messaggio-popup {
        right: 10px;
        left: 10px;
        max-width: none;
        min-width: auto;
        transform: translateY(-100px);
    }
    
    .messaggio-popup.mostra {
        transform: translateY(0);
    }
    
    .messaggio-contenuto {
        padding: 1rem;
    }

    /* Footer smartphone */
    .social-links a {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }

    .footer-links {
        font-size: 0.9rem;
    }

    .copyright {
        font-size: 0.9rem;
    }

    /* Menu hamburger smartphone */
    .hamburger {
        padding: 3px;
    }

    .hamburger span {
        width: 22px;
        height: 2.5px;
        margin: 2.5px 0;
    }

    .nav-menu a {
        font-size: 1.3rem;
        padding: 0.8rem;
    }
}

/* Mobile molto piccolo */
@media (max-width: 360px) {
    .contacts-hero {
        padding: 4.5rem 0 2rem;
        min-height: 70vh;
    }
    
    .contacts-hero h1 {
        font-size: 1.6rem;
    }
    
    .hero-icon {
        font-size: 2rem;
    }

    .hero h1 {
        font-size: 1.6rem;
    }

    .container {
        padding: 0 0.6rem;
    }
}

/* Landscape mobile */
@media (max-height: 500px) and (orientation: landscape) {
    .hero {
        min-height: 100vh;
        padding-top: 70px;
        padding-bottom: 1rem;
    }
    
    .hero-content {
        min-height: calc(100vh - 120px);
        justify-content: center;
    }
    
    .hero h1 {
        font-size: 1.6rem;
        margin-bottom: 0.5rem;
    }

    .hero p {
        font-size: 0.9rem;
        margin-bottom: 0.8rem;
    }

    .hero-subtitle {
        font-size: 0.8rem;
        margin-bottom: 1rem;
    }

    .contacts-hero {
        min-height: 100vh;
        padding: 4rem 0 2rem;
    }
    
    .hero-icon {
        font-size: 1.8rem;
        margin-bottom: 0.8rem;
    }
    
    .contacts-hero h1 {
        font-size: 1.6rem;
        margin-bottom: 0.8rem;
    }
    
    .contacts-hero p {
        font-size: 0.9rem;
        margin-bottom: 0.8rem;
    }
    
    .contacts-hero .hero-subtitle {
        font-size: 0.8rem;
        margin-bottom: 1rem;
    }

    .hero-buttons {
        margin-top: 1rem;
        gap: 0.5rem;
    }

    .hero-btn {
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
    }
}

/* Correzione per Safari iOS */
@supports (-webkit-touch-callout: none) {
    .hero {
        min-height: calc(100vh + env(safe-area-inset-top));
        padding-top: calc(80px + env(safe-area-inset-top));
    }

    .contacts-hero {
        min-height: calc(60vh + env(safe-area-inset-top));
        padding-top: calc(6rem + env(safe-area-inset-top));
        margin-top: calc(80px + env(safe-area-inset-top));
    }
    
    @media (max-width: 768px) {
        .contacts-hero {
            min-height: calc(60vh + env(safe-area-inset-top));
            padding-top: calc(6rem + env(safe-area-inset-top));
            margin-top: calc(77px + env(safe-area-inset-top));
        }
    }
    
    @media (max-width: 480px) {
        .contacts-hero {
            min-height: calc(65vh + env(safe-area-inset-top));
            padding-top: calc(5rem + env(safe-area-inset-top));
        }
    }
}