/* =========
   Base
========= */
:root{
  --bg: #0b0d14;
  --bg2:#0e1220;
  --card:#10172a;
  --text:#e9ecf5;
  --muted:#b4bdd6;
  --border: rgba(255,255,255,.10);
  --shadow: 0 20px 60px rgba(0,0,0,.35);

  --brand:#0B1AA8; /* pulled from logo direction */
  --brand2:#2f67ff;

  --radius: 18px;
  --radius2: 26px;

  --max: 1120px;
}

[data-theme="light"]{
  --bg:#f7f8fc;
  --bg2:#ffffff;
  --card:#ffffff;
  --text:#0b0d14;
  --muted:#4b556b;
  --border: rgba(15,23,42,.12);
  --shadow: 0 18px 40px rgba(2,6,23,.10);
}

*{ box-sizing:border-box; }
html{ scroll-behavior:smooth; }
body{
  margin:0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji","Segoe UI Emoji";
  background: radial-gradient(1200px 600px at 20% -10%, rgba(47,103,255,.25), transparent 60%),
              radial-gradient(900px 500px at 90% 10%, rgba(11,26,168,.25), transparent 55%),
              linear-gradient(180deg, var(--bg), var(--bg2));
  color:var(--text);
  line-height:1.55;
}

img{ max-width:100%; height:auto; display:block; }

.container{
  width:min(var(--max), calc(100% - 2.2rem));
  margin-inline:auto;
}

a{ color:inherit; text-decoration:none; }
a:hover{ opacity:.9; }

.sr-only{
  position:absolute;
  width:1px;height:1px;
  padding:0;margin:-1px;
  overflow:hidden;clip:rect(0,0,0,0);
  border:0;
}

.skip-link{
  position:absolute;
  left:-999px;
  top:0;
  background:var(--card);
  border:1px solid var(--border);
  color:var(--text);
  padding:.7rem 1rem;
  border-radius:12px;
  z-index:9999;
}
.skip-link:focus{ left:1rem; top:1rem; }

/* =========
   Header
========= */
.site-header{
  position:sticky;
  top:0;
  z-index:40;
  backdrop-filter:saturate(180%) blur(12px);
  background: color-mix(in srgb, var(--bg2) 70%, transparent);
  border-bottom:1px solid var(--border);
}
.header-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:.85rem 0;
  gap:1rem;
}
.brand{ display:flex; align-items:center; gap:.75rem; }
.brand-mark{ width:auto; height:64px; }

.nav{ display:flex; align-items:center; gap:.75rem; }
.nav-menu{
  display:flex;
  align-items:center;
  gap:.9rem;
}
.nav-link{
  padding:.55rem .8rem;
  border-radius:999px;
  color:var(--muted);
  border:1px solid transparent;
}
.nav-link:hover{
  color:var(--text);
  border-color:var(--border);
  background: color-mix(in srgb, var(--card) 65%, transparent);
}
.theme-toggle{
  border:1px solid var(--border);
  background: color-mix(in srgb, var(--card) 65%, transparent);
  color:var(--text);
  border-radius:999px;
  padding:.55rem .75rem;
  cursor:pointer;
}
.theme-toggle:hover{ transform: translateY(-1px); }

.nav-toggle{
  display:none;
  border:1px solid var(--border);
  background: color-mix(in srgb, var(--card) 65%, transparent);
  border-radius:999px;
  padding:.55rem .75rem;
  cursor:pointer;
}
.nav-toggle-lines{
  width:18px;height:12px;
  display:inline-block;
  position:relative;
}
.nav-toggle-lines::before,
.nav-toggle-lines::after{
  content:"";
  position:absolute;
  left:0; right:0;
  height:2px;
  background:var(--text);
  border-radius:2px;
}
.nav-toggle-lines::before{ top:0; }
.nav-toggle-lines::after{ bottom:0; }

/* =========
   Hero
========= */
.hero{
  padding: 5.2rem 0 2.4rem;
}
/* AicyngImages hero image fix */
.hero-visual{
  width: 100%;
  height: auto;           /* prevents distortion */
  max-width: 560px;       /* keeps it from stretching too wide */
  max-height: 340px;      /* keeps it from dominating vertically */
  object-fit: contain;    /* key: no squish, preserve aspect */
  display: block;
  margin-left: auto;      /* aligns nicely on the right */
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(0,0,0,.35);
}

/* Hero text-only layout */
.hero--text .hero-grid{
  grid-template-columns: 1fr; /* single column */
}

.hero--text .hero-copy{
  max-width: 1040px; /* wider hero text */
}

@media (min-width: 1200px){
  .hero--text .hero-copy{
    max-width: 1120px; /* match container max */
  }
}

.hero-grid{
  display:grid;
  grid-template-columns: 1.1fr 1fr;
  gap:2rem;
  align-items:stretch;
}

.eyebrow{
  display:inline-flex;
  gap:.5rem;
  align-items:center;
  font-weight:600;
  letter-spacing:.08em;
  text-transform:uppercase;
  font-size:.78rem;
  color: color-mix(in srgb, var(--muted) 75%, var(--text));
  margin:0 0 .6rem;
}
h1{
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  line-height:1.06;
  letter-spacing:-.02em;
  margin: 0 0 1rem;
}
.lead{
  font-size: 1.08rem;
  color: var(--muted);
  margin: 0 0 1.4rem;
  max-width: 58ch;
}

/* Make hero lead copy wider */
.hero .lead{
  max-width: 72ch;
}

.hero-actions{
  display:flex;
  gap:.75rem;
  flex-wrap:wrap;
  margin-bottom: 1.15rem;
}
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:.75rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card) 65%, transparent);
  color: var(--text);
  font-weight:600;
  cursor:pointer;
  transition: transform .12s ease, background .12s ease;
}
.btn:hover{ transform: translateY(-1px); }
.btn:active{ transform: translateY(0px); }

.btn-primary{
  border-color: color-mix(in srgb, var(--brand) 60%, var(--border));
  background: linear-gradient(135deg, color-mix(in srgb, var(--brand) 75%, #000 25%), var(--brand2));
}
.btn-ghost{
  background: transparent;
}
.hero-badges{
  display:flex;
  gap:.55rem;
  flex-wrap:wrap;
}
.badge{
  padding:.38rem .65rem;
  border-radius:999px;
  border:1px solid var(--border);
  color: var(--muted);
  background: color-mix(in srgb, var(--card) 55%, transparent);
  font-size:.88rem;
}

.hero-card{
  display:flex;
  justify-content:flex-end;
}
.glass{
  width:100%;
  max-width: 460px;
  border-radius: var(--radius2);
  border: 1px solid var(--border);
  background: linear-gradient(180deg,
    color-mix(in srgb, var(--card) 75%, transparent),
    color-mix(in srgb, var(--card) 55%, transparent)
  );
  box-shadow: var(--shadow);
  overflow:hidden;
}
.glass-top{
  display:flex;
  align-items:center;
  gap:.45rem;
  padding:.85rem 1rem;
  border-bottom:1px solid var(--border);
}
.dot{
  width:10px;height:10px;border-radius:999px;
  background: color-mix(in srgb, var(--muted) 50%, var(--text));
  opacity:.75;
}
.glass-title{
  margin-left:.5rem;
  color: var(--muted);
  font-size:.9rem;
}
.glass-body{
  padding: 1.15rem 1.1rem 1.25rem;
}
.metric{
  display:flex;
  justify-content:space-between;
  padding:.65rem .7rem;
  border:1px solid var(--border);
  border-radius:14px;
  margin-bottom:.65rem;
  background: color-mix(in srgb, var(--bg2) 55%, transparent);
}
.metric-label{ color:var(--muted); }
.metric-value{
  font-weight:700;
  letter-spacing:.02em;
  background: linear-gradient(90deg, var(--brand2), var(--brand));
  -webkit-background-clip:text;
  background-clip:text;
  color:transparent;
}
.spark{
  display:grid;
  grid-template-columns: repeat(7, 1fr);
  gap:.35rem;
  margin: 1rem 0 .9rem;
  align-items:end;
  height:54px;
}
.spark span{
  display:block;
  border-radius: 10px;
  border:1px solid var(--border);
  background: linear-gradient(180deg, color-mix(in srgb, var(--brand2) 65%, transparent), transparent);
  height: 10px;
}
.spark span:nth-child(1){ height:18px;}
.spark span:nth-child(2){ height:36px;}
.spark span:nth-child(3){ height:26px;}
.spark span:nth-child(4){ height:44px;}
.spark span:nth-child(5){ height:22px;}
.spark span:nth-child(6){ height:40px;}
.spark span:nth-child(7){ height:30px;}

.glass-note{
  margin:0;
  color:var(--muted);
  font-size:.98rem;
}

.hero-divider{
  height:1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  margin-top: 3rem;
}

/* =========
   Sections
========= */
.section{
  padding: 4.1rem 0;
}
.section-alt{
  background: color-mix(in srgb, var(--bg2) 80%, transparent);
  border-top:1px solid var(--border);
  border-bottom:1px solid var(--border);
}
.section-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:1.25rem;
  margin-bottom: 1.8rem;
}
.section-head h2{
  margin:0;
  font-size: clamp(1.6rem, 2.5vw, 2.1rem);
  letter-spacing:-.01em;
}
.muted{ color: var(--muted); margin: .35rem 0 0; }

.grid{ display:grid; gap:1.1rem; }
.cards{ grid-template-columns: repeat(3, 1fr); }
.two{ grid-template-columns: repeat(2, 1fr); }
.three{ grid-template-columns: repeat(3, 1fr); }

.card, .panel, .feature{
  border:1px solid var(--border);
  background: color-mix(in srgb, var(--card) 72%, transparent);
  border-radius: var(--radius);
  padding: 1.25rem 1.25rem 1.1rem;
  box-shadow: 0 8px 30px rgba(0,0,0,.10);
}
.card h3, .panel h3, .feature h3{ margin:.2rem 0 .55rem; }
.card p, .panel p, .feature p{ margin:.2rem 0 1rem; color: var(--muted); }

.list{
  margin:.4rem 0 1rem;
  padding-left: 1.1rem;
  color: var(--muted);
}
.list li{ margin:.35rem 0; }

.card-foot{
  display:flex;
  justify-content:flex-start;
}

/* =========================
   Clickable / Colored Pills
========================= */

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg2) 55%, transparent);
  color: var(--muted);
  white-space: nowrap;
}

/* Make pills usable as links */
a.pill {
  text-decoration: none;
  cursor: pointer;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    border-color 0.15s ease,
    transform 0.12s ease;
}

a.pill:hover {
  transform: translateY(-1px);
}

a.pill:active {
  transform: translateY(0);
}

a.pill:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand2) 30%, transparent);
}

/* =========================
   Color Variants
========================= */

/* Live / Primary */
.pill--primary {
display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  border-color: color-mix(in srgb, var(--brand2) 55%, var(--border));
  background: linear-gradient(
    135deg,
    color-mix(in srgb, var(--brand2) 85%, transparent),
    color-mix(in srgb, var(--brand) 85%, transparent)
  );
  color: #fff;
  white-space: nowrap;
}

/* Secondary / Info */
.pill--info {
  border-color: color-mix(in srgb, var(--brand2) 45%, var(--border));
  background: color-mix(in srgb, var(--brand2) 20%, transparent);
  color: var(--text);
}

/* Success / Available */
.pill--success {
  border-color: color-mix(in srgb, #2ecc71 45%, var(--border));
  background: color-mix(in srgb, #2ecc71 20%, transparent);
  color: #eafff3;
}

/* Warning / Beta */
.pill--warning {
  border-color: color-mix(in srgb, #f5b942 55%, var(--border));
  background: color-mix(in srgb, #f5b942 20%, transparent);
  color: #fff7e6;
}

/* Muted / Coming Soon */
.pill--muted {
  background: color-mix(in srgb, var(--card) 85%, transparent);
  color: var(--muted);
}

/* Hover polish for colored pills */
a.pill--primary:hover,
a.pill--info:hover,
a.pill--success:hover,
a.pill--warning:hover {
  filter: brightness(1.08);
}

.mini-grid{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:.75rem;
  margin-top: 1rem;
}
.mini{
  border:1px solid var(--border);
  border-radius: 14px;
  padding:.8rem .85rem;
  background: color-mix(in srgb, var(--bg2) 55%, transparent);
}
.mini-k{ font-size:.85rem; color: var(--muted); }
.mini-v{ font-weight:700; margin-top:.25rem; }

.codebox{
  border:1px solid var(--border);
  border-radius: 14px;
  background: color-mix(in srgb, var(--bg) 80%, transparent);
  padding: .9rem 1rem;
  overflow:auto;
}
.codebox pre{
  margin:0;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  color: color-mix(in srgb, var(--text) 85%, var(--muted));
  font-size:.92rem;
}

/* =========
   Contact
========= */
.contact{
  display:grid;
  grid-template-columns: 1.05fr .95fr;
  gap:1.2rem;
  align-items:start;
}
.contact-cards{
  display:grid;
  gap:.75rem;
  margin-top: 1.2rem;
}
.contact-card{
  border:1px solid var(--border);
  background: color-mix(in srgb, var(--card) 72%, transparent);
  border-radius: var(--radius);
  padding: 1rem 1rem .95rem;
}
.contact-k{ color: var(--muted); font-size:.9rem; }
.contact-v{ font-weight:700; margin-top:.25rem; display:inline-block; }

.form{
  border:1px solid var(--border);
  background: color-mix(in srgb, var(--card) 72%, transparent);
  border-radius: var(--radius);
  padding: 1.1rem;
}
label{ display:block; margin-bottom:.85rem; }
label span{ display:block; margin-bottom:.4rem; color: var(--muted); font-size:.92rem; }
input, textarea{
  width:100%;
  border-radius: 14px;
  border:1px solid var(--border);
  padding:.75rem .8rem;
  background: color-mix(in srgb, var(--bg2) 65%, transparent);
  color: var(--text);
  outline:none;
}
input:focus, textarea:focus{
  border-color: color-mix(in srgb, var(--brand2) 55%, var(--border));
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand2) 18%, transparent);
}
.form-note{
  margin:.75rem 0 0;
  color: var(--muted);
  min-height: 1.2em;
}

/* =========
   Footer
========= */
.site-footer{
  padding: 2.2rem 0;
}
.footer-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
}
.footer-left{
  display:flex;
  align-items:center;
  gap:1rem;
}
.footer-mark{ height:28px; width:auto; }
.footer-right{
  display:flex;
  gap:1rem;
  flex-wrap:wrap;
  color: var(--muted);
}
.footer-right a:hover{ color: var(--text); }

/* =========
   Responsive
========= */
@media (max-width: 980px){
  .hero-grid{ grid-template-columns: 1fr; }
  .hero-card{ justify-content:flex-start; }
  .cards{ grid-template-columns: 1fr; }
  .two{ grid-template-columns: 1fr; }
  .three{ grid-template-columns: 1fr; }
  .contact{ grid-template-columns: 1fr; }
  .section-head{ flex-direction:column; align-items:flex-start; }
}

@media (max-width: 760px){
  .nav-toggle{ display:inline-flex; align-items:center; justify-content:center; }
  .nav-menu{
    position:absolute;
    right:1.1rem;
    top:64px;
    display:none;
    flex-direction:column;
    align-items:stretch;
    gap:.25rem;
    padding:.65rem;
    border-radius: 16px;
    border:1px solid var(--border);
    background: color-mix(in srgb, var(--bg2) 92%, transparent);
    box-shadow: var(--shadow);
    min-width: 220px;
  }
  .nav-menu.is-open{ display:flex; }
  .nav-link{ width:100%; }
  .theme-toggle{ width:100%; }
  .footer-inner{ flex-direction:column; align-items:flex-start; }
}

/* Section visual (image under section headers) */
.section-visual{
  
  text-align: center;
  position: relative;
}

.section-visual img{
  
  height: auto;
  
}

/* Video embed */
.video-shell{
  max-width: 880px;
  margin: 0 auto;
}

.video-embed{
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 20px;
  overflow: hidden;
  background: #000;
  box-shadow: 0 16px 45px rgba(0,0,0,.35);
}

.video-embed iframe{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

/* =========
   Media Carousel (4-up thumbs + large preview)
========= */
.media-carousel{
  display:grid;
  gap: 1rem;
}

.media-main{
  margin: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  background: color-mix(in srgb, var(--card) 72%, transparent);
  box-shadow: var(--shadow);
  overflow:hidden;
}

.media-main-img{
  width: 100%;
  height: auto;
  display:block;
  object-fit: contain;
}

/* Thumbnails */
.media-thumbs{
  display:grid;
  grid-template-columns: repeat(4, 1fr);
  gap: .75rem;
}

.media-thumb{
  appearance: none;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg2) 55%, transparent);
  border-radius: 16px;
  padding: .35rem;
  cursor: pointer;
  transition: transform .12s ease, border-color .12s ease, background .12s ease;
}

.media-thumb img{
  width:100%;
  height: 84px;
  object-fit: cover;
  border-radius: 12px;
  display:block;
}

.media-thumb:hover{ transform: translateY(-1px); }
.media-thumb:active{ transform: translateY(0px); }

.media-thumb.is-active{
  border-color: color-mix(in srgb, var(--brand2) 70%, var(--border));
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand2) 18%, transparent);
}

.media-thumb:focus-visible{
  outline: none;
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand2) 22%, transparent);
}

/* Mobile: make thumbs horizontally scrollable if needed */
@media (max-width: 760px){
  .media-thumbs{
    display:flex;
    gap: .65rem;
    overflow-x: auto;
    padding-bottom: .25rem;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
  }
  .media-thumb{
    flex: 0 0 auto;
    width: 120px;
    scroll-snap-align: start;
  }
  .media-thumb img{
    height: 78px;
  }
}
.media-thumb { touch-action: manipulation; }
