:root {
  --color-ink: #121212;
  --color-orange: #F37A22;
  --color-orange-hover: #F6974D;
  --color-ember: #E5531A;
  --color-grey-600: #6E7278;
  --color-grey-300: #E3E5E8;
  --color-grey-100: #F5F6F7;
  --radius-pill: 999px;
  --radius-frame: 24px;
}

.qotg-detail h2 { font-size:var(--wp--preset--font-size--statement); line-height:1.2; letter-spacing:-.025em; }
.qotg-detail-lead { font-size:18px; line-height:1.5; color:var(--wp--preset--color--muted); }
.qotg-detail .qotg-centre > p { max-width:900px; }
.qotg-detail .qotg-centre > h2 { max-width:1100px; margin-inline:auto; }

/* ==========================================================================
   Shared FeatureHero (ElevenLabs / Google Antigravity clean minimal style)
   ========================================================================== */

/* Nav on white: transparent background, Ink text, 1px #E8EAED border after scroll */
.qotg-header:not(.is-scrolled) {
  background: transparent !important;
  border-bottom: 1px solid transparent !important;
  box-shadow: none !important;
}
.qotg-header.is-scrolled {
  background: #ffffff !important;
  border-bottom: 1px solid #E8EAED !important;
}

.qotg-feature-hero,
.qotg-detail-hero {
  background: #ffffff !important;
  color: var(--color-ink, #121212) !important;
  padding-top: 128px !important;
  padding-bottom: 0 !important;
  padding-inline: 0 !important;
  position: relative;
  overflow: visible !important;
}

.qotg-hero-shell,
.qotg-detail-hero .qotg-shell {
  max-width: 880px !important;
  margin-inline: auto !important;
  padding-inline: 24px !important;
  box-sizing: border-box;
}

.qotg-hero-copy,
.qotg-detail-hero .qotg-hero-copy {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  text-align: center !important;
  margin-inline: auto !important;
}

/* 1. Eyebrow pill */
.qotg-hero-eyebrow-pill,
.qotg-detail-hero .qotg-eyebrow {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 32px !important;
  padding: 0 16px 0 12px !important;
  border-radius: var(--radius-pill, 999px) !important;
  background: #ffffff !important;
  border: 1px solid var(--color-grey-300, #E3E5E8) !important;
  font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  color: var(--color-ink, #121212) !important;
  line-height: 1 !important;
  box-sizing: border-box !important;
  margin: 0 auto 24px auto !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
}

.qotg-hero-eyebrow-dot,
.qotg-detail-hero .qotg-eyebrow::before {
  content: '' !important;
  width: 8px !important;
  height: 8px !important;
  border-radius: 50% !important;
  background-color: var(--color-orange, #F37A22) !important;
  margin-right: 8px !important;
  flex-shrink: 0 !important;
  display: inline-block !important;
}

/* 2. Headline: Two balanced lines on desktop, fluid wrap on mobile */
.qotg-hero-headline,
.qotg-detail-hero h1 {
  font-family: "Google Sans Flex", "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, system-ui, sans-serif !important;
  font-weight: 500 !important;
  color: var(--color-ink, #121212) !important;
  text-align: center !important;
  font-size: clamp(40px, 5.2vw, 72px) !important;
  line-height: 1.08 !important;
  letter-spacing: -0.025em !important;
  margin: 0 0 24px 0 !important;
  text-wrap: balance;
}

.qotg-hero-title-line {
  display: block;
}

/* 3. Subtitle */
.qotg-hero-subtitle,
.qotg-detail-hero .qotg-centre > .qotg-detail-lead {
  font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
  font-weight: 400 !important;
  font-size: clamp(16px, 1.4vw, 19px) !important;
  line-height: 1.55 !important;
  color: var(--color-grey-600, #6E7278) !important;
  max-width: 640px !important;
  margin: 0 auto 36px auto !important;
  text-align: center !important;
}

/* 4. Buttons */
.qotg-hero-actions,
.qotg-detail-hero .qotg-actions {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 12px !important;
  margin: 0 auto 16px auto !important;
}

.qotg-hero-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  padding: 0 24px;
  border-radius: var(--radius-pill, 999px);
  font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none !important;
  cursor: pointer;
  box-sizing: border-box;
  transition: background-color 150ms ease-out, color 150ms ease-out, border-color 150ms ease-out, outline 150ms ease-out;
}

.qotg-hero-btn-primary,
.qotg-detail-hero .wp-block-button__link {
  background: var(--color-orange, #F37A22) !important;
  color: var(--color-ink, #121212) !important;
  border: none !important;
  border-radius: var(--radius-pill, 999px) !important;
  height: 48px !important;
  padding: 0 24px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: background-color 150ms ease-out, color 150ms ease-out !important;
}

.qotg-hero-btn-primary:hover,
.qotg-detail-hero .wp-block-button__link:hover {
  background: var(--color-orange-hover, #F6974D) !important;
  color: var(--color-ink, #121212) !important;
}
.qotg-hero-btn-primary:active,
.qotg-detail-hero .wp-block-button__link:active {
  background: var(--color-ember, #E5531A) !important;
}
.qotg-hero-btn-primary:focus-visible,
.qotg-detail-hero .wp-block-button__link:focus-visible {
  outline: 2px solid var(--color-orange, #F37A22) !important;
  outline-offset: 2px !important;
}

.qotg-hero-btn-secondary {
  background: #ffffff !important;
  color: var(--color-ink, #121212) !important;
  border: 1px solid var(--color-grey-300, #E3E5E8) !important;
}
.qotg-hero-btn-secondary:hover {
  background: var(--color-grey-100, #F5F6F7) !important;
}
.qotg-hero-btn-secondary:focus-visible {
  outline: 2px solid var(--color-ink, #121212) !important;
  outline-offset: 2px !important;
}

/* 5. Microcopy */
.qotg-hero-microcopy {
  font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 13px;
  line-height: 1.4;
  color: var(--color-grey-600, #6E7278);
  text-align: center;
  margin: 0 auto 64px auto;
}

/* 6. Mockup Container & Soft Warm Glow */
.qotg-hero-mockup-wrapper {
  position: relative;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding-inline: 24px;
  box-sizing: border-box;
}

.qotg-hero-glow,
.qotg-detail-stage .qotg-shell::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -46%);
  width: min(92%, 1060px);
  height: 80%;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 50% 45% at 50% 50%, rgba(255, 162, 74, 0.35) 0%, transparent 65%),
    radial-gradient(ellipse 85% 75% at 50% 50%, rgba(255, 214, 180, 0.9) 0%, rgba(255, 214, 180, 0.4) 45%, transparent 75%);
  filter: blur(55px);
  opacity: 0.9;
}

.qotg-hero-frame,
.qotg-detail-stage-frame {
  position: relative;
  z-index: 1;
  width: 100%;
  border-radius: var(--radius-frame, 24px) !important;
  overflow: hidden !important;
  border: 1px solid rgba(18, 18, 18, 0.06) !important;
  box-shadow: 0 24px 60px -12px rgba(120, 60, 20, 0.18), 0 2px 6px rgba(18, 18, 18, 0.04) !important;
  background: #ffffff;
  will-change: transform;
}

.qotg-detail-stage {
  background: #ffffff !important;
  padding: 0 0 64px !important;
  position: relative;
}

.qotg-detail-stage .qotg-shell {
  position: relative;
  max-width: 1200px !important;
}

.qotg-hero-frame img,
.qotg-hero-frame video,
.qotg-hero-frame picture img,
.qotg-detail-stage-frame img,
.qotg-detail-stage-frame video,
.qotg-detail-stage .qotg-image,
.qotg-detail-stage .wp-block-video,
.qotg-detail-stage .qotg-video {
  width: 100% !important;
  max-width: 100% !important;
  height: auto !important;
  display: block !important;
  object-fit: unset !important;
  border-radius: inherit;
  margin: 0 !important;
  border: none !important;
  box-shadow: none !important;
}

.qotg-hero-frame.has-fade-bottom,
.qotg-detail-stage-frame {
  -webkit-mask-image: linear-gradient(to bottom, #000 85%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 85%, transparent 100%);
}

/* Audiences section transitioning seamlessly on pure white */
.qotg-detail-audiences {
  background: #ffffff !important;
  color: var(--color-ink, #121212) !important;
  padding: 40px 0 80px;
}
.qotg-detail-audiences .qotg-detail-lead {
  color: var(--color-grey-600, #6E7278) !important;
}
.qotg-detail-names {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 32px;
  text-align: center;
  margin-top: 40px;
  font-size: 18px;
  color: var(--color-ink, #121212) !important;
}

/* ==========================================================================
   Entrance Animations & Scroll Parallax
   ========================================================================== */

@media (prefers-reduced-motion: no-preference) {
  .qotg-hero-anim-item {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 400ms cubic-bezier(0.16, 1, 0.3, 1), transform 400ms cubic-bezier(0.16, 1, 0.3, 1);
  }
  .qotg-hero-loaded .qotg-hero-anim-1 {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0ms;
  }
  .qotg-hero-loaded .qotg-hero-anim-2 {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 60ms;
  }
  .qotg-hero-loaded .qotg-hero-anim-3 {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 120ms;
  }
  .qotg-hero-loaded .qotg-hero-anim-4 {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 180ms;
  }
  .qotg-hero-loaded .qotg-hero-anim-5 {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 240ms;
  }

  .qotg-hero-mockup-wrapper,
  .qotg-detail-stage-frame {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 600ms cubic-bezier(0.16, 1, 0.3, 1), transform 600ms cubic-bezier(0.16, 1, 0.3, 1);
    transition-delay: 150ms;
  }
  .qotg-hero-loaded .qotg-hero-mockup-wrapper,
  .qotg-hero-loaded .qotg-detail-stage-frame {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .qotg-hero-anim-item,
  .qotg-hero-mockup-wrapper,
  .qotg-detail-stage-frame {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* ==========================================================================
   Existing Detail Page Rows, Workflows, and Steps
   ========================================================================== */

.qotg-detail-intro { background:transparent; padding:clamp(80px,8vw,120px) 0; }
.qotg-detail-intro .qotg-detail-lead { margin-top:32px; }
.qotg-detail-row { background:transparent; padding:clamp(80px,8vw,128px) 0; }
.qotg-detail-split { display:grid; grid-template-columns:0.9fr 1.1fr; gap:clamp(48px,6vw,96px); align-items:center; }
.qotg-detail-reverse .qotg-detail-split { grid-template-columns:1.1fr 0.9fr; }
.qotg-detail-copy h2 { font-size:clamp(32px,3.8vw,44px); line-height:1.15; letter-spacing:-.025em; margin-bottom:20px; font-weight:600; }
.qotg-detail-copy .qotg-detail-lead { max-width:48ch; font-size:18px; line-height:1.6; }
.qotg-detail-visual .qotg-image { margin:0; border-radius:var(--wp--custom--radius--stage); overflow:hidden; border:none; box-shadow:0 14px 44px rgba(0,0,0,0.07); }
.qotg-detail-visual .qotg-image img { width:100%; height:auto; display:block; object-fit:cover; border-radius:inherit; }
.qotg-detail-reverse .qotg-detail-copy { grid-column:2; grid-row:1; }
.qotg-detail-reverse .qotg-detail-visual { grid-column:1; grid-row:1; }
.qotg-detail-workflow { padding-block:clamp(80px,8vw,120px); }
.qotg-detail-workflow .qotg-centre { max-width:820px; margin-inline:auto; }
.qotg-detail-workflow .qotg-detail-lead { margin-top:24px; font-size:18px; color:var(--wp--preset--color--muted); }
.qotg-detail-workflow .qotg-actions { margin-top:32px; }
.qotg-detail-steps { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:32px; margin-top:64px; }
.qotg-detail-step { display:flex; flex-direction:column; padding:0!important; background:transparent!important; border:none!important; box-shadow:none!important; }
.qotg-detail-step .qotg-image { width:100%; aspect-ratio:1 / 1; border-radius:28px!important; overflow:hidden!important; border:none!important; box-shadow:0 12px 36px rgba(0,0,0,0.06); background:#ffffff; margin:0 0 20px 0; transition:transform var(--wp--custom--motion--control) var(--wp--custom--motion--ease), box-shadow var(--wp--custom--motion--control) var(--wp--custom--motion--ease); }
.qotg-detail-step:hover .qotg-image { transform:translateY(-3px); box-shadow:0 18px 48px rgba(0,0,0,0.1); }
.qotg-detail-step .qotg-image img { width:100%; height:100%; object-fit:cover; display:block; border-radius:inherit; }
.qotg-detail-step > p { margin:0; font-size:16px; font-weight:600; line-height:1.35; color:var(--wp--preset--color--ink); text-align:center; }
.qotg-detail-start { background:var(--wp--preset--color--dark-panel); color:var(--wp--preset--color--canvas); padding:96px 0; }
.qotg-detail-start .qotg-detail-lead { margin-top:32px; color:var(--wp--preset--color--light-muted); }
.qotg-detail-start .qotg-text-link { margin-top:32px; }
.qotg-detail-start .qotg-text-link a { color:var(--wp--preset--color--canvas); }

@media(max-width:1024px) {
  .qotg-detail-steps { grid-template-columns:repeat(2,minmax(0,1fr)); gap:32px; }
}

/* Tablet & Mobile responsive (<= 781px / <= 640px) */
@media(max-width:781px) {
  .qotg-detail h2, .qotg-detail-copy h2 { font-size:clamp(28px, 6.5vw, 36px) !important; line-height:1.16 !important; letter-spacing:-.025em !important; margin-bottom:16px !important; }
  .qotg-detail-names { grid-template-columns:repeat(2,minmax(0,1fr)); gap:24px; font-size:16px; }
  .qotg-detail-intro { padding:64px 0 40px; }
  .qotg-detail-row { padding:clamp(48px, 8vw, 64px) 0 !important; }
  .qotg-detail-split,
  .qotg-detail-reverse .qotg-detail-split { display:grid !important; grid-template-columns:1fr !important; gap:28px !important; }
  .qotg-detail-copy,
  .qotg-detail-reverse .qotg-detail-copy { grid-column:1 !important; grid-row:1 !important; width:100% !important; }
  .qotg-detail-visual,
  .qotg-detail-reverse .qotg-detail-visual { grid-column:1 !important; grid-row:2 !important; width:100% !important; }
  .qotg-detail-copy .qotg-detail-lead { font-size:16px !important; line-height:1.6 !important; max-width:100% !important; }
  .qotg-detail-visual .qotg-image { width:100% !important; border-radius:var(--wp--custom--radius--stage, 24px) !important; overflow:hidden !important; }
  .qotg-detail-visual .qotg-image img { width:100% !important; height:auto !important; display:block !important; }
  .qotg-detail-workflow,.qotg-detail-start { padding:64px 0; }
  .qotg-detail-steps { grid-template-columns:1fr; gap:36px; margin-top:40px; }
  .qotg-detail-step .qotg-image { border-radius:24px!important; }
  .qotg-detail-step > p { margin-top:16px; }
}

/* Mobile spec (<= 640px) */
@media (max-width: 640px) {
  .qotg-feature-hero,
  .qotg-detail-hero {
    padding-top: 96px !important;
  }
  .qotg-hero-shell,
  .qotg-detail-hero .qotg-shell {
    padding-inline: 24px !important;
  }
  .qotg-hero-eyebrow-pill,
  .qotg-detail-hero .qotg-eyebrow {
    margin-bottom: 20px !important;
  }
  .qotg-hero-headline,
  .qotg-detail-hero h1 {
    font-size: 40px !important;
    line-height: 1.1 !important;
    margin-bottom: 20px !important;
  }
  .qotg-hero-title-line {
    display: inline !important;
  }
  .qotg-hero-subtitle,
  .qotg-detail-hero .qotg-centre > .qotg-detail-lead {
    font-size: 15px !important;
    margin-bottom: 28px !important;
  }
  .qotg-hero-actions,
  .qotg-detail-hero .qotg-actions {
    flex-direction: column !important;
    width: 100% !important;
    gap: 10px !important;
    margin-bottom: 14px !important;
  }
  .qotg-hero-btn,
  .qotg-detail-hero .wp-block-button__link {
    width: 100% !important;
    height: 52px !important;
  }
  .qotg-hero-microcopy {
    margin-bottom: 48px !important;
  }
  .qotg-hero-mockup-wrapper,
  .qotg-detail-stage .qotg-shell {
    padding-inline: 16px !important;
  }
  .qotg-hero-frame,
  .qotg-detail-stage-frame {
    border-radius: 18px !important;
  }
  .qotg-hero-glow,
  .qotg-detail-stage .qotg-shell::before {
    filter: blur(35px) !important;
    opacity: 0.75 !important;
    height: 70% !important;
  }
}
