/*
Theme Name:   Keana Theme
Theme URI:    https://keana.mv
Description:  Keana Liveaboard – Divi Child Theme
Author:       Keana
Author URI:   https://keana.com
Template:     Divi
Version:      1.0.0
License:      GNU General Public License v2 or later
License URI:  https://www.gnu.org/licenses/gpl-2.0.html
Text Domain:  keana-theme
*/

/* Logo: weiß auf transparentem Header, original wenn gescrollt */
html body .et-l--header .et_pb_text img {
  filter: brightness(0) invert(1);
  transition: filter 0.3s ease, max-width 0.3s ease, max-height 0.3s ease;
}
html body.header-scrolled .et-l--header .et_pb_text img {
  filter: none;
  max-width: 160px !important;
  max-height: 70px !important;
}

html body .et_pb_menu_0_tb_header {
    padding-top: 25px;
}

/* Route Einzelseite – Beitragsbild fullwidth, 50vh hoch */
.single-route .et_pb_title_featured_container {
  width: 100% !important;
  height: 65vh !important;
  overflow: hidden !important;
}
.single-route .et_pb_title_featured_container .et_pb_image_wrap {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
}
.single-route .et_pb_title_featured_container .et_pb_image_wrap img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center !important;
  max-width: none !important;
}

.roundedshaded img {
  border-radius: 20px;
  box-shadow: rgba(0, 0, 0, 0.4) 8px 8px 20px;
}

/* Mobile: Row horizontal halten, Hamburger oben rechts */
@media (max-width: 980px) {
  html body .et-l--header .et_pb_row {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    flex-wrap: nowrap !important;
  }

  html body .et_pb_menu_0_tb_header {
    padding-top: 15px;
}
  html body .et-l--header .et_pb_row > .et_pb_column:first-child {
    flex: 0 0 auto !important;
    width: auto !important;
  }
  html body .et-l--header .et_pb_row > .et_pb_column:last-child {
    flex: 1 1 auto !important;
    width: auto !important;
    display: flex !important;
    justify-content: flex-end !important;
    align-items: flex-start !important;
  }
  html body .et-l--header .et_pb_menu_0_tb_header {
    margin-top: -25px !important;
  }
  html body .et-l--header .et_pb_row {
    padding-top: 20px !important;
    padding-bottom: 0px !important;
  }
  html body .et-l--header .et_pb_text img {
    max-height: 50px !important;
  }
  html body .et-l--header .et_pb_sticky--top {
    z-index: 1001 !important;
  }

  .et_pb_row .et_pb_column.et_pb_column_1_4 {
        width: 100%;
        margin: 0 0 15px;
    }

  /* Hamburger: weiß auf transparentem Header, dunkel wenn gescrollt */
  html body .et-l--header .mobile_menu_bar::before {
    color: #ffffff !important;
  }
  html body .et-l--header .et_pb_menu__hamburger span {
    background-color: #ffffff !important;
  }
  html body.header-scrolled .et-l--header .mobile_menu_bar::before {
    color: #003049 !important;
  }
  html body.header-scrolled .et-l--header .et_pb_menu__hamburger span {
    background-color: #003049 !important;
  }
  html body .et-l--header .et_mobile_menu {
    position: fixed !important;
    top: 85px !important;
    left: 0 !important;
    right: 0 !important;
    width: 100vw !important;
    box-sizing: border-box !important;
    z-index: 1000 !important;
  }
  /* Divi TB setzt background:#003049 !important → höhere Spezifität nötig */
  html body .et-l--header .et_pb_menu_0_tb_header.et_pb_menu .et_mobile_menu,
  html body .et-l--header .et_pb_menu_0_tb_header.et_pb_menu .et_mobile_menu ul {
    background-color: #ffffff !important;
  }
  html body .et-l--header .et_pb_menu_0_tb_header.et_pb_menu .et_mobile_menu li a,
  html body .et-l--header .et_pb_menu_0_tb_header.et_pb_menu .et_mobile_menu li a:hover,
  html body .et-l--header .et_pb_menu_0_tb_header.et_pb_menu .et_mobile_menu li span {
    color: #003049 !important;
    background-color: transparent !important;
  }
}

/* Dezente verlaufende Unterstreichung – Klasse "heading-rule" */
.heading-rule h1,
.heading-rule h2,
.heading-rule h3 {
  position: relative;
  padding-bottom: 0.6em;
}

.heading-rule h1::after,
.heading-rule h2::after,
.heading-rule h3::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent 0%,
    currentColor 35%,
    currentColor 65%,
    transparent 100%
  );
  opacity: 0.35;
}

/* Submenü-Links immer dunkel – Hintergrund ist weiß, unabhängig vom Header-Zustand */
html body .et-l--header .et_pb_menu .et-menu li ul.sub-menu a {
  color: #003049 !important;
}

/* Dropdown per CSS :hover zeigen – Divi's et-hover JS-Klasse wird im sticky-Zustand nicht gesetzt */
html body .et-l--header .et_pb_menu .et-menu > li.menu-item-has-children:hover > ul.sub-menu {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  transform: none !important;
}

/* Dropdown-Fix: Divi setzt overflow:hidden auf sticky Section/Row → Dropdown wird abgeschnitten */
html body .et-l--header .et_pb_section_0_tb_header,
html body .et-l--header .et_pb_section_0_tb_header .et_pb_row,
html body .et-l--header .et_pb_section_0_tb_header .et_pb_column {
  overflow: visible !important;
}

/* pointer-events fix: Divi setzt u.U. pointer-events:none auf sticky-Elemente */
html body .et-l--header .et_pb_section_0_tb_header .et_pb_row,
html body .et-l--header .et_pb_section_0_tb_header .et_pb_column,
html body .et-l--header .et_pb_section_0_tb_header .et_pb_menu,
html body .et-l--header .et_pb_section_0_tb_header .et_pb_menu * {
  pointer-events: auto !important;
}

/* z-index des sticky Headers sicherstellen */
html body .et-l--header .et_pb_section_0_tb_header.et_pb_sticky {
  z-index: 1000 !important;
}

/* Header immer fixed halten – auch wenn Divi et_pb_sticky entfernt */
html body .et-l--header > .et_builder_inner_content .et_pb_section.et_pb_section_0_tb_header:not(.et_pb_sticky) {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  z-index: 999 !important;
}

/* Transparent – mit und ohne et_pb_sticky */
html body .et-l--header > .et_builder_inner_content .et_pb_section.et_pb_section_0_tb_header.et_pb_sticky,
html body .et-l--header > .et_builder_inner_content .et_pb_section.et_pb_section_0_tb_header:not(.et_pb_sticky) {
  background-color: transparent !important;
  background: transparent !important;
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

/* Weiß beim Scrollen – mit und ohne et_pb_sticky */
html body.header-scrolled .et-l--header > .et_builder_inner_content .et_pb_section.et_pb_section_0_tb_header.et_pb_sticky,
html body.header-scrolled .et-l--header > .et_builder_inner_content .et_pb_section.et_pb_section_0_tb_header:not(.et_pb_sticky) {
  background-color: #ffffff !important;
  background: #ffffff !important;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.sa-widget-row .sa-line {
    flex: 1;
    height: 1px;
}
.sa-widget-row .sa-line:first-child {
    background: linear-gradient(to right, transparent, rgba(255,255,255,0.4));
}
.sa-widget-row .sa-line:last-child {
    background: linear-gradient(to left, transparent, rgba(255,255,255,0.4));
}
@media (max-width: 700px) {
    .sa-widget-row .sa-line { display: none; }
}

/* ── Unsere Schiffe: Image Hover-Lift ─────────────────────────── */
.ships-section .et_pb_image {
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}
.ships-section .et_pb_image:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.14);
}
.ships-section .et_pb_image_wrap img {
    display: block;
    transition: transform 0.45s ease;
}
.ships-section .et_pb_image:hover .et_pb_image_wrap img {
    transform: scale(1.03);
}

/* ── keana_badge Shortcode ─────────────────────────────────────── */

/* Text-Modul mit dieser Klasse schwebt absolut über dem Hero, ohne Höhe zu belegen */
.keana-badges-float {
    position: absolute !important;
    top: 50% !important;
    bottom: auto !important;
    right: 2% !important;
    left: auto !important;
    width: auto !important;
    transform: translateY(-50%);
    z-index: 10;
    margin: 0 !important;
}
.keana-badges-float .et_pb_module_inner {
    padding: 0 !important;
}

/* Auf kleinen Bildschirmen ausblenden – sonst überlagern die Badges den Haupt-Content */
@media (max-width: 980px) {
    .keana-badges-float {
        display: none !important;
    }
}


.keana-badge {
    position: relative;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 115px;
    height: 115px;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.30);
    border-radius: 50%;
    padding: 12px;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.25;
    white-space: normal;
    text-align: center;
    text-shadow: 0 1px 3px rgba(0,0,0,0.35);
    margin: 6px;
    overflow: hidden;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.45),
        inset 0 -1px 0 rgba(0,0,0,0.12),
        0 4px 14px rgba(0,0,0,0.25),
        0 1px 3px rgba(0,0,0,0.18);
    vertical-align: top;
}

/* 3D-Glanz: helles Highlight oben, dunkler Abschluss unten */
.keana-badge::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(
        to bottom,
        rgba(255,255,255,0.30) 0%,
        rgba(255,255,255,0.05) 45%,
        rgba(0,0,0,0.08) 100%
    );
    pointer-events: none;
}

.keana-badge svg {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.5;
    position: relative;
}

.keana-badge span {
    position: relative;
}

@media (max-width: 640px) {
    .keana-badge {
        width: 95px;
        height: 95px;
        font-size: 0.7rem;
    }
    .keana-badge svg {
        width: 26px;
        height: 26px;
    }
}
