/* ==========================================================================
   Digitekten — base
   Tokens, self-hosted fonts, typography, header + navigation overlay, footer,
   plain pages. Values match preview/index.html.
   ========================================================================== */

/* Fonts: self-hosted (no Google requests). Newsreader keeps its optical-size axis. */
@font-face{font-family:"Newsreader";font-style:normal;font-weight:400;font-display:swap;
  src:url(../fonts/newsreader-latin-400-opsz.woff2) format("woff2")}
@font-face{font-family:"Figtree";font-style:normal;font-weight:400;font-display:swap;
  src:url(../fonts/figtree-latin-400-normal.woff2) format("woff2")}
@font-face{font-family:"Figtree";font-style:normal;font-weight:500;font-display:swap;
  src:url(../fonts/figtree-latin-500-normal.woff2) format("woff2")}

:root{
  --night:#0C1814; --ivory:#F3EFE7; --paper:#FEFCF8;
  --cobalt:#315BFF; --cobalt-text:#2547D6; --cobalt-light:#8DA4FF;
  --coral:#FF725C;
  --navy:#1A2A6C; --navy-deep:#0E1640; --foot:#0A1131;
  --graphite:#3D4743; --mute:#8A918C; --line:#D9D3C7;
  --on-dark:#C3CBEA; --on-dark-mute:#8F98BF;
  --display:"Newsreader",Georgia,"Times New Roman",serif;
  --body:"Figtree",system-ui,-apple-system,"Segoe UI",sans-serif;
  --hdr:70px;
  color-scheme:light;
}

/* ---------- base ---------- */
*{box-sizing:border-box}
html,body{margin:0;padding:0}
body{background:var(--ivory);color:var(--night);font-family:var(--body);font-size:16px;line-height:1.6;overflow-x:hidden;
  -webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility}
img,svg{max-width:100%}
.wrap{max-width:1180px;margin:0 auto;padding-left:max(16px,env(safe-area-inset-left,0px));padding-right:max(16px,env(safe-area-inset-right,0px))}
h1,h2,h3{font-family:var(--display);font-weight:400;text-wrap:balance;margin:0}
a{color:inherit}
:focus-visible{outline:2px solid var(--cobalt);outline-offset:3px}
:root{--k-gap:34px}   /* eyebrow (.k / .kicker / .section-subtitle) → title, everywhere */
@media (max-width:820px){:root{--k-gap:24px}}
.k{font-size:12px;letter-spacing:.14em;text-transform:uppercase;color:var(--cobalt-text);display:flex;align-items:center;gap:10px;margin:0 0 var(--k-gap)}
.dot{width:7px;height:7px;border-radius:50%;background:var(--coral);flex:none}
.pill{display:inline-flex;align-items:center;gap:8px;background:var(--cobalt);color:#fff;text-decoration:none;font-size:14px;font-weight:500;padding:10px 18px;border-radius:999px;transition:background-color .25s}
.pill:hover{background:var(--cobalt-text)}
.skip-link{position:absolute;left:16px;top:-60px;z-index:100;background:var(--night);color:var(--ivory);padding:10px 16px;border-radius:8px;text-decoration:none}
.skip-link:focus{top:12px}
.screen-reader-text{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(1px,1px,1px,1px);white-space:nowrap}

/* ---------- header ---------- */
.top{position:sticky;top:env(safe-area-inset-top,0px);z-index:20;background:color-mix(in srgb,var(--ivory) 88%,transparent);backdrop-filter:blur(8px);transition:background-color .35s,backdrop-filter .35s}
.top.dark{background:transparent;backdrop-filter:none}
.top.dark.scrolled{background:color-mix(in srgb,var(--navy-deep) 78%,transparent);backdrop-filter:blur(8px)}
.top .owl,.top .menu{transition:color .35s}
.top.dark .owl,.top.dark .menu{color:var(--ivory)}
body::before{content:"";position:fixed;inset:0 0 auto;height:env(safe-area-inset-top,0px);z-index:21;background:var(--ivory)}
body.hero-dark::before{background:var(--navy)}
.top .wrap{display:flex;align-items:center;justify-content:space-between;padding-block:14px;min-height:var(--hdr)}
.top__home{display:block;line-height:0}
.owl{display:block;color:var(--cobalt)}
.right{display:flex;align-items:center;gap:22px}
.menu{background:none;border:0;font:inherit;font-size:13px;letter-spacing:.12em;text-transform:uppercase;color:var(--night);display:flex;align-items:center;gap:10px;cursor:pointer;padding:6px 0}
.burger{width:22px;height:9px;position:relative;display:block}
.burger i{position:absolute;left:0;right:0;height:1.5px;background:currentColor;transition:transform .35s ease,top .35s ease}
.burger i:first-child{top:0}.burger i:last-child{top:7px}
.burger.is-x i{top:4px}
.burger.is-x i:first-child{transform:rotate(45deg)}.burger.is-x i:last-child{transform:rotate(-45deg)}

/* logged-in editors: the sticky header sits below the WordPress admin bar */
.admin-bar .top{top:32px}
@media (max-width:782px){.admin-bar .top{top:46px}}
@media (max-width:600px){.admin-bar .top{top:0}}

/* ---------- navigation overlay ---------- */
.nav-ov{position:fixed;inset:0;z-index:50;background:linear-gradient(180deg,#142057 0%,var(--navy-deep) 100%);color:var(--ivory);
  display:flex;flex-direction:column;overflow-y:auto;opacity:0;visibility:hidden;transition:opacity .4s ease,visibility 0s linear .4s}
.nav-ov.is-open{opacity:1;visibility:visible;transition:opacity .4s ease}
.nav-ov[hidden]{display:none}
.nav-ov>.wrap{width:100%}   /* auto margins in a flex column would otherwise shrink the rows */
.nav-ov .owl{color:var(--ivory)}
.nav-ov .menu{color:var(--ivory)}
.nav-ov__head{display:flex;align-items:center;justify-content:space-between;padding-block:14px;min-height:var(--hdr);padding-top:calc(14px + env(safe-area-inset-top,0px))}
.nav-ov__body{flex:1;display:grid;grid-template-columns:minmax(0,7fr) minmax(0,4fr);gap:48px;align-items:center;padding-block:48px 64px}
.nav-ov__list{list-style:none;margin:0;padding:0;counter-reset:nav}
.nav-ov__list li{counter-increment:nav;overflow:hidden}
.nav-ov__list a{display:flex;align-items:baseline;gap:22px;padding-block:6px;text-decoration:none;font-family:var(--display);font-size:clamp(40px,6vw,76px);line-height:1.1;color:var(--ivory);
  transform:translateY(105%);transition:transform .7s cubic-bezier(.2,.7,.2,1),color .25s}
.nav-ov__list a::before{content:counter(nav,decimal-leading-zero);font-family:var(--body);font-size:12px;letter-spacing:.14em;color:var(--cobalt-light);transform:translateY(-1.6em)}
.nav-ov__list a:hover,.nav-ov__list .current-menu-item>a{color:var(--coral)}
.nav-ov.is-open .nav-ov__list a{transform:none}
.nav-ov.is-open .nav-ov__list li:nth-child(2) a{transition-delay:.06s}
.nav-ov.is-open .nav-ov__list li:nth-child(3) a{transition-delay:.12s}
.nav-ov.is-open .nav-ov__list li:nth-child(4) a{transition-delay:.18s}
.nav-ov.is-open .nav-ov__list li:nth-child(5) a{transition-delay:.24s}
.nav-ov.is-open .nav-ov__list li:nth-child(6) a{transition-delay:.3s}
.nav-ov__aside{display:flex;flex-direction:column;gap:10px;align-items:flex-start;color:var(--on-dark);font-size:15px;
  opacity:0;transform:translateY(12px);transition:opacity .6s .2s,transform .6s .2s}
.nav-ov.is-open .nav-ov__aside{opacity:1;transform:none}
.nav-ov__aside .k{color:var(--cobalt-light);margin-bottom:8px}
.nav-ov__aside address{font-style:normal;line-height:1.6;margin-bottom:6px}
.nav-ov__aside a:not(.pill){color:#E6E9F5;text-decoration:none}
.nav-ov__aside a:not(.pill):hover{color:var(--coral)}
.nav-ov__aside .pill{margin-top:18px}
body.menu-open{overflow:hidden}

/* ---------- plain pages (until each page gets its own template) ---------- */
.page-head{background:var(--paper)}
.page-head .wrap{padding-block:96px 56px}
.page-head h1{font-size:clamp(36px,5vw,64px);line-height:1.06;max-width:18ch}
.entry{padding-block:56px 120px;max-width:820px;margin-left:max(16px,calc((100% - 1180px)/2 + 16px));margin-right:auto}
.entry>*:first-child{margin-top:0}
.entry h2{font-size:clamp(26px,3vw,38px);line-height:1.15;margin:56px 0 16px}
.entry h3{font-size:clamp(21px,2.2vw,26px);line-height:1.2;margin:36px 0 12px}
.entry p,.entry li{color:var(--graphite)}
.entry a{color:var(--cobalt-text)}

/* ---------- page templates: Page Hero + Simple Header ---------- */
.pill,.btn,.btn-white{cursor:pointer}
.btn,.btn-white{display:inline-flex;align-items:center;gap:8px;text-decoration:none;font-size:15px;font-weight:500;padding:12px 22px;border-radius:999px;transition:background-color .25s,color .25s}
.btn{background:var(--cobalt);color:#fff}.btn:hover{background:var(--cobalt-text)}
.btn-white{background:var(--ivory);color:var(--navy)}.btn-white:hover{background:#fff}
.link-arrow::after{content:"→";display:inline-block;margin-left:8px;transition:transform .3s}
.link-arrow:hover::after{transform:translateX(4px)}
.section-subtitle{font-size:12px;letter-spacing:.14em;text-transform:uppercase;color:var(--cobalt-text);display:flex;align-items:center;gap:10px;margin:0 0 var(--k-gap)}
.section-subtitle::before{content:"";width:7px;height:7px;border-radius:50%;background:var(--coral);flex:none}

/* Page Hero: featured image full-bleed behind the header, same photo treatment as the case-study cards,
   plus a deeper navy gradient at the bottom-left so the excerpt's headline always reads */
.hero-slide-item{position:relative;display:flex;align-items:flex-end;min-height:clamp(520px,78svh,780px);margin-top:calc(-1 * var(--hdr));
  overflow:hidden;color:var(--ivory);background:linear-gradient(160deg,var(--navy) 0%,var(--navy-deep) 100%)}
.hero-slide-image{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;filter:saturate(.78) contrast(1.03) brightness(.98)}
.hero-slide-item::after{content:"";position:absolute;inset:0;pointer-events:none;
  background:linear-gradient(180deg,rgba(14,22,64,.45) 0%,rgba(14,22,64,.25) 35%,rgba(14,22,64,.82) 100%),
             linear-gradient(90deg,rgba(14,22,64,.55) 0%,rgba(14,22,64,0) 70%),
             linear-gradient(160deg,rgba(26,42,108,.22) 0%,rgba(49,91,255,.14) 100%)}
.hero-container{position:relative;z-index:1;width:100%;max-width:1180px;margin:0 auto;
  padding:calc(var(--hdr) + 96px) max(16px,env(safe-area-inset-right,0px)) 88px max(16px,env(safe-area-inset-left,0px))}
.hero-content{max-width:780px}
.hero-content .section-subtitle{color:var(--cobalt-light);margin-bottom:var(--k-gap)}
.hero-content h1,.page-header-simple h1{font-family:var(--display);font-weight:400;font-size:clamp(40px,5.6vw,76px);line-height:1.04;margin:0 0 24px;text-wrap:balance}
.hero-content h2{font-size:clamp(28px,3.4vw,44px);line-height:1.12;margin:0 0 20px}
.hero-content p{font-size:18px;line-height:1.6;color:var(--on-dark);max-width:56ch;margin:0 0 28px}
.hero-content p:last-child{margin-bottom:0}

/* Simple Header (e.g. Impressum, Datenschutz): paper band, no photo */
.page-header-simple{background:var(--paper)}
.page-header-simple>.wrap{padding-block:96px 56px}
.page-header-simple p{font-size:18px;color:var(--graphite);max-width:56ch}

/* content column of the page templates; full-width bands inside it break out to the viewport edges */
.wrap--narrow{max-width:1180px}   /* same left edge as the hero text; the reading measure is set per element below */
.wrap--narrow>*:not(.band){max-width:820px}
.site-main>.wrap--narrow{padding-top:72px;padding-bottom:120px}
.wrap--narrow>*:first-child{margin-top:0}
.wrap--narrow h2{font-size:clamp(26px,3vw,38px);line-height:1.15;margin:56px 0 16px}
.wrap--narrow h3{font-size:clamp(21px,2.2vw,26px);line-height:1.2;margin:36px 0 12px}
.wrap--narrow p,.wrap--narrow li{color:var(--graphite)}
.wrap--narrow a:not(.btn):not(.btn-white):not(.pill){color:var(--cobalt-text)}
.wrap--narrow .band{width:100vw;margin-left:calc(50% - 50vw);margin-right:calc(50% - 50vw)}

/* ---------- forms: Contact Form 7 (any page; layout helpers .cf-grid / .cf-field / .cf-full, see README) ---------- */
.wpcf7{max-width:820px}
.wpcf7 form>p,.wpcf7 .cf-field p{margin:0}
.wpcf7 br{display:none}   /* CF7 adds <br> after label texts; fields are block-level anyway */
.cf-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px 24px;margin-bottom:24px}
.cf-full{grid-column:1 / -1}
.cf-field label,.wpcf7 label{display:block;font-size:14px;font-weight:500;color:var(--night)}
.wpcf7-form-control-wrap{display:block;margin-top:8px}
.wpcf7 input[type=text],.wpcf7 input[type=email],.wpcf7 input[type=tel],.wpcf7 input[type=url],.wpcf7 input[type=number],.wpcf7 input[type=date],.wpcf7 select,.wpcf7 textarea{
  width:100%;font:inherit;font-size:16px;color:var(--night);background:var(--paper);border:1px solid var(--line);border-radius:12px;padding:13px 16px;
  transition:border-color .2s,box-shadow .2s;-webkit-appearance:none;appearance:none}
.wpcf7 textarea{min-height:160px;resize:vertical;line-height:1.55}
.wpcf7 select{padding-right:44px;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23315BFF' stroke-width='1.6'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 18px center}
.wpcf7 input:hover,.wpcf7 select:hover,.wpcf7 textarea:hover{border-color:#BDB6A8}
.wpcf7 input:focus,.wpcf7 select:focus,.wpcf7 textarea:focus{outline:none;border-color:var(--cobalt);box-shadow:0 0 0 3px rgba(49,91,255,.15)}
.wpcf7 ::placeholder{color:var(--mute)}
/* consent checkbox (acceptance) */
.wpcf7-acceptance,.wpcf7-checkbox,.wpcf7-radio{display:block}
.wpcf7-list-item{display:block;margin:0 0 10px}
.wpcf7-list-item label{display:flex;gap:12px;align-items:flex-start;font-weight:400;font-size:14px;line-height:1.55;color:var(--graphite);cursor:pointer}
.wpcf7-list-item input[type=checkbox],.wpcf7-list-item input[type=radio]{flex:none;width:20px;height:20px;margin:1px 0 0;accent-color:var(--cobalt);cursor:pointer}
.wpcf7-list-item a{color:var(--cobalt-text)}
/* submit: same pill as the site's buttons */
.wpcf7 input[type=submit],.wpcf7 button[type=submit]{display:inline-flex;align-items:center;gap:8px;margin-top:20px;font:inherit;font-size:15px;font-weight:500;color:#fff;background:var(--cobalt);
  border:0;border-radius:999px;padding:13px 26px;cursor:pointer;transition:background-color .25s,opacity .25s}
.wpcf7 input[type=submit]:hover,.wpcf7 button[type=submit]:hover{background:var(--cobalt-text)}
.wpcf7 input[type=submit]:disabled{opacity:.45;cursor:not-allowed}
.wpcf7-spinner{vertical-align:middle;margin:20px 0 0 14px}
/* validation + response */
.wpcf7-not-valid{border-color:#C2412D!important}
.wpcf7-not-valid-tip{display:block;margin-top:6px;font-size:13px;color:#C2412D}
.wpcf7 form .wpcf7-response-output{margin:24px 0 0;padding:14px 18px;border:0;border-left:2px solid var(--coral);background:rgba(255,114,92,.07);border-radius:0 10px 10px 0;font-size:15px;color:var(--night)}
.wpcf7 form.sent .wpcf7-response-output{border-left-color:var(--cobalt);background:rgba(49,91,255,.07)}
.wpcf7 form.init .wpcf7-response-output,.wpcf7 form.resetting .wpcf7-response-output,.wpcf7 form.submitting .wpcf7-response-output{display:none}
.screen-reader-response{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(1px,1px,1px,1px)}
/* on navy bands */
.band--navy .wpcf7 label,.cta-band .wpcf7 label{color:var(--ivory)}
.band--navy .wpcf7-list-item label,.cta-band .wpcf7-list-item label{color:var(--on-dark)}
.band--navy .wpcf7 input:not([type=submit]):not([type=checkbox]):not([type=radio]),.band--navy .wpcf7 select,.band--navy .wpcf7 textarea{background:rgba(255,255,255,.06);border-color:rgba(243,239,231,.22);color:var(--ivory)}
.band--navy .wpcf7 form .wpcf7-response-output{color:var(--ivory)}

/* ---------- footer ---------- */
.site-foot{background:var(--foot);color:var(--on-dark)}
.site-foot .wrap{padding-block:72px 32px}
.f-top{display:grid;grid-template-columns:minmax(0,5fr) minmax(0,3fr) minmax(0,3fr);gap:48px;padding-bottom:56px;border-bottom:1px solid rgba(243,239,231,.1)}
.f-logo{display:block;width:220px;height:auto;color:var(--ivory);margin-bottom:20px}
.f-brand p{margin:0;font-size:14px;color:var(--on-dark-mute);max-width:32ch}
.f-col{display:flex;flex-direction:column;gap:10px;font-size:15px}
.f-list,.f-legal{list-style:none;margin:0;padding:0}
.f-list{display:flex;flex-direction:column;gap:10px}
.f-k{font-size:11px;letter-spacing:.16em;text-transform:uppercase;color:var(--on-dark-mute);margin-bottom:6px}
.site-foot a{color:#E6E9F5;text-decoration:none}
.site-foot a:hover{color:var(--coral)}
.f-addr{font-style:normal;color:var(--on-dark);line-height:1.6;margin-bottom:6px}
.f-bottom{display:flex;justify-content:space-between;gap:16px;flex-wrap:wrap;padding-top:24px;font-size:13px;color:var(--on-dark-mute)}
.f-legal{display:flex;gap:24px;flex-wrap:wrap}

/* ---------- small screens ---------- */
@media (max-width:820px){
  /* wider side margins on phones (room for the progress thread, text block stays centred) — same as preview */
  .wrap{padding-left:max(26px,env(safe-area-inset-left,0px));padding-right:max(26px,env(safe-area-inset-right,0px))}
  .top .pill span:first-child{display:none}   /* header keeps just the arrow on phones */
  .right{gap:14px}
  .nav-ov__body{grid-template-columns:minmax(0,1fr);align-items:start;gap:40px;padding-block:24px 48px}
  .nav-ov__list a{font-size:clamp(34px,10vw,48px);gap:14px}
  .f-top{grid-template-columns:minmax(0,1fr);gap:36px}
  .page-head .wrap{padding-block:64px 40px}
  .cf-grid{grid-template-columns:minmax(0,1fr)}
  .hero-slide-item{min-height:clamp(480px,82svh,680px)}
  .hero-container{padding:calc(var(--hdr) + 64px) max(26px,env(safe-area-inset-right,0px)) 56px max(26px,env(safe-area-inset-left,0px))}
  .hero-content p{font-size:17px}
  /* long German compounds (Digitalisierungsprojekte) must never run off a phone screen */
  .hero-content h1,.page-header-simple h1{font-size:clamp(32px,9vw,44px);hyphens:auto;-webkit-hyphens:auto;overflow-wrap:break-word}
  .page-header-simple>.wrap{padding-block:64px 40px}
  .site-main>.wrap--narrow{padding-top:48px;padding-bottom:80px}
  .entry{padding-block:40px 80px;margin-left:auto}
}

@media (prefers-reduced-motion:reduce){
  .nav-ov,.nav-ov__list a,.nav-ov__aside,.burger i{transition:none!important}
}
