/* ======================================================
   RUNHLP LEGACY MASTER CSS
   Átmeneti központi stílusfájl.
   FONTOS: új fejlesztés lehetőleg már ne ide kerüljön,
   hanem külön WPCode snippetbe.
   Refaktor státusz: migráció alatt.
====================================================== */

/******************************************************
 * RUNHLP — CLEAN & STABLE MASTER CSS (2026)
 * Cél:
 *  - Minden nem-home oldal: scroll ON
 *  - Csak a valóban globális alapstílusok maradjanak itt
 ******************************************************/

/* =============== 0) GLOBAL BASE =============== */
html,
body {
  margin: 0 !important;
  padding: 0 !important;
  width: 100%;
  overflow-x: hidden !important;
  padding-bottom: env(safe-area-inset-bottom, 0) !important;
}

/* Minden nem-home oldalon alapból legyen görgetés */
body:not(.home) {
  position: relative !important;
  height: auto !important;
  min-height: 100vh !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
}

/* Ha a theme belső wrapperrel vágna, oldjuk fel (nem-home) */
body:not(.home) .wp-site-blocks,
body:not(.home) main,
body:not(.home) .wp-block-group,
body:not(.home) .wp-block-cover,
body:not(.home) .entry-content,
body:not(.home) .wp-block-post-content {
  position: relative !important;
  height: auto !important;
  min-height: auto !important;
  max-height: none !important;
  overflow: visible !important;
  background: transparent !important;
}

/* Cover általános */
.wp-block-cover {
  position: relative !important;
  width: 100%;
  background-size: cover !important;
  background-position: center top !important;
  background-repeat: no-repeat !important;
  overflow: hidden !important;
}

/* ======================================================
   RUNHLP HOME FIX OVERRIDE
====================================================== */

/* 1) A főoldal legyen görgethető */
body.home,
body.page-id-2483,
body.page-template-homepage-full-width,
body.page-template-homepage-full-width .wp-site-blocks,
body.home .wp-site-blocks,
body.page-id-2483 .wp-site-blocks {
  position: relative !important;
  height: auto !important;
  min-height: 100vh !important;
  max-height: none !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
}

/* 2) A teljes főoldal kapja meg a háttérképet */
body.home,
body.page-id-2483,
body.page-template-homepage-full-width {
  background-color: #b84a27 !important;
  background-image:
    linear-gradient(rgba(196, 120, 60, 0.58), rgba(140, 55, 25, 0.58)),
    url("https://runhlp.com/wp-content/uploads/2025/10/chatgpt-image-2025.-okt.-29.-08_37_40-1.png") !important;
  background-size: cover !important;
  background-position: center top !important;
  background-repeat: no-repeat !important;
  background-attachment: scroll !important;
}

/* 3) A theme wrapper ne szorítsa össze a főoldalt */
body.home main,
body.home .entry-content,
body.home .wp-block-post-content,
body.home .wp-site-blocks,
body.page-id-2483 main,
body.page-id-2483 .entry-content,
body.page-id-2483 .wp-block-post-content,
body.page-id-2483 .wp-site-blocks,
body.page-template-homepage-full-width main,
body.page-template-homepage-full-width .entry-content,
body.page-template-homepage-full-width .wp-block-post-content,
body.page-template-homepage-full-width .wp-site-blocks {
  width: 100% !important;
  max-width: 100% !important;
  background: transparent !important;
}

/* 4) A hero blokk teljes szélességű legyen */
body.home .wp-block-cover,
body.page-id-2483 .wp-block-cover,
body.page-template-homepage-full-width .wp-block-cover {
  width: 100% !important;
  max-width: 100% !important;
  min-height: 100vh !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
  background-size: cover !important;
  background-position: center top !important;
  background-repeat: no-repeat !important;
  background-attachment: scroll !important;
}

/* 5) A cover belső tartalma legyen szélesebb */
body.home .wp-block-cover__inner-container,
body.page-id-2483 .wp-block-cover__inner-container,
body.page-template-homepage-full-width .wp-block-cover__inner-container {
  width: 100% !important;
  max-width: 1200px !important;
  margin: 0 auto !important;
  padding-left: 24px !important;
  padding-right: 24px !important;
  box-sizing: border-box !important;
}

/* 6) A szöveges blokkok mögött ne legyen fekete háttér */
body.home .wp-block-post-content > *:not(.wp-block-cover),
body.page-id-2483 .wp-block-post-content > *:not(.wp-block-cover),
body.page-template-homepage-full-width .wp-block-post-content > *:not(.wp-block-cover) {
  background: transparent !important;
}

/* 7) A főoldali tartalmi blokk ne kapjon külön fekete hátteret */
body.home .wp-block-post-content,
body.page-id-2483 .wp-block-post-content,
body.page-template-homepage-full-width .wp-block-post-content {
  background: transparent !important;
}

/* 8) A főoldali headline és szekciók maradjanak olvashatók */
body.home h1,
body.home h2,
body.home h3,
body.page-id-2483 h1,
body.page-id-2483 h2,
body.page-id-2483 h3,
body.page-template-homepage-full-width h1,
body.page-template-homepage-full-width h2,
body.page-template-homepage-full-width h3 {
  color: #ffffff !important;
}

body.home p,
body.page-id-2483 p,
body.page-template-homepage-full-width p {
  color: rgba(255, 255, 255, 0.92) !important;
}

/* 9) Mobil javítás */
@media (max-width: 782px) {
  body.home,
  body.page-id-2483,
  body.page-template-homepage-full-width,
  body.home .wp-site-blocks,
  body.page-id-2483 .wp-site-blocks,
  body.page-template-homepage-full-width .wp-site-blocks {
    height: auto !important;
    min-height: 100vh !important;
    overflow-y: auto !important;
  }

  body.home .wp-block-cover,
  body.page-id-2483 .wp-block-cover,
  body.page-template-homepage-full-width .wp-block-cover {
    min-height: 100vh !important;
  }

  body.home .wp-block-cover__inner-container,
  body.page-id-2483 .wp-block-cover__inner-container,
  body.page-template-homepage-full-width .wp-block-cover__inner-container {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }
}