/*
Theme Name: GO Jugendschutz
Theme URI: https://www.go-jugendschutz.de/
Author: GO Jugendschutz
Description: Barrierearmes, responsives WordPress Theme für GO Jugendschutz mit Paketdarstellung, Blog und Contact Form 7 Integration.
Version: 1.4.1
Requires at least: 6.4
Tested up to: 6.9
Requires PHP: 8.0
Text Domain: go-jugendschutz
*/

:root {
  --gj-red: #d10b12;
  --gj-red-dark: #99070d;
  --gj-red-bright: #ef161c;
  --gj-ink: #15191e;
  --gj-charcoal: #20252b;
  --gj-muted: #5c646d;
  --gj-line: #dfe3e7;
  --gj-soft: #f4f5f6;
  --gj-white: #fff;
  --gj-radius: 14px;
  --gj-shadow: 0 16px 45px rgba(18, 23, 28, .12);
  --gj-focus: #ffbf47;
  --gj-content: 1180px;
  --gj-hero-height: 430px;
  --gj-hero-image-scale: .9;
  --gj-hero-image-position: 50%;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--gj-ink);
  background: var(--gj-white);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; }
a { color: var(--gj-red-dark); text-decoration-thickness: .12em; text-underline-offset: .18em; }
a:hover { color: var(--gj-red); }
button, input, textarea, select { font: inherit; }
:focus-visible { outline: 3px solid var(--gj-focus); outline-offset: 3px; }
.screen-reader-text {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.screen-reader-text:focus {
  position: fixed !important; z-index: 99999; top: 12px; left: 12px; width: auto; height: auto;
  clip: auto; padding: .75rem 1rem; margin: 0; background: #fff; color: #000;
  border: 2px solid var(--gj-ink); font-weight: 800;
}
.gj-container { width: min(calc(100% - 2rem), var(--gj-content)); margin-inline: auto; }
.gj-section { padding: clamp(3.5rem, 7vw, 6.5rem) 0; }
.gj-section-title { margin: 0 0 .75rem; font-size: clamp(2rem, 4vw, 3.25rem); line-height: 1.12; letter-spacing: -.03em; }
.gj-section-lead { max-width: 760px; margin: 0 0 2rem; color: var(--gj-muted); font-size: 1.12rem; }

.gj-button, .wp-block-button__link, input[type="submit"], button[type="submit"] {
  display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .72rem 1.25rem;
  border: 2px solid var(--gj-red); border-radius: 8px; background: var(--gj-red); color: #fff;
  font-weight: 780; line-height: 1.2; text-decoration: none; cursor: pointer; transition: .2s ease;
}
.gj-button:hover, .wp-block-button__link:hover, input[type="submit"]:hover, button[type="submit"]:hover {
  background: var(--gj-red-dark); border-color: var(--gj-red-dark); color: #fff; transform: translateY(-1px);
}
.gj-button--light { background: #fff; color: var(--gj-red-dark); border-color: #fff; }
.gj-button--light:hover { background: var(--gj-soft); color: var(--gj-red-dark); border-color: var(--gj-soft); }
.gj-button--outline { background: transparent; color: currentColor; border-color: currentColor; }
.gj-button--outline:hover { background: rgba(255,255,255,.12); border-color: currentColor; color: currentColor; }

.site-header { position: relative; z-index: 100; background: rgba(255,255,255,.98); border-top: 4px solid var(--gj-red); box-shadow: 0 2px 18px rgba(0,0,0,.06); }
.site-header__inner { min-height: 84px; display: flex; align-items: center; gap: 2rem; }
.custom-logo-link { display: inline-flex; align-items: center; flex: 0 0 auto; }
.custom-logo { max-height: 55px; width: auto; }
.gj-wordmark { display: inline-flex; position: relative; color: var(--gj-red); font-weight: 900; font-size: 1.25rem; letter-spacing: -.04em; text-decoration: none; text-transform: uppercase; }
.gj-wordmark::after { content: ""; position: absolute; right: -18px; bottom: -7px; width: 74px; height: 21px; border-bottom: 3px solid var(--gj-red); border-radius: 50%; transform: rotate(4deg); }
.site-navigation { margin-left: auto; }
.site-navigation ul { list-style: none; margin: 0; padding: 0; }
.site-navigation > ul { display: flex; align-items: center; gap: .25rem; }
.site-navigation li { position: relative; }
.site-navigation a { display: block; padding: .7rem .85rem; color: var(--gj-ink); font-weight: 650; text-decoration: none; border-radius: 6px; }
.site-navigation a:hover, .site-navigation .current-menu-item > a { color: var(--gj-red-dark); background: var(--gj-soft); }
.site-navigation .menu-item-has-children > a::after { content: "▾"; display: inline-block; margin-left: .4rem; color: var(--gj-red-dark); font-size: .75em; }
.site-navigation .sub-menu {
  position: absolute; z-index: 110; top: calc(100% + .4rem); left: 0; display: block; min-width: 235px;
  padding: .55rem; visibility: hidden; opacity: 0; transform: translateY(-7px); pointer-events: none;
  border: 1px solid var(--gj-line); border-radius: 9px; background: #fff; box-shadow: 0 15px 38px rgba(0,0,0,.15); transition: .18s ease;
}
.site-navigation .sub-menu::before { content: ""; position: absolute; inset: -.5rem 0 auto; height: .5rem; }
.site-navigation .sub-menu a { padding: .72rem .8rem; white-space: normal; }
.site-navigation li:hover > .sub-menu, .site-navigation li:focus-within > .sub-menu { visibility: visible; opacity: 1; transform: translateY(0); pointer-events: auto; }
.site-navigation .sub-menu .sub-menu { top: 0; left: calc(100% + .45rem); }
.header-actions { display: flex; align-items: center; gap: .6rem; }
.header-phone { color: var(--gj-ink); font-weight: 800; text-decoration: none; white-space: nowrap; }
.menu-toggle { display: none; min-width: 48px; min-height: 48px; padding: .5rem; color: var(--gj-ink); background: #fff; border: 2px solid var(--gj-ink); border-radius: 8px; }

.gj-hero { position: relative; overflow: hidden; color: #fff; background: linear-gradient(115deg, #7f050a 0%, var(--gj-red) 45%, #e0161c 100%); }
.gj-hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 70% 20%, rgba(255,255,255,.13), transparent 38%); }
.gj-hero__inner { position: relative; min-height: var(--gj-hero-height); display: grid; grid-template-columns: minmax(0, .95fr) minmax(400px, 1.05fr); align-items: stretch; }
.gj-hero__content { z-index: 2; align-self: center; padding: clamp(1.7rem, 3.5vw, 3rem) clamp(2rem, 5vw, 5rem) clamp(5.3rem, 7vw, 6.6rem) 0; }
.gj-eyebrow { display: inline-block; margin-bottom: 1rem; font-size: .86rem; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.gj-hero h1 { max-width: 650px; margin: 0 0 1.25rem; font-size: clamp(2.55rem, 5.5vw, 4.65rem); line-height: 1.02; letter-spacing: -.045em; }
.gj-hero__lead { max-width: 640px; margin: 0 0 1.4rem; font-size: clamp(1.08rem, 2vw, 1.27rem); }
.gj-checks { list-style: none; margin: 0 0 2rem; padding: 0; }
.gj-checks li { position: relative; margin: .48rem 0; padding-left: 1.7rem; font-weight: 620; }
.gj-checks li::before { content: "✓"; position: absolute; left: 0; font-weight: 900; }
.gj-hero__actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.gj-hero__media { position: relative; min-height: 100%; overflow: hidden; }
.gj-hero__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--gj-red) 0%, rgba(209,11,18,.72) 10%, rgba(209,11,18,.05) 42%, rgba(209,11,18,.2) 100%), linear-gradient(0deg, rgba(209,11,18,.75), transparent 38%); }
.gj-hero__media img { width: 100%; height: 100%; min-height: var(--gj-hero-height); object-fit: cover; object-position: center var(--gj-hero-image-position); filter: saturate(.9) contrast(1.03); transform: scale(var(--gj-hero-image-scale)); transition: transform .25s ease; }
.gj-hero__visual-fallback { position: absolute; inset: 0; display: grid; place-items: center; background: radial-gradient(circle at 55% 45%, #f54a4e 0 9%, transparent 10%), radial-gradient(circle at 70% 36%, #aa070d 0 18%, transparent 19%); }
.gj-shield { width: min(58%, 320px); aspect-ratio: .82; display: grid; place-items: center; border: 8px solid rgba(255,255,255,.85); border-radius: 48% 48% 55% 55% / 28% 28% 68% 68%; color: white; font-size: 5rem; font-weight: 900; transform: perspective(500px) rotateY(-8deg); box-shadow: 0 28px 60px rgba(70,0,0,.35), inset 0 0 0 14px rgba(255,255,255,.08); }

.gj-packages { position: relative; z-index: 4; margin-top: -82px; padding-bottom: 1.5rem; }
.gj-packages__intro { max-width: 770px; margin: 0 auto 1.6rem; text-align: center; color: #fff; }
.gj-package-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; max-width: 900px; margin-inline: auto; align-items: stretch; }
.gj-package { position: relative; display: flex; flex-direction: column; padding: 2.2rem; background: #fff; color: var(--gj-ink); border: 1px solid var(--gj-line); border-radius: var(--gj-radius); box-shadow: var(--gj-shadow); }
.gj-package--featured { border: 2px solid var(--gj-red); transform: translateY(-10px); }
.gj-package__badge { position: absolute; inset: 0 0 auto; min-height: 34px; display: grid; place-items: center; padding: .25rem; border-radius: 11px 11px 0 0; background: var(--gj-red); color: #fff; font-weight: 850; font-size: .8rem; letter-spacing: .05em; text-transform: uppercase; }
.gj-package__name { margin: .3rem 0 0; text-align: center; font-size: 1.25rem; }
.gj-package--featured .gj-package__name { margin-top: 1.45rem; }
.gj-package__price { margin: .8rem 0 1.25rem; text-align: center; font-size: 3rem; font-weight: 900; line-height: 1; }
.gj-package__price small { display: block; margin-top: .4rem; color: var(--gj-muted); font-size: .92rem; font-weight: 600; }
.gj-package ul { flex: 1; list-style: none; margin: 0 0 1.5rem; padding: 0; }
.gj-package li { position: relative; padding: .6rem 0 .6rem 1.6rem; border-bottom: 1px solid var(--gj-line); }
.gj-package li::before { content: "✓"; position: absolute; left: 0; color: var(--gj-red); font-weight: 900; }
.gj-price-note { margin: 1.25rem 0 0; color: var(--gj-muted); text-align: center; }

.gj-trust { background: var(--gj-soft); border-block: 1px solid var(--gj-line); }
.gj-trust__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; padding: 1.3rem 0; }
.gj-trust__item { display: flex; align-items: center; gap: .7rem; font-weight: 750; }
.gj-trust__icon { flex: 0 0 auto; width: 42px; height: 42px; display: grid; place-items: center; border: 2px solid var(--gj-red); border-radius: 50%; color: var(--gj-red); font-weight: 900; }

.gj-process { background: #fff; }
.gj-process__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; counter-reset: steps; }
.gj-step { position: relative; padding: 2rem; border: 1px solid var(--gj-line); border-radius: var(--gj-radius); background: #fff; }
.gj-step::before { counter-increment: steps; content: counter(steps); width: 48px; height: 48px; display: grid; place-items: center; margin-bottom: 1.1rem; border-radius: 50%; background: var(--gj-red); color: #fff; font-weight: 900; }
.gj-step h3 { margin: 0 0 .55rem; font-size: 1.25rem; }
.gj-step p { margin: 0; color: var(--gj-muted); }

.gj-news { background: var(--gj-soft); }
.gj-news__head { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 2rem; }
.gj-post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.gj-post-card { overflow: hidden; background: #fff; border: 1px solid var(--gj-line); border-radius: var(--gj-radius); box-shadow: 0 8px 25px rgba(20,25,30,.07); }
.gj-post-card__media { display: block; aspect-ratio: 16/8.5; background: linear-gradient(135deg, var(--gj-charcoal), var(--gj-red-dark)); overflow: hidden; }
.gj-post-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.gj-post-card:hover .gj-post-card__media img { transform: scale(1.03); }
.gj-post-card__body { padding: 1.35rem; }
.gj-post-card__meta { color: var(--gj-red-dark); font-weight: 800; font-size: .82rem; text-transform: uppercase; letter-spacing: .04em; }
.gj-post-card h3 { margin: .45rem 0 .55rem; font-size: 1.25rem; line-height: 1.25; }
.gj-post-card h3 a { color: var(--gj-ink); text-decoration: none; }
.gj-post-card p { margin: 0 0 1rem; color: var(--gj-muted); }
.gj-text-link { font-weight: 850; }

.gj-cta { padding: clamp(2.75rem, 5vw, 4.25rem) 0; color: #fff; background: linear-gradient(115deg, var(--gj-red-dark), var(--gj-red)); }
.gj-cta__inner { display: grid; grid-template-columns: 1.15fr .85fr; gap: 3rem; align-items: center; }
.gj-cta h2 { margin: 0 0 .7rem; font-size: clamp(2rem, 4vw, 3.2rem); line-height: 1.1; }
.gj-contact-box { width: 100%; max-width: 450px; justify-self: end; padding: 1.2rem; border: 1px solid rgba(255,255,255,.3); border-radius: var(--gj-radius); background: rgba(255,255,255,.1); }
.gj-phone-large { display: block; margin: .35rem 0 1rem; color: #fff; font-size: clamp(1.8rem, 4vw, 2.7rem); font-weight: 900; text-decoration: none; }

.site-main--content { min-height: 55vh; padding: clamp(3rem, 7vw, 6rem) 0; }
.entry-header, .entry-content, .entry-footer, .comments-area, .posts-navigation, .pagination { width: min(calc(100% - 2rem), 840px); margin-inline: auto; }
.entry-title { margin: 0 0 1rem; font-size: clamp(2.2rem, 5vw, 4rem); line-height: 1.08; }
.entry-meta { margin-bottom: 2rem; color: var(--gj-muted); }
.entry-content { font-size: 1.08rem; }
.entry-content h2, .entry-content h3 { line-height: 1.2; margin-top: 2em; }
.entry-content img { border-radius: 10px; }
.archive-header { margin-bottom: 2rem; }

.wpcf7 form { display: grid; gap: 1rem; }
.wpcf7 label { display: block; font-weight: 800; }
.wpcf7 input:not([type="submit"]):not([type="checkbox"]):not([type="radio"]), .wpcf7 textarea, .wpcf7 select,
.gj-form-control {
  width: 100%; min-height: 50px; margin-top: .35rem; padding: .75rem .85rem; color: var(--gj-ink); background: #fff;
  border: 2px solid #69727b; border-radius: 7px;
}
.wpcf7 textarea { min-height: 150px; resize: vertical; }
.wpcf7-not-valid-tip { margin-top: .35rem; color: #8a0010; font-weight: 800; }
.wpcf7 form .wpcf7-response-output { margin: 1rem 0 0; padding: .8rem 1rem; border: 3px solid var(--gj-red); border-radius: 6px; }
.entry-content .wpcf7 { max-width: 680px; }
.entry-content .wpcf7 form { display: block; }
.entry-content .wpcf7 p { margin: 0 0 .78rem; }
.entry-content .wpcf7 label { font-size: .92rem; }
.entry-content .wpcf7 input:not([type="submit"]):not([type="checkbox"]):not([type="radio"]),
.entry-content .wpcf7 select { min-height: 43px; margin-top: .22rem; padding: .5rem .65rem; }
.entry-content .wpcf7 textarea { min-height: 110px; max-height: 160px; margin-top: .22rem; padding: .55rem .65rem; }
.entry-content .wpcf7 input[type="submit"] { min-height: 44px; padding: .6rem 1rem; }
.entry-content .wpcf7-acceptance label { display: flex; gap: .5rem; align-items: flex-start; font-size: .82rem; line-height: 1.45; }
.entry-content .wpcf7-acceptance input { flex: 0 0 auto; margin-top: .18rem; }
.gj-contact-box .wpcf7 form { display: block; }
.gj-contact-box .wpcf7 p { margin: 0 0 .72rem; }
.gj-contact-box .wpcf7 label { font-size: .9rem; }
.gj-contact-box .wpcf7 input:not([type="submit"]):not([type="checkbox"]):not([type="radio"]),
.gj-contact-box .wpcf7 select { min-height: 43px; margin-top: .25rem; padding: .5rem .65rem; }
.gj-contact-box .wpcf7 textarea { min-height: 105px; max-height: 150px; margin-top: .25rem; padding: .55rem .65rem; }
.gj-contact-box .wpcf7 input[type="submit"] { min-height: 44px; padding: .6rem 1rem; }
.gj-contact-box .wpcf7-acceptance label { display: flex; gap: .5rem; align-items: flex-start; font-size: .8rem; line-height: 1.4; }
.gj-contact-box .wpcf7-acceptance input { flex: 0 0 auto; margin-top: .2rem; }

.site-footer { color: #e8ebee; background: #171c21; }
.site-footer__grid { display: grid; grid-template-columns: 1.3fr .9fr 1fr; gap: clamp(2rem, 6vw, 5rem); padding: 4rem 0 2.5rem; }
.site-footer h2 { color: #fff; font-size: 1.05rem; }
.site-footer a { color: #fff; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: .45rem 0; }
.site-footer .gj-wordmark { color: #ff3035; }
.site-footer .gj-phone-large { margin: .35rem 0 1rem; font-size: 1.2rem; line-height: 1.25; white-space: nowrap; }
.site-footer__bottom { padding: 1.2rem 0; border-top: 1px solid #3c434a; color: #bcc2c8; font-size: .9rem; }
.mobile-actions { display: none; }

@media (max-width: 1020px) {
  .header-phone { display: none; }
  .gj-hero__inner { grid-template-columns: 1fr 46%; }
  .gj-hero__content { padding-left: 1rem; }
  .gj-trust__grid { grid-template-columns: repeat(2, 1fr); }
  .site-footer__grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 820px) {
  body { padding-bottom: 74px; }
  .site-header__inner { min-height: 72px; flex-wrap: wrap; gap: .7rem; padding-block: .65rem; }
  .menu-toggle { display: inline-grid; place-items: center; margin-left: auto; }
  .header-actions .gj-button { display: none; }
  .site-navigation { display: none; order: 3; width: 100%; margin: 0; }
  .site-navigation.is-open { display: block; }
  .site-navigation > ul { display: block; padding: .5rem 0; border-top: 1px solid var(--gj-line); }
  .site-navigation a { padding: .85rem .4rem; }
  .site-navigation .sub-menu, .site-navigation .sub-menu .sub-menu {
    position: static; min-width: 0; margin: 0 0 .3rem .8rem; padding: 0 0 0 .85rem; visibility: visible; opacity: 1;
    transform: none; pointer-events: auto; border: 0; border-left: 3px solid var(--gj-red); border-radius: 0; box-shadow: none;
  }
  .site-navigation .sub-menu a { padding: .7rem .45rem; }
  .gj-hero__inner { min-height: auto; display: flex; flex-direction: column; }
  .gj-hero__content { order: 1; padding: 3.6rem 0 2rem; }
  .gj-hero__media { order: 2; min-height: 300px; margin-inline: -1rem; }
  .gj-hero__media img { min-height: 300px; max-height: 390px; transform: none; }
  .gj-hero__media::after { background: linear-gradient(180deg, var(--gj-red) 0%, rgba(209,11,18,.05) 24%, rgba(209,11,18,.35) 100%); }
  .gj-packages { margin-top: 0; padding-top: 1.25rem; background: var(--gj-soft); }
  .gj-package-grid, .gj-process__grid, .gj-post-grid, .gj-cta__inner { grid-template-columns: 1fr; }
  .gj-package--featured { order: -1; transform: none; }
  .gj-package { padding: 1.6rem; }
  .gj-contact-box { max-width: none; justify-self: stretch; }
  .gj-news__head { align-items: start; flex-direction: column; }
  .mobile-actions { position: fixed; z-index: 90; inset: auto 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: .55rem; padding: .55rem max(.65rem, env(safe-area-inset-right)) max(.55rem, env(safe-area-inset-bottom)) max(.65rem, env(safe-area-inset-left)); background: rgba(23,28,33,.97); box-shadow: 0 -8px 25px rgba(0,0,0,.2); }
  .mobile-actions .gj-button { width: 100%; min-height: 50px; }
}

@media (max-width: 560px) {
  .gj-container { width: min(calc(100% - 1.25rem), var(--gj-content)); }
  .gj-wordmark { font-size: 1.05rem; }
  .gj-hero h1 { font-size: clamp(2.4rem, 12vw, 3.3rem); }
  .gj-hero__actions { display: grid; }
  .gj-button { width: 100%; }
  .gj-trust__grid { grid-template-columns: 1fr; }
  .gj-trust__item { font-size: .95rem; }
  .site-footer__grid { grid-template-columns: 1fr; }
}

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

@media (prefers-contrast: more) {
  :root { --gj-muted: #343a40; --gj-line: #68717a; }
  .gj-package, .gj-post-card, .gj-step { border-width: 2px; }
}
