/*
  Simify Partner Brief Hub - shared design system
  Applies to: hub home, blog brief, video briefs (longform/shortform), assets, links, per-partner pages.
  Tokens captured from brand-guidelines skill + live partner-longform.pages.dev / partner-shortform.pages.dev
  (white background, blue accents, sans-serif, star value-prop banner, 5-step horizontal flow, sticky logo top-left).
  No build step. Vanilla CSS only.
*/

/*
  Font stack: brand-guidelines specifies Rubik (primary) + Crimson Text (secondary
  italic), but this build is a free-tier, self-contained, no-CDN static site, so
  we do not load web fonts from a CDN. The stack below names Rubik / Crimson Text
  first (in case they are ever installed locally or self-hosted later) and falls
  through to close system equivalents: a geometric/grotesque sans for Rubik,
  a serif for Crimson Text italic.
*/

/* -------------------- Tokens -------------------- */
/*
  Palette source: brand-guidelines skill Section 11.2 "Live Design Tokens"
  (scraped from simify.com/search and help.simify.com). The skill is explicit
  that these live values win over the aspirational Section 1 palette for any
  partner-facing artifact, so every color below is the live token, not the
  aspirational one, except where the two already agree.
*/
:root {
  /* Core brand palette (live tokens, brand-guidelines Section 11.2) */
  --navy: #0C1924;           /* --simify-primary, matches live */
  --navy-text: #101720;      /* --simify-text-dark, matches live */
  --blue: #0078FC;           /* --simify-blue-bright, matches live */
  --blue-dark: #004DA1;      /* Section 1 dark-blue shade, no live divergence documented */
  --blue-bg: #F0FAFF;        /* --simify-blue-bg (live; Section 1's #E5F6FF is more saturated) */
  --amber: #FFA800;          /* --simify-variant-border, matches live */
  --yellow-pop: #FFEB72;     /* --simify-yellow, the signature flat-shadow pop, matches live */
  --orange: #FF6B17;         /* --simify-orange (live; brighter/redder than Section 1's #F75D05) */
  --white: #FFFFFF;
  --cream: #FFFBEB;          /* --simify-yellow-bg, matches live */
  --grey-border: #D6DEE8;    /* --simify-grey-border (live; Section 1's #E6ECF2 is lighter) */
  --grey-text: #333F48;      /* --simify-grey (live; Section 1's #465164 is bluer) */
  /* --green: live success green is --simify-green #32D77A, but that fails contrast
     against the white text this token is used with (~1.9:1). --simify-dark-green
     #00964E ("data viz green" in the skill) clears ~3.8:1 against white, close to
     the previous token's contrast, so it is used here for the copy-button success
     state instead of the brighter live success green. */
  --green: #00964E;

  /* Body text softened per live-site tokens */
  --body-text: rgba(18, 18, 18, 0.78); /* exact live value: rgba(18, 18, 18, 0.78) */

  /* Type */
  --font-primary: "Rubik", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-secondary: "Crimson Text", Georgia, "Times New Roman", serif;

  /* Layout */
  --container-max: 1200px;
  --content-max: 800px;
  --radius-card: 12px;
  --radius-pill: 999px;
  --radius-button: 8px;
  --shadow-pop-sm: 2px 2px 0 0 var(--yellow-pop);
  --shadow-pop-md: 4px 4px 0 0 var(--yellow-pop);
  --shadow-pop-lg: 6px 6px 0 0 var(--yellow-pop);

  --nav-height: 64px;
}

:root[data-theme="dark"] {
  --white: #0C1924;
  --cream: #14202B;
  --navy-text: #F2F6FA;
  --body-text: rgba(242, 246, 250, 0.82);
  --grey-border: #26333F;
  --blue-bg: #10202B;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --white: #0C1924;
    --cream: #14202B;
    --navy-text: #F2F6FA;
    --body-text: rgba(242, 246, 250, 0.82);
    --grey-border: #26333F;
    --blue-bg: #10202B;
  }
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--white);
  color: var(--body-text);
  font-family: var(--font-primary);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-family: var(--font-primary);
  font-weight: 700;
  color: var(--navy-text);
  line-height: 1.25;
  margin: 0 0 0.5em;
}

h1 { font-size: 2.25rem; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.375rem; }
h4 { font-size: 1.125rem; }

@media (min-width: 769px) {
  h1 { font-size: 3rem; }
  h2 { font-size: 2rem; }
}

.subheading {
  font-family: var(--font-secondary);
  font-style: italic;
  font-weight: 400;
  color: var(--grey-text);
  font-size: 1.15rem;
  margin: 0 0 1.25em;
}

p { margin: 0 0 1em; }

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 24px;
}

@media (min-width: 1025px) {
  .container { padding: 0 48px; }
}

.content-width {
  max-width: var(--content-max);
  margin: 0 auto;
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* -------------------- Header / Sticky nav -------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 2px solid var(--navy);
}

.site-header__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: var(--nav-height);
}

.site-header__logo {
  display: flex;
  align-items: center;
  height: 36px;
}

.site-header__logo img {
  height: 100%;
  width: auto;
}

/* Section nav: sticky scrollable strip of in-page anchors */
.section-nav {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.section-nav::-webkit-scrollbar { display: none; }

.section-nav__link {
  flex: 0 0 auto;
  padding: 8px 14px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--grey-text);
  border-radius: var(--radius-pill);
  white-space: nowrap;
  transition: background 0.15s ease, color 0.15s ease;
}

.section-nav__link:hover {
  background: var(--blue-bg);
  color: var(--blue);
  text-decoration: none;
}

.section-nav__link.is-active {
  background: var(--blue);
  color: var(--white);
}

/* -------------------- Star value-prop banner -------------------- */
.star-banner {
  background: var(--navy);
  color: var(--white);
  overflow: hidden;
  padding: 12px 0;
  border-bottom: 2px solid var(--navy);
}

.star-banner__track {
  display: flex;
  width: max-content;
  animation: star-banner-scroll 32s linear infinite;
}

.star-banner__set {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
}

.star-banner__item {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 20px;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
}

.star-banner__star {
  color: var(--amber);
  font-size: 1rem;
}

@keyframes star-banner-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .star-banner__track { animation: none; }
}

/* -------------------- Buttons -------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 20px;
  border-radius: var(--radius-button);
  border: 2px solid transparent;
  font-family: var(--font-primary);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.1s ease, box-shadow 0.1s ease, background 0.15s ease;
}

.btn:hover { text-decoration: none; }

.btn--primary {
  background: var(--blue);
  color: var(--white);
  box-shadow: var(--shadow-pop-sm);
}

.btn--primary:hover {
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0 0 var(--yellow-pop);
}

.btn--secondary {
  background: var(--white);
  color: var(--blue);
  border-color: var(--blue);
}

.btn--secondary:hover {
  background: var(--blue-bg);
}

.btn--orange {
  background: var(--orange);
  color: var(--white);
}

/* Copy button */
.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 6px 14px;
  border-radius: var(--radius-button);
  border: 2px solid var(--navy);
  background: var(--white);
  color: var(--navy-text);
  font-family: var(--font-primary);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  box-shadow: var(--shadow-pop-sm);
  transition: transform 0.1s ease, background 0.15s ease;
}

.copy-btn:hover {
  background: var(--blue-bg);
  transform: translate(-1px, -1px);
}

.copy-btn:active {
  transform: translate(0, 0);
  box-shadow: none;
}

.copy-btn.is-copied {
  background: var(--green);
  border-color: var(--green);
  color: var(--white);
}

.copy-btn__icon { font-size: 0.9rem; }

/* -------------------- Cards -------------------- */
.card {
  background: var(--white);
  border: 2px solid var(--navy);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-pop-md);
  padding: 24px;
}

.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 769px) {
  .card-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card__badge {
  display: inline-block;
  background: var(--orange);
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  margin-bottom: 12px;
}

/* Kit item row (code / discount / link, each with a copy button) */
.kit-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 14px 16px;
  background: var(--cream);
  border: 1px solid var(--grey-border);
  border-radius: var(--radius-button);
  margin-bottom: 12px;
}

.kit-item__label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--grey-text);
  margin-bottom: 2px;
}

.kit-item__value {
  font-weight: 700;
  color: var(--navy-text);
  word-break: break-word;
}

/* -------------------- Accordion -------------------- */
.accordion {
  border: 1px solid var(--grey-border);
  border-radius: var(--radius-card);
  overflow: hidden;
  margin-bottom: 16px;
}

.accordion__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 16px 20px;
  background: var(--white);
  border: none;
  text-align: left;
  font-family: var(--font-primary);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--navy-text);
  cursor: pointer;
}

.accordion__header:hover { background: var(--blue-bg); }

.accordion__icon {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  transition: transform 0.2s ease;
  color: var(--blue);
  font-weight: 700;
}

.accordion[data-open="true"] .accordion__icon {
  transform: rotate(45deg);
}

.accordion__panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease;
  background: var(--white);
}

.accordion[data-open="true"] .accordion__panel {
  max-height: var(--panel-height, 2000px);
}

.accordion__panel-inner {
  padding: 4px 20px 20px;
}

/* -------------------- Sections -------------------- */
.section {
  padding: 48px 0;
  border-bottom: 1px solid var(--grey-border);
}

.section:last-child { border-bottom: none; }

.section--alt { background: var(--cream); }

.section__label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 8px;
}

.section__label::before {
  content: "\2605"; /* star */
  color: var(--amber);
}

/* -------------------- Hero -------------------- */
.hero {
  background: var(--navy);
  color: var(--white);
  padding: 56px 0;
  text-align: center;
}

.hero h1, .hero .subheading { color: var(--white); }
.hero .subheading { color: rgba(255,255,255,0.75); }

.hero__mascot {
  max-width: 220px;
  margin: 0 auto 24px;
}

/* -------------------- 5-step flow (video briefs) -------------------- */
.step-flow {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  counter-reset: step;
}

@media (min-width: 769px) {
  .step-flow {
    grid-template-columns: repeat(5, 1fr);
  }
}

.step-flow__step {
  position: relative;
  padding: 24px 16px 16px;
  border: 2px solid var(--navy);
  border-radius: var(--radius-card);
  background: var(--white);
  box-shadow: var(--shadow-pop-sm);
  counter-increment: step;
}

.step-flow__step::before {
  content: counter(step);
  position: absolute;
  top: -16px;
  left: 16px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--blue);
  color: var(--white);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* -------------------- Footer -------------------- */
.site-footer {
  background: var(--navy);
  color: rgba(255,255,255,0.8);
  padding: 40px 0;
  font-size: 0.9rem;
}

.site-footer a { color: var(--white); }

.site-footer__row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  align-items: center;
}

/* -------------------- Utilities -------------------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
