/* ==========================================================================
   TeraQloo: landing page styles
   No external fonts, no frameworks. System font stack only.
   ========================================================================== */

:root {
  --ink:        #0b1220;
  --ink-soft:   #334155;
  --slate:      #64748b;
  --line:       #e4e9f0;
  --bg:         #f7fafc;
  --surface:    #ffffff;
  --surface-2:  #f1f6f8;

  --brand:      #0d9488;
  --brand-dark: #0f766e;
  --brand-deep: #115e59;
  --aqua:       #2dd4bf;
  --aqua-soft:  #ccfbf1;
  --amber:      #b45309;
  --amber-soft: #fef3c7;

  --radius:     16px;
  --radius-sm:  11px;
  --radius-lg:  24px;
  --shadow:     0 1px 2px rgba(15, 23, 42, .05), 0 12px 30px -18px rgba(15, 23, 42, .25);
  --shadow-lg:  0 1px 3px rgba(15, 23, 42, .06), 0 30px 60px -30px rgba(15, 23, 42, .35);
  --maxw:       1120px;
  --ease:       cubic-bezier(.22, .61, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
               Arial, "Noto Sans", "Liberation Sans", sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; display: block; height: auto; }
a { color: var(--brand-dark); text-decoration: none; }
a:hover { color: var(--brand-deep); }

h1, h2, h3 { line-height: 1.15; letter-spacing: -.02em; margin: 0 0 .5em; font-weight: 700; }
h1 { font-size: clamp(2.1rem, 5.2vw, 3.5rem); letter-spacing: -.03em; }
h2 { font-size: clamp(1.65rem, 3.4vw, 2.35rem); }
h3 { font-size: 1.12rem; }
p  { margin: 0 0 1rem; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 100;
  background: var(--brand-deep); color: #fff; padding: 10px 16px; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* ---- Header ---- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .82);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: 66px; gap: 16px; }

.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 700; }
.brand-mark { display: inline-flex; }
.brand-name { font-size: 1.18rem; letter-spacing: -.02em; }
.brand-accent { color: var(--brand); }

.primary-nav ul { display: flex; align-items: center; gap: 6px; list-style: none; margin: 0; padding: 0; }
.primary-nav a {
  color: var(--ink-soft); font-size: .95rem; font-weight: 500;
  padding: 8px 12px; border-radius: 9px; transition: background .18s var(--ease), color .18s var(--ease);
}
.primary-nav a:hover { background: var(--surface-2); color: var(--brand-deep); }
.primary-nav .nav-cta {
  background: var(--brand); color: #fff; padding: 9px 16px;
}
.primary-nav .nav-cta:hover { background: var(--brand-dark); color: #fff; }

.nav-toggle {
  display: none; background: transparent; border: 1px solid var(--line); color: var(--ink);
  border-radius: 10px; padding: 7px; cursor: pointer; line-height: 0;
}
.nav-toggle:hover { background: var(--surface-2); }

/* ---- Hero ---- */
.hero { position: relative; overflow: hidden; padding: clamp(48px, 8vw, 92px) 0 clamp(48px, 7vw, 84px); }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(760px 420px at 82% -8%, rgba(45, 212, 191, .16), transparent 62%),
    radial-gradient(620px 360px at -6% 12%, rgba(13, 148, 136, .10), transparent 60%);
}
.hero-inner { display: grid; grid-template-columns: 1.08fr .92fr; gap: clamp(28px, 5vw, 64px); align-items: center; }

.eyebrow {
  display: inline-block; font-size: .8rem; font-weight: 600; letter-spacing: .10em;
  text-transform: uppercase; color: var(--brand-deep); background: var(--aqua-soft);
  padding: 6px 13px; border-radius: 999px; margin: 0 0 18px;
}
.lead { font-size: clamp(1.06rem, 1.9vw, 1.22rem); color: var(--ink-soft); max-width: 46ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 26px 0 14px; }
.hero-note { font-size: .9rem; color: var(--slate); margin: 0; }

.hero-art { position: relative; }
.hero-art img { width: 100%; filter: drop-shadow(0 30px 50px rgba(13, 148, 136, .16)); }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-weight: 600; font-size: .98rem; line-height: 1;
  padding: 14px 22px; border-radius: 12px; border: 1px solid transparent;
  cursor: pointer; transition: transform .16s var(--ease), background .18s var(--ease),
              box-shadow .18s var(--ease), border-color .18s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn-lg { padding: 16px 24px; font-size: 1.02rem; }
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 12px 24px -14px rgba(13, 148, 136, .9); }
.btn-primary:hover { background: var(--brand-dark); color: #fff; box-shadow: 0 16px 30px -14px rgba(13, 148, 136, .95); }
.btn-ghost { background: var(--surface); color: var(--ink); border-color: var(--line); box-shadow: var(--shadow); }
.btn-ghost:hover { border-color: var(--aqua); color: var(--brand-deep); }

/* ---- Sections ---- */
.section { padding: clamp(56px, 8vw, 96px) 0; }
.section-alt { background: linear-gradient(180deg, var(--surface) 0%, var(--surface-2) 100%); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { max-width: 62ch; margin-bottom: clamp(30px, 4vw, 52px); }
.section-kicker {
  font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--brand); margin: 0 0 10px;
}
.section-sub { color: var(--ink-soft); font-size: 1.06rem; margin: 0; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 60px); align-items: center; }
.copy p { color: var(--ink-soft); }
.copy .muted { color: var(--slate); font-size: .97rem; }

/* ---- Pillars ---- */
.pillar-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.pillar {
  display: flex; gap: 15px; align-items: flex-start;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px 20px; box-shadow: var(--shadow);
}
.pillar-icon {
  flex: none; width: 42px; height: 42px; border-radius: 12px;
  display: grid; place-items: center; color: var(--brand-deep); background: var(--aqua-soft);
}
.pillar h3 { margin: 0 0 3px; font-size: 1.02rem; }
.pillar p { margin: 0; color: var(--slate); font-size: .93rem; }

/* ---- Product ---- */
.grid-product { align-items: center; }
.product-art img { width: 100%; }
.checklist { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 10px; }
.checklist li { position: relative; padding-left: 30px; color: var(--ink-soft); font-size: .97rem; }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: 3px; width: 18px; height: 18px;
  border-radius: 50%; background: var(--aqua-soft);
}
.checklist li::after {
  content: ""; position: absolute; left: 6px; top: 6px; width: 4px; height: 8px;
  border-right: 2px solid var(--brand-deep); border-bottom: 2px solid var(--brand-deep);
  transform: rotate(42deg);
}

/* ---- Funding ---- */
.funding-card {
  display: flex; flex-wrap: wrap; gap: 26px; justify-content: space-between; align-items: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: clamp(26px, 4vw, 42px); box-shadow: var(--shadow-lg); position: relative; overflow: hidden;
}
.funding-card::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px;
  background: linear-gradient(180deg, var(--aqua), var(--brand));
}
.funding-program {
  display: inline-block; font-weight: 700; color: var(--amber);
  background: var(--amber-soft); padding: 6px 14px; border-radius: 999px;
  font-size: .88rem; margin: 0 0 14px;
}
.funding-amount { font-size: clamp(2rem, 5vw, 3rem); font-weight: 800; letter-spacing: -.03em; margin: 0 0 10px; }
.funding-note { color: var(--ink-soft); max-width: 52ch; margin: 0; font-size: .98rem; }
.funding-meta {
  text-align: center; background: var(--surface-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px 28px; min-width: 150px;
}
.meta-label { display: block; font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--slate); margin-bottom: 4px; }
.meta-value { font-size: 1.5rem; font-weight: 700; color: var(--brand-deep); }
.funding-disclaimer { margin: 18px 0 0; color: var(--slate); font-size: .88rem; }

/* ---- Problem / compare ---- */
.compare { display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; align-items: stretch; }
.compare-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px 26px; box-shadow: var(--shadow);
}
.compare-card p { margin: 0; color: var(--ink-soft); font-size: .97rem; }
.compare-card .compare-label { margin: 0 0 8px; font-weight: 700; font-size: .95rem; }
.compare-card.typical { background: var(--surface-2); }
.compare-card.typical .compare-label { color: var(--slate); }
.compare-card.qloo {
  border-color: var(--aqua);
  background: linear-gradient(180deg, #ffffff 0%, #f1fbf9 100%);
}
.compare-card.qloo .compare-label { color: var(--brand-deep); }
.compare-vs {
  align-self: center; margin: 0; font-weight: 700; text-transform: uppercase;
  letter-spacing: .14em; font-size: .76rem; color: var(--slate);
}

/* ---- Team ---- */
.team-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 16px;
}
.team-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px 20px; text-align: center; box-shadow: var(--shadow);
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
}
.team-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--aqua); }
.avatar {
  display: grid; place-items: center; width: 76px; height: 76px; margin: 0 auto 16px; border-radius: 50%;
  overflow: hidden; background: linear-gradient(135deg, var(--aqua-soft), #e0f2f1); color: var(--brand-deep);
  font-weight: 700; font-size: 1.05rem; letter-spacing: .02em;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.team-card h3 { font-size: 1rem; margin: 0 0 4px; }
.team-role { margin: 0; color: var(--slate); font-size: .85rem; }

/* ---- Contact ---- */
.contact-card {
  display: flex; flex-wrap: wrap; gap: 26px; align-items: center; justify-content: space-between;
  background: linear-gradient(135deg, var(--brand-deep), var(--brand));
  color: #fff; border-radius: var(--radius-lg); padding: clamp(30px, 5vw, 52px); box-shadow: var(--shadow-lg);
}
.contact-card .section-kicker { color: var(--aqua); }
.contact-card h2 { color: #fff; margin-bottom: .3em; }
.contact-card .section-sub { color: rgba(255, 255, 255, .86); }
.contact-card .btn-primary { background: #fff; color: var(--brand-deep); box-shadow: none; }
.contact-card .btn-primary:hover { background: var(--aqua-soft); color: var(--brand-deep); }

/* ---- Footer ---- */
.site-footer { background: var(--ink); color: #cbd5e1; padding: 44px 0 34px; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 20px; align-items: center; justify-content: space-between; }
.footer-brand .brand-name { color: #fff; font-weight: 700; font-size: 1.1rem; }
.footer-brand .brand-accent { color: var(--aqua); }
.footer-tag { margin: 4px 0 0; font-size: .85rem; color: #94a3b8; }
.footer-nav { display: flex; gap: 18px; flex-wrap: wrap; }
.footer-nav a { color: #cbd5e1; font-size: .92rem; }
.footer-nav a:hover { color: #fff; }
.footer-copy { margin: 0; font-size: .84rem; color: #94a3b8; width: 100%; border-top: 1px solid rgba(255,255,255,.08); padding-top: 18px; }

/* ---- 404 ---- */
.notfound { min-height: 78vh; display: grid; place-items: center; text-align: center; padding: 80px 0; }
.notfound-inner { max-width: 46ch; }
.notfound-mark { margin-bottom: 18px; }
.notfound-code { font-size: clamp(3.5rem, 12vw, 6rem); font-weight: 800; letter-spacing: -.04em; color: var(--brand); margin: 0; line-height: 1; }
.notfound h1 { font-size: clamp(1.3rem, 3vw, 1.8rem); margin-top: 6px; }
.notfound .section-sub { margin-bottom: 26px; }

/* ---- Reveal animation ---- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .team-card { transition: none; }
}

/* ---- Responsive ---- */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-art { order: -1; max-width: 460px; margin: 0 auto; }
  .grid-2 { grid-template-columns: 1fr; }
  .grid-product .product-art { order: -1; }

  .nav-toggle { display: inline-flex; }
  .primary-nav {
    position: absolute; left: 0; right: 0; top: 66px;
    background: var(--surface); border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-lg);
    max-height: 0; overflow: hidden; transition: max-height .28s var(--ease);
  }
  .primary-nav.open { max-height: 392px; }
  .primary-nav ul { flex-direction: column; align-items: stretch; gap: 2px; padding: 12px 18px 18px; }
  .primary-nav a { padding: 12px 14px; }
  .primary-nav .nav-cta { text-align: center; }
}

@media (max-width: 520px) {
  body { font-size: 16px; }
  .funding-card { flex-direction: column; align-items: flex-start; }
  .funding-meta { width: 100%; }
}
