/*
Theme Name: ÓE Téma
Theme URI: https://nagysmarton.hu
Author: Nagy Sándor Márton
Author URI: https://nagysmarton.hu
Description: Saját fejlesztésű téma - Bootstrap 5.3.7 használatával
Version: 1.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: obudai
*/

/* -------------------------------------------------------
   0) Alapok, betűkészlet
-------------------------------------------------------- */
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap');





/* Sticky footer layout */
html, body { height: 100%; }
body {
  min-height: 100svh;           /* modern mobilokon is pontos */
  display: flex;
  flex-direction: column;
}

.page-content {                 /* ez fog “nyúlni” */
  flex: 1 0 auto;
}

footer {                        /* a footer lecsúszik az aljára */
  margin-top: auto;
}



body { background: #f6f6f6; }
.page-content { background: #f6f6f6; }

h1, h2, h3 {
  font-family: "Open Sans", sans-serif;
  color: #1d294d;
  font-weight: 700;
}

.dark-blue-bg { background: #1d294d; }
.logo { width: 235px; }


.dropdown-menu{background-color:#1d294d !important;}
.dropdown-menu a{color:#fff !important; text-transform:uppercase;}
#mainMenu a {
	text-transform: uppercase;
	font-weight: 400;
	font-size: 13px;
	letter-spacing: 1px;
}


.page-content .container {
	background: #fff;
	margin-top: 40px;
	border-radius: 20px;
}

/* -------------------------------------------------------
   1) Navbar – színek és alap állapot
-------------------------------------------------------- */

.navbar-nav .nav-link { color: #fff; }
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus { color: #fff; opacity: .85; }

/* A dropdown panel mindig legyen a felső sor elemei felett */
.navbar .dropdown-menu {
  position: absolute;   /* desktop alap */
  overflow: visible;
  z-index: 2000;        /* elég magas, hogy a top-szint caretje se üljön rá */
}

/* -------------------------------------------------------
   2) TOP szintű dropdown (top1 → top2)
   Modern „rés-mentes” megjelenítés translate-tel
-------------------------------------------------------- */
.navbar-nav > .dropdown > .dropdown-menu {
  margin-top: 0;                  /* nincs negatív margin → nincs hover-rés */
  transform: translateY(-0.5rem); /* finom előtolás, animálható */
  opacity: 0;
  visibility: hidden;
  transition: transform .12s ease, opacity .12s ease, visibility 0s linear .12s;
}

/* Desktop: hoverre jelenjen meg, szépen csúszva */
@media (hover:hover) and (pointer:fine) {
  .navbar-nav > .dropdown:hover > .dropdown-menu {
    display: block;
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    transition: transform .12s ease, opacity .12s ease, visibility 0s;
  }
}

/* Mobil/JS: amikor a Bootstrap .show-t rak rá, ugyanaz a végállapot */
.navbar-nav > .dropdown > .dropdown-menu.show {
  display: block;
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
  transition: transform .12s ease, opacity .12s ease, visibility 0s;
}

/* -------------------------------------------------------
   3) 2–3. szint (oldalra nyíló submenu-k)
   – jobbra az alap, open-left esetén balra nyíljon
-------------------------------------------------------- */
.dropdown-submenu { position: relative; }

/* Jobbra nyíló (alap) */
.dropdown-submenu > .dropdown-menu {
  top: 0;
  left: 100%;
  margin: 0;
  transform: translateX(.25rem);  /* kis „párna”, rés nélkül */
  opacity: 0;
  visibility: hidden;
  transition: transform .12s ease, opacity .12s ease, visibility 0s linear .12s;
}

/* Balra nyíló (ha a <li> kapja: open-left) */
.dropdown-submenu.open-left > .dropdown-menu {
  left: auto;
  right: 100%;
  transform: translateX(-.25rem);
}

/* Desktop: hoverre mutassuk az alszintet */
@media (hover:hover) and (pointer:fine) {
  .dropdown-submenu:hover > .dropdown-menu {
    display: block;
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
    transition: transform .12s ease, opacity .12s ease, visibility 0s;
  }
}

/* Mobil/JS: .show esetén látszódjon (akár 2., akár 3. szint) */
.dropdown-submenu > .dropdown-menu.show,
.dropdown-submenu.open-left > .dropdown-menu.show {
  display: block;
  transform: translateX(0);
  opacity: 1;
  visibility: visible;
  transition: transform .12s ease, opacity .12s ease, visibility 0s;
}

/* -------------------------------------------------------
   4) Ikonok / caretek a belső (2–3. szintű) toggle-okon
   – Desktop: oldalra mutató nyilak (› / ‹)
   – Mobil: lenyitás/felnyitás (▾ / ▴)
-------------------------------------------------------- */

/* Bootstrap caret „lenullázása” a belső toggle-okon:
   - ne maradjanak háromszög-borderok / marginok
   - NEM használunk !important-et, hogy a saját szabályaink felülírhassák
*/
.dropdown-menu .dropdown-item.dropdown-toggle::after {
  border: 0;
  margin-left: 0;
  vertical-align: middle;

  /* Saját ikon pozicionálása */
  position: absolute;
  right: .75rem;
  top: 50%;
  transform: translateY(-50%);
  float: none;
  opacity: .6;

  /* a content-et lent, desktop/mobil media query-kben állítjuk */
}

/* Desktopon oldalirányú nyilak: jobbra az alap, open-left esetén balra */
@media (hover:hover) and (pointer:fine) {
  .dropdown-menu .dropdown-item.dropdown-toggle::after { content: "›"; }
  .dropdown-submenu.open-left > a.dropdown-toggle::after { content: "‹"; }
}

/* Mobilon fel/le nyilak: zárt → ▾, nyitott → ▴ */
@media (max-width: 991.98px) {
  .dropdown-menu .dropdown-item.dropdown-toggle::after { content: "▾"; }
  .dropdown-menu .dropdown-item.dropdown-toggle[aria-expanded="true"]::after { content: "▴"; }
}

/* -------------------------------------------------------
   5) Mobil / tablet (lg alatt): stackelt submenu-k
   – minden submenu egymás alatt jelenik meg, nem oldalra
-------------------------------------------------------- */
@media (max-width: 991.98px) {
  /* A collapse-en belül statikus elrendezés – ne legyen absolute/float */
  .navbar .dropdown-menu {
    position: static;
    float: none;
    transform: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    margin: 0;
    display: none;            /* alap: rejtve */
    border: 0;                /* opcionális vizuális tisztítás */
    box-shadow: none;         /* opcionális */
    width: 100%;              /* szépen törjön a szélesség */
  }

  /* .show állapotban látszódjon */
  .navbar .dropdown-menu.show { display: block; }

  /* A 2–3. szint már ne próbáljon oldalra nyílni mobilon */
  .dropdown-submenu > .dropdown-menu,
  .dropdown-submenu.open-left > .dropdown-menu {
    left: 0 !important;
    right: auto !important;
  }

  /* Hierarchia jelölése: beljebb húzás */
  .dropdown-menu .dropdown-item { padding-left: 1.25rem; }
  .dropdown-menu .dropdown-menu .dropdown-item { padding-left: 2rem; }

  /* Hosszú listák: ne lógjon ki a viewportból (opcionális) */
  .navbar .dropdown-menu.show {
    max-height: 70vh;
    overflow-y: auto;
  }
}

.mb-5 {
	padding-top: 15px;
	margin-bottom: 1rem !important;
}

.wp-block-post-featured-image img {
    max-width: 100%;
    height: auto;
	aspect-ratio: 16/9;
	object-fit: cover;
	object-position: center;
}

.searchandfilter { 
  display:flex; 
  flex-wrap:wrap; 
  align-items:center; 
  gap:12px; 
  padding:12px 16px; 
  border-radius:6px;
}
.searchandfilter li { 
  display:flex; 
  align-items:center; 
  margin:0 !important; 
  gap:8px;
}
.searchandfilter label { 
  margin:0; 
  font-weight:600;
}
.searchandfilter select,
.searchandfilter .sf-input-select select,
.searchandfilter .select2-container { 
  min-width:240px; 
  max-width:320px;
}
.searchandfilter .sf-field-submit input[type="submit"] {
  margin:0;
}

@media (max-width: 768px){
  .searchandfilter { gap:8px; }
  .searchandfilter select,
  .searchandfilter .sf-input-select select,
  .searchandfilter .select2-container { 
    min-width:180px; 
    max-width:90%;
  }
}

.dropdown-item:hover,
.dropdown-item:focus,
.dropdown-item:active {
  background-color: #98cfee;
  color: #fff;
}

.wp-block-post-excerpt__excerpt { 
  margin-top: 15px;
  margin-bottom: 15px;
}

img.wp-image-2606 {
  max-width: 60% !important;
  height: auto !important;
}

img.wp-image-2609 {
  max-width: 60% !important;
  height: auto !important;
}

.searchandfilter{
  display:flex;
  flex-wrap:nowrap;
  align-items:flex-end;
  gap:16px;
}
.searchandfilter li{ margin:0 !important; }
.searchandfilter label{ margin:0; font-weight:600; }
.searchandfilter select,
.searchandfilter .sf-input-select select,
.searchandfilter .select2-container{
  min-width:240px;
  max-width:320px;
}

@media (max-width: 767.98px){
  .searchandfilter{
    flex-wrap:wrap;
    justify-content:center;
    align-items:center;
    gap:10px 12px;
  }
  .searchandfilter > ul,
  .searchandfilter li{
    width:100%;
  }
  .searchandfilter label{ width:100%; }
  .searchandfilter select,
  .searchandfilter .sf-input-select select,
  .searchandfilter .select2-container{
    min-width:0;
    max-width:100%;
    width:100%;
  }
  .searchandfilter .sf-field-submit input[type="submit"]{
    width:auto;
    padding:.4rem .9rem;
  }
}

.project-logos{ margin-left:auto; margin-right:auto; }

@media (max-width: 575.98px){
  .project-logos .col-md-3{ flex:0 0 100%; max-width:100%; }
}

@media (min-width: 576px) and (max-width: 991.98px){
  .project-logos .col-md-3{ flex:0 0 50%; max-width:50%; }
}

@media (min-width: 992px){
  .project-logos .col-md-3{ flex:0 0 25%; max-width:25%; margin-bottom: 10px; margin-top: 10px; }
}

.logo-tile{
  display:flex;
  align-items:center;
  justify-content:center;
  height:120px;
  background:#fff;
  border-radius:12px;
  box-shadow:0 1px 4px rgba(0,0,0,.05);
  margin-bottom:25px;
  margin-top:25px;
}
.logo-tile img{
  width:100%;
  max-width:160px;
  height:auto;
  object-fit:contain;
}

@media (max-width: 575.98px){
  .logo-tile{ height:100px; margin-bottom:12px; }
  .logo-tile img{ max-width:40%; }
}

.project-panel{
  max-width:820px;
  margin:0 auto 1.5rem;
}
.project-header{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}
.project-header h2{ margin:0; }
.project-header .btn-readmore-top{ padding:.35rem .9rem; }

footer a,
footer a:visited {
  color: #98cfee !important;
  text-decoration: none;
}

footer a:hover,
footer a:focus {
  color: #55a2cc !important;
  text-decoration: underline;
}