/* ============================================================
   voiceagents.md  ·  a field note by Dhruv Dholakia
   Editorial light theme. Warm cream, charcoal, gold,
   with an AsqVox-family warm gradient reserved for brand moments.
   ============================================================ */

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; padding: 0; }
:focus-visible { outline: 2px solid var(--gold-deep); outline-offset: 3px; border-radius: 4px; }

/* ---------- Tokens ---------- */
:root {
  --cream:      #FBF7EE;
  --cream-deep: #F5EEDD;
  --paper:      #FFFDF8;
  --ink:        #1E1B16;
  --ink-soft:   #35302A;
  --muted:      #5E574B;
  --line:       #E8DFC9;
  --line-soft:  #EFE8D7;

  --gold:       #C9A227;   /* bright: large + decorative only */
  --gold-ink:   #9A7A16;   /* accents on cream */
  --gold-deep:  #7A5E0F;   /* link hover / focus (passes contrast) */

  --grad:       linear-gradient(135deg, #FF6A2B 0%, #F5931F 46%, #E8B23C 100%);
  --grad-warm:  linear-gradient(135deg, #FF6A2B 0%, #F0A62C 100%);

  --maxw:       688px;   /* comfortable reading measure */
  --wide:       1080px;

  --shadow-sm:  0 2px 10px -6px rgba(30,27,22,.20);
  --shadow-md:  0 18px 50px -26px rgba(30,27,22,.34);
  --shadow-orb: 0 20px 60px -18px rgba(255,106,43,.45);

  --ease:       cubic-bezier(.22,.61,.36,1);
  --ease-out:   cubic-bezier(.16,1,.3,1);

  --pad:        clamp(20px, 5vw, 40px);
  --font:       "Poppins", "Segoe UI", system-ui, -apple-system, sans-serif;
}

/* ---------- Base ---------- */
body {
  font-family: var(--font);
  color: var(--ink-soft);
  background: var(--cream);
  line-height: 1.75;
  font-size: clamp(1.06rem, 0.6vw + 1rem, 1.22rem);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  /* faint warm vignette + a whisper of grain, drawn once */
  background-image:
    radial-gradient(120% 60% at 50% -8%, rgba(255,180,90,.10), transparent 60%),
    radial-gradient(80% 40% at 90% 8%, rgba(255,106,43,.05), transparent 55%);
  background-attachment: fixed;
}

::selection { background: rgba(232,178,60,.32); color: var(--ink); }

.skip-link {
  position: fixed; left: 12px; top: -60px; z-index: 100;
  background: var(--ink); color: var(--cream);
  padding: 10px 16px; border-radius: 10px; font-size: .9rem; font-weight: 500;
  transition: top .2s var(--ease);
}
.skip-link:focus { top: 12px; }

/* ---------- Reading progress ---------- */
.progress {
  position: fixed; inset: 0 0 auto 0; height: 3px; z-index: 60;
  background: transparent; pointer-events: none;
}
.progress__bar {
  display: block; height: 100%; width: 0;
  background: var(--grad);
  box-shadow: 0 0 12px rgba(255,106,43,.5);
  transform-origin: left;
}

/* ---------- Header ---------- */
.site-head {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  padding: 14px var(--pad);
  background: color-mix(in srgb, var(--cream) 82%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background .3s var(--ease);
}
.site-head.is-stuck {
  border-bottom-color: var(--line);
  background: color-mix(in srgb, var(--cream) 90%, transparent);
}
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; letter-spacing: -.01em; }
.brand__mark {
  width: 30px; height: 30px; border-radius: 9px;
  background: var(--grad);
  display: grid; place-items: center;
  box-shadow: var(--shadow-sm), inset 0 0 0 1px rgba(255,255,255,.18);
}
.brand__wave { display: flex; align-items: center; gap: 2.5px; height: 14px; }
.brand__wave i {
  width: 2.5px; border-radius: 2px; background: #fff;
  height: 40%;
  animation: bar 1.4s var(--ease) infinite;
}
.brand__wave i:nth-child(1) { animation-delay: 0s; }
.brand__wave i:nth-child(2) { animation-delay: .18s; }
.brand__wave i:nth-child(3) { animation-delay: .36s; }
.brand__word { color: var(--ink); font-size: 1.02rem; }
.brand__dot { color: var(--gold-ink); }

.head-cta {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: .92rem; font-weight: 500; color: var(--ink);
  padding: 8px 14px; border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper);
  transition: transform .25s var(--ease), border-color .25s var(--ease), box-shadow .25s var(--ease);
}
.head-cta__arrow { transition: transform .25s var(--ease); }
.head-cta:hover { transform: translateY(-1px); border-color: color-mix(in srgb, var(--gold) 55%, var(--line)); box-shadow: var(--shadow-sm); }
.head-cta:hover .head-cta__arrow { transform: translate(1px,-1px); }

@keyframes bar { 0%,100% { height: 30%; } 50% { height: 100%; } }

/* ---------- Layout rhythm ---------- */
.essay { padding: 0 var(--pad); }
.block, .pullquote, .honest-note, .author, .cta {
  max-width: var(--maxw);
  margin-inline: auto;
}
.block { margin-block: clamp(38px, 6vw, 62px); }
.block p + p { margin-top: 1.1em; }

/* ---------- Hero ---------- */
.hero {
  max-width: 860px; margin-inline: auto;
  padding: clamp(56px, 11vw, 120px) 0 clamp(30px, 6vw, 56px);
  text-align: center;
}
.hero__eyebrow, .eyebrow {
  font-size: .78rem; font-weight: 600; letter-spacing: .18em; text-transform: uppercase;
  color: var(--gold-ink);
}
.hero__eyebrow { margin-bottom: 20px; }
.hero__eyebrow::after {
  content: ""; display: block; width: 26px; height: 2px; margin: 12px auto 0;
  background: var(--grad); border-radius: 2px;
}
.hero__title {
  font-size: clamp(2.35rem, 6.4vw, 4.15rem);
  line-height: 1.06; font-weight: 700; letter-spacing: -.028em;
  color: var(--ink);
  max-width: 15ch; margin-inline: auto;
  text-wrap: balance;
}
.u { position: relative; white-space: nowrap; }
.u__line {
  position: absolute; left: -2%; bottom: -.14em; width: 104%; height: .38em;
  overflow: visible;
}
.u__line path { stroke-dasharray: 260; stroke-dashoffset: 260; }
.js .reveal.is-visible .u__line path,
.hero__title.is-visible .u__line path { animation: draw 1s var(--ease-out) .5s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }

.hero__byline {
  margin-top: 26px; font-size: clamp(1.06rem, 1.4vw, 1.24rem);
  color: var(--muted); font-weight: 400; max-width: 44ch; margin-inline: auto;
}
.hero__author { color: var(--ink); font-weight: 500; }

/* ---------- Hero orb ---------- */
.hero__orb-wrap {
  margin-top: clamp(40px, 7vw, 68px);
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}
.orb {
  position: relative; display: grid; place-items: center;
  width: 132px; height: 132px; border-radius: 50%;
  isolation: isolate;
}
.orb__core {
  position: relative; z-index: 3;
  width: 92px; height: 92px; border-radius: 50%;
  background: var(--grad);
  display: grid; place-items: center;
  box-shadow: var(--shadow-orb), inset 0 2px 6px rgba(255,255,255,.4), inset 0 -8px 18px rgba(200,60,0,.28);
  transition: transform .35s var(--ease-out);
}
.orb__wave { display: flex; align-items: center; gap: 4px; height: 34px; }
.orb__wave i {
  width: 4px; border-radius: 4px; background: #fff; height: 30%;
  box-shadow: 0 0 6px rgba(255,255,255,.55);
  animation: orbbar 1.5s var(--ease) infinite;
}
.orb__wave i:nth-child(1){ animation-delay: 0s; }
.orb__wave i:nth-child(2){ animation-delay: .16s; }
.orb__wave i:nth-child(3){ animation-delay: .32s; }
.orb__wave i:nth-child(4){ animation-delay: .48s; }
.orb__wave i:nth-child(5){ animation-delay: .64s; }
@keyframes orbbar { 0%,100% { height: 22%; } 50% { height: 92%; } }

.orb__ring {
  position: absolute; inset: 0; z-index: 1; border-radius: 50%;
  border: 1.5px solid rgba(255,106,43,.55);
  animation: ripple 3s var(--ease-out) infinite;
}
.orb__ring--2 { animation-delay: 1.5s; }
@keyframes ripple {
  0%   { transform: scale(.7); opacity: .7; }
  100% { transform: scale(1.7); opacity: 0; }
}
.orb:hover .orb__core { transform: scale(1.06); }
.orb:active .orb__core { transform: scale(.97); }

.orb__caption {
  font-size: .84rem; letter-spacing: .04em; color: var(--muted);
  display: inline-flex; align-items: center; gap: 7px;
}
.orb__caption::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: #14a05a; box-shadow: 0 0 0 3px rgba(20,160,90,.16);
}

/* ---------- Scroll cue ---------- */
.scroll-cue {
  margin-top: clamp(44px, 8vw, 84px);
  display: inline-flex; flex-direction: column; align-items: center; gap: 8px;
  color: var(--muted); font-size: .74rem; letter-spacing: .16em; text-transform: uppercase;
}
.scroll-cue svg { animation: nudge 2.2s var(--ease) infinite; color: var(--gold-ink); }
@keyframes nudge { 0%,100% { transform: translateY(0); opacity: .5; } 50% { transform: translateY(5px); opacity: 1; } }

/* ---------- Section eyebrows ---------- */
.eyebrow {
  display: inline-block; margin-bottom: 18px; position: relative; padding-left: 34px;
}
.eyebrow::before {
  content: ""; position: absolute; left: 0; top: 50%; width: 24px; height: 2px;
  background: var(--grad); border-radius: 2px; transform: translateY(-50%);
}

/* ---------- Body copy ---------- */
.block p, .honest-note p, .author__lead, .author__bio, .cta__lead {
  color: var(--ink-soft);
}
.block p:first-letter { }

/* Inline links: ink text + animated gold underline (always high contrast) */
.link {
  color: var(--ink); font-weight: 500;
  background-image: linear-gradient(var(--gold), var(--gold));
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 100% 2px;
  padding-bottom: 1px;
  transition: color .25s var(--ease), background-size .25s var(--ease);
}
.link:hover, .link:focus-visible {
  color: var(--gold-deep);
  background-size: 100% 100%;
  background-image: linear-gradient(rgba(232,178,60,.16), rgba(232,178,60,.16));
  border-radius: 4px;
}

/* ---------- Pull-quotes ---------- */
.pullquote {
  position: relative; text-align: center;
  margin-block: clamp(52px, 9vw, 96px);
  padding: 0 clamp(8px, 3vw, 24px);
}
.pullquote__glyph {
  display: block; font-size: clamp(4rem, 11vw, 7rem); line-height: .5;
  font-weight: 700; color: transparent;
  background: var(--grad); -webkit-background-clip: text; background-clip: text;
  opacity: .9; margin-bottom: 6px; height: .5em;
  user-select: none;
}
.pullquote blockquote {
  font-size: clamp(1.7rem, 4.6vw, 2.85rem);
  line-height: 1.18; font-weight: 600; letter-spacing: -.02em;
  color: var(--ink); text-wrap: balance;
  max-width: 16ch; margin-inline: auto;
}
.pullquote::after {
  content: ""; display: block; width: 46px; height: 3px; margin: clamp(22px,3vw,30px) auto 0;
  background: var(--grad); border-radius: 3px;
}

/* ---------- Honest note ---------- */
.honest-note {
  position: relative;
  margin-block: clamp(44px, 7vw, 76px);
  padding: clamp(26px, 4vw, 38px) clamp(24px, 4vw, 40px);
  background: linear-gradient(180deg, var(--paper), #FFFCF4);
  border: 1px solid var(--line-soft);
  border-left: 4px solid transparent;
  border-radius: 16px;
  box-shadow: var(--shadow-md);
}
.honest-note::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
  background: var(--grad); border-radius: 16px 0 0 16px;
}
.honest-note__tag {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: .76rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase;
  color: var(--gold-ink); margin-bottom: 16px;
}
.honest-note__tag .dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--grad);
  box-shadow: 0 0 0 4px rgba(232,178,60,.14);
}
.honest-note p { font-size: 1.02em; }
.honest-note strong { color: var(--ink); font-weight: 600; }

/* ---------- Author ---------- */
.author { margin-block: clamp(56px, 9vw, 96px); }
.author__lead {
  font-size: clamp(1.24rem, 2.2vw, 1.5rem); line-height: 1.5; font-weight: 500;
  color: var(--ink); letter-spacing: -.01em; text-wrap: pretty;
}
.author__card {
  display: flex; align-items: center; gap: 20px;
  margin-block: clamp(28px, 4vw, 40px);
  padding: 20px; border-radius: 18px;
  background: var(--paper); border: 1px solid var(--line-soft);
  box-shadow: var(--shadow-sm);
}
.author__photo {
  width: 92px; height: 92px; border-radius: 50%;
  object-fit: cover; object-position: 50% 22%;
  border: 3px solid var(--cream);
  box-shadow: 0 0 0 1.5px var(--line), var(--shadow-md);
  flex: none;
}
.author__name { font-size: 1.16rem; font-weight: 600; color: var(--ink); line-height: 1.2; }
.author__role { font-size: .95rem; color: var(--muted); margin-bottom: 12px; }
.author__bio { font-size: 1rem; color: var(--ink-soft); }
.author__bio + .author__bio { margin-top: .9em; }
.author__bio--muted { color: var(--muted); font-size: .95rem; }

/* ---------- Socials ---------- */
.socials { display: flex; gap: 10px; }
.socials a {
  width: 38px; height: 38px; border-radius: 11px;
  display: grid; place-items: center; color: var(--ink);
  background: var(--cream); border: 1px solid var(--line);
  transition: transform .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), box-shadow .25s var(--ease);
}
.socials a:hover {
  transform: translateY(-3px); color: var(--gold-deep);
  border-color: color-mix(in srgb, var(--gold) 55%, var(--line));
  box-shadow: var(--shadow-sm);
}

/* ---------- CTA ---------- */
.cta { margin-block: clamp(48px, 8vw, 88px); text-align: left; }
.cta__lead { font-size: clamp(1.1rem, 1.6vw, 1.28rem); color: var(--ink-soft); }
.cta__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 1rem; font-weight: 600; letter-spacing: -.005em;
  padding: 14px 24px; border-radius: 999px;
  transition: transform .25s var(--ease-out), box-shadow .25s var(--ease), background .25s var(--ease);
}
.btn--primary { color: #fff; background: var(--ink); box-shadow: var(--shadow-md); }
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 24px 60px -24px rgba(30,27,22,.5); }
.btn__orb {
  width: 18px; height: 18px; border-radius: 50%; background: var(--grad);
  box-shadow: 0 0 0 0 rgba(255,106,43,.5);
  animation: pulse 2.4s var(--ease-out) infinite;
}
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255,106,43,.5); } 70% { box-shadow: 0 0 0 8px rgba(255,106,43,0); } 100% { box-shadow: 0 0 0 0 rgba(255,106,43,0); } }
.btn--ghost { color: var(--ink); background: var(--paper); border: 1px solid var(--line); }
.btn--ghost:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--gold) 55%, var(--line)); box-shadow: var(--shadow-sm); }

/* ---------- Footer ---------- */
.site-foot {
  margin-top: clamp(40px, 8vw, 80px);
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, transparent, var(--cream-deep));
  padding: clamp(36px, 6vw, 60px) var(--pad) clamp(40px, 6vw, 60px);
}
.site-foot__inner {
  max-width: var(--maxw); margin-inline: auto;
  display: grid; gap: 24px;
  grid-template-columns: 1fr auto; align-items: center;
}
.site-foot__brand { display: flex; align-items: center; gap: 14px; }
.site-foot__mark { width: 34px; height: 34px; border-radius: 9px; }
.site-foot__name { font-weight: 600; color: var(--ink); line-height: 1.3; }
.site-foot__tag { font-size: .92rem; color: var(--muted); }
.site-foot__legal { grid-column: 1 / -1; font-size: .84rem; color: var(--muted); border-top: 1px solid var(--line-soft); padding-top: 20px; }
.socials--foot a { background: var(--paper); }

/* ---------- Reveal system ---------- */
.js .reveal { opacity: 0; transform: translateY(20px); }
.js .reveal.is-visible {
  opacity: 1; transform: none;
  transition: opacity .8s var(--ease-out), transform .8s var(--ease-out);
}

/* ---------- Responsive ---------- */
@media (max-width: 560px) {
  .author__card { flex-direction: column; text-align: center; align-items: center; }
  .author__meta { display: flex; flex-direction: column; align-items: center; }
  .socials { justify-content: center; }
  .site-foot__inner { grid-template-columns: 1fr; }
  .site-foot .socials--foot { justify-self: start; }
  .head-cta { font-size: .86rem; padding: 7px 12px; }
}

/* ---------- Motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .js .reveal { opacity: 1 !important; transform: none !important; }
  .u__line path { stroke-dashoffset: 0 !important; }
}

/* ---------- Print ---------- */
@media print {
  .site-head, .progress, .hero__orb-wrap, .scroll-cue, .cta__actions { display: none !important; }
  body { background: #fff; color: #000; }
  .js .reveal { opacity: 1 !important; transform: none !important; }
}
