/* ==========================================================================
   Convertly — inner pages (every template except the homepage)
   Builds on css/site.css (tokens, type, buttons, cards, stats, plans, FAQ, posts, the
   contact card, header and footer) with what only inner pages need. Mobile-first;
   breakpoints at 640px, 900px and 1100px like site.css.
   ========================================================================== */

/* ---------- Page hero (title banner) ---------- */
.page-hero { position: relative; overflow: hidden; isolation: isolate; padding: 48px 0 64px; }
/* A faint pixel grid and a red glow, fading out from the top: the homepage's engine, at rest */
.page-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: radial-gradient(rgba(254, 253, 255, .13) 1.2px, transparent 1.6px); background-size: 28px 28px;
  -webkit-mask-image: radial-gradient(ellipse 60% 90% at 50% 0%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 60% 90% at 50% 0%, #000 20%, transparent 75%);
}
.page-hero::after {
  content: ""; position: absolute; left: 50%; top: -260px; z-index: -1; width: min(1000px, 140vw); height: 560px; transform: translateX(-50%); pointer-events: none;
  background: radial-gradient(closest-side, rgba(239, 2, 31, .2), transparent);
}
.page-hero__inner { display: flex; flex-direction: column; align-items: center; gap: 22px; text-align: center; }
.page-hero__title { max-width: 1040px; font-size: clamp(2.5rem, 1.5rem + 3.9vw, 4.75rem); font-weight: 500; line-height: 1.05; }
.page-hero__lead { max-width: 720px; }
.page-hero__meta { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 18px; font-size: 14px; color: var(--text-muted); }
.page-hero__meta > * + *::before { content: ""; display: inline-block; width: 5px; height: 5px; margin-right: 18px; vertical-align: middle; background: var(--red); }
.page-hero__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 6px; }
@media (max-width: 767px) { .page-hero__lead br { display: none; } } /* line breaks set for the old desktop layout */
@media (min-width: 768px) { .page-hero { padding: 72px 0 56px; } .page-hero__inner { gap: 26px; } }
/* The first section under the banner starts closer: the banner already has its own space */
.page-hero + .section { padding-top: clamp(40px, 5vw, 72px); }

/* Breadcrumbs (Rank Math) */
.breadcrumbs { font-size: 13px; font-weight: 600; color: var(--text-muted); }
.breadcrumbs p { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 4px 10px; }
.breadcrumbs a { color: var(--text-soft); }
.breadcrumbs a:hover { color: var(--white); }
.breadcrumbs .separator { font-size: 0; }
.breadcrumbs .separator::before { content: ""; display: inline-block; width: 5px; height: 5px; background: var(--red); vertical-align: middle; }
.breadcrumbs .last { color: var(--text-muted); }

/* ---------- Text written in the editor ---------- */
.prose { font-size: 17px; line-height: 1.75; color: var(--text-soft); }
.prose > * + * { margin-top: 1.05em; }
.prose h2, .prose h3, .prose h4, .prose h5 { margin-top: 1.7em; color: var(--white); line-height: 1.2; letter-spacing: -0.02em; }
.prose h2 { font-size: clamp(1.6rem, 1.3rem + 1vw, 2.1rem); }
.prose h3 { font-size: 1.4rem; }
.prose h4, .prose h5 { font-family: var(--font-display); font-size: 1.15rem; }
.prose > :first-child { margin-top: 0; }
.prose a { color: var(--white); text-decoration: underline; text-decoration-color: var(--red); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.prose a:hover { color: var(--red-text); }
.prose strong, .prose b { color: var(--white); font-weight: 700; }
.prose ul, .prose ol { display: grid; gap: .55em; }
.prose ul li { position: relative; padding-left: 24px; }
.prose ul li::before { content: ""; position: absolute; left: 2px; top: .72em; width: 7px; height: 7px; background: var(--red); } /* the brand's pixel as the bullet */
.prose ol { counter-reset: item; }
.prose ol li { position: relative; padding-left: 36px; counter-increment: item; }
.prose ol li::before { content: counter(item, decimal-leading-zero); position: absolute; left: 0; font-weight: 700; font-size: .85em; line-height: 2.05; color: var(--red-text); }
.prose li > ul, .prose li > ol { margin-top: .55em; }
.prose img { border-radius: var(--radius); height: auto; }
.prose blockquote { margin: 0; padding-left: 22px; border-left: 3px solid var(--red); font-family: var(--font-accent); font-style: italic; font-size: 1.45em; line-height: 1.35; color: var(--white); }
.prose table { width: 100%; border-collapse: collapse; font-size: .92em; }
.prose th, .prose td { padding: 12px 14px; border-bottom: 1px solid var(--line-strong); text-align: left; vertical-align: top; }
.prose th { color: var(--white); }
.prose hr { border: 0; border-top: 1px solid var(--line-strong); }
/* The old theme's red-word span inside editor text and headings */
.fc-primary { color: var(--red-text); }

/* FAQ answers written in the editor (the homepage's answers are single paragraphs) */
.faq__answer { padding: 0 56px 26px 0; font-size: 16px; }
.faq__item .faq__answer p { padding: 0; }

/* ---------- Image beside text (left or right) ---------- */
.media-split { display: grid; gap: 40px; align-items: center; }
.media-split__media { overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
.media-split__media img { width: 100%; height: auto; }
.media-split__body { display: flex; flex-direction: column; align-items: flex-start; gap: 22px; }
.media-split__title { font-size: clamp(1.9rem, 1.35rem + 1.7vw, 2.9rem); line-height: 1.06; }
@media (min-width: 900px) {
  .media-split { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 72px; }
  .media-split--reverse .media-split__media { order: 2; }
}

/* Accordion inside a section (native <details>, the answers stay in the HTML) */
.accordion { width: 100%; border-top: 1px solid var(--line-strong); }
.accordion__item { border-bottom: 1px solid var(--line-strong); }
.accordion__item summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 0; }
.accordion__item summary::-webkit-details-marker { display: none; }
.accordion__item summary h3 { font-family: var(--font-body); font-size: 18px; letter-spacing: -0.01em; }
.accordion__item summary:hover h3 { color: var(--red-text); }
.accordion__icon { flex-shrink: 0; width: 32px; height: 32px; border-radius: 50%; border: 1px solid rgba(254, 253, 255, .2); display: inline-flex; align-items: center; justify-content: center; transition: transform .25s, background-color .25s, border-color .25s; }
.accordion__icon .icon { width: 14px; height: 14px; }
.accordion__item[open] .accordion__icon { transform: rotate(45deg); background: var(--red-btn); border-color: var(--red-btn); }
.accordion__body { padding: 0 48px 20px 0; font-size: 16px; }

/* ---------- Statement with the monogram ---------- */
.statement { display: grid; gap: 40px; align-items: center; }
.statement__body { display: flex; flex-direction: column; align-items: flex-start; gap: 24px; }
.statement__title { font-size: clamp(2rem, 1.4rem + 2vw, 3.25rem); line-height: 1.05; }
.statement__mark { display: none; }
@media (min-width: 900px) {
  .statement { grid-template-columns: 7fr 1fr 4fr; }
  .statement__mark {
    display: flex; grid-column: 3; aspect-ratio: 1; align-items: center; justify-content: center;
    border: 1px solid var(--line); border-radius: var(--radius-lg);
    background: radial-gradient(circle at 70% 30%, rgba(239, 2, 31, .22), transparent 60%), var(--surface);
  }
  .statement__mark .icon { width: 52%; height: 52%; color: var(--red); }
}

/* ---------- Card grids (services, industries) ---------- */
.card-grid { display: grid; gap: 16px; }
.card-grid .service { min-height: 0; }
.service__title { font-family: var(--font-display); font-size: var(--fs-h3); font-weight: 700; line-height: 1.15; letter-spacing: -0.02em; }
@media (min-width: 640px) { .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) {
  .card-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
  .card-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .card-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .card-grid .service { min-height: 230px; }
}

/* Stat card extras */
.stat__text { margin-top: -28px; font-size: 14px; color: var(--text-muted); }
.stat--red dd span { color: var(--white); } /* the symbol (+, %) on the red card */

/* ---------- Call-to-action band (grow your business, performance, strategy) ---------- */
.band {
  position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: flex-start; gap: 22px;
  padding: clamp(32px, 5vw, 72px); border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--red) 0%, var(--red-deep) 45%, var(--surface) 100%);
}
.band > * { position: relative; }
.band__mark { position: absolute !important; right: -50px; bottom: -70px; width: 380px; height: 380px; opacity: .14; color: var(--white); pointer-events: none; }
.band__title { max-width: 860px; font-size: clamp(2.2rem, 1.6rem + 2.2vw, 3.6rem); line-height: 1.02; }
.band__title .fc-primary, .band__title .accent { font-family: var(--font-accent); font-style: italic; font-weight: 400; letter-spacing: -0.01em; color: var(--white); }
.band__text { max-width: 640px; color: #f3dfe2; font-size: var(--fs-lead); line-height: 1.65; }
.band__text p + p { margin-top: .8em; }
.band .btn { background: var(--white); color: var(--navy); }
.band .btn:hover { background: #f3dfe2; color: var(--navy); }
.band--center { align-items: center; text-align: center; }
.band--center .band__mark { right: auto; left: -60px; }
/* The quieter version on navy (strategy section) */
.band--quiet { background: radial-gradient(circle at 85% 15%, rgba(239, 2, 31, .2), transparent 55%), var(--surface); border: 1px solid var(--line); }
.band--quiet .band__mark { color: var(--red); opacity: .18; }
.band--quiet .band__text { color: var(--text-soft); }
.band--quiet .band__title .fc-primary, .band--quiet .band__title .accent { color: var(--red-text); }
.band--quiet .btn { background: var(--red-btn); color: var(--white); }
.band--quiet .btn:hover { background: var(--red-hover); color: var(--white); }

/* ---------- Packages ---------- */
.plan__logos { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.plan__logos img { width: 34px; height: 34px; padding: 5px; border-radius: 10px; background: var(--white); object-fit: contain; }
.plan__text { font-size: 15px; line-height: 1.65; color: var(--text-muted); }
.plan__text p + p { margin-top: .6em; }
.plan__powered { display: inline-block; margin-left: 6px; padding: 2px 8px; border-radius: 999px; border: 1px solid rgba(239, 2, 31, .5); font-size: 11px; font-weight: 700; letter-spacing: .06em; color: var(--red-text); vertical-align: 1px; }
.plan .btn { width: 100%; }
/* Bundles: one wide card each */
.bundles { display: grid; gap: 20px; margin-top: 20px; }
.bundle { padding: clamp(28px, 4vw, 44px); display: grid; gap: 28px; }
.bundle__head { display: flex; flex-direction: column; gap: 16px; }
.bundle__head h3 { font-size: clamp(1.6rem, 1.3rem + 1vw, 2.1rem); }
.bundle__buy { display: flex; flex-direction: column; gap: 18px; }
.bundle__lists { display: grid; gap: 14px 32px; }
@media (min-width: 900px) {
  .bundle { grid-template-columns: 5fr 7fr; column-gap: 56px; }
  .bundle__lists { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- Filter chips (pricing categories, blog categories) ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 36px; }
.filters button { display: inline-flex; align-items: center; min-height: 44px; padding: 0 20px; border-radius: 999px; border: 1px solid var(--line-strong); background: #161c2d; color: var(--white); font: 600 15px var(--font-body); cursor: pointer; transition: border-color .2s, background-color .2s; }
.filters button:hover { border-color: var(--red); }
.filters button[aria-pressed="true"] { border-color: var(--red-btn); background: var(--red-btn); }
[data-filter-group][hidden] { display: none !important; }

/* ---------- Blog index ---------- */
.post--featured { margin-bottom: 20px; }
.post--featured > a { display: grid; }
.post--featured .post__body { justify-content: center; gap: 18px; padding: clamp(28px, 4vw, 48px); }
.post--featured h2 { font-size: clamp(1.8rem, 1.4rem + 1.4vw, 2.6rem); line-height: 1.08; }
.post--featured .post__excerpt { color: var(--text-soft); }
.post__label { font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--red-text); }
.post__excerpt { font-size: 15px; color: var(--text-muted); }
@media (min-width: 900px) { .post--featured > a { grid-template-columns: 6fr 5fr; } .post--featured .post__media { aspect-ratio: auto; min-height: 100%; } }
.post a:hover h3, .post a:hover h2 { color: var(--red-text); }

/* ---------- Article (blog posts, case studies) ---------- */
.article__cover { margin: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-lg); aspect-ratio: 1200 / 520; background: var(--surface); }
.article__cover img { width: 100%; height: 100%; object-fit: cover; }
.container:has(> .article__cover) + .section { padding-top: clamp(48px, 6vw, 88px); } /* the article under the cover */
.article { display: grid; gap: 40px; }
.article__main { min-width: 0; }
.article__section { scroll-margin-top: calc(var(--header-top) + var(--header-h) + 24px); }
.article__section + .article__section { margin-top: 56px; padding-top: 56px; border-top: 1px solid var(--line); }
.article__section > h2 { font-size: clamp(1.7rem, 1.35rem + 1.2vw, 2.4rem); line-height: 1.12; margin-bottom: 20px; }
.article__section .prose + h2 { margin-top: 44px; }
.article__figure { margin: 28px 0 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); }
.article__figure img { width: 100%; height: auto; }
.toc { display: none; }
.toc__title { font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--text-muted); }
.toc ol { display: flex; flex-direction: column; gap: 2px; margin-top: 14px; border-left: 1px solid var(--line-strong); }
.toc a { display: block; margin-left: -1px; padding: 8px 0 8px 16px; border-left: 2px solid transparent; font-size: 15px; font-weight: 600; line-height: 1.35; color: var(--text-muted); }
.toc a:hover { border-left-color: var(--red); color: var(--white); }
@media (min-width: 1100px) {
  .article { grid-template-columns: 250px minmax(0, 1fr); gap: 80px; }
  .toc { display: block; position: sticky; top: calc(var(--header-top) + var(--header-h) + 32px); align-self: start; }
}
.subscribe-card { margin-top: 40px; }
.article__footer { display: flex; flex-direction: column; gap: 28px; margin-top: 56px; padding-top: 32px; border-top: 1px solid var(--line); }
.share { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.share__label { margin-right: 6px; font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--text-muted); }
.share a, .share button { display: inline-flex; align-items: center; min-height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-strong); background: transparent; color: var(--white); font: 600 13px var(--font-body); cursor: pointer; }
.share a:hover, .share button:hover { border-color: var(--red); color: var(--white); }
.share button.is-copied { border-color: #1f9d55; }
.author-card { display: flex; align-items: center; gap: 18px; padding: 24px; }
.author-card img { width: 64px; height: 64px; flex-shrink: 0; border-radius: 50%; object-fit: cover; background: var(--surface-hover); }
.author-card__role { font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--red-text); }
.author-card__name { font-family: var(--font-display); font-size: 20px; font-weight: 700; }
.author-card__bio { margin-top: 4px; font-size: 14px; color: var(--text-muted); }
.author-card .btn { margin-left: auto; flex-shrink: 0; }
@media (max-width: 639px) { .author-card { flex-wrap: wrap; } .author-card .btn { margin-left: 0; } }
/* Case study figures */
.figures { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 28px; }
.figures .stat { gap: 18px; }

/* ---------- Text pages (privacy, terms) ---------- */
.text-page { max-width: 820px; margin-inline: auto; }

/* ---------- Contact page ---------- */
.map-card { display: grid; overflow: hidden; }
.map-card__media img { width: 100%; height: 100%; object-fit: cover; }
.map-card__body { display: flex; flex-direction: column; align-items: flex-start; gap: 18px; padding: clamp(28px, 4vw, 48px); }
.map-card__logo { width: 150px; height: auto; }
@media (min-width: 900px) { .map-card { grid-template-columns: 7fr 5fr; } .map-card__body { justify-content: center; } }

/* ---------- Not found ---------- */
.not-found__links { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }

/* Sections with the heading centred over a grid */
.section-head--center .lead, .section-head--center .muted { max-width: 720px; }
.section-head .prose { max-width: 720px; }
