/**
 * Hypsipyle - Supplementary CSS
 * Patches for missing Divi theme CSS, CF7 form styling, and layout fixes
 */

/* ========================================
   FIX: page-container padding for fixed header
   ======================================== */
.et_fixed_nav.et_show_nav #page-container {
    padding-top: 80px;
}

/* ========================================
   FIX: Container & layout
   ======================================== */
.container {
    width: 80%;
    max-width: 1080px;
    margin: 0 auto;
    position: relative;
}
.clearfix:after {
    content: "";
    display: table;
    clear: both;
}

/* ========================================
   FIX: Sections, Rows, Columns base
   ======================================== */
.et_pb_section {
    position: relative;
    padding: 54px 0;
    background-size: cover;
    background-position: center;
}
.et_pb_row {
    width: 80%;
    max-width: 1080px;
    margin: 0 auto;
    padding: 27px 0;
    position: relative;
}
.et_pb_column {
    float: left;
    position: relative;
    z-index: 1;
    min-height: 1px;
    background-size: cover;
    background-position: center;
}
.et_pb_column_4_4 { width: 100%; }
.et_pb_gutters3 .et_pb_column_1_2 { width: 47.25%; margin-right: 5.5%; }
.et_pb_gutters3 .et_pb_column_1_2.et-last-child { margin-right: 0; }
.et_pb_gutters3 .et_pb_column_3_4 { width: 73.625%; margin-right: 5.5%; }
.et_pb_gutters3 .et_pb_column_1_4 { width: 20.875%; margin-right: 5.5%; }
.et_pb_gutters3 .et_pb_column_1_4.et-last-child { margin-right: 0; }
.et_pb_gutters3 .et_pb_column_3_5 { width: 55.75%; margin-right: 5.5%; }
.et_pb_gutters3 .et_pb_column_2_5 { width: 38.75%; margin-right: 0; }

/* Gutters4 overrides */
.et_pb_gutters4 .et_pb_column_1_2 { width: 46%; margin-right: 8%; }
.et_pb_gutters4 .et_pb_column_1_2.et-last-child { margin-right: 0; }
.et_pb_gutters4 .et_pb_column_1_4 { width: 19%; margin-right: 8%; }
.et_pb_gutters4 .et_pb_column_1_4.et-last-child { margin-right: 0; }

.et_pb_equal_columns > .et_pb_column {
    display: flex;
    flex-direction: column;
}

/* Row clearfix */
.et_pb_row:after {
    content: "";
    display: table;
    clear: both;
}

/* ========================================
   FIX: Modules base
   ======================================== */
.et_pb_module { position: relative; }
.et_pb_text { word-wrap: break-word; }
.et_pb_text_inner { position: relative; }
.et_pb_image { margin-bottom: 30px; }
.et_pb_image_wrap { display: block; }
.et_pb_image_wrap img { display: block; }
.et_pb_bg_layout_light { color: #666; }

/* Dividers */
.et_pb_divider { position: relative; }
.et_pb_divider_hidden { max-height: 0; overflow: hidden; }
.et_pb_divider:before {
    content: '';
    display: block;
    border-top: 1px solid #ccc;
}
.et_pb_divider_hidden:before { display: none; }
.et_pb_space { margin-bottom: 0; }

/* Buttons */
.et_pb_button {
    font-size: 20px;
    font-weight: 500;
    padding: 0.3em 1em;
    line-height: 1.7em;
    background-color: transparent;
    border: 2px solid;
    transition: all 0.3s ease;
    display: inline-block;
    text-decoration: none !important;
    cursor: pointer;
}
.et_pb_button_module_wrapper { display: inline-block; }

/* ========================================
   FIX: Contact Form (CF7 CSS was truncated)
   ======================================== */
.wpcf7 .screen-reader-response {
    position: absolute;
    overflow: hidden;
    clip: rect(1px, 1px, 1px, 1px);
    height: 1px;
    width: 1px;
    margin: -1px;
    padding: 0;
    border: 0;
}
.wpcf7-response-output {
    margin: 2em 0.5em 1em;
    padding: 0.2em 1em;
    border: 2px solid #00a0d2;
    display: none;
}

/* Contact form field layout */
.et_pb_contact_field { margin-bottom: 12px; }
.et_pb_contact_field br { display: none; }
.et_pb_contact_field_half {
    width: 48%;
    float: left;
}
.et_pb_contact_field_half.et_pb_contact_field_last {
    float: right;
}
.et_pb_contact_field_last:not(.et_pb_contact_field_half) {
    width: 100%;
    clear: both;
}

/* Form inputs in dark section (Contact) */
.et_pb_section_7 .et_pb_contact input[type="text"],
.et_pb_section_7 .et_pb_contact input[type="email"],
.et_pb_section_7 .et_pb_contact input[type="tel"],
.et_pb_section_7 .et_pb_contact textarea,
.et_pb_section_7 .wpcf7-form-control.input,
.et_pb_section_7 .wpcf7-form-control.wpcf7-textarea {
    width: 100%;
    padding: 16px;
    border: none;
    border-bottom: 1px solid rgba(255,255,255,0.3);
    background: transparent;
    color: #fff;
    font-size: 14px;
    font-family: 'Open Sans', Arial, Helvetica, sans-serif;
    outline: none;
    transition: border-color 0.3s ease;
    -webkit-appearance: none;
    border-radius: 0;
}
.et_pb_section_7 .wpcf7-form-control::placeholder {
    color: rgba(255,255,255,0.5);
}
.et_pb_section_7 .wpcf7-form-control:focus {
    border-bottom-color: #cea479;
}
.et_pb_section_7 textarea.wpcf7-textarea {
    min-height: 120px;
    resize: vertical;
}

/* Submit button */
.et_pb_contact_submit,
.et_contact_bottom_container .et_pb_button,
input.wpcf7-submit {
    background-color: #cea479 !important;
    color: #fff !important;
    border: none !important;
    padding: 12px 40px !important;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Open Sans', Arial, Helvetica, sans-serif;
    -webkit-appearance: none;
    border-radius: 0;
}
.et_pb_contact_submit:hover,
input.wpcf7-submit:hover {
    background-color: #b8905f !important;
}
.et_contact_bottom_container {
    clear: both;
    padding-top: 10px;
}

/* RGPD checkbox */
.wpcf7-acceptance label {
    color: rgba(255,255,255,0.5);
    font-size: 12px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    cursor: pointer;
    line-height: 1.5;
}
.wpcf7-acceptance input[type="checkbox"] {
    margin-top: 3px;
    flex-shrink: 0;
}

/* Form container with border */
.et_pb_with_border {
    border: 1px solid rgba(255,255,255,0.15);
    padding: 30px;
}

/* Validation error */
.wpcf7-not-valid {
    border-bottom-color: #cf2e2e !important;
}
/* Honeypot */
input[name="website_url"] { display: none !important; }

/* ========================================
   FIX: Header - Logo left, Hamburger right
   ======================================== */
#main-header .container.et_menu_container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.logo_container {
    position: relative !important;
    width: auto !important;
    height: auto !important;
    z-index: 2;
}
#logo {
    max-height: 40px;
    width: auto;
}

/* ========================================
   Hamburger: replace ETmodules icon with CSS bars
   (ETmodules font is not available locally)
   ======================================== */
.et_toggle_slide_menu {
    display: block !important;
    cursor: pointer;
    width: 28px;
    height: 20px;
    position: relative;
    z-index: 100000;
}
/* Override Divi's ETmodules ::after icon */
.et_toggle_slide_menu::after {
    content: '' !important;
    font-size: 0 !important;
    font-family: inherit !important;
    display: block !important;
    width: 28px;
    height: 2px;
    background-color: #cea479;
    position: absolute !important;
    left: 0 !important;
    top: 18px !important;
    opacity: 1 !important;
    transform: none !important;
    transition: all 0.3s ease !important;
}
.et_toggle_slide_menu::before {
    content: '' !important;
    font-size: 0 !important;
    font-family: inherit !important;
    display: block !important;
    width: 28px;
    height: 2px;
    background-color: #cea479;
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    box-shadow: 0 9px 0 #cea479;
    opacity: 1 !important;
    transition: all 0.3s ease !important;
}

/* Animate to X when menu open */
body.et_pb_slide_menu_active .et_toggle_slide_menu::before {
    transform: rotate(45deg) !important;
    top: 9px !important;
    box-shadow: none !important;
    opacity: 1 !important;
}
body.et_pb_slide_menu_active .et_toggle_slide_menu::after {
    transform: rotate(-45deg) !important;
    top: 9px !important;
    opacity: 1 !important;
}

/* ========================================
   Slide-in panel overrides
   (Divi inline handles position/transition,
    we just fix colors and padding)
   ======================================== */
.et_slide_in_menu_container {
    background: #000 !important;
}
.et_slide_in_menu_container ul#mobile_menu_slide {
    padding: 28px 40px !important;
}

/* Menu links - refined style */
.et_slide_in_menu_container #mobile_menu_slide li a {
    font-family: 'Bauer Bodoni', Helvetica, Arial, sans-serif !important;
    font-size: 16px !important;
    color: rgba(255,255,255,0.7) !important;
    border-bottom: 1px solid rgba(255,255,255,0.08) !important;
    padding: 15px 0 !important;
    letter-spacing: 0.5px;
    transition: color 0.3s ease, padding-left 0.3s ease !important;
}
.et_slide_in_menu_container #mobile_menu_slide li a:hover {
    color: #cea479 !important;
    padding-left: 8px !important;
}

/* ========================================
   FIX: Footer
   ======================================== */
#main-footer { background-color: #000; }
#et-footer-nav { padding: 20px 0; }
.bottom-nav {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
}
.bottom-nav li { display: inline-block; }
.bottom-nav a, .bottom-nav li a {
    font-size: 13px;
    text-decoration: none;
}
#footer-bottom { padding: 10px 0; }

/* ========================================
   FIX: Cookie bar
   ======================================== */
#cookie-law-info-bar {
    position: fixed !important;
    bottom: 0;
    left: 0; right: 0;
    background: #fff;
    border-top: 1px solid #b1a6a6c2;
    padding: 15px 20px;
    z-index: 99999;
    font-size: 12px;
    text-align: center;
    display: none;
}
.cli-plugin-button {
    display: inline-block;
    padding: 6px 15px;
    margin: 0 5px;
    border-radius: 3px;
    font-size: 12px;
    text-decoration: none;
    cursor: pointer;
}
#cookie_action_close_header {
    background-color: #81d742;
    color: #fff;
}
.cli-modal { display: none; position: fixed; top:0;left:0;right:0;bottom:0; z-index:100000; align-items:center; justify-content:center; }
.cli-modal.cli-show { display: flex; }
.cli-modal-dialog { background:#fff; max-width:600px; width:90%; border-radius:5px; position:relative; z-index:100001; }
.cli-modal-content { padding: 30px; }
.cli-modal-close { position:absolute; top:10px; right:15px; background:none; border:none; font-size:24px; cursor:pointer; }
.cli-modal-backdrop { display:none; position:fixed; top:0;left:0;right:0;bottom:0; background:rgba(0,0,0,0.5); z-index:99999; }
.cli-modal.cli-show ~ .cli-modal-backdrop { display: block; }

/* ========================================
   FIX: Overflow hidden on body/html
   ======================================== */
html, body, section { overflow-x: hidden; }

/* ========================================
   RESPONSIVE
   ======================================== */
@media only screen and (max-width: 980px) {
    .et_pb_column_1_2,
    .et_pb_column_1_3,
    .et_pb_column_1_4,
    .et_pb_column_3_4,
    .et_pb_column_3_5,
    .et_pb_column_2_5 {
        width: 100% !important;
        margin-right: 0 !important;
        float: none !important;
    }
    .et_pb_gutters4 .et_pb_column_1_2,
    .et_pb_gutters4 .et_pb_column_1_4 {
        width: 100% !important;
        margin-right: 0 !important;
        float: none !important;
    }
    .et_pb_contact_field_half { width: 100%; float: none; }
    .container, .et_pb_row { width: 90%; }
}

@media only screen and (max-width: 767px) {
    .container, .et_pb_row { width: 95%; }
    .et_pb_with_border { padding: 15px; }
    .et_slide_in_menu_container { width: 280px !important; }
}
