/* ============================================
 * m10_contact (Child Override) — H&S Kontakt-Layout
 *   - Topline + Headline + Body oben
 *   - 2 Spalten: Bild links, Dark-Form rechts
 *   - Map full-width darunter
 * ============================================ */
.m10_contact.m10_hs {
    background: #fff;
    padding: clamp(48px, 7vw, 110px) 0 0;
    /* Spuerbarer Abstand zum Modul oben (m38 etc.) — schafft die Luft, in die
       die Form per negativem Margin sichtbar hineinragt. */
    margin-top: clamp(60px, 7vw, 140px);
    color: #1d1d1b;
}
/* Container-Breite kommt aus globalem .hs_container + data-container Attribut */
.m10_hs_inner {
    padding-bottom: 0;
}

.m10_hs_left {
    display: flex;
    flex-direction: column;
    align-self: stretch;
}
.m10_hs_header {
    margin-bottom: clamp(40px, 4vw, 64px);
    max-width: 780px;
}
.m10_hs_headline {
    color: var(--hs-dark);
    font-weight: 600;
    font-size: clamp(26px, 2.6vw, 40px);
    line-height: 1.125;
    letter-spacing: 0.03em;
    margin: 18px 0 24px;
}
.m10_hs_headline em, .m10_hs_headline i {
    font-style: italic; font-weight: 600; font-family: var(--hs-font-display);
}
.m10_hs_text {
    color: #1d1d1b;
    font-weight: 300;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.03em;
    max-width: 600px;
}

/* --- Grid Bild + Form ---
   Figma: Bild bleedet links ueber den Container hinaus zur Viewport-Kante;
   Form-Spalte ist ~715/1656 breit. Wir spiegeln das, indem die Image-Col
   per neg. margin-left aus dem .hs_container heraus zur Viewport-Linke geht. */
.m10_hs_grid {
    display: grid;
    /* Form-Spalte fix auf Figma-Breite (715px); Image-Col bekommt den Rest
       (~ alles bis dahin) — wegen des Bleeds nach links wirkt das Image im
       Viewport breiter als seine Grid-Spalte. */
    grid-template-columns: minmax(0, 1fr) clamp(280px, 38vw, 715px);
    gap: clamp(40px, 4vw, 70px);
    align-items: stretch;
}
.m10_hs_image_col {
    position: relative;
    background: transparent;
    overflow: hidden;
    /* Bleed nach links bis zur Viewport-Kante */
    --m10-bleed: max(0px, calc((100vw - 1726px) / 2 + var(--hs-container-px)));
    margin-left: calc(-1 * var(--m10-bleed));
    width: calc(100% + var(--m10-bleed));
    /* Fuellt den restlichen Platz unter dem Header in der linken Col.
       Figma: Foto 681px bei 1920px Viewport (≈36vw). Min-Height bestimmt
       den Grid-Track — muss groesser sein als die Form-Contribution damit
       das Bild die Track-Hoehe setzt und die Form-Background nicht streckt. */
    flex: 1;
    min-height: clamp(500px, 36vw, 720px);
}
.m10_hs_image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: top center;
}

/* --- Dark Form Container ---
   Figma: Form-Block bleedet ~73px ueber den Section-Top in den vorherigen
   Bereich hinein. Wir setzen negative margin-top auf die Form-Col, damit
   das dunkle Form-Background sichtbar nach oben raus ragt. */
.m10_hs_form_col {
    display: flex;
    /* align-self: start verhindert, dass der dunkle Form-Background auf die
       volle Grid-Track-Hoehe gestreckt wird. Die linke Spalte (stretch) bestimmt
       die Track-Hoehe; rechts bleibt der BG auf die Form-Content-Hoehe begrenzt. */
    align-self: start;
    /* Form bleedet sichtbar UEBER den weissen Section-BG hinaus in den
       Bereich zwischen dem Modul darueber (m38) und m10. Negativer Margin
       deckt das gesamte Section-Padding-Top + einen Teil des Section-margin-top
       ab — d.h. zwischen m38 und Form bleibt nur ein kleiner heller Streifen. */
    margin-top: calc(-1 * (clamp(48px, 7vw, 110px) + clamp(40px, 5vw, 90px)));
}
.m10_hs_form {
    background: #2F3A46;
    color: #fff;
    padding: clamp(36px, 4vw, 65px) clamp(28px, 3vw, 50px);
    width: 100%;
}

/* --- CF7 Styling im Dark-Theme --- */
.m10_hs_form .wpcf7 { color: #fff; }
.m10_hs_form .wpcf7-form > p,
.m10_hs_form .hs_form_row {
    margin: 0 0 22px;
}
.m10_hs_form label {
    display: block;
    color: #fff;
    font-size: 14.5px;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 0.083em;
    margin-bottom: 12px;
}
.m10_hs_form .hs_form_grid_2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
}
.m10_hs_form input[type="text"],
.m10_hs_form input[type="email"],
.m10_hs_form input[type="tel"],
.m10_hs_form select,
.m10_hs_form textarea {
    width: 100%;
    background: rgba(250, 250, 250, 0.10);
    border: 1px solid rgba(209, 213, 215, 0.50);
    color: #fff;
    font-family: var(--hs-font-body);
    font-size: 16px;
    font-weight: 300;
    line-height: 1.5;
    letter-spacing: 0.03em;
    padding: 18px 28px;
    box-shadow: none;
    appearance: none;
    -webkit-appearance: none;
    transition: border-color 0.3s ease, background 0.3s ease;
}
.m10_hs_form input[type="text"]:focus,
.m10_hs_form input[type="email"]:focus,
.m10_hs_form input[type="tel"]:focus,
.m10_hs_form select:focus,
.m10_hs_form textarea:focus {
    border-color: var(--hs-gold);
    outline: none;
    background: rgba(250, 250, 250, 0.15);
}
.m10_hs_form input::placeholder,
.m10_hs_form textarea::placeholder {
    color: rgba(255, 255, 255, 0.50);
}
.m10_hs_form textarea { min-height: 171px; resize: vertical; }
.m10_hs_form select {
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8' fill='%23fff'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23fff' fill='none' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 28px center;
    background-size: 12px 8px;
    padding-right: 56px;
}

/* === Custom Select (mM_select_*) — ausschliesslich STYLING.
   mM_select.js (Parent) toggelt .mM_select_arrow_active auf .mM_select_selected
   und animiert die Hoehe von .mM_select_items per jQuery. Daher hier KEIN
   display:none (sonst funktioniert die Hoehen-Animation nicht) und KEIN
   pointer-events:none/opacity:0 auf native <select> (greift in das Verhalten ein).
   Nur Visuals.
   --------------------------------------------------- */
.m10_hs_form .mM_custom_select {
    position: relative;
    display: block;
    width: 100%;
}
.m10_hs_form .mM_custom_select > select {
    /* native <select> visuell ausblenden — Custom-DIV uebernimmt Darstellung.
       Keine display:none — sonst koennen Validation-Fokus / Screenreader nicht
       greifen. Wir machen es transparent, nicht klickbar.
       (Click-Events laufen ueber die Custom-DIVs.) */
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    background: transparent;
    color: transparent;
    opacity: 0;
    pointer-events: none;
}
.m10_hs_form .mM_select_selected {
    position: relative;
    background: rgba(250, 250, 250, 0.10);
    border: 1px solid rgba(209, 213, 215, 0.50);
    color: #fff;
    font-family: var(--hs-font-body);
    font-size: 16px;
    font-weight: 300;
    line-height: 1.5;
    letter-spacing: 0.03em;
    padding: 18px 56px 18px 28px;
    cursor: pointer;
    transition: border-color 0.3s ease, background 0.3s ease;
}
.m10_hs_form .mM_custom_select:hover .mM_select_selected {
    background: rgba(250, 250, 250, 0.15);
}
.m10_hs_form .mM_select_arrows {
    position: absolute;
    right: 28px;
    top: 50%;
    margin-top: -4px; /* = -height/2 ohne Transform (Transform wuerde Layout-Klassen-Rotation stoeren) */
    width: 12px;
    height: 8px;
    pointer-events: none;
}
.m10_hs_form .mM_select_arrow_down {
    width: 12px;
    height: 8px;
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23fff' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-size: contain;
    transition: transform 0.3s ease;
}
/* Wenn das SELECTED-Div .mM_select_arrow_active hat, rotieren wir NUR den
   Pfeil-Down (Descendant), nicht das ganze SELECTED-Div. */
.m10_hs_form .mM_select_selected.mM_select_arrow_active .mM_select_arrow_down {
    transform: rotate(180deg);
}
.m10_hs_form .mM_select_items {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    background: #2F3A46;
    border: 1px solid rgba(209, 213, 215, 0.50);
    z-index: 10;
    /* overflow-y: auto — JS begrenzt die Hoehe auf ~4 Items; alles darueber
       wird scrollbar (Auswahl-Liste kann viele Items haben).
       overflow-x: hidden verhindert horizontalen Scrollbar bei langen Items. */
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}
/* Schmaler Scroll-Indikator passend zum Dark-Theme */
.m10_hs_form .mM_select_items::-webkit-scrollbar { width: 6px; }
.m10_hs_form .mM_select_items::-webkit-scrollbar-track { background: transparent; }
.m10_hs_form .mM_select_items::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.25);
    border-radius: 3px;
}
.m10_hs_form .mM_select_items::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.40);
}
/* JS animiert die height-Property fuer Auf-/Zu — wir setzen NUR den Initial-
   Hide-Zustand und ueberlassen die Animation der JS-Steuerung. */
.m10_hs_form .mM_select_items.mM_select_hide {
    height: 0;
    border-width: 0;
    box-shadow: none;
}
.m10_hs_form .mM_select_item {
    padding: 14px 28px;
    color: #fff;
    font-family: var(--hs-font-body);
    font-size: 16px;
    font-weight: 300;
    line-height: 1.5;
    letter-spacing: 0.03em;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}
.m10_hs_form .mM_select_item:hover {
    background: rgba(171, 143, 80, 0.18);
    color: var(--hs-gold);
}
.m10_hs_form .mM_select_item.mM_same_as_selected {
    color: rgba(255, 255, 255, 0.65);
}

/* Checkbox */
.m10_hs_form .wpcf7-acceptance .wpcf7-list-item {
    margin: 0;
    display: flex;
    align-items: flex-start;
    gap: 14px;
}
.m10_hs_form input[type="checkbox"] {
    width: 19px;
    height: 19px;
    border: 1px solid rgba(255, 255, 255, 0.50);
    background: rgba(250, 250, 250, 0.10);
    appearance: none;
    -webkit-appearance: none;
    flex-shrink: 0;
    margin-top: 2px;
    cursor: pointer;
    position: relative;
}
.m10_hs_form input[type="checkbox"]:checked {
    background: var(--hs-gold);
    border-color: var(--hs-gold);
}
.m10_hs_form input[type="checkbox"]:checked::after {
    content: '\2713';
    position: absolute;
    inset: 0;
    color: #fff;
    font-size: 14px;
    line-height: 17px;
    text-align: center;
}
.m10_hs_form .wpcf7-list-item-label {
    color: rgba(255, 255, 255, 0.50);
    font-size: 16px;
    font-weight: 300;
    letter-spacing: 0.03em;
}

/* Pflichtfeld-Hinweis rechts */
.m10_hs_form .hs_form_required_hint {
    color: rgba(255, 255, 255, 0.5);
    font-size: 14.5px;
    text-align: right;
    margin-bottom: 24px;
}

/* Submit-Button */
.m10_hs_form input[type="submit"],
.m10_hs_form button[type="submit"] {
    width: 100%;
    background: var(--hs-gold);
    border: none;
    color: #fff;
    font-family: var(--hs-font-body);
    font-size: 16px;
    font-weight: 300;
    line-height: 1;
    letter-spacing: 0.075em;
    text-transform: uppercase;
    padding: 28px;
    cursor: pointer;
    margin-top: 12px;
    transition: background 0.3s ease;
}
.m10_hs_form input[type="submit"]:hover,
.m10_hs_form button[type="submit"]:hover {
    background: var(--hs-gold-dark);
}
.m10_hs_form .wpcf7-spinner { display: none; }

/* Map ---
   Figma: 1720x663 mit 100px Inset links/rechts bei 1920 Viewport (= 5.2%).
   Map sitzt knapp unter dem Team-Foto — minimaler Abstand (Figma: leichter
   Overlap mit Bild-Unterkante). Negative margin-top damit Map kein Gap zum
   Bild produziert. */
.m10_hs_map {
    /* Map-Top sitzt buendig an der Bildunterkante (Left-Col endet jetzt
       genau an den Personenfuessen, also ist 0 Margin korrekt). */
    margin-top: 0;
    padding: 0 clamp(20px, 5vw, 100px) clamp(60px, 6vw, 100px);
    position: relative;
    z-index: 0;
}
/* Team-Foto soll vor der Map liegen (Cut-out-Personen ueber Map-Oberkante) */
.m10_hs_left { position: relative; z-index: 1; }
/* <a name="map1"> ist ein leeres Inline-Element — erzeugt durch body line-height
   eine ~24px Luecke vor der Karte. Block + height 0 entfernt das. */
.m10_hs_map > a[name] {
    display: block;
    height: 0;
    overflow: hidden;
}
/* Outer wrapper vom WP Google Maps Plugin: BFC damit der float-left des
   .wpgmza_map-Divs den Container nicht kollabieren lässt */
.m10_hs_map > div {
    width: 100% !important;
    display: block;
    overflow: hidden;
}
.m10_hs_map iframe,
.m10_hs_map .wpgmza_map {
    width: 100% !important;
    float: none !important;
    border: 0;
    display: block;
    /* Plugin setzt height per inline-style — überschreiben */
    height: clamp(200px, 38.55vw, 600px) !important;
}

@media (max-width: 992px) {
    .m10_hs_grid { grid-template-columns: minmax(0, 1fr); gap: 36px; }
    .m10_hs_image_col { min-height: 280px; min-width: 0; }
    .m10_hs_form_col { min-width: 0; }
    .m10_hs_form .hs_form_grid_2 { grid-template-columns: 1fr; }
}
@supports (aspect-ratio: 1) {
    @media (max-width: 992px) {
        .m10_hs_image_col { min-height: 0; aspect-ratio: 16 / 10; }
    }
}
