/* /services overview. Typography, buttons and sections come from represent-studio.css;
   this file only adds the overview layout, the video grids and the Orbit block. */

.sv-service { --sv-bg: var(--swatch--brand-500); }
.sv-white { --sv-bg: var(--swatch--light-100); background-color: var(--swatch--light-100); }

/* Hero: a heading and a line, the tabs below do the navigating */
.sv-hero { padding-top: 9rem; padding-bottom: 3rem; }
.sv-hero-inner { display: flex; flex-direction: column; gap: 1.75rem; }
.sv-hero-title { max-width: 46rem; font-size: clamp(2.25rem, 4vw, 3.5rem); line-height: 1.05; letter-spacing: -.03em; font-weight: 500; }
.sv-hero-lead { max-width: 40rem; color: #3c3c46; }

/* Site nav on this page: the services replace the usual links, gray until you reach their section */
.sv-nav .nav_links_text { display: flex; gap: .375rem; align-items: baseline; white-space: nowrap; }
.sv-nav .nav_links_link { padding: 0 .75rem; transition: opacity .25s ease; }
.sv-nav .nav_links_link.is-current { opacity: 1; }
@media (max-width: 1279px) { .sv-nav .nav_links_link { padding: 0 .5rem; } .sv-nav .nav_links_text { font-size: .9375rem; } }

/* Below the desktop nav breakpoint the same links ride in a row under the menu bar */
.sv-tabs { position: sticky; top: var(--sv-nav-h, 64px); z-index: 50; background: var(--swatch--light-100); border-bottom: 1px solid var(--swatch--border); }
.sv-tabs-row { display: flex; gap: 1.25rem; overflow-x: auto; scrollbar-width: none; padding: .875rem 0; }
.sv-tabs-row::-webkit-scrollbar { display: none; }
.sv-tabs-row a { flex: none; display: flex; gap: .375rem; align-items: baseline; color: var(--swatch--dark-900); opacity: .5; text-decoration: none; font-size: .9375rem; white-space: nowrap; transition: opacity .25s ease; }
.sv-tabs-row a.is-current { opacity: 1; }
/* The site nav switches to desktop on a fluid container query; JS mirrors that as .sv-desk-nav */
html.sv-desk-nav .sv-tabs { display: none; }
html:not(.sv-desk-nav) .sv-service { scroll-margin-top: calc(var(--sv-nav-h, 64px) + 3rem); }

/* Service section: text column beside its work */
.sv-service { scroll-margin-top: var(--sv-nav-h, 80px); padding-top: 8rem; padding-bottom: 8rem; }
.sv-layout { display: grid; gap: 3rem; }
@media (min-width: 992px) {
  .sv-layout { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 6rem; align-items: start; }
  .sv-info { position: sticky; top: calc(var(--sv-nav-h, 80px) + 3rem); }
}
.sv-info { display: flex; flex-direction: column; }
/* Spacing follows grouping: title and lead together, then more room before each new block */
.sv-info h2 { margin-bottom: 1.5rem; }
.sv-info .u-text-style-large { margin-bottom: 2rem; }
.sv-info .sv-list, .sv-info .sv-formats { margin-bottom: 2.5rem; }
.sv-info .u-text-style-large { color: #3c3c46; }

.sv-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: .875rem; }
.sv-list li { position: relative; padding-left: 1.5rem; line-height: 1.45; }
.sv-list li::before { content: ""; position: absolute; left: 0; top: .45em; width: .75rem; height: .375rem; border-left: 2px solid currentColor; border-bottom: 2px solid currentColor; rotate: -45deg; }

.sv-formats { margin: 0; display: flex; flex-direction: column; gap: 1.25rem; }
.sv-formats div { padding-left: 1rem; border-left: 2px solid var(--swatch--border); }
.sv-formats dt { font-weight: 600; }
.sv-formats dd { margin: .375rem 0 0; color: #3c3c46; line-height: 1.45; }

.sv-more-row { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; }
.sv-more { display: inline-flex; gap: .5rem; align-items: center; width: fit-content; font-weight: 600; color: var(--swatch--dark-900); text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.sv-more span { transition: transform .2s ease; }
.sv-more:hover span { transform: translateX(4px); }

/* Client proof: logo and one line, set apart by a hairline */
.sv-proof { display: flex; gap: 1rem; align-items: center; margin-top: 3rem; padding-top: 1.75rem; border-top: 1px solid var(--swatch--border); }
.sv-proof img { flex: none; width: auto; object-fit: contain; }
.sv-proof img.is-mark { height: 2.25rem; }
.sv-proof img.is-word { height: 1.375rem; max-width: 7.5rem; }
.sv-proof p { font-size: .9375rem; line-height: 1.4; color: #3c3c46; }

/* Media column */
.sv-media { display: flex; flex-direction: column; gap: 4.5rem; min-width: 0; }
.sv-group { display: flex; flex-direction: column; gap: 1.5rem; }
.sv-group-head { display: flex; flex-direction: column; gap: .75rem; }
.sv-group-head p { color: #5c5c66; line-height: 1.45; }

.sv-grid { display: grid; gap: 2rem 1.25rem; }
.sv-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
/* First video full width, the rest in pairs */
.sv-grid-feature { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.sv-grid-feature > :first-child { grid-column: 1 / -1; }
@media (max-width: 767px) { .sv-grid-2, .sv-grid-feature { grid-template-columns: minmax(0, 1fr); } }

.sv-video { margin: 0; display: flex; flex-direction: column; gap: .875rem; min-width: 0; }
.sv-video figcaption { display: flex; flex-wrap: wrap; gap: .25rem .5rem; align-items: baseline; font-size: .875rem; color: #5c5c66; }
.sv-video figcaption strong { color: var(--swatch--dark-900); font-weight: 600; }

.sv-frame { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; border-radius: .875rem; overflow: hidden; background: #e4e4e8; box-shadow: 0 1px 2px rgb(9 9 17 / .06), 0 12px 32px rgb(9 9 17 / .08); }
.sv-frame wistia-player, .sv-frame iframe, .sv-frame video, .sv-frame img { display: block; position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }
.sv-frame wistia-player:not(:defined) { background: center / cover no-repeat var(--sv-swatch, none); filter: blur(4px); }

/* YouTube facade: thumbnail and play button until clicked */
.sv-yt { padding: 0; border: 0; cursor: pointer; }
.sv-yt img { transition: transform .4s ease; }
.sv-yt:hover img { transform: scale(1.03); }
.sv-play { position: absolute; left: 50%; top: 50%; width: 4rem; height: 4rem; translate: -50% -50%; border-radius: 50%; background: rgb(9 9 17 / .78); backdrop-filter: blur(4px); transition: background-color .2s ease; }
.sv-play::after { content: ""; position: absolute; left: 54%; top: 50%; translate: -50% -50%; border-style: solid; border-width: .625rem 0 .625rem 1rem; border-color: transparent transparent transparent #fff; }
.sv-yt:hover .sv-play { background: var(--swatch--dark-900); }

/* YouTube results: real analytics screenshots, number first */
.sv-results { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
.sv-result { margin: 0; display: flex; flex-direction: column; gap: 1rem; padding: 1.25rem; border-radius: .875rem; background: var(--swatch--light-100); border: 1px solid var(--swatch--border); }
.sv-result.is-dark { background: #1b1b1f; border-color: #1b1b1f; color: var(--swatch--light-100); }
/* Screenshots differ in shape; a shared frame keeps the pair level */
.sv-result img { display: block; width: 100%; height: auto; aspect-ratio: 554 / 300; object-fit: contain; border-radius: .5rem; }
.sv-result figcaption { margin-top: auto; font-size: .9375rem; line-height: 1.35; color: inherit; opacity: .85; }
.sv-result figcaption b { display: block; font-size: 1.75rem; line-height: 1.1; letter-spacing: -.02em; font-weight: 600; opacity: 1; }
@media (max-width: 479px) { .sv-results { grid-template-columns: minmax(0, 1fr); } }

/* Orbit: launch posts take turns while creators repost around them (from the influencer page) */
.im-tw { display: flex; flex-direction: column; gap: .75rem; padding: 1rem 1.125rem; border-radius: var(--radius--main); background: var(--swatch--light-100); color: var(--swatch--dark-900); font-size: .9375rem; line-height: 1.4; box-shadow: 0 24px 48px rgb(14 14 14 / .12); }
.im-tw-head { display: flex; gap: .625rem; align-items: center; }
.im-tw-head img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex: none; }
.im-tw-head p { line-height: 1.25; }
.im-tw-head span { color: #5c5c66; }
.im-tw-head svg { width: 16px; height: 16px; vertical-align: -3px; }
.im-tw-media { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; border-radius: .75rem; }
/* Reposts and likes, then views pushed right and set larger */
.im-tw-metrics { display: flex; align-items: center; gap: 1.25rem; color: var(--swatch--dark-900); }
.im-tw-metrics span { display: inline-flex; align-items: center; gap: .375rem; }
.im-tw-metrics span[data-k="reply"] { display: none; }
.im-tw-metrics svg { width: 20px; height: 20px; flex: none; color: #5c5c66; }
.im-tw-metrics b { font-weight: 600; font-size: 1.0625rem; font-variant-numeric: tabular-nums; }
.im-tw-metrics span[data-k="views"] { margin-left: auto; }
.im-tw-metrics span[data-k="views"] svg { width: 26px; height: 26px; }
.im-tw-metrics span[data-k="views"] b { font-size: 1.75rem; letter-spacing: -.03em; }

/* Square box so the ring is a true circle; ten faces sit 36deg apart around the post */
.sv-media .im-orbit { width: 100%; max-width: 31rem; margin: 0 auto; }
.im-orbit { --r: 46%; position: relative; display: grid; align-content: center; aspect-ratio: 1; }
.im-orbit > .im-posts { width: 64%; }
.im-posts { position: relative; z-index: 2; display: grid; max-width: 30rem; margin: 0 auto; }
.im-posts .im-tw { grid-area: 1 / 1; opacity: 0; transform: translateY(16px) scale(.98); transition: opacity .6s ease, transform .6s ease; }
.im-posts .im-tw.is-on { opacity: 1; transform: none; }
.im-posts .im-tw-text { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.im-orbit-face { --a: calc(var(--i) * 36deg - 72deg); position: absolute; left: calc(50% + cos(var(--a)) * var(--r)); top: calc(50% + sin(var(--a)) * var(--r)); z-index: 3; width: 60px; height: 60px; translate: -50% -50%; opacity: 0; scale: .4; transition: opacity .4s ease, scale .45s cubic-bezier(.3, 1.6, .5, 1); transition-delay: calc(var(--i) * 180ms + 500ms); }
.im-orbit-face img { display: block; width: 100%; height: 100%; max-width: none; border-radius: 50%; object-fit: cover; background: var(--swatch--light-100); border: 3px solid var(--swatch--light-100); box-shadow: 0 0 0 1px rgb(14 14 14 / .12), 0 6px 16px rgb(14 14 14 / .08); }
.im-orbit-face i { position: absolute; right: -4px; bottom: -4px; width: 22px; height: 22px; border-radius: 50%; background: #0f7a3d; color: var(--swatch--light-100); display: grid; place-items: center; border: 2px solid var(--swatch--light-100); }
.im-orbit-face i svg { width: 12px; height: 12px; display: block; }
.im-orbit.is-in .im-orbit-face { opacity: 1; scale: 1; }
.im-orbit-face.is-pop { animation: sv-pop .5s ease; }
@keyframes sv-pop { 40% { scale: 1.18; } }
@media (max-width: 767px) {
  .im-orbit { --r: 47%; }
  .im-orbit > .im-posts { width: 70%; }
  .im-orbit-face { width: 40px; height: 40px; }
  .im-orbit-face i { width: 16px; height: 16px; }
  .im-orbit-face i svg { width: 9px; height: 9px; }
  .im-tw { padding: .75rem; font-size: .8125rem; gap: .5rem; }
  .im-tw-head img { width: 28px; height: 28px; }
  .im-tw-metrics { gap: .75rem; }
  .im-tw-metrics svg { width: 16px; height: 16px; }
  .im-tw-metrics b { font-size: .875rem; }
  .im-tw-metrics span[data-k="views"] svg { width: 18px; height: 18px; }
  .im-tw-metrics span[data-k="views"] b { font-size: 1.25rem; }
}
@media (prefers-reduced-motion: reduce) {
  .im-orbit-face { opacity: 1; scale: 1; transition: none; }
}

/* Closing CTA */
.sv-cta-section { padding-top: 2rem; padding-bottom: 8rem; }
.sv-cta { display: flex; flex-direction: column; align-items: flex-start; gap: 1.5rem; padding: clamp(2rem, 5vw, 4.5rem); border-radius: 1.5rem; background: var(--swatch--dark-900); }
.sv-cta p { max-width: 36rem; opacity: .8; }

@media (max-width: 767px) {
  .sv-hero { padding-top: 7rem; padding-bottom: 2rem; }
}

/* Stacked layout (tablet and phone): each section's title sticks under the nav while you're
   in it. .sv-info steps aside so the title's sticky box is the whole section, not the text column. */
@media (max-width: 991px) {
  .sv-layout { gap: 0; }
  .sv-info { display: contents; }
  .sv-info h2 { margin-bottom: .5rem; }
  .sv-proof { margin-top: 2.5rem; }
  .sv-media { margin-top: 3.5rem; gap: 3.5rem; }
  /* The site trims heading line-height with ::before/::after; this bar reuses both pseudos */
  .sv-service h2 { position: sticky; top: calc(var(--sv-nav-h, 64px) + var(--sv-tabs-h, 0px)); z-index: 5; margin-top: -.5rem; padding: .625rem 0; }
  /* Full-bleed bar behind the title: section colour at rest, a raised bar once it sticks */
  .sv-service h2::before { content: ""; display: block !important; margin: 0 !important; position: absolute; z-index: -1; top: 0; bottom: 0; left: calc(50% - 50vw); width: 100vw; background: var(--sv-bg); transition: background-color .25s ease, box-shadow .25s ease; }
  .sv-service h2.is-stuck::before { background: color-mix(in srgb, var(--swatch--light-100) 94%, transparent); backdrop-filter: blur(12px); box-shadow: 0 1px 0 var(--swatch--border), 0 10px 24px rgb(9 9 17 / .08); }
  /* How far through the section you are */
  .sv-service h2::after { content: ""; display: block !important; margin: 0 !important; position: absolute; bottom: 0; left: calc(50% - 50vw); width: 100vw; height: 3px; background: var(--swatch--dark-900); transform: scaleX(var(--sv-p, 0)); transform-origin: left; opacity: 0; transition: opacity .25s ease; }
  .sv-service h2.is-stuck::after { opacity: 1; }
}

/* Phones: two videos per service at most (one per format where a service has two),
   two result screenshots, tighter spacing */
@media (max-width: 767px) {
  .sv-service { padding-top: 4rem; padding-bottom: 4.5rem; }
  .sv-service h2 { font-size: 1.75rem; line-height: 1.15; }
  .sv-media { margin-top: 3rem; gap: 3rem; }
  .sv-group { gap: 1.25rem; }
  .sv-grid { row-gap: 1.75rem; }
  .sv-info .u-text-style-large { margin-bottom: 1.75rem; }
  .sv-info .sv-list, .sv-info .sv-formats { margin-bottom: 2rem; }
  .sv-group .sv-grid > .sv-video:nth-child(n+2),
  .sv-media > .sv-grid > .sv-video:nth-child(n+3),
  .sv-results > .sv-result:nth-child(n+3) { display: none; }
  .sv-proof { margin-top: 2rem; padding-top: 1.5rem; }
  .sv-cta-section { padding-bottom: 4.5rem; }
}
