/*
Theme Name: Sylvia Wallinger
Theme URI: https://sylviawallinger.at
Author: JZ Webservices
Description: Schlankes, responsives WordPress-Theme für sylviawallinger.at. Bestehende WordPress-Seiten und Menüs werden weiterverwendet.
Version: 1.5.0
Text Domain: sylvia-wallinger
*/

:root {
  --sw-primary: #850000;
  --sw-primary-dark: #680000;
  --sw-primary-light: #a62a2a;
  --sw-background: #ffffff;
  --sw-page-background: #eeeeee;
  --sw-text: #292929;
  --sw-muted: #737373;
  --sw-border: #dedede;
  --sw-content-width: 900px;
  --sw-site-width: 1200px;
  --sw-radius: 2px;
  --sw-body-font: Arial, Helvetica, sans-serif;
  --sw-heading-font: Georgia, 'Times New Roman', serif;
  --sw-h1-size: 48px;
  --sw-h2-size: 34px;
  --sw-h3-size: 28px;
  --sw-h4-size: 24px;
  --sw-h5-size: 20px;
  --sw-h6-size: 17px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--sw-text);
  background: var(--sw-page-background);
  font-family: var(--sw-body-font);
  font-size: 16px;
  line-height: 1.7;
}
a { color: var(--sw-primary); text-decoration: none; }
a:hover, a:focus { color: var(--sw-primary-dark); }
img { max-width: 100%; height: auto; }

.sw-site {
  width: min(calc(100% - 40px), var(--sw-site-width));
  margin: 0 auto;
  background: var(--sw-background);
  min-height: 100vh;
  box-shadow: 0 0 18px rgba(0,0,0,.06);
}

.sw-topbar {
  padding: 5px 18px 4px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 18px;
  text-align: right;
  color: var(--sw-primary);
  border-bottom: 1px solid var(--sw-primary);
  font-size: .95rem;
}
.sw-topbar a { color: inherit; }
.sw-languages { display: inline-flex; align-items: center; gap: 7px; font-size: .88rem; }
.sw-languages a { opacity: .7; letter-spacing: .04em; }
.sw-languages a:hover, .sw-languages a:focus { opacity: 1; }
.sw-languages a.is-active { opacity: 1; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.sw-lang-separator { opacity: .45; }

.sw-nav-wrap { background: var(--sw-primary); }
.sw-nav-inner {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 50px;
}
.sw-menu-toggle {
  display: none;
  margin: 8px 14px;
  padding: 8px 12px;
  border: 1px solid rgba(255,255,255,.55);
  background: transparent;
  color: #fff;
  font: inherit;
  cursor: pointer;
}
.sw-primary-menu,
.sw-primary-menu ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.sw-primary-menu { display: flex; flex-wrap: wrap; }
.sw-primary-menu > li { position: relative; border-right: 1px solid rgba(255,255,255,.10); }
.sw-primary-menu a {
  display: block;
  padding: 13px 18px;
  color: #fff;
}
.sw-primary-menu > li > a:hover,
.sw-primary-menu > li.current-menu-item > a,
.sw-primary-menu > li.current-menu-ancestor > a { background: var(--sw-primary-dark); }
.sw-primary-menu .sub-menu {
  display: none;
  position: absolute;
  z-index: 100;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: var(--sw-primary-dark);
  box-shadow: 0 8px 20px rgba(0,0,0,.15);
}
.sw-primary-menu li:hover > .sub-menu,
.sw-primary-menu li:focus-within > .sub-menu { display: block; }
.sw-primary-menu .sub-menu a { padding: 10px 15px; }
.sw-primary-menu .sub-menu a:hover { background: var(--sw-primary); }

.sw-content {
  width: min(calc(100% - 48px), var(--sw-content-width));
  margin: 0 auto;
  padding: 52px 0 64px;
  min-height: 55vh;
}
.sw-content h1,
.sw-content h2,
.sw-content h3,
.sw-content h4,
.sw-content h5,
.sw-content h6 {
  line-height: 1.25;
  font-family: var(--sw-heading-font);
  font-weight: 400;
  color: var(--sw-primary-dark);
}
.sw-content h1 { font-size: var(--sw-h1-size); margin-top: 0; }
.sw-content h2 { font-size: var(--sw-h2-size); margin-top: 1.8em; }
.sw-content h3 { font-size: var(--sw-h3-size); }
.sw-content h4 { font-size: var(--sw-h4-size); }
.sw-content h5 { font-size: var(--sw-h5-size); }
.sw-content h6 { font-size: var(--sw-h6-size); }

/* Seiten ohne automatisch ausgegebenen Seitentitel beginnen auf derselben Höhe wie Beiträge.
   Überschriften, die als erstes Element im Seiteninhalt stehen, erhalten keinen zusätzlichen oberen Abstand. */
.page .sw-content article > h1:first-child,
.page .sw-content article > h2:first-child,
.page .sw-content article > h3:first-child,
.page .sw-content article > h4:first-child,
.page .sw-content article > h5:first-child,
.page .sw-content article > h6:first-child,
.page .sw-content article > .wp-block-heading:first-child {
  margin-top: 0;
}
@media (max-width: 600px) {
  .sw-content h1 { font-size: min(var(--sw-h1-size), 40px); }
  .sw-content h2 { font-size: min(var(--sw-h2-size), 32px); }
  .sw-content h3 { font-size: min(var(--sw-h3-size), 27px); }
}
.sw-content blockquote {
  margin: 2rem 0;
  padding: .4rem 0 .4rem 1.4rem;
  border-left: 3px solid var(--sw-primary);
  color: var(--sw-muted);
  font-family: var(--sw-heading-font);
  font-size: 1.1rem;
}
.sw-content hr { border: 0; border-top: 1px solid var(--sw-border); margin: 2.5rem 0; }
.sw-content .wp-block-button__link,
.sw-content button,
.sw-content input[type="submit"] {
  border: 0;
  border-radius: var(--sw-radius);
  background: var(--sw-primary);
  color: #fff;
  padding: .75rem 1.2rem;
}
.sw-content .wp-block-button__link:hover,
.sw-content button:hover,
.sw-content input[type="submit"]:hover { background: var(--sw-primary-dark); color: #fff; }

.sw-footer {
  border-top: 4px solid var(--sw-primary);
  background: #f7f7f7;
  color: var(--sw-muted);
}
.sw-footer-inner {
  width: min(calc(100% - 48px), var(--sw-content-width));
  margin: 0 auto;
  padding: 24px 0;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  font-size: .9rem;
}
.sw-footer-menu { margin: 0; padding: 0; list-style: none; display: flex; gap: 16px; flex-wrap: wrap; }

@media (max-width: 720px) {
  .sw-site { width: 100%; box-shadow: none; }
  .sw-topbar { padding-right: 14px; }
  .sw-nav-inner { display: block; }
  .sw-menu-toggle { display: inline-block; }
  .sw-primary-menu { display: none; width: 100%; }
  .sw-primary-menu.is-open { display: block; }
  .sw-primary-menu > li { border-right: 0; border-top: 1px solid rgba(255,255,255,.12); }
  .sw-primary-menu .sub-menu {
    display: block;
    position: static;
    min-width: 0;
    box-shadow: none;
    background: rgba(0,0,0,.12);
    padding-left: 16px;
  }
  .sw-content { width: min(calc(100% - 32px), var(--sw-content-width)); padding: 34px 0 48px; }
  .sw-footer-inner { width: calc(100% - 32px); }
}
