html, body { overflow-x: hidden; }

:root {
  --tf-page-bg: #dddddd;
  --tf-nav-bg: #0a0b0f;
  --tf-nav-text: #ffffff;
  --tf-nav-active: #61b92f;
  --tf-title: #2e425c;
  --tf-body-text: #1f2b3a;
  --tf-container-bg: #ffffff;
}

body {
  background: var(--tf-page-bg) !important;
  color: var(--tf-body-text);
}

.site-header.default-style.site-header-custom {
  background: var(--tf-container-bg) !important;
}

.site-header.default-style {
  background: var(--tf-container-bg) !important;
}

#masthead.site-header-custom {
  background: var(--tf-container-bg) !important;
}

.site-header.default-style.site-header-custom .container,
.site-header.default-style.site-header-custom .site-branding {
  background: transparent !important;
}

.site-header-custom .header-top {
  background: var(--tf-container-bg) !important;
  padding: 26px 0 20px;
}

.site-header-custom .header-top,
.site-header-custom .header-top > .container,
.site-header-custom .header-top .site-branding,
.site-header-custom .header-top .site-logo-image,
.site-header-custom .header-top .custom-logo-link {
  background-color: var(--tf-container-bg) !important;
}

.site-header-custom .header-top .container {
  display: flex;
  justify-content: flex-start;
}

.site-header-custom .site-logo-image {
  border-bottom: none;
  padding-bottom: 10px;
  width: 220px;
}

.site-header-custom .custom-logo {
  width: 190px;
  height: auto;
}

.site-header-custom .header-nav {
  background: var(--tf-nav-bg) !important;
}

.site-header-custom .header-nav .container {
  display: flex;
  background: var(--tf-nav-bg) !important;
}

.site-header.default-style .main-navigation,
.site-header-custom .main-navigation,
.site-header.default-style .main-navigation ul,
.site-header-custom .main-navigation ul {
  background: var(--tf-nav-bg) !important;
}

.nav-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--tf-nav-bg) !important;
}

.menu-toggle {
  display: none;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 3px;
  margin: 5px auto;
  border-radius: 999px;
  background: #ffffff;
  transition: transform .18s ease, opacity .18s ease;
}

.main-navigation .menu {
  display: flex;
  align-items: center;
  gap: 0;
  margin: 0;
  padding: 0 0 0 46px;
}

.main-navigation .menu > li {
  position: relative;
  list-style: none;
}

.main-navigation .menu > li > a {
  display: block;
  padding: 16px 18px;
  text-transform: uppercase;
  font-family: "Source Sans Pro", Graphik, -apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif;
  font-size: 18px;
  font-weight: 600;
  line-height: 50px;
  padding: 0 16px;
  color: var(--tf-nav-text) !important;
  letter-spacing: .02em;
}

.main-navigation .menu > li > a:hover,
.main-navigation .menu > li.current-menu-item > a {
  color: var(--tf-nav-active) !important;
}

.main-navigation .sub-menu {
  position: absolute;
  top: calc(100% - 1px);
  left: 0;
  min-width: 270px;
  background: #333333 !important;
  border: 1px solid #3f3f3f !important;
  display: none;
  z-index: 99999;
  padding: 0 !important;
  box-sizing: border-box;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.site-header.default-style .main-navigation ul ul {
  padding: 0 !important;
  margin: 0 !important;
  background: #333333 !important;
}

.site-header.default-style .main-navigation ul ul li {
  float: none;
  width: 100%;
}

.site-header.default-style .main-navigation ul ul li a {
  display: block !important;
  width: 100% !important;
  box-sizing: border-box;
  padding: 12px 16px !important;
  line-height: 1.3 !important;
  text-transform: none;
  background: transparent !important;
}

.main-navigation .menu-item-has-children:hover .sub-menu,
.main-navigation .menu-item-has-children:focus-within .sub-menu,
.main-navigation .sub-menu:hover {
  display: block;
}

.main-navigation .sub-menu li {
  list-style: none;
}

.main-navigation .sub-menu li a {
  white-space: nowrap;
  padding: 12px 16px;
  display: block;
  color: #eeeeee !important;
  font-size: 16px;
  line-height: 1.3;
  background: transparent !important;
  width: 100% !important;
  box-sizing: border-box;
}

#content.site-content {
  padding: 42px 0 60px;
}

#content .container {
  max-width: 1200px;
}

#primary.content-area {
  float: none;
  width: 100%;
}

.site-main article {
  background: var(--tf-container-bg) !important;
  max-width: 930px;
  margin: 0 auto;
  padding: 44px 44px 60px;
  border: 1px solid #d2d2d2;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.page-entry-title {
  margin-bottom: 30px;
  color: var(--tf-title) !important;
  font-size: 52px;
  line-height: 1.15;
  font-weight: 400;
}

.entry-content,
.entry-content p,
.entry-content li,
.entry-content td,
.entry-content th {
  color: var(--tf-body-text);
}

.entry-content a.kontakt-link,
.entry-content a[href="/kontakt/"],
.entry-content a[href="/kontakt"],
.entry-content a[href$="/kontakt/"],
.entry-content a[href$="/kontakt"],
.entry-content a[href*="/kontakt/?"],
.entry-content a[href*="/kontakt#"] {
  display: inline-block;
  background: var(--tf-nav-active) !important;
  color: #ffffff !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.02em;
  font-size: 24px !important;
  line-height: 1.2;
  padding: 14px 20px !important;
  border-radius: 12px !important;
  text-decoration: none !important;
  border: 0 !important;
  transition: background .18s ease, transform .18s ease;
}

.entry-content a.kontakt-link:hover,
.entry-content a.kontakt-link:focus,
.entry-content a[href="/kontakt/"]:hover,
.entry-content a[href="/kontakt/"]:focus,
.entry-content a[href="/kontakt"]:hover,
.entry-content a[href="/kontakt"]:focus,
.entry-content a[href$="/kontakt/"]:hover,
.entry-content a[href$="/kontakt/"]:focus,
.entry-content a[href$="/kontakt"]:hover,
.entry-content a[href$="/kontakt"]:focus,
.entry-content a[href*="/kontakt/?"]:hover,
.entry-content a[href*="/kontakt/?"]:focus,
.entry-content a[href*="/kontakt#"]:hover,
.entry-content a[href*="/kontakt#"]:focus {
  background: #4a9d1f !important;
  transform: translateY(-1px);
}

.home-available-apartments {
  margin-bottom: 28px;
}

.home-available-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.home-available-button {
  display: inline-block;
  background: var(--tf-nav-active);
  color: #ffffff !important;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none !important;
  padding: 14px 20px;
  border-radius: 10px;
  transition: background .18s ease, transform .18s ease;
}

.home-available-button:hover,
.home-available-button:focus {
  background: #4a9d1f;
  transform: translateY(-1px);
}

.home-no-available {
  font-size: 22px;
  font-weight: 600;
  margin: 0 0 8px;
}

.wohnung-page h4 {
  margin: 0 0 18px;
  color: var(--tf-title);
  font-size: 23px;
  font-weight: 400;
}

.wohnung-hero-table {
  width: 100%;
  border: 0;
  border-collapse: collapse;
  table-layout: fixed;
  margin: 4px 0 26px;
}

.wohnung-hero-table td {
  border: 0;
  padding: 0;
  vertical-align: top;
}

.wohnung-hero-table__text {
  width: 48%;
  padding-right: 26px;
}

.wohnung-hero-table__text h4 {
  margin-top: 34px;
}

.wohnung-hero-table__image {
  width: 52%;
  text-align: right;
}

.wohnung-hero-table__image a,
.wohnung-hero-table__image img {
  display: inline-block;
}

.wohnung-hero-table__image img {
  width: 406px;
  max-width: 100%;
  height: auto;
  object-fit: contain;
}

.wohnung-facts {
  max-width: none;
  margin: 8px 0 36px;
}

.wohnung-facts table {
  width: 100%;
  border-collapse: collapse;
}

.wohnung-facts td {
  padding: 12px 12px;
  border: 0;
  vertical-align: middle;
  color: #2d3f59;
  font-size: 16px;
}

.wohnung-facts tr:nth-child(odd) td {
  background: #efefef;
}

.wohnung-facts tr:nth-child(even) td {
  background: #ffffff;
}

.wohnung-facts td:first-child {
  width: 68%;
}

.wohnung-facts td:last-child {
  width: 32%;
  text-align: right;
  white-space: nowrap;
}

.wohnung-facts__subrow td:first-child {
  padding-left: 140px;
}

@media (max-width: 760px) {
  .wohnung-hero-table,
  .wohnung-hero-table tbody,
  .wohnung-hero-table tr,
  .wohnung-hero-table td {
    display: block;
    width: 100%;
  }

  .wohnung-hero-table__text {
    padding-right: 0;
  }

  .wohnung-hero-table__text h4 {
    margin-top: 0;
  }

  .wohnung-hero-table__image {
    margin-top: 18px;
    text-align: left;
  }

  .wohnung-facts td:last-child {
    white-space: normal;
  }
}

.site-header.default-style .main-navigation ul ul li a:hover,
.site-header.default-style .main-navigation ul ul li a:focus,
.main-navigation .sub-menu li:hover > a,
.main-navigation .sub-menu li:focus-within > a,
.main-navigation .sub-menu li a:hover,
.main-navigation .sub-menu li a:focus {
  color: #ffffff !important;
  background: var(--tf-nav-active) !important;
}

.main-navigation .sub-menu li.current-menu-item > a {
  color: #ffffff !important;
  background: var(--tf-nav-active) !important;
}

.main-navigation .sub-menu {
  pointer-events: auto;
}

.header-search {
  position: relative;
  padding-right: 20px;
}

.search-toggle {
  background: transparent;
  border: 0;
  color: #fff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  padding: 8px;
}

.search-toggle:hover {
  color: var(--tf-nav-active);
}

.search-popover {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 290px;
  display: none;
  background: #fff;
  border: 1px solid #cfcfcf;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.18);
  padding: 8px;
  z-index: 1300;
}

.search-popover.open {
  display: flex;
}

.search-popover input {
  flex: 1;
  border: 1px solid #cfcfcf;
  padding: 8px 10px;
  font-size: 16px;
}

.search-popover button {
  border: 0;
  background: #111;
  color: #fff;
  width: 38px;
}

#search-results {
  margin-top: 20px;
}

.search-hit {
  border-bottom: 1px solid #ddd;
  padding: 10px 0;
}

.search-hit h3 {
  margin: 0 0 6px;
  font-size: 28px;
}

.search-hit p {
  margin: 0;
}

.entry-content figure { margin: 0 0 16px 0; }
.entry-content img { max-width: 100%; height: auto; }
.wp-block-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; margin: 0; padding: 0; }
.wp-block-gallery .wp-block-image { margin: 0; }
.wp-block-gallery .wp-block-image a {
  display: block;
}
.wp-block-gallery .wp-block-image img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
}
.wp-block-buttons .wp-block-button__link { display: inline-block; }
.faq-list details {
  border: 2px solid #e8e8e8;
  margin-bottom: 8px;
  border-radius: 3px;
  background: #fff;
  overflow: hidden;
}

.faq-list summary {
  cursor: pointer;
  padding: 12px 48px 12px 16px;
  font-weight: 600;
  background: #e8e8e8;
  list-style: none;
  position: relative;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "+";
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 26px;
  line-height: 1;
  font-weight: 400;
}

.faq-list summary .fa {
  display: inline-block;
  width: 20px;
  margin-right: 8px;
  margin-left: 8px;
  text-align: center;
}

.faq-list details[open] summary::after {
  content: "-";
}

.faq-list .answer {
  padding: 14px 16px;
  border-top: 2px solid #e8e8e8;
  background: #fff;
}

.map-small iframe {
  width: 100%;
  max-width: 420px;
  height: 260px;
  display: block;
}

.kontakt-page {
  display: grid;
  gap: 34px;
}

.kontakt-intro > *:last-child {
  margin-bottom: 0;
}

.kontakt-form-section {
  border-top: 1px solid #d8dee6;
  padding-top: 28px;
}

.kontakt-form-section h2 {
  margin: 0 0 10px;
  color: var(--tf-title);
  font-size: 34px;
  line-height: 1.15;
}

.kontakt-form {
  margin-top: 24px;
}

.kontakt-form__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin-bottom: 18px;
}

.kontakt-form__field {
  margin-bottom: 18px;
}

.kontakt-form__field label {
  display: block;
  margin-bottom: 8px;
  font-weight: 700;
  color: #223246;
}

.kontakt-form__field input,
.kontakt-form__field textarea {
  width: 100%;
  border: 1px solid #bfc8d2;
  border-radius: 8px;
  background: #ffffff;
  color: var(--tf-body-text);
  font-size: 17px;
  line-height: 1.5;
  padding: 12px 14px;
  transition: border-color .18s ease, box-shadow .18s ease;
}

.kontakt-form__field textarea {
  min-height: 180px;
  resize: vertical;
}

.kontakt-form__field input:focus,
.kontakt-form__field textarea:focus {
  border-color: var(--tf-nav-active);
  box-shadow: 0 0 0 3px rgba(97, 185, 47, 0.18);
  outline: none;
}

.kontakt-form__hidden {
  display: none !important;
}

.kontakt-form__captcha {
  margin: 8px 0 22px;
}

.kontakt-form__submit {
  display: inline-block;
  border: 0;
  border-radius: 12px;
  background: var(--tf-nav-active);
  color: #ffffff;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.2;
  padding: 14px 22px;
  cursor: pointer;
  transition: background .18s ease, transform .18s ease;
}

.kontakt-form__submit:hover,
.kontakt-form__submit:focus {
  background: #4a9d1f;
  transform: translateY(-1px);
  outline: none;
}

.table-wrap { overflow-x: auto; }

.share-rail {
  position: fixed;
  right: 16px;
  top: 48%;
  transform: translateY(-50%);
  z-index: 1200;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.share-btn {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f4f4f4;
  font-size: 26px;
  text-decoration: none;
  transition: transform .15s ease, box-shadow .15s ease;
}

.share-btn:hover {
  transform: translateX(-2px);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
}

.share-fb {
  color: #3b5998 !important;
  border: 3px solid #3b5998;
}

.share-msgr {
  color: #3f7fff !important;
  border: 3px solid #3f7fff;
}

.share-wa {
  color: #20b62f !important;
  border: 3px solid #20b62f;
}

.share-x {
  color: #111111 !important;
  border: 3px solid #111111;
}

.share-mail {
  color: #737373 !important;
  border: 3px solid #9a9a9a;
}

.x-icon {
  font-family: "Roboto Condensed", sans-serif;
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
}

@media (max-width: 900px) {
  #content.site-content {
    padding: 20px 0 36px;
  }

  #content .container {
    padding-left: 10px;
    padding-right: 10px;
  }

  .site-header-custom .site-logo-image {
    width: 180px;
  }

  .site-header-custom .custom-logo {
    width: 160px;
  }

  .nav-row {
    position: relative;
    align-items: flex-start;
    gap: 10px;
  }

  .menu-toggle {
    display: block;
    position: absolute;
    top: 4px;
    right: 14px;
    z-index: 100001;
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.06);
  }

  .menu-toggle.open span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  .menu-toggle.open span:nth-child(2) {
    opacity: 0;
  }

  .menu-toggle.open span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  .site-header.default-style .main-navigation,
  .main-navigation {
    display: none !important;
    width: 100%;
    padding-top: 8px;
    flex: none;
  }

  .site-header.default-style .main-navigation.open,
  .main-navigation.open {
    display: block !important;
  }

  .main-navigation .menu {
    display: block;
    padding: 4px 0 0;
    background: var(--tf-nav-bg);
  }

  .main-navigation .menu > li {
    display: block;
    width: 100%;
  }

  .main-navigation .menu > li > a {
    font-size: 16px;
    padding: 14px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    line-height: 1.2;
  }

  .main-navigation .sub-menu {
    position: static;
    display: block;
    border: 0;
    min-width: unset;
    padding: 0 !important;
    box-shadow: none;
    top: auto;
    background: #111111 !important;
  }

  .main-navigation .sub-menu li a,
  .site-header.default-style .main-navigation ul ul li a {
    padding: 12px 24px !important;
    white-space: normal;
  }

  .site-main article {
    margin: 0;
    padding: 28px 22px 34px;
  }

  .page-entry-title {
    font-size: 42px;
    line-height: 1.08;
    margin-bottom: 20px;
  }

  .home-available-button {
    font-size: 20px;
    padding: 12px 18px;
  }

  .kontakt-form-section h2 {
    font-size: 30px;
  }

  .entry-content a.kontakt-link,
  .entry-content a[href="/kontakt/"],
  .entry-content a[href="/kontakt"],
  .entry-content a[href$="/kontakt/"],
  .entry-content a[href$="/kontakt"],
  .entry-content a[href*="/kontakt/?"],
  .entry-content a[href*="/kontakt#"] {
    font-size: 20px !important;
    padding: 12px 16px !important;
  }

  .header-search {
    padding-right: 8px;
  }

  .search-popover {
    width: min(240px, calc(100vw - 24px));
    right: 0;
  }

  .share-rail {
    display: none;
  }

  .share-btn {
    width: 42px;
    height: 42px;
    font-size: 20px;
  }
}

@media (max-width: 680px) {
  html,
  body {
    overflow-x: hidden;
  }

  #page.site,
  #content .container,
  #primary.content-area,
  .site-main,
  .site-main article,
  .entry-content {
    max-width: 100%;
    min-width: 0;
  }

  .site-header-custom .header-top {
    display: block !important;
    background: var(--tf-container-bg) !important;
    padding: 18px 0 10px !important;
  }

  .site-header-custom .header-top .container {
    display: block !important;
    text-align: center;
  }

  .site-header.default-style .site-branding,
  .site-header-custom .site-branding,
  .site-header-custom .site-logo-image,
  .site-header-custom .site-branding-text {
    float: none !important;
    height: auto !important;
  }

  .site-header-custom .header-nav .container,
  .nav-row {
    display: block;
  }

  .site-header-custom .site-branding,
  .site-header-custom .site-logo-image,
  .site-header-custom .custom-logo-link {
    display: block !important;
    width: 100%;
  }

  .site-header-custom .header-nav .container {
    padding-left: 0;
    padding-right: 0;
  }

  .site-header-custom .header-nav {
    min-height: 52px;
  }

  .site-header-custom .site-logo-image {
    width: 150px;
    padding-bottom: 6px;
    margin: 0 auto 8px !important;
  }

  .site-header-custom .custom-logo {
    width: 140px;
    display: block;
    margin: 0 auto;
    height: auto;
  }

  .nav-row {
    min-height: 52px;
    padding-right: 72px;
  }

  .header-search {
    position: absolute;
    top: 8px;
    right: 60px;
    padding: 0;
    z-index: 100001;
  }

  .search-toggle {
    width: 44px;
    height: 32px;
    padding: 0;
  }

  .search-popover {
    position: absolute;
    top: 40px;
    right: -46px;
    width: min(240px, calc(100vw - 32px));
    margin-top: 0;
  }

  .page-entry-title {
    font-size: 28px;
    line-height: 1.12;
    margin-bottom: 16px;
  }

  .entry-content h2 {
    font-size: 28px;
    line-height: 1.2;
  }

  .entry-content h3,
  .entry-content h4,
  .wohnung-page h4 {
    font-size: 22px;
    line-height: 1.25;
  }

  .entry-content p,
  .entry-content li,
  .entry-content td,
  .entry-content th {
    font-size: 17px;
    line-height: 1.65;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  .home-available-buttons {
    display: block;
  }

  .home-available-button {
    display: block;
    width: 100%;
    font-size: 19px;
    padding: 14px 16px;
    text-align: center;
    margin-bottom: 12px;
  }

  .wp-block-gallery {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .kontakt-form__grid {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .kontakt-form-section h2 {
    font-size: 24px;
  }

  .kontakt-form__submit {
    width: 100%;
  }

  .wohnung-hero-table,
  .wohnung-hero-table tbody,
  .wohnung-hero-table tr,
  .wohnung-hero-table td {
    display: block;
    width: 100%;
  }

  .wohnung-hero-table {
    table-layout: auto;
    margin-bottom: 18px;
  }

  .wohnung-hero-table__text {
    padding-right: 0;
  }

  .wohnung-hero-table__text h4 {
    margin-top: 0;
  }

  .wohnung-hero-table__image {
    margin-top: 14px;
    text-align: left;
  }

  .wohnung-hero-table__image img {
    width: 100%;
    max-width: 100%;
    max-height: 240px;
  }

  .wohnung-facts td {
    display: table-cell;
    padding: 8px 10px;
    font-size: 14px;
    line-height: 1.35;
    vertical-align: middle;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  .wohnung-facts table {
    width: 100%;
    table-layout: fixed;
  }

  .wohnung-facts td:first-child {
    width: 64% !important;
  }

  .wohnung-facts td:last-child {
    width: 36% !important;
    text-align: right !important;
    white-space: normal;
  }

  .wohnung-facts__subrow td:first-child {
    padding-left: 22px;
  }

  .wohnung-facts,
  .table-wrap {
    width: 100%;
    overflow-x: hidden;
  }

  .map-small iframe {
    max-width: 100%;
    height: 220px;
  }
}
