/* GrainLab – shared base styles (tokens, reset, keyframes, chrome, slots).
   Page layouts live inline in the page HTML (from the Claude Design export). */

:root { --gl-header-h: 72px;
  --gl-accent: #d6633f; --gl-accent-dark: #bd5330; --gl-accent-deep: #a3421f; --gl-accent-text: #b04a26; --gl-accent-soft: #db8f69;
  --gl-on-primary-link: #eab89b;
  --gl-primary: #34495d; --gl-primary-dark: #26384a; --gl-surface: #ecf2f6;
  --gl-ink: #262b2c; --gl-ink-2: #4c5356; --gl-ink-3: #5f686c; --gl-ink-4: #8f989c;
  --gl-w: max(1320px, min(88vw, 1720px));
  --gl-t11: 11px; --gl-t13: 13px; --gl-t14: 14px; --gl-t15: 15px; --gl-t16: 16px;
  --gl-h1: clamp(34px,5vw,64px); --gl-h2: clamp(24px,3.2vw,42px); --gl-h3: clamp(16px,1.7vw,20px); --gl-lead: clamp(15px,1.4vw,18px);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: #ffffff; color: var(--gl-ink); font-family: 'Montserrat', system-ui, sans-serif; font-size: 15px; line-height: 1.55; font-weight: 400; }
/* base type from the design-system sheet the export loaded (pages override inline) */
h1, h2, h3, h4, h5, h6 { line-height: 1.12; letter-spacing: -0.015em; margin: 0 0 10px; }
p { margin: 0 0 15px; }
figure { margin: 0; }
::selection { background: rgba(214,99,63,.2); }
a { color: #34495d; text-decoration: none; text-underline-offset: 3px; }
a:hover { color: #d6633f; }
button, input, textarea, select { font-family: inherit; }
:focus-visible { outline: 2px solid #d6633f; outline-offset: 3px; }
[hidden] { display: none !important; }
img { display: block; max-width: 100%; }

/* ---- motion ---- */
@keyframes glFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes glIn { from { opacity: 0; transform: translateY(22px); filter: blur(12px); } to { opacity: 1; transform: none; filter: blur(0); } }
@keyframes glRise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes glHint { 0%, 100% { transform: translateY(0); opacity: .55; } 50% { transform: translateY(6px); opacity: 1; } }
@keyframes glSpin { to { transform: rotate(360deg); } }
@keyframes glShift { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(2.5px); } }
@keyframes glTwinkle { 0%, 100% { opacity: .3; } 50% { opacity: 1; } }
@keyframes glPanel { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: none; } }

/* Film-Lightbox (Startseite, Arbeiten). Mit Titel/Text: Player bis 56vh (wie bisher).
   Ohne Textblock (Showreel, data-lb-wide): Player so groß, wie der Bildschirm erlaubt
   (oben 24px Rand + Schließen-Zeile 50px, unten 24px Rand). */
.gl-film-lb { padding: 24px; }
.gl-film-lb-panel { width: min(1040px, 100%); }
.gl-film-lb-player { width: min(100%, calc(56vh * 16 / 9)); max-height: 56vh; }
.gl-film-lb-panel[data-lb-wide] { width: min(1920px, 100%); }
.gl-film-lb-panel[data-lb-wide] .gl-film-lb-player { width: min(100%, calc((100vh - 110px) * 16 / 9)); max-height: calc(100vh - 110px); }
@supports (height: 100svh) {
  .gl-film-lb-panel[data-lb-wide] .gl-film-lb-player { width: min(100%, calc((100svh - 110px) * 16 / 9)); max-height: calc(100svh - 110px); }
}
@media (max-width: 600px) { .gl-film-lb { padding: 16px 12px; } }
@keyframes glCaret { 0%, 49% { opacity: 1; } 50%, 100% { opacity: 0; } }
@keyframes glMarqueeL2R { from { transform: translateX(-50%); } to { transform: translateX(0); } }
@keyframes glMarqueeR2L { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  @keyframes glIn { from { opacity: 0; } to { opacity: 1; } }
  @keyframes glRise { from { opacity: 0; } to { opacity: 1; } }
  @keyframes glHint { from { opacity: .7; } to { opacity: .7; } }
  @keyframes glMarqueeL2R { from { transform: translateX(0); } to { transform: translateX(0); } }
  @keyframes glMarqueeR2L { from { transform: translateX(0); } to { transform: translateX(0); } }
}

/* ---- header / navigation (shared partial) ---- */
.gl-header { position: fixed; top: 0; left: 0; right: 0; z-index: 60; background: rgba(255,255,255,.7); backdrop-filter: blur(24px) saturate(180%); -webkit-backdrop-filter: blur(24px) saturate(180%); border-bottom: 1px solid rgba(38,43,44,.06); }
.gl-header-in { max-width: var(--gl-w); margin: 0 auto; padding: 0 clamp(18px,3vw,32px); height: var(--gl-header-h); display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.gl-logo { display: flex; align-items: center; flex: 0 0 auto; }
.gl-logo img { height: 30px; width: auto; display: block; }
.gl-nav { display: flex; align-items: center; gap: 30px; }
.gl-nav a { font-size: var(--gl-t14); font-weight: 500; color: var(--gl-ink-2); }
.gl-nav a[aria-current="page"] { color: var(--gl-accent-text); font-weight: 600; }
.gl-nav a:hover { color: var(--gl-accent); }
.gl-header-cta { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.gl-btn-cta { display: inline-flex; align-items: center; height: 38px; padding: 0 20px; border-radius: 999px; background: var(--gl-accent-dark); color: #ffffff; font-size: var(--gl-t14); font-weight: 600; transition: transform .18s cubic-bezier(.22,1,.36,1), background .2s ease; }
.gl-btn-cta:hover { background: var(--gl-accent-deep); color: #ffffff; }
.gl-btn-cta:active { transform: scale(.96); }
.gl-burger { display: none; width: 40px; height: 40px; margin-right: -6px; align-items: center; justify-content: center; border: 0; background: transparent; padding: 0; cursor: pointer; }
.gl-burger span { display: block; width: 20px; height: 9px; border-top: 1.5px solid var(--gl-ink); border-bottom: 1.5px solid var(--gl-ink); }
@media (max-width: 900px) {
  .gl-nav { display: none; }
  .gl-burger { display: flex; }
  /* Handy/Tablet: Leiste etwas flacher, Logo etwas kleiner als am Desktop */
  :root { --gl-header-h: 64px; }
  .gl-logo img { height: 26px; }
}
@media (max-width: 480px) {
  .gl-header-cta .gl-btn-cta { display: none; }
}

/* mobile menu overlay */
.gl-menu { position: fixed; inset: 0; z-index: 70; background: rgba(255,255,255,.95); backdrop-filter: blur(30px) saturate(180%); -webkit-backdrop-filter: blur(30px) saturate(180%); display: flex; flex-direction: column; padding: 18px 22px 40px; animation: glFade .22s ease both; overflow-y: auto; }
.gl-menu-top { height: 40px; display: flex; align-items: center; justify-content: space-between; }
.gl-menu-top img { height: 26px; width: auto; }
.gl-menu-close { width: 38px; height: 38px; border: 0; background: transparent; font-size: 26px; line-height: 1; color: var(--gl-ink); cursor: pointer; }
.gl-menu-links { display: flex; flex-direction: column; gap: 2px; margin-top: 32px; }
.gl-menu-links a { font-family: 'termina', sans-serif; font-size: 32px; font-weight: 600; letter-spacing: -.02em; color: var(--gl-ink); padding: 12px 0; }
.gl-menu-links a.gl-menu-accent { color: var(--gl-accent-text); }
.gl-menu-sub { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 28px; padding-top: 22px; border-top: 1px solid rgba(38,43,44,.09); }
.gl-menu-sub a { font-size: var(--gl-t14); font-weight: 500; color: var(--gl-ink-2); padding: 6px 0; }
body.gl-menu-open { overflow: hidden; }

/* ---- footer (shared partial) ---- */
.gl-footer { background: var(--gl-primary); color: rgba(255,255,255,.72); padding: clamp(46px,5.5vh,68px) clamp(18px,4vw,40px) 40px; }
.gl-footer-in { max-width: var(--gl-w); margin: 0 auto; display: flex; flex-wrap: wrap; gap: clamp(28px,3vw,48px); }
.gl-footer-brand { flex: 1 1 340px; }
.gl-footer-brand img { height: 26px; width: auto; display: block; margin-bottom: 24px; }
.gl-footer-brand p { margin: 0; max-width: 60ch; font-size: var(--gl-t14); line-height: 1.7; font-weight: 300; color: rgba(255,255,255,.66); text-wrap: pretty; }
.gl-footer-col { flex: 0 1 190px; }
.gl-footer-col.wide { flex: 0 1 210px; }
.gl-footer-col.contact { flex: 0 1 240px; }
.gl-footer-h { margin: 0 0 16px; font-size: var(--gl-t11); font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: rgba(255,255,255,.5); }
.gl-footer-links { display: flex; flex-direction: column; gap: 10px; }
.gl-footer-links a, .gl-footer-col p a { font-size: var(--gl-t14); color: rgba(255,255,255,.82); }
.gl-footer-links a:hover, .gl-footer-col p a:hover { color: var(--gl-on-primary-link); }
.gl-footer-col p { margin: 0; font-size: var(--gl-t14); line-height: 1.7; font-weight: 300; color: rgba(255,255,255,.82); }
.gl-footer-col p a { color: var(--gl-on-primary-link); }
.gl-footer-legal { max-width: var(--gl-w); margin: clamp(30px,4vh,44px) auto 0; font-size: 12px; color: rgba(255,255,255,.42); display: flex; flex-wrap: wrap; gap: 6px 14px; }
.gl-footer-legal a { color: rgba(255,255,255,.6); }
.gl-footer-legal a:hover { color: var(--gl-on-primary-link); }

/* ---- image slots (placeholders until real images are dropped in) ---- */
.gl-slot { position: relative; display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; min-height: 0; overflow: hidden; background: rgba(127,127,127,.08); color: inherit; }
.gl-slot::after { content: ""; position: absolute; inset: 0; pointer-events: none; border: 1.5px dashed currentColor; opacity: .35; border-radius: inherit; }
.gl-slot-cap { display: flex; flex-direction: column; align-items: center; gap: 8px; font: 500 12px/1.4 'Montserrat', system-ui, sans-serif; text-align: center; padding: 12px; opacity: .7; user-select: none; }
.gl-slot-cap::before { content: ""; width: 22px; height: 22px; opacity: .8; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='16' rx='2'/%3E%3Ccircle cx='9' cy='10' r='1.8'/%3E%3Cpath d='M21 16l-5-5-8 8'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='16' rx='2'/%3E%3Ccircle cx='9' cy='10' r='1.8'/%3E%3Cpath d='M21 16l-5-5-8 8'/%3E%3C/svg%3E") center / contain no-repeat; }

/* ---- Foto-Laufband + Galerie (Case-Seiten, Über uns; JS: assets/js/case.js) ---- */
/* Stills-Laufband: anhalten, solange man drueberfaehrt oder per Tastatur darin ist */
.gl-stills-view:hover .gl-stills-track, .gl-stills-view:focus-within .gl-stills-track { animation-play-state: paused; }
.gl-zoom { transition: opacity .2s ease; }
.gl-zoom:hover img, .gl-zoom:focus-visible img { opacity: .88; }
.gl-zoom:focus-visible { outline: 2px solid var(--gl-accent); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  /* Keyframes stehen dann still (site.css): seitlich scrollen statt laufen, ohne die Kopien */
  .gl-stills-view { overflow-x: auto !important; }
  .gl-stills-track > [aria-hidden="true"] { display: none; }
}

/* Galerie (assets/js/case.js) */
.gl-gal { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(14,17,19,.95); color: #ffffff; overflow: hidden; }
.gl-gal[open] { display: flex; align-items: center; justify-content: center; }
.gl-gal::backdrop { background: rgba(14,17,19,.95); }
.gl-gal-fig { margin: 0; width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; padding: 64px max(84px, env(safe-area-inset-right, 0px)) 64px max(84px, env(safe-area-inset-left, 0px)); box-sizing: border-box; }
.gl-gal-img { display: block; width: auto; height: auto; max-width: 100%; max-height: 100%; border-radius: 10px; object-fit: contain; user-select: none; -webkit-user-drag: none; touch-action: pan-y; }
.gl-gal-count { position: absolute; left: 0; right: 0; bottom: max(20px, env(safe-area-inset-bottom, 0px)); margin: 0; text-align: center; font: 600 12px/1 'Montserrat', system-ui, sans-serif; letter-spacing: .16em; color: rgba(255,255,255,.7); pointer-events: none; }
.gl-gal-btn { position: absolute; display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; border: 0; border-radius: 50%; padding: 0; background: var(--gl-accent-dark); color: #ffffff; cursor: pointer; transition: background .2s ease, transform .2s cubic-bezier(.22,1,.36,1); }
.gl-gal-btn:hover { background: var(--gl-accent-deep); }
.gl-gal-btn:focus-visible { outline: 2px solid #ffffff; outline-offset: 3px; }
.gl-gal-prev { left: max(18px, env(safe-area-inset-left, 0px)); top: 50%; transform: translateY(-50%); }
.gl-gal-next { right: max(18px, env(safe-area-inset-right, 0px)); top: 50%; transform: translateY(-50%); }
.gl-gal-close { top: max(16px, env(safe-area-inset-top, 0px)); right: max(16px, env(safe-area-inset-right, 0px)); width: 44px; height: 44px; background: rgba(255,255,255,.14); }
.gl-gal-close:hover { background: rgba(255,255,255,.24); }
.gl-gal-single .gl-gal-prev, .gl-gal-single .gl-gal-next { display: none; }
@media (max-width: 640px) {
  .gl-gal-fig { padding: 64px 12px 96px; }
  .gl-gal-prev, .gl-gal-next { top: auto; bottom: max(14px, env(safe-area-inset-bottom, 0px)); transform: none; width: 48px; height: 48px; }
  .gl-gal-count { bottom: max(32px, calc(env(safe-area-inset-bottom, 0px) + 18px)); }
}

/* ---- legal / text pages ---- */
/* Normale Containerbreite wie die übrigen Abschnitte (Fabian, 24.11.2026): --gl-w plus Seitenrand, weil border-box das Padding in max-width einrechnet. */
.gl-prose { max-width: calc(var(--gl-w) + 2 * clamp(18px,4vw,40px)); margin: 0 auto; padding: clamp(96px,10vh,116px) clamp(18px,4vw,40px) clamp(56px,7vh,96px); font-size: var(--gl-t15); line-height: 1.75; color: var(--gl-ink-2); }
.gl-prose h1 { font-family: 'termina', sans-serif; hyphens: auto; overflow-wrap: break-word; font-size: var(--gl-h1); line-height: 1.02; letter-spacing: -.03em; font-weight: 700; color: var(--gl-ink); margin: 0 0 28px; }
.gl-prose h2 { font-family: 'termina', sans-serif; hyphens: auto; overflow-wrap: break-word; font-size: clamp(20px,2.2vw,28px); letter-spacing: -.02em; color: var(--gl-ink); margin: 42px 0 12px; }
.gl-prose h3 { font-size: var(--gl-t16); color: var(--gl-ink); margin: 26px 0 8px; }
.gl-prose p, .gl-prose ul { margin: 0 0 14px; }
.gl-prose a { color: var(--gl-accent-text); text-decoration: underline; text-underline-offset: 3px; }
.gl-prose .gl-kicker { display: block; margin: 0 0 14px; font-size: var(--gl-t11); font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: var(--gl-accent-text); }

/* Termina laeuft sehr breit: lange deutsche Komposita (Produktionsgeschichte,
   Datenschutzerklaerung) passen auf dem Handy nicht in eine Zeile. Dort
   duerfen Ueberschriften trennen – die Hero-Headline nicht. */
@media (max-width: 480px) {
  h1, h2, h3 { hyphens: auto; overflow-wrap: break-word; }
  #top h1 { hyphens: manual; }
}

/* nur fuer Screenreader sichtbar (z. B. H1 der Cases-Seite) */
.gl-sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0 0 0 0) !important; clip-path: inset(50%) !important; white-space: nowrap !important; border: 0 !important; }

/* Bestätigung nach dem Absenden (Kontaktseite, Rent-Shop) – gleiche Bildsprache wie die
   Lightbox „Bühne“ auf der Startseite: dunkle Fläche, Häkchen zeichnet sich, „Angekommen.“ */
.gl-ok { position: relative; overflow: hidden; box-sizing: border-box; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px; padding: clamp(36px, 5vw, 56px) clamp(22px, 4vw, 48px); border-radius: 28px; background: radial-gradient(90% 70% at 0% 0%, rgba(255,255,255,.07), rgba(255,255,255,0) 60%), var(--gl-primary-dark); color: #ffffff; text-align: center; animation: glOkIn .6s cubic-bezier(.22,1,.36,1) both; }
.gl-ok[hidden] { display: none; }
.gl-ok-glow { position: absolute; left: calc(50% - 160px); top: 8%; width: 320px; height: 320px; border-radius: 50%; background: radial-gradient(closest-side, rgba(214,99,63,.13), rgba(214,99,63,0)); pointer-events: none; animation: glOkFade 1s ease .8s both; }
.gl-ok-check { position: relative; width: 104px; height: 104px; color: var(--gl-accent); }
.gl-ok-ring, .gl-ok-tick { stroke-dasharray: 100 200; stroke-dashoffset: 0; } /* Lücke > Pfad: sonst zeigt Safari vorab einen Punkt */
.gl-ok-halo { animation: glOkFade .6s ease .2s both; }
.gl-ok-ring { animation: glOkDraw .8s cubic-bezier(.65,0,.35,1) .25s both; }
.gl-ok-tick { animation: glOkDraw .5s cubic-bezier(.65,0,.35,1) .85s both; }
.gl-ok-h { position: relative; margin: 0; font-family: 'termina', sans-serif; font-size: clamp(34px, 4.4vw, 52px); line-height: 1.02; font-weight: 600; letter-spacing: -.035em; color: #ffffff; outline: none; animation: glOkRise .7s cubic-bezier(.22,1,.36,1) .55s both; }
.gl-ok-p { position: relative; margin: 0; max-width: 32em; font-size: var(--gl-t16, 16px); line-height: 1.6; font-weight: 300; color: #d3dde5; animation: glOkRise .7s cubic-bezier(.22,1,.36,1) .7s both; }
.gl-ok-again { position: relative; display: inline-flex; align-items: center; justify-content: center; height: 48px; margin: 6px 0 0; padding: 0 30px; border: 0; border-radius: 999px; background: #ffffff; color: var(--gl-primary-dark); font: inherit; font-size: var(--gl-t15, 15px); font-weight: 600; cursor: pointer; transition: background .2s ease, transform .18s cubic-bezier(.22,1,.36,1); animation: glOkRise .7s cubic-bezier(.22,1,.36,1) .9s both; }
.gl-ok-again:hover { background: var(--gl-surface); }
.gl-ok-again:active { transform: scale(.97); }
.gl-ok-again:focus-visible { outline: 2px solid #eab89b; outline-offset: 3px; }
.gl-ok--compact { gap: 16px; border-radius: 20px; }
.gl-ok--compact .gl-ok-check { width: 76px; height: 76px; }
.gl-ok--compact { padding: 32px 20px; }
.gl-ok--compact .gl-ok-h { font-size: 26px; }
.gl-ok--compact .gl-ok-p { font-size: 14px; }
.gl-ok--compact .gl-ok-again { height: 44px; padding: 0 22px; font-size: 14px; white-space: nowrap; }
@keyframes glOkIn { from { opacity: 0; transform: translateY(10px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes glOkFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes glOkRise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes glOkDraw { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) { .gl-ok, .gl-ok * { animation: none !important; } }
