/*
Theme Name: AC Hörbranz Athletic
Theme URI: https://ac-hoerbranz.at/
Author: AC Hörbranz
Description: Schnelles, barrierearmes Vereins-Theme im Athletic-Power-&-Precision-Design. Kompatibel mit Gutenberg, Elementor Free und gängigen Page Buildern.
Version: 1.0.0
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 8.0
Text Domain: ac-hoerbranz
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Tags: custom-logo, custom-menu, featured-images, threaded-comments, translation-ready, block-styles, wide-blocks, editor-style, accessibility-ready
*/

:root {
  --ach-primary: #ee7a00;
  --ach-primary-hover: #ff8e1c;
  --ach-bg: #0b0f17;
  --ach-surface: #111827;
  --ach-card: #1e293b;
  --ach-card-alt: #161f30;
  --ach-border: #36445a;
  --ach-text: #e5e7eb;
  --ach-muted: #b9bdc8;
  --ach-success: #10b981;
  --ach-error: #ef4444;
  --ach-heading-font: "Oswald", "Arial Narrow", Arial, sans-serif;
  --ach-body-font: "Inter", Arial, sans-serif;
  --ach-label-font: "Barlow Condensed", "Arial Narrow", Arial, sans-serif;
  --ach-container: 1320px;
  --ach-header-height: 80px;
  --ach-radius: 6px;
  --ach-section-space: 96px;
  --ach-content-width: 820px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ach-bg);
  color: var(--ach-text);
  font-family: var(--ach-body-font);
  font-size: 16px;
  line-height: 1.6;
  overflow-wrap: break-word;
}
body.admin-bar .site-header { top: 32px; }
:focus-visible { outline: 3px solid var(--ach-primary); outline-offset: 3px; }
a { color: var(--ach-primary-hover); text-decoration-thickness: .08em; text-underline-offset: .16em; }
a:hover { color: #ffc092; }
img { display: block; height: auto; max-width: 100%; }
figure { margin: 0; }
button, input, select, textarea { font: inherit; }
button, input[type="button"], input[type="submit"] { cursor: pointer; }
h1, h2, h3, h4, h5, h6 {
  color: var(--ach-text);
  font-family: var(--ach-heading-font);
  font-weight: 700;
  line-height: 1.12;
  margin: 0 0 .55em;
  text-transform: uppercase;
}
h1 { font-size: clamp(2.5rem, 6vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 2.75rem); }
h3 { font-size: clamp(1.35rem, 2vw, 2rem); }
p { margin: 0 0 1.2em; }
table { border-collapse: collapse; width: 100%; }
th, td { border-bottom: 1px solid var(--ach-border); padding: .8rem; text-align: left; }
th { color: var(--ach-primary-hover); font-family: var(--ach-label-font); text-transform: uppercase; }

.screen-reader-text {
  clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%); height: 1px; overflow: hidden;
  position: absolute !important; width: 1px; word-wrap: normal !important;
}
.screen-reader-text:focus {
  background: var(--ach-text); clip: auto !important; clip-path: none; color: var(--ach-bg);
  display: block; font-weight: 700; height: auto; left: 1rem; padding: 1rem; top: 1rem; width: auto; z-index: 100000;
}
.site-container { margin-inline: auto; max-width: var(--ach-container); padding-inline: clamp(1rem, 4vw, 3rem); width: 100%; }
.site-main { min-height: 60vh; padding-top: var(--ach-header-height); }
.site-main--canvas { padding-top: 0; }
.content-area { padding-block: clamp(3.5rem, 8vw, var(--ach-section-space)); }
.entry-content > * { margin-inline: auto; max-width: var(--ach-content-width); }
.entry-content > .alignwide { max-width: var(--ach-container); }
.entry-content > .alignfull { max-width: none; width: 100%; }
.entry-content::after { clear: both; content: ""; display: table; }
.alignleft { float: left; margin: .5rem 1.5rem 1rem 0; }
.alignright { float: right; margin: .5rem 0 1rem 1.5rem; }
.aligncenter { margin-inline: auto; }

/* Header */
.site-header {
  backdrop-filter: blur(18px); background: rgba(7, 12, 20, .94); border-bottom: 1px solid rgba(54, 68, 90, .25);
  left: 0; min-height: var(--ach-header-height); position: fixed; right: 0; top: 0; z-index: 999;
}
.header-inner { align-items: center; display: flex; gap: 1rem; height: var(--ach-header-height); justify-content: space-between; }
.site-branding { align-items: center; color: var(--ach-text); display: flex; flex: 0 0 auto; gap: .75rem; text-decoration: none; }
.custom-logo { max-height: 52px; width: auto; }
.site-title-wrap { line-height: 1; }
.site-title { color: var(--ach-text); display: block; font-family: var(--ach-heading-font); font-size: 1.25rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.site-tagline { color: var(--ach-primary-hover); display: block; font-family: var(--ach-label-font); font-size: .82rem; font-weight: 700; letter-spacing: .12em; margin-top: .3rem; text-transform: uppercase; }
.main-navigation { margin-left: auto; }
.main-navigation ul { align-items: center; display: flex; gap: .15rem; list-style: none; margin: 0; padding: 0; }
.main-navigation li { position: relative; }
.main-navigation a {
  border-radius: 2px; color: #dec1af; display: block; font-family: var(--ach-label-font); font-size: .92rem;
  font-weight: 700; letter-spacing: .06em; padding: .55rem .7rem; text-decoration: none; text-transform: uppercase;
}
.main-navigation a:hover, .main-navigation .current-menu-item > a, .main-navigation .current_page_item > a { background: var(--ach-card); color: var(--ach-primary-hover); }
.main-navigation .sub-menu {
  align-items: stretch; background: var(--ach-card); border: 1px solid var(--ach-border); display: none; flex-direction: column;
  left: 0; min-width: 220px; padding: .4rem; position: absolute; top: 100%;
}
.main-navigation li:hover > .sub-menu, .main-navigation li:focus-within > .sub-menu { display: flex; }
.main-navigation .sub-menu .sub-menu { left: 100%; top: 0; }
.header-cta, .ach-button, .wp-element-button, .wp-block-button__link, input[type="submit"] {
  background: var(--ach-primary); border: 0; border-radius: 999px; color: #281200; display: inline-flex; font-family: var(--ach-label-font);
  font-weight: 700; justify-content: center; letter-spacing: .06em; line-height: 1.2; padding: .75rem 1.35rem; text-decoration: none; text-transform: uppercase; transition: .18s ease;
}
.header-cta:hover, .ach-button:hover, .wp-element-button:hover, .wp-block-button__link:hover, input[type="submit"]:hover { background: var(--ach-primary-hover); color: #281200; transform: translateY(-1px); }
.ach-button--ghost { background: transparent; border: 1px solid var(--ach-muted); color: var(--ach-text); }
.ach-button--ghost:hover { background: var(--ach-card); border-color: var(--ach-primary); color: var(--ach-text); }
.menu-toggle { background: transparent; border: 1px solid var(--ach-border); border-radius: var(--ach-radius); color: var(--ach-text); display: none; padding: .55rem; }
.menu-toggle-lines { display: grid; gap: 5px; width: 24px; }
.menu-toggle-lines span { background: currentColor; display: block; height: 2px; transition: .2s; }
.mobile-menu-cta, .submenu-toggle { display: none; }
.ach-post-card h3 a { color: var(--ach-text); text-decoration: none; }
.ach-post-card h3 a:hover { color: var(--ach-primary-hover); }
.ach-product-price { color: #ffb785; font-family: var(--ach-heading-font); font-size: 1.8rem; margin-bottom: .75rem; }

/* Reusable athletic components */
.ach-section { padding-block: var(--ach-section-space); }
.ach-section--surface { background: var(--ach-surface); }
.ach-section--deep { background: #080d15; }
.ach-eyebrow { color: #ffb785; display: block; font-family: var(--ach-label-font); font-size: .9rem; font-weight: 700; letter-spacing: .11em; margin-bottom: .6rem; text-transform: uppercase; }
.ach-eyebrow::before { background: var(--ach-primary); border-radius: 50%; content: ""; display: inline-block; height: .5rem; margin-right: .55rem; width: .5rem; }
.ach-section-heading { margin-bottom: 2.5rem; }
.ach-section-heading.center { margin-inline: auto; max-width: 760px; text-align: center; }
.ach-section-heading p { color: var(--ach-muted); font-size: 1.05rem; }
.ach-card { background: var(--ach-card); border: 1px solid rgba(54, 68, 90, .75); border-radius: var(--ach-radius); overflow: hidden; }
.ach-card__body { padding: 1.5rem; }
.ach-grid { display: grid; gap: 1.5rem; }
.ach-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ach-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ach-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.ach-hero { align-items: center; display: grid; gap: clamp(2rem, 5vw, 5rem); grid-template-columns: 1.15fr .85fr; min-height: 650px; padding-block: 5rem; }
.ach-hero h1 span { color: var(--ach-primary); }
.ach-hero__lead { color: var(--ach-muted); font-size: 1.12rem; max-width: 700px; }
.ach-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
.ach-hero__media { background: var(--ach-card); border: 1px solid var(--ach-border); border-radius: calc(var(--ach-radius) * 2); min-height: 370px; overflow: hidden; position: relative; }
.ach-hero__media img { height: 100%; object-fit: cover; position: absolute; width: 100%; }
.ach-hero__placeholder { align-items: center; background: linear-gradient(135deg, var(--ach-card), var(--ach-card-alt)); color: var(--ach-muted); display: flex; inset: 0; justify-content: center; position: absolute; }
.ach-info-strip { background: var(--ach-card); border: 1px solid var(--ach-border); border-radius: var(--ach-radius); display: grid; gap: 1px; grid-template-columns: repeat(3, 1fr); margin-top: 2rem; overflow: hidden; }
.ach-info-strip > div { background: var(--ach-card); padding: 1.15rem; }
.ach-info-strip strong { display: block; font-family: var(--ach-heading-font); font-size: 1.15rem; text-transform: uppercase; }
.ach-info-strip span { color: var(--ach-muted); font-size: .85rem; }
.ach-event-list { display: grid; gap: .65rem; margin-inline: auto; max-width: 1000px; }
.ach-event {
  align-items: center; background: var(--ach-card); border: 1px solid #607089; border-radius: var(--ach-radius); color: inherit;
  display: grid; gap: 1.2rem; grid-template-columns: 64px 1fr auto; padding: .75rem 1rem; text-decoration: none;
}
.ach-event:hover { border-color: var(--ach-primary); color: inherit; }
.ach-event__date { border: 1px solid #8b96a8; border-radius: 4px; font-family: var(--ach-label-font); line-height: 1; padding: .45rem; text-align: center; text-transform: uppercase; }
.ach-event__date b { color: #ffb785; display: block; font-size: 1.45rem; }
.ach-event__title { font-family: var(--ach-heading-font); font-size: 1.2rem; font-weight: 700; text-transform: uppercase; }
.ach-event__meta { color: var(--ach-muted); display: block; font-size: .8rem; }
.ach-pill { background: #59452f; border-radius: 999px; color: #ffc599; font-family: var(--ach-label-font); font-size: .72rem; font-weight: 700; letter-spacing: .04em; padding: .25rem .65rem; text-transform: uppercase; }
.ach-post-card { display: flex; flex-direction: column; min-width: 0; }
.ach-post-card__image { aspect-ratio: 16/9; background: var(--ach-card-alt); overflow: hidden; }
.ach-post-card__image img { height: 100%; object-fit: cover; transition: transform .3s; width: 100%; }
.ach-post-card:hover img { transform: scale(1.035); }
.ach-post-card .ach-card__body { display: flex; flex: 1; flex-direction: column; }
.ach-post-card h3 { font-size: 1.45rem; }
.ach-post-card p { color: var(--ach-muted); }
.ach-post-card__link { font-family: var(--ach-label-font); font-weight: 700; margin-top: auto; text-transform: uppercase; }
.ach-sponsor-row { display: grid; gap: 1rem; grid-template-columns: repeat(6, 1fr); }
.ach-sponsor { align-items: center; border: 1px solid #647087; color: var(--ach-text); display: flex; font-family: var(--ach-heading-font); font-size: 1.1rem; font-weight: 700; justify-content: center; min-height: 84px; padding: 1rem; text-align: center; text-transform: uppercase; }
.ach-banner { align-items: center; background: var(--ach-primary); color: #311700; display: flex; gap: 1rem; justify-content: space-between; padding-block: 2rem; }
.ach-banner h2 { color: inherit; margin: 0; }
.ach-empty { background: var(--ach-card); border: 1px dashed var(--ach-border); color: var(--ach-muted); padding: 2rem; text-align: center; }

/* Blog forms/comments */
input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]), select, textarea {
  background: #171c25; border: 1px solid #303a4b; border-radius: 2px; color: var(--ach-text); padding: .8rem 1rem; width: 100%;
}
input:focus, select:focus, textarea:focus { border-color: var(--ach-primary); outline: 2px solid rgba(238, 122, 0, .25); }
label { display: block; font-family: var(--ach-label-font); font-weight: 700; letter-spacing: .04em; margin-bottom: .35rem; text-transform: uppercase; }
.comment-list { list-style: none; padding: 0; }
.comment-body { background: var(--ach-card); border: 1px solid var(--ach-border); margin-bottom: 1rem; padding: 1.25rem; }
.comment-metadata { font-size: .8rem; }
.navigation.pagination { margin-top: 3rem; }
.nav-links { display: flex; flex-wrap: wrap; gap: .5rem; }
.page-numbers { background: var(--ach-card); border: 1px solid var(--ach-border); padding: .5rem .8rem; text-decoration: none; }
.page-numbers.current { background: var(--ach-primary); color: #281200; }
.entry-meta { color: var(--ach-muted); font-size: .88rem; margin-bottom: 1.5rem; }
.entry-header { margin-inline: auto; max-width: var(--ach-content-width); }
.post-navigation { border-top: 1px solid var(--ach-border); margin-top: 3rem; padding-top: 2rem; }
.post-navigation .nav-links { justify-content: space-between; }
.wp-caption, .gallery-caption { color: var(--ach-muted); font-size: .85rem; }
.bypostauthor .comment-body { border-left: 3px solid var(--ach-primary); }
.sticky { border-top: 3px solid var(--ach-primary); }

/* Footer */
.site-footer { background: #070c14; color: var(--ach-muted); padding-block: 4rem 2rem; }
.footer-sponsors { align-items: center; background: var(--ach-card); border-radius: var(--ach-radius); display: flex; gap: 2rem; justify-content: space-between; margin-bottom: 3rem; padding: 1.5rem; }
.footer-sponsors strong { color: var(--ach-text); font-family: var(--ach-heading-font); text-transform: uppercase; }
.footer-sponsors__names { color: #9da4b1; display: flex; flex-wrap: wrap; font-family: var(--ach-heading-font); font-size: 1.25rem; font-weight: 700; gap: 2rem; text-transform: uppercase; }
.footer-grid { display: grid; gap: 2.5rem; grid-template-columns: 1.1fr 1fr 1fr 1fr; }
.footer-title { color: #ffb785; font-family: var(--ach-label-font); font-size: .85rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.footer-menu { list-style: none; margin: .7rem 0 0; padding: 0; }
.footer-menu a { color: var(--ach-muted); text-decoration: none; }
.footer-menu a:hover { color: var(--ach-text); }
.footer-bottom { align-items: center; border-top: 1px solid rgba(54,68,90,.35); display: flex; font-size: .8rem; justify-content: space-between; margin-top: 3rem; padding-top: 2rem; }
.social-links { display: flex; gap: .6rem; }
.social-links a { align-items: center; background: var(--ach-card); border-radius: 50%; color: var(--ach-text); display: flex; height: 36px; justify-content: center; text-decoration: none; width: 36px; }

/* Builder compatibility */
body.elementor-page .entry-content > *, body.fl-builder .entry-content > *, body.bricks-is-frontend .entry-content > * { max-width: none; }
body.elementor-template-canvas .site-main { padding-top: 0; }
.elementor-section.elementor-section-boxed > .elementor-container { max-width: var(--ach-container); }
.ach-page-full-width .entry-content > * { max-width: none; }

@media (max-width: 1100px) {
  .header-cta { display: none; }
  .menu-toggle { display: block; }
  .main-navigation { background: #0a0f17; border-top: 1px solid var(--ach-border); display: none; left: 0; margin: 0; max-height: calc(100vh - var(--ach-header-height)); overflow-y: auto; padding: 1rem; position: absolute; right: 0; top: 100%; }
  .main-navigation.is-open { display: block; }
  .main-navigation ul { align-items: stretch; flex-direction: column; }
  .main-navigation a { font-size: 1.1rem; padding: .9rem; }
  body.menu-open { overflow: hidden; }
  .main-navigation .sub-menu { border: 0; display: none; margin-left: 1rem; min-width: 0; position: static; }
  .main-navigation .submenu-open > .sub-menu { display: flex; }
  .main-navigation li:hover > .sub-menu:not([data-mobile-ready]), .main-navigation li:focus-within > .sub-menu:not([data-mobile-ready]) { display: none; }
  .main-navigation .menu-item-has-children > a { padding-right: 3.5rem; }
  .submenu-toggle { background: transparent; border: 0; color: var(--ach-text); display: block; font-size: 1.4rem; line-height: 1; padding: .7rem 1rem; position: absolute; right: 0; top: .35rem; }
  .submenu-toggle::before { content: "+"; }
  .submenu-toggle[aria-expanded="true"]::before { content: "−"; }
  .mobile-menu-cta { display: flex; margin-top: 1rem; }
  .ach-grid--4 { grid-template-columns: repeat(2, 1fr); }
  .ach-sponsor-row { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 782px) {
  body.admin-bar .site-header { top: 46px; }
  :root { --ach-header-height: 68px; --ach-section-space: 56px; }
  .custom-logo { max-height: 44px; }
  .site-title { font-size: 1rem; }
  .site-tagline { font-size: .7rem; }
  .ach-hero { grid-template-columns: 1fr; min-height: 0; padding-block: 3.5rem; }
  .ach-hero__media { min-height: 300px; order: -1; }
  .ach-info-strip, .ach-grid--2, .ach-grid--3, .ach-grid--4, .footer-grid { grid-template-columns: 1fr; }
  .ach-event { grid-template-columns: 55px 1fr; }
  .ach-event .ach-pill { grid-column: 2; justify-self: start; }
  .ach-sponsor-row { grid-template-columns: repeat(2, 1fr); }
  .ach-banner, .footer-sponsors, .footer-bottom { align-items: flex-start; flex-direction: column; }
  .footer-sponsors__names { gap: 1rem; }
  .alignleft, .alignright { float: none; margin-inline: 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}

@media print {
  .site-header, .site-footer, .menu-toggle { display: none; }
  .site-main { padding-top: 0; }
  body { background: #fff; color: #000; }
}
