/* ============================================================
   Site theme — edit freely per client.
   Designed to pair with GSAP scroll reveals + Three.js hero.
   ============================================================ */
/* Fallback palette. The admin Branding page injects a <style> after this
   file that overrides these custom properties (with separate light + dark
   values), so edit colors there — not here. */
:root{
  --bg:#0a0a0f; --bg-soft:#13131c; --fg:#f4f4f8; --heading:#ffffff; --muted:#9a9ab0;
  --border:#ffffff14; --accent:#6c5ce7; --accent-2:#00d2ff;
  --btn-text:#ffffff; --link:#00d2ff; --banner-text:#e8e8f0;
  --maxw:1100px; --radius:14px;
  --font:'Inter',system-ui,-apple-system,'Segoe UI',sans-serif;
}
*{box-sizing:border-box;margin:0;padding:0}
html{scroll-behavior:smooth}
body{
  background:var(--bg);color:var(--fg);font-family:var(--font);
  line-height:1.6;overflow-x:hidden;-webkit-font-smoothing:antialiased;
}
a{color:inherit;text-decoration:none}
h1,h2,h3,h4,.hero-title{color:var(--heading)}
.container{max-width:var(--maxw);margin:0 auto;padding:0 1.5rem}
.muted{color:var(--muted)}
body,.post-card,.site-nav,.btn-hero{transition:background-color .3s ease,color .3s ease,border-color .3s ease}

/* ---------- Light/dark toggle ---------- */
.theme-toggle{background:none;border:0;cursor:pointer;width:38px;height:38px;display:flex;align-items:center;justify-content:center;flex:0 0 auto;color:var(--fg)}
.theme-toggle-icon{position:relative;width:18px;height:18px;border-radius:50%;border:2px solid currentColor;transition:.3s}
/* Sun in dark mode (click for light), moon in light mode (click for dark) */
.theme-toggle[data-mode="dark"] .theme-toggle-icon{box-shadow:0 0 0 2px transparent;background:currentColor}
.theme-toggle[data-mode="light"] .theme-toggle-icon{background:transparent;box-shadow:inset -5px -3px 0 0 currentColor;border-color:transparent}

/* ---------- Header / nav ----------
   The header markup is owned by each SKIN's chrome-header.php, so header
   styling belongs to the skin — NOT core. The starter uses .dd-site-header /
   .dd-burger (styled in the starter skin CSS). The old generic .site-header /
   .logo / .site-nav / .nav-toggle rules were Mini-Maxi leftovers that matched
   nothing in core yet COLLIDED with client skins that (reasonably) use
   .site-header — e.g. the .site-header{mix-blend-mode:difference} rule inverted
   a client header's colors against a dark hero. Removed so every skin owns its
   own header cleanly. (Restore a header treatment in the SKIN, never here.) */

/* ---------- Hero (WebGL) ---------- */
.hero{position:relative;height:100vh;min-height:600px;display:flex;align-items:center;justify-content:center;text-align:center;overflow:hidden}
.hero-canvas{position:absolute;inset:0;width:100%;height:100%;display:block}
.hero-content{position:relative;z-index:2;padding:0 1.5rem;max-width:820px}
.hero-title{font-size:clamp(2.6rem,8vw,6rem);line-height:1.02;font-weight:800;letter-spacing:-.02em}
.hero-subtitle{font-size:clamp(1.05rem,2.5vw,1.5rem);color:var(--muted);margin:1.25rem 0 2.25rem}
.btn-hero{
  display:inline-block;padding:.9rem 2.2rem;border-radius:100px;font-weight:600;
  background:linear-gradient(120deg,var(--accent),var(--accent-2));color:var(--btn-text);
  transition:transform .25s ease,box-shadow .25s ease;box-shadow:0 10px 40px -10px var(--accent);
}
.btn-hero:hover{transform:translateY(-3px);box-shadow:0 18px 50px -10px var(--accent)}
.scroll-hint{position:absolute;bottom:2rem;left:50%;transform:translateX(-50%);font-size:.8rem;letter-spacing:.2em;text-transform:uppercase;color:var(--muted);animation:bob 2s ease-in-out infinite}
@keyframes bob{0%,100%{transform:translate(-50%,0)}50%{transform:translate(-50%,8px)}}

/* ---------- Sections ---------- */
.site-main{min-height:60vh}
.intro,.page-body{padding:7rem 0}
.page-head{padding:9rem 0 3rem}
.page-head h1{font-size:clamp(2.4rem,6vw,4.5rem);font-weight:800;letter-spacing:-.02em}
.page-head .eyebrow{color:var(--muted);font-size:.9rem;font-weight:600;margin-bottom:.6rem}
.page-head .eyebrow a:hover{color:var(--accent)}
.page-head .lead{color:var(--muted);font-size:1.1rem;max-width:52ch;margin-top:.8rem}
.intro-text{font-size:clamp(1.2rem,3vw,1.9rem);max-width:780px;line-height:1.4}

/* ---------- Prose ---------- */
.prose{max-width:740px;font-size:1.1rem}
.prose h2{font-size:1.9rem;margin:2.5rem 0 1rem}
.prose h3{font-size:1.4rem;margin:2rem 0 .75rem}
.prose p{margin:0 0 1.25rem}
.prose a{color:var(--link);text-decoration:underline;text-underline-offset:3px}
.prose img{max-width:100%;height:auto;border-radius:var(--radius);margin:1.5rem 0}
.prose ul,.prose ol{margin:0 0 1.25rem 1.5rem}
.prose blockquote{border-left:3px solid var(--accent);padding-left:1.25rem;color:var(--muted);font-style:italic;margin:1.5rem 0}

/* ---------- Blog ---------- */
.post-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:2rem}
.post-card{background:var(--bg-soft);border-radius:var(--radius);overflow:hidden;transition:transform .3s ease}
.post-card:hover{transform:translateY(-6px)}
.post-cover img{width:100%;aspect-ratio:16/10;object-fit:cover;display:block}
.post-card-body{padding:1.5rem}
.post-card-body h2{font-size:1.3rem;margin:.4rem 0 .6rem}
.post-card-body p{color:var(--muted);font-size:.95rem}
.post-card-cats{display:flex;flex-wrap:wrap;gap:.4rem;padding:0 1.5rem 1.4rem}
.cat-chip{display:inline-block;font-size:.72rem;font-weight:600;letter-spacing:.02em;
  padding:.28rem .7rem;border-radius:999px;color:var(--accent);
  background:color-mix(in srgb,var(--accent) 14%,transparent);
  border:1px solid color-mix(in srgb,var(--accent) 32%,transparent);
  transition:background-color .2s ease,color .2s ease}
.cat-chip:hover{background:var(--accent);color:var(--btn-text)}
.post-head-cats{display:flex;flex-wrap:wrap;gap:.5rem;justify-content:center;margin-top:1rem}
.post-head{padding:9rem 0 2rem;text-align:center}
.post-head h1{font-size:clamp(2.2rem,5vw,3.8rem);font-weight:800}
.post-hero-image img{width:100%;max-height:62vh;object-fit:cover;margin:2rem 0 3rem}
.post-content{margin:0 auto}

/* ---------- Contact / capture form ---------- */
.cms-form-section{padding:5rem 0}
.cms-form-wrap{max-width:640px}
.cms-form-title{font-size:clamp(1.8rem,4vw,2.6rem);font-weight:800;margin-bottom:.6rem;text-align:center}
.cms-form-intro{color:var(--muted);text-align:center;margin-bottom:2rem}
.cms-form{display:flex;flex-direction:column;gap:1rem}
.cms-form-row{display:grid;grid-template-columns:1fr 1fr;gap:1rem}
.cms-form label{display:flex;flex-direction:column;gap:.4rem;font-size:.9rem;font-weight:600;color:var(--fg)}
.cms-form input,.cms-form textarea{
  font:inherit;font-size:1rem;color:var(--fg);background:var(--bg-soft);
  border:1px solid var(--border);border-radius:10px;padding:.75rem .9rem;width:100%;
  transition:border-color .2s ease,box-shadow .2s ease;
}
.cms-form input:focus,.cms-form textarea:focus{outline:none;border-color:var(--accent);box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 22%,transparent)}
.cms-form textarea{resize:vertical;min-height:120px}
.cms-form button{
  align-self:flex-start;font:inherit;font-size:1rem;font-weight:700;cursor:pointer;
  background:var(--accent);color:var(--btn-text);border:0;border-radius:11px;padding:.85rem 1.8rem;
  transition:transform .12s ease,filter .2s ease;
}
.cms-form button:hover{transform:translateY(-1px);filter:brightness(1.06)}
.cms-form-ok{
  background:color-mix(in srgb,var(--accent) 12%,transparent);
  border:1px solid color-mix(in srgb,var(--accent) 40%,transparent);
  color:var(--fg);border-radius:12px;padding:1.1rem 1.3rem;text-align:center;font-size:1.05rem;
}

/* File field — only rendered by contact_form(['uploads' => true]). The native
   control is left in place (it is the accessible one and it reports the chosen
   filenames for free); it just gets the same box as the text inputs. */
.cms-form input[type=file]{
  padding:.6rem .9rem;cursor:pointer;
  border-style:dashed;background:transparent;
}
.cms-form input[type=file]::file-selector-button{
  font:inherit;font-size:.85rem;font-weight:700;cursor:pointer;margin-right:.9rem;
  background:var(--accent);color:var(--btn-text);border:0;border-radius:8px;padding:.45rem 1rem;
}
.cms-form-hint{margin:-.35rem 0 0;font-size:.82rem;color:var(--muted);line-height:1.5}

@media (max-width:560px){ .cms-form-row{grid-template-columns:1fr} }

/* ---------- Footer ---------- */
.site-footer{padding:4rem 0;border-top:1px solid var(--border);margin-top:6rem}
.footer-inner{max-width:var(--maxw);margin:0 auto;padding:0 1.5rem;display:flex;justify-content:space-between;flex-wrap:wrap;gap:1rem;color:var(--muted);font-size:.9rem}
.socials{display:flex;gap:1.25rem}

/* ---------- GSAP reveal initial states ---------- */
[data-reveal]{opacity:0;transform:translateY(30px)}
.no-js [data-reveal]{opacity:1;transform:none}

/* ---------- Page-builder blocks (public) ---------- */
.builder-page{padding:7rem 0}
.blk{margin:0 0 1.75rem}
.blk-heading{font-weight:800;letter-spacing:-.01em;line-height:1.1;font-size:clamp(1.6rem,4vw,2.8rem)}
.blk-text{max-width:740px}
.blk-button .btn-hero.btn-outline{background:transparent;border:1px solid var(--accent);box-shadow:none}
.blk-image img{max-width:100%;height:auto;border-radius:var(--radius);display:inline-block}
.blk-image.align-center{text-align:center}
.blk-image.align-right{text-align:right}
.imgw-medium{max-width:520px}
.imgw-small{max-width:320px}
.imgw-large{max-width:820px}
.blk-video{position:relative;max-width:900px;aspect-ratio:16/9}
.blk-video iframe,.blk-video video{position:absolute;inset:0;width:100%;height:100%;border:0;border-radius:var(--radius)}
.blk-banner{position:relative;display:flex;align-items:center;justify-content:center;
  background-size:cover;background-position:center;border-radius:var(--radius);overflow:hidden;padding:3rem}
.blk-banner-overlay{position:absolute;inset:0}
.blk-banner-inner{position:relative;z-index:2;max-width:720px}
.blk-banner-inner h2{font-size:clamp(1.8rem,4vw,3rem);font-weight:800;margin-bottom:.75rem}
.blk-banner-inner{color:var(--banner-text)}
.blk-banner-inner p{color:var(--banner-text);margin-bottom:1.5rem}

/* container columns/flex */
.blk-container{width:100%}
.blk-container .blk-col{min-width:0}
.blk-container-inner[style*="row"]>.blk-col{flex:1 1 0}
/* icon list */
.blk-iconlist{list-style:none;margin:0;padding:0;display:inline-block;text-align:left}
.blk-iconlist li{display:flex;align-items:flex-start;gap:.6rem;margin:.4rem 0}
.blk-iconlist .ic{color:var(--accent-2);font-weight:700;flex:0 0 auto}
.blk-iconlist.size-sm{font-size:.9rem}
.blk-iconlist.size-lg{font-size:1.3rem}
/* gallery */
.blk-gallery{display:grid;gap:.75rem}
.blk-gallery img{width:100%;aspect-ratio:1;object-fit:cover;border-radius:10px;display:block}
/* spacer + divider */
.blk-spacer{width:100%}
.blk-divider{width:100%;margin:0}

/* ---------- Mobile ---------- */
@media (max-width:760px){
  .nav-toggle{display:flex}
  .site-nav{position:fixed;inset:0;background:var(--bg);flex-direction:column;justify-content:center;align-items:center;gap:2rem;font-size:1.5rem;transform:translateX(100%);transition:transform .4s ease}
  .site-nav.open{transform:translateX(0)}
  .footer-inner{flex-direction:column}
}
