/* =====================================================================
   responsive.css — mobile-first responsive layer for IRTESH.
   Loaded LAST so it corrects issues introduced by the full-width /
   de-Elementor / restyle changes. Written mobile-first: the base rules
   target small phones, then min-width media queries scale up to tablet
   and desktop. The hero is kept but made to fit the viewport.
   ===================================================================== */

/* ---------------------------------------------------------------------
   -1. Sticky (scrolled) header: force LIGHT theme — white background with the
   DARK logo (logo-dark.png) and DARK nav links. The theme intends this but the
   white background wasn't winning, so we enforce it here.
   --------------------------------------------------------------------- */
.stick.masthead-container,
.header-sticky-wrapper .masthead-container,
body .stick .site-header,
body .stick.masthead-container {
  background-color: #ffffff !important;
  border-bottom: 2px solid #0929ca;
}
/* dark nav links on the white sticky bar */
.stick .main-navigation ul.menu > li > a,
.stick.masthead-container .main-navigation ul li a,
.header-sticky-wrapper .masthead-container .main-navigation ul li a {
  color: #111111 !important;
}
.stick .main-navigation ul.menu > li > a:hover,
.stick .main-navigation ul.menu > li.current-menu-item > a,
.stick .main-navigation ul.menu > li.current > a {
  color: #0929ca !important;
}
/* show the DARK logo, hide the light one, when sticky */
.stick .site-branding a.dark-logo,
.stick.masthead-container .site-branding a.dark-logo {
  display: table-cell !important;
}
.stick .site-branding a.light-logo,
.stick.masthead-container .site-branding a.light-logo {
  display: none !important;
}
/* search icon + separators dark on the white bar */
.stick .search-box .search-button i,
.stick .header-icon-seperator,
.stick .header-icon-area .cart-icon-area > a { color: #111111 !important; }

/* ---------------------------------------------------------------------
   0. Global guards — never let anything cause horizontal scroll
   --------------------------------------------------------------------- */
html, body {
  max-width: 100%;
  overflow-x: hidden;
}
.site-wrp img,
.site-wrp iframe,
.site-wrp .ls-wp-container {
  max-width: 100%;
}

/* ---------------------------------------------------------------------
   1. Hero LayerSlider — DESKTOP IS LEFT UNTOUCHED (the slider works there).
   On tablet/phone the LayerSlider JS forces a fixed pixel width + negative
   margin that overflows the viewport and breaks the whole layout + header.
   So on <=1024px we HIDE the real slider and show a responsive CSS banner
   with a caption instead. All of this is scoped inside the media query so
   desktop keeps the original LayerSlider exactly as before.
   --------------------------------------------------------------------- */
@media (max-width: 1024px) {
  /* hide the real (overflowing) slider content */
  .site-wrp .ls-inner,
  .site-wrp .ls-fullscreen-wrapper > .ls-container > *,
  .site-wrp [id^="layerslider_"] > .ls-inner { display: none !important; }

  /* turn the slider container into a responsive banner */
  .site-wrp .ls-wp-container,
  .site-wrp [id^="layerslider_"],
  .site-wrp .ls-fullscreen-wrapper {
    width: 100% !important;
    max-width: 100vw !important;
    min-height: 380px;
    height: 380px !important;
    margin: 0 !important;
    left: 0 !important;
    overflow: hidden !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    background-image: linear-gradient(rgba(9,41,202,0.35), rgba(9,41,202,0.35)),
      url("https://images.unsplash.com/photo-1540575467063-178a50c2df87?crop=entropy&fit=crop&w=1920&h=931&q=75");
    background-size: cover;
    background-position: center;
  }
  /* Banner caption — mirrors the desktop hero content so mobile feels
     consistent: event title + date/venue line. */
  .site-wrp .ls-wp-container::after {
    content: "Keynote Conferencee 2022 \A 17 \2013 25 October \00b7 King Hussein Hall, Amman";
    white-space: pre-line;
    color: #fff;
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    font-size: 27px;
    line-height: 1.28;
    text-align: center;
    padding: 0 22px;
    text-shadow: 0 2px 14px rgba(0,0,0,0.55);
    letter-spacing: -0.3px;
  }
  /* also clip the hero section wrappers so nothing leaks past the viewport */
  .el-4a05c06c,
  .el-4a05c06c .container-inner,
  .el-4a05c06c .col,
  .el-4a05c06c .col-inner,
  .el-4a05c06c .widget,
  .el-4a05c06c .widget-inner,
  .el-4a05c06c .single-sidebar {
    overflow: hidden !important;
    max-width: 100vw !important;
  }
}
@media (max-width: 767px) {
  .site-wrp .ls-wp-container,
  .site-wrp [id^="layerslider_"],
  .site-wrp .ls-fullscreen-wrapper { min-height: 320px; height: 320px !important; }
  .site-wrp .ls-wp-container::after { font-size: 22px; }
}

/* ---------------------------------------------------------------------
   1b. Header: deterministic mobile menu. Below 1100px show the mobile bar
   (with hamburger) and hide the desktop nav; above, the reverse. This does
   not rely on the meanmenu JS timing, so the hamburger is always present.
   --------------------------------------------------------------------- */
/* The theme's original mobile-menu CSS was missing from the captured files, so
   the mobile bar (.mean-bar) + hamburger (.sidebarBtn) + off-canvas nav
   (.rt-slide-nav) are styled here from scratch. main.js already toggles them:
   clicking .sidebarBtn slides .rt-slide-nav in/out. */
@media (min-width: 1100px) {
  .rt-header-menu.mean-container { display: none !important; }
  .site-header .masthead-container { display: block !important; }
}
@media (max-width: 1099px) {
  /* hide desktop header, show the theme's own mobile bar. The theme already
     styles .mean-bar / .sidebarBtn (absolute, right:15px) and .rt-slide-nav, so
     we only need to reveal the bar and make the hamburger clearly visible. */
  .site-header .masthead-container { display: none !important; }
  .rt-header-menu.mean-container {
    display: block !important;
    position: relative;
    z-index: 1000;
    width: 100%;
    max-width: 100vw;
    background: #ffffff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.10);
    min-height: 64px;
  }
  /* the bar itself is the positioning context for the absolute hamburger */
  .rt-header-menu .mean-bar {
    position: relative;
    width: 100%;
    max-width: 100vw;
    min-height: 64px;
  }
  /* the off-canvas panel must never widen the bar / push the button off-screen */
  .rt-header-menu .rt-slide-nav {
    width: 100% !important;
    max-width: 100vw !important;
    box-sizing: border-box;
    padding: 20px !important;
  }
  .rt-header-menu .rt-slide-nav ul,
  .rt-header-menu .rt-slide-nav nav { max-width: 100%; }
  /* The mobile bar can compute wider than the viewport (off-canvas content),
     which pushed the absolutely-positioned hamburger off-screen below 480px.
     Pin it to the viewport with high-specificity + fixed positioning so it is
     always at the top-right, whatever the container width. */
  body .rt-header-menu#meanmenu .mean-bar .sidebarBtn,
  html body .rt-header-menu .mean-bar .sidebarBtn {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    opacity: 1 !important;
    visibility: visible !important;
    position: fixed !important;
    top: 9px !important;
    right: 14px !important;
    left: auto !important;
    bottom: auto !important;
    width: 46px !important;
    height: 46px !important;
    border-radius: 8px !important;
    background: #0929ca !important;
    color: #ffffff !important;
    z-index: 2147483000 !important;
  }
  .rt-header-menu .mean-bar .sidebarBtn * {
    color: #ffffff !important;
    font-size: 22px !important;
    line-height: 46px !important;
  }
  .header-action-items.mobile-button-area { z-index: 5; }
  /* readable off-canvas nav links (theme panel is white) */
  .rt-slide-nav .offscreen-navigation ul li a {
    display: block;
    padding: 12px 6px;
    color: #111;
    text-decoration: none;
    border-bottom: 1px solid rgba(0,0,0,0.06);
  }
  .rt-slide-nav .offscreen-navigation ul li a:hover { color: #0929ca; }
  .rt-slide-nav .offscreen-navigation ul ul li a { padding-left: 22px; font-size: 14px; }
}

/* =====================================================================
   MOBILE-FIRST BASE  (applies to all sizes; overridden upward)
   ===================================================================== */

/* --- Sections stack cleanly; kill the flex row on small screens so
       columns become full-width blocks (prevents the overlap). --- */
.content-area .section > .container-inner {
  flex-direction: column;
  max-width: 100% !important;
  padding-left: 16px;
  padding-right: 16px;
}
.content-area .col,
.content-area .col-33,
.content-area .col-100 {
  width: 100% !important;
  flex: 0 0 100% !important;
  max-width: 100% !important;
}

/* --- Comfortable vertical padding on phones (theme used ~100px). Exclude the
       full-bleed banners (hero / countdown / map) so they stay flush. --- */
.content-area .section:not(.el-4a05c06c):not(.el-56941cdd):not(.el-24432544) > .container-inner {
  padding-top: 40px;
  padding-bottom: 40px;
}
.content-area .el-4a05c06c > .container-inner {
  padding: 0 !important;   /* hero fills behind the transparent header */
}

/* --- Fluid headings on phones --- */
.content-area h1 { font-size: 30px !important; line-height: 1.2 !important; }
.content-area h2,
.content-area .rtin-title { font-size: 26px !important; line-height: 1.25 !important; }
.content-area h3 { font-size: 20px !important; }
.content-area .rtin-subtitle,
.content-area .rtin-subtitle p { font-size: 15px !important; }

/* --- Speaker grid: 1 per row on small phones (theme cols too tight) --- */
.content-area .rt-el-team-slider-4 .rtin-item {
  width: 100%;
  max-width: 320px;
  margin-left: auto;
  margin-right: auto;
}

/* --- Info box items stack and center --- */
.content-area .rt-el-info-box.rtin-style1 {
  text-align: center;
  margin-bottom: 22px;
}

/* --- Blog cards: full width stacked --- */
.content-area .rt-el-blgo-post .blog-posts { margin-bottom: 22px; }

/* --- Schedule: allow horizontal scroll of the table instead of overlap --- */
.content-area .schedule-layout-wrp .table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.content-area .schedule-layout1 { min-width: 640px; }

/* --- Newsletter: stack input + button on phones --- */
.content-area .subscribe-layout1 .input-group {
  flex-direction: column;
}
.content-area .subscribe-layout1 .form-control {
  border-radius: 10px !important;
  width: 100%;
  margin-bottom: 10px;
}
.content-area .subscribe-layout1 .input-group-addon,
.content-area .subscribe-layout1 .input-group-addon .btn-fill {
  border-radius: 10px !important;
  width: 100%;
}

/* --- Google map: shorter on phones --- */
.content-area .el-7e8ad2e iframe,
.widget-texteditor iframe[src*="google.com/maps"] {
  height: 360px !important;
}

/* --- Footer social: wrap + center --- */
footer .footer-social ul {
  flex-wrap: wrap;
  justify-content: center;
}

/* =====================================================================
   >= 576px  (large phones landscape / small tablets)
   ===================================================================== */
@media (min-width: 576px) {
  .content-area h1 { font-size: 36px !important; }
  .content-area h2,
  .content-area .rtin-title { font-size: 30px !important; }
  /* speakers 2 per row */
  .content-area .rt-el-team-slider-4 .rtin-item {
    width: 50%;
    max-width: none;
  }
  /* newsletter back to inline */
  .content-area .subscribe-layout1 .input-group { flex-direction: row; }
  .content-area .subscribe-layout1 .form-control {
    border-radius: 10px 0 0 10px !important;
    width: auto; margin-bottom: 0;
  }
  .content-area .subscribe-layout1 .input-group-addon,
  .content-area .subscribe-layout1 .input-group-addon .btn-fill {
    border-radius: 0 10px 10px 0 !important; width: auto;
  }
}

/* =====================================================================
   >= 768px  (tablet portrait)
   ===================================================================== */
@media (min-width: 768px) {
  .content-area .section:not(.el-4a05c06c):not(.el-56941cdd):not(.el-24432544) > .container-inner {
    padding-top: 64px;
    padding-bottom: 64px;
  }
  .content-area h2,
  .content-area .rtin-title { font-size: 34px !important; }
  /* info-box 3 across again */
  .content-area .el-bc8b1ca .col-33 {
    width: 33.333% !important;
    flex: 0 0 33.333% !important;
  }
  .content-area .rt-el-info-box.rtin-style1 { text-align: left; }
  /* schedule table fits, no forced scroll */
  .content-area .schedule-layout1 { min-width: 0; }
}

/* =====================================================================
   >= 1025px  (tablet landscape / small desktop) — restore rows
   ===================================================================== */
@media (min-width: 1025px) {
  .content-area .section > .container-inner {
    flex-direction: row;
  }
  /* Content sections get generous padding, but NOT the full-bleed banners
     (hero / countdown / map) — the hero especially must have 0 top padding so
     the slider fills behind the transparent header (no white gap). */
  .content-area .section:not(.el-4a05c06c):not(.el-56941cdd):not(.el-24432544) > .container-inner {
    padding-top: 80px;
    padding-bottom: 80px;
  }
  .content-area .el-4a05c06c > .container-inner {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
  }
  /* speakers 4 per row (theme default) */
  .content-area .rt-el-team-slider-4 .rtin-item { width: 25%; }
  .content-area h1 { font-size: 46px !important; }
  .content-area h2,
  .content-area .rtin-title { font-size: 36px !important; }
}

/* =====================================================================
   >= 1200px  (desktop) — content centered at comfortable max-width
   (matches the earlier "centered content, full-bleed bg" behaviour)
   ===================================================================== */
@media (min-width: 1200px) {
  .content-area .section:not(.el-4a05c06c):not(.el-56941cdd):not(.el-24432544) > .container-inner {
    max-width: 1240px !important;
    padding-left: 15px;
    padding-right: 15px;
  }
}
