/**
 * DTV Tema - Temel Layout CSS
 * Drupal 10 Tam Uyumlu Versiyon
 * D7 layout.css yapısı korunarak çevrildi
 */

/* ---------- Temel Layout Stilleri ----------- */

html,
body,
#page {
  height: 100%;
}

#page {
  max-width: 1200px;
  margin: 0 auto;
}

#page-wrapper {
  margin-left: auto;
  margin-right: auto;
}

#header div.section,
#featured div.section,
#messages div.section,
#main,
#triptych,
#footer-columns,
#footer {
  margin-left: auto;
  margin-right: auto;
}

#header div.section {
  position: relative;
}

.region-header {
  float: right;
  margin: 0 5px 10px;
}

.with-secondary-menu .region-header {
  margin-top: 15px;
}

.without-secondary-menu .region-header {
  margin-top: 15px;
}

#secondary-menu {
  position: absolute;
  right: 0;
  top: 0;
  width: 350px;
}

#content,
#sidebar-first,
#sidebar-second,
.region-triptych-first,
.region-triptych-middle,
.region-triptych-last,
.region-footer-firstcolumn,
.region-footer-secondcolumn,
.region-footer-thirdcolumn,
.region-footer-fourthcolumn {
  display: inline;
  float: left;
  position: relative;
}

/* D10'da sidebar durumlarına göre content genişliği */
.one-sidebar #content {
  /* Dinamik olarak flex ile hesaplanır */
}

.two-sidebars #content {
  width: 480px;
}

.no-sidebars #content {
  width: 100%;
  float: none;
}

#sidebar-first,
#sidebar-second {
  width: 210px;
}

#main-wrapper {
  min-height: 300px;
}

#content .section,
.sidebar .section {
  padding: 0 15px;
}

#breadcrumb {
  margin: 0 15px;
}

.region-triptych-first,
.region-triptych-middle,
.region-triptych-last {
  margin: 20px 20px 30px;
  width: 280px;
}

.region-footer-firstcolumn,
.region-footer-secondcolumn,
.region-footer-thirdcolumn,
.region-footer-fourthcolumn {
  padding: 0 10px;
  width: 220px;
}

/* D7 Header yapısı destek */
.header-all-wrapper {
  width: 100%;
}

.main-header {
  width: 100%;
  background: #fff;
  border-bottom: 1px solid #e5e5e5;
}

#header-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 30px;
  padding: 18px 0 0;
}

#header-top-left {
  flex: 0 0 auto;
}

#header-top-right {
  display: flex;
  flex: 1 1 auto;
  min-width: 0;
  flex-direction: column;
  align-items: flex-end;
  width: auto;
  text-align: right;
}

#header-right-top,
#header-right-bottom {
  width: 100%;
}

#header-right-top .region,
#header-right-bottom .region {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  width: 100%;
}

#header-right-top .block {
  float: none;
  margin: 0 0 0 18px;
}

#header-right-bottom {
  margin-top: 15px;
  padding-bottom: 0;
}

#header-bottom {
  clear: both;
}

/* Mobil menü */
.mobile-menu-wrapper {
  display: none;
}

/* Clearfix (Geriye Dönük Uyumluluk) */
.clearfix::after,
.container::after {
  content: "";
  display: table;
  clear: both;
}

/* Responsive (Mobil & Tablet) */
@media (max-width: 992px) {
  #main {
    flex-direction: column;
  }

  #sidebar-first,
  #sidebar-second {
    float: none;
    width: 100%;
    max-width: 100%;
  }

  #secondary-menu {
    position: static;
    width: 100%;
  }

  #header-top {
    flex-direction: column;
    align-items: stretch;
    gap: 15px;
    padding-top: 15px;
  }

  #header-top-left,
  #header-top-right {
    text-align: center;
    width: 100%;
  }

  #header-top-right,
  #header-right-top .region,
  #header-right-bottom .region {
    align-items: center;
  }

  #header-right-top .block {
    margin: 0 8px;
  }
}

@media (max-width: 480px) {
  #header-top {
    display: flex;
    flex-direction: column;
  }

  #main-menu-links {
    padding: 0;
    list-style: none;
  }

  #main-menu-links li {
    display: block;
  }

  #main-menu-links a {
    display: block;
    width: 100%;
    padding: 10px 0;
  }
}