/* ==========================================================================
   CONTACT PAGE STYLES - M3 PIXEL UI (FLOATING LABELS & ANIMATIONS)
   ========================================================================== */

/* 1. Hero Section */
.contact-hero-container {
    padding: 24px;
    max-width: 1400px;
    margin: 0 auto;
}

.contact-hero {
    background: linear-gradient(135deg, rgba(10, 58, 106, 0.85) 0%, rgba(10, 58, 106, 0.95) 100%), 
                url('https://images.unsplash.com/photo-1516387938699-a93567ec168e?auto=format&fit=crop&w=1920&q=80') center/cover no-repeat;
    padding: 100px 32px;
    text-align: center;
    border-radius: var(--md-sys-shape-corner-extra-large); 
    box-shadow: var(--md-sys-elevation-2);
    margin-bottom: 24px;
    transition: background 0.4s var(--md-sys-motion-easing-emphasized);
}

body.dark-mode .contact-hero {
    background: linear-gradient(135deg, rgba(17, 19, 24, 0.9) 0%, rgba(17, 19, 24, 0.98) 100%), 
                url('https://images.unsplash.com/photo-1516387938699-a93567ec168e?auto=format&fit=crop&w=1920&q=80') center/cover no-repeat;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.hero-content { 
    max-width: 800px; 
    margin: 0 auto; 
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero-icon {
    font-size: 48px;
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.15);
    padding: 16px;
    border-radius: 20px; 
    margin-bottom: 24px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.contact-hero .display-large { color: #ffffff; margin-bottom: 16px; font-weight: 500; letter-spacing: -0.5px;}
.contact-hero .body-large { color: rgba(255, 255, 255, 0.9); font-size: 18px; }


/* 2. Main Grid */
.contact-main-section {
    max-width: 1300px;
    margin: 48px auto; 
    padding: 0 24px;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 40px;
    align-items: start;
}

/* ==========================================================================
   INFO CARDS (Left Column)
   ========================================================================== */
.info-cards-column { display: flex; flex-direction: column; gap: 16px; }

.m3-info-card {
    background-color: var(--md-sys-color-surface-container-low);
    border: 1px solid var(--md-sys-color-surface-container-high);
    border-radius: var(--md-sys-shape-corner-extra-large);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.4s var(--md-sys-motion-easing-emphasized); 
    box-shadow: var(--md-sys-elevation-1);
    will-change: transform, box-shadow;
}

.m3-info-card:hover {
    box-shadow: var(--md-sys-elevation-2);
    transform: translateY(-4px) scale(1.01);
    border-color: transparent;
    background-color: var(--md-sys-color-surface-container);
}

body.dark-mode .m3-info-card:hover { box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4); }

.card-icon-wrapper {
    background: linear-gradient(135deg, var(--md-sys-color-primary-container) 0%, var(--md-sys-color-surface) 100%);
    width: 60px; height: 60px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 18px; 
    flex-shrink: 0;
    border: 1px solid var(--md-sys-color-surface-container-high);
    transition: transform 0.4s var(--md-sys-motion-easing-emphasized);
}

.card-icon-wrapper .material-symbols-rounded { 
    font-size: 28px; 
    color: var(--md-sys-color-primary); 
    transition: transform 0.4s var(--md-sys-motion-easing-emphasized);
}

.m3-info-card:hover .card-icon-wrapper { transform: rotate(-5deg); }
.m3-info-card:hover .material-symbols-rounded { transform: scale(1.1); }

.info-text h3 {
    font-size: 16px;
    color: var(--md-sys-color-on-surface);
    margin-bottom: 4px;
    font-weight: 600;
}

.info-text p, .info-text a {
    font-size: 15px;
    color: var(--md-sys-color-on-surface);
    opacity: 0.8;
    text-decoration: none;
    line-height: 1.5;
}
.info-text a { transition: color 0.2s; color: var(--md-sys-color-primary); font-weight: 500;}
.info-text a:hover { opacity: 1; text-decoration: underline;}

/* ==========================================================================
   M3 PREMIUM FORM (Filled Text Fields with Floating Labels)
   ========================================================================== */
.m3-premium-form {
    background-color: var(--md-sys-color-surface);
    padding: 48px;
    border-radius: 32px; 
    border: 1px solid var(--md-sys-color-surface-container-high);
    box-shadow: var(--md-sys-elevation-1); 
    width: 100%;
    box-sizing: border-box;
    transition: background-color 0.4s ease, border-color 0.4s ease;
}

.form-header { margin-bottom: 40px; }
.form-header .title-large { color: var(--md-sys-color-primary); margin-bottom: 8px; font-weight: 600; letter-spacing: -0.2px;}
.form-header .body-medium { opacity: 0.8; font-size: 15px; }

.form-fields-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px; /* Περισσότερο κενό ανάμεσα στα πεδία */
}

/* M3 Filled Field Structure */
.m3-filled-field {
    position: relative; 
    margin-bottom: 24px;
    background-color: var(--md-sys-color-surface-container-low);
    border-radius: 12px 12px 0 0; /* Στρογγυλό πάνω, ίσιο κάτω */
    border-bottom: 2px solid var(--md-sys-color-surface-container-high);
    transition: all 0.3s var(--md-sys-motion-easing-emphasized);
}

.m3-filled-field:hover {
    background-color: var(--md-sys-color-surface-container);
    border-bottom-color: var(--md-sys-color-outline);
}

/* Το Input Box */
.m3-filled-field input, 
.m3-filled-field textarea {
    width: 100%;
    box-sizing: border-box;
    background-color: transparent;
    border: none;
    padding: 24px 16px 8px; /* Μεγάλο padding πάνω για να χωρέσει το label */
    font-family: inherit;
    font-size: 16px;
    color: var(--md-sys-color-on-surface);
    outline: none;
}

.m3-filled-field textarea { padding-top: 28px; resize: vertical; min-height: 120px; }

/* Το Floating Label */
.m3-filled-field label {
    position: absolute;
    left: 16px;
    top: 16px; /* Κέντρο όταν είναι άδειο */
    color: var(--md-sys-color-on-surface);
    opacity: 0.6;
    font-size: 16px;
    pointer-events: none; 
    transform-origin: left top;
    transition: all 0.3s var(--md-sys-motion-easing-emphasized);
}

/* Όταν κάνεις Focus ή έχει κείμενο (Το Label "πετάει" πάνω) */
.m3-filled-field input:focus ~ label,
.m3-filled-field textarea:focus ~ label,
.m3-filled-field input:not(:placeholder-shown) ~ label,
.m3-filled-field textarea:not(:placeholder-shown) ~ label {
    transform: translateY(-8px) scale(0.75); 
    color: var(--md-sys-color-primary);
    opacity: 1;
    font-weight: 500;
}

/* Όταν δεν έχει focus αλλά έχει κείμενο, το label παραμένει πάνω αλλά γίνεται γκρι */
.m3-filled-field input:not(:focus):not(:placeholder-shown) ~ label,
.m3-filled-field textarea:not(:focus):not(:placeholder-shown) ~ label {
    color: var(--md-sys-color-on-surface);
    opacity: 0.8;
}

/* Η μπλε γραμμή (Indicator) που εμφανίζεται στο Focus */
.m3-filled-field::after {
    content: '';
    position: absolute;
    bottom: -2px; left: 0; width: 100%; height: 2px;
    background-color: var(--md-sys-color-primary);
    transform: scaleX(0);
    transition: transform 0.3s var(--md-sys-motion-easing-emphasized);
}

.m3-filled-field:focus-within::after { transform: scaleX(1); }
.m3-filled-field:focus-within { background-color: var(--md-sys-color-primary-container); border-bottom-color: transparent;}

/* Κρύβουμε τα native placeholders γιατί έχουμε τα floating labels */
.m3-filled-field input::placeholder, 
.m3-filled-field textarea::placeholder { color: transparent; }


/* ==========================================================================
   M3 SUBMIT BUTTON ADVANCED STATES
   ========================================================================== */
.submit-btn {
    width: 100%; padding: 0; height: 56px; 
    font-size: 16px; font-weight: 600; letter-spacing: 0.5px;
    border-radius: var(--md-sys-shape-corner-full);
    position: relative; display: flex; align-items: center; justify-content: center;
    overflow: hidden;
}

.btn-content {
    position: absolute; display: flex; align-items: center; justify-content: center;
    width: 100%; height: 100%;
    transition: all 0.4s var(--md-sys-motion-easing-emphasized);
    will-change: opacity, transform;
}

.loading-content, .success-content { opacity: 0; transform: scale(0.8); pointer-events: none; }

.submit-btn.loading {
    background-color: var(--md-sys-color-surface-container-high) !important;
    color: var(--md-sys-color-primary) !important;
    cursor: wait; box-shadow: none;
}
.submit-btn.loading .default-content { opacity: 0; transform: translateY(-20px); }
.submit-btn.loading .loading-content { opacity: 1; transform: translateY(0); }

.submit-btn.success {
    background-color: #146c2e !important; /* M3 Green */
    color: white !important;
}
.submit-btn.success .loading-content { opacity: 0; transform: translateY(-20px); }
.submit-btn.success .success-content { opacity: 1; transform: translateY(0); }

.m3-spinner {
    width: 24px; height: 24px;
    border: 3px solid rgba(10, 58, 106, 0.2);
    border-top-color: var(--md-sys-color-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}
body.dark-mode .m3-spinner { border-top-color: var(--md-sys-color-on-primary-container); }

@keyframes spin { to { transform: rotate(360deg); } }

/* ==========================================================================
   MAP SECTION & MEDIA QUERIES
   ========================================================================== */
.map-section { max-width: 1400px; margin: 0 auto 80px; padding: 0 24px; }
.map-wrapper {
    height: 450px;
    border-radius: var(--md-sys-shape-corner-extra-large);
    overflow: hidden;
    box-shadow: var(--md-sys-elevation-1);
    border: 4px solid var(--md-sys-color-surface-container-low);
    transition: all 0.4s var(--md-sys-motion-easing-emphasized);
}
.map-wrapper:hover { border-color: var(--md-sys-color-primary-container); box-shadow: var(--md-sys-elevation-2);}

@media (max-width: 992px) {
    .contact-grid { grid-template-columns: 1fr; gap: 48px; }
    .contact-hero { padding: 60px 20px; border-radius: var(--md-sys-shape-corner-large); }
    .form-fields-grid { grid-template-columns: 1fr; gap: 0; }
    .m3-premium-form { padding: 32px 24px; border-radius: 24px; }
    .map-wrapper { height: 350px; border-radius: 24px; }
}