/* Concise case study (inc/aa-brand-2026.php, release 2026-10b).
   Uses the site's own tokens, so dark/light mode and the accent picker apply
   unchanged. Motion: the site's reveal system (inbio-brand.js) plus small
   hover lifts; everything is switched off under prefers-reduced-motion. */

.aa-cs2 { --cs-blue: #3C78A8; --cs-wine: #90243C; --cs-r: 18px; color: var(--color-body); }
.aa-cs2__wrap { width: min(100% - 40px, 1160px); margin-inline: auto; }
.aa-cs2 svg { display: block; flex: none; }
.aa-cs2__stack li, .aa-cs2__feats li, .aa-cs2__shots li { list-style: none; }
[dir="rtl"] .aa-cs2__flip { transform: scaleX(-1); }

/* ---------------------------------------------------------------- hero */
.aa-cs2__hero { position: relative; padding: clamp(28px, 5vw, 64px) 0 clamp(28px, 4vw, 48px); overflow: clip; }
.aa-cs2__hero::before {
  content: ""; position: absolute; inset: -40% -10% auto; height: 120%; pointer-events: none; z-index: 0;
  background:
    radial-gradient(40% 50% at 18% 40%, color-mix(in srgb, var(--cs-blue) 22%, transparent), transparent 70%),
    radial-gradient(36% 46% at 86% 30%, color-mix(in srgb, var(--cs-wine) 18%, transparent), transparent 70%);
  opacity: .9;
}
.aa-cs2__hero-in { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: clamp(24px, 4vw, 56px); align-items: center; }
.aa-cs2__intro { min-width: 0; }
.aa-cs2__back { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; margin: 0 0 6px;
  font-size: 14px; font-weight: 600; color: var(--color-body) !important; text-decoration: none !important;
  transition: color var(--aa-dur, .28s) var(--aa-ease, ease), gap var(--aa-dur, .28s) var(--aa-ease, ease); }
.aa-cs2__back:hover { color: var(--aa-accent) !important; gap: 11px; }
.aa-cs2__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 0 0 14px; font-size: 13px; }
.aa-cs2__cat { color: var(--color-heading); font-weight: 600; }
.aa-cs2__read { color: var(--color-body); opacity: .85; }
.aa-cs2__read::before { content: "·"; margin-inline-end: 12px; opacity: .6; }
.aa-cs2__h1 { margin: 0 0 14px !important; font-size: clamp(36px, 5.2vw, 60px) !important; line-height: 1.06 !important;
  letter-spacing: -.03em; font-weight: 750; color: var(--color-heading); overflow-wrap: anywhere; }
[dir="rtl"] .aa-cs2__h1 { letter-spacing: 0; line-height: 1.25 !important; }
.aa-cs2__lede { margin: 0 0 22px !important; max-width: 46ch; font-size: clamp(17px, 1.5vw, 20px); line-height: 1.6; color: var(--color-body); }
.aa-cs2__actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 22px; }

.aa-cs2__btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 48px; padding: 0 20px;
  border-radius: 999px; font-size: 15px; font-weight: 600; line-height: 1.2; text-decoration: none !important; border: 1px solid transparent;
  transition: transform .28s var(--aa-ease, ease), box-shadow .28s var(--aa-ease, ease), border-color .28s, background-color .28s, filter .28s; }
.aa-cs2__btn--primary { color: #fff !important;
  background: linear-gradient(120deg, var(--cs-blue), color-mix(in srgb, var(--cs-blue) 50%, var(--cs-wine))); }
.aa-cs2__btn--primary:hover { transform: translateY(-2px); filter: brightness(1.07);
  box-shadow: 0 12px 28px -14px color-mix(in srgb, var(--cs-blue) 90%, transparent); }
.aa-cs2__btn--ghost { color: var(--color-heading) !important; border-color: var(--aa-line); background: var(--aa-surface); }
.aa-cs2__btn--ghost:hover { transform: translateY(-2px); border-color: var(--aa-accent); }
.aa-cs2__btn--ghost svg { transition: transform .28s var(--aa-ease, ease); }
.aa-cs2__btn--ghost:hover svg { transform: translateX(3px); }
[dir="rtl"] .aa-cs2__btn--ghost:hover svg { transform: scaleX(-1) translateX(3px); }
.aa-cs2__btn:active { transform: translateY(0) scale(.98); }
.aa-cs2__btn:focus-visible, .aa-cs2__back:focus-visible, .aa-cs2__link:focus-visible,
.aa-cs2__nextcard:focus-visible, .aa-cs2__more summary:focus-visible { outline: 2px solid var(--aa-accent); outline-offset: 3px; }

.aa-cs2__stack { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.aa-cs2__stack-l { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--color-heading); margin-inline-end: 4px; }
[dir="rtl"] .aa-cs2__stack-l { letter-spacing: 0; font-size: 13px; }
.aa-cs2__stack ul { display: contents; }
.aa-cs2__stack li { margin: 0; padding: 4px 11px; border-radius: 999px; font-size: 12.5px; line-height: 1.5;
  border: 1px solid var(--aa-line); color: var(--color-body); background: var(--aa-surface); }
.aa-cs2__stack li::before { content: none !important; }

.aa-cs2__visual { position: relative; margin: 0; border-radius: var(--cs-r); padding: 1px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--cs-blue) 70%, transparent), color-mix(in srgb, var(--cs-wine) 55%, transparent));
  box-shadow: 0 40px 80px -48px rgba(0, 0, 0, .85); }
body.white-version .aa-cs2__visual { box-shadow: 0 30px 60px -40px rgba(16, 24, 40, .45); }
.aa-cs2__visual-img { display: block; width: 100%; height: auto; border-radius: calc(var(--cs-r) - 1px); }

/* ------------------------------------------------------------ the story */
.aa-cs2__story { padding: clamp(8px, 2vw, 20px) 0 clamp(28px, 4vw, 48px); }
.aa-cs2__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 0 0 16px; }
.aa-cs2__card, .aa-cs2__panel { position: relative; min-width: 0; padding: 22px 22px 20px; border-radius: var(--cs-r);
  border: 1px solid var(--aa-line); background: var(--aa-surface);
  transition: transform .3s var(--aa-ease, ease), border-color .3s, box-shadow .3s; }
.aa-cs2__card:hover, .aa-cs2__panel:hover { transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--aa-accent) 45%, var(--aa-line)); box-shadow: var(--aa-shadow-2); }
.aa-cs2__num { margin: 0 0 10px !important; font-size: 13px; font-weight: 700; letter-spacing: .1em; color: var(--aa-accent); font-variant-numeric: tabular-nums; }
.aa-cs2__h2 { margin: 0 0 8px !important; font-size: clamp(19px, 1.8vw, 22px) !important; line-height: 1.3 !important;
  font-weight: 700; letter-spacing: -.01em; color: var(--color-heading); }
[dir="rtl"] .aa-cs2__h2 { letter-spacing: 0; }
.aa-cs2__card p:last-child, .aa-cs2__panel p { margin: 0; font-size: 15.5px; line-height: 1.7; color: var(--color-body); }
.aa-cs2__card--problem::after { content: ""; position: absolute; inset-inline-start: 22px; top: 0; width: 36px; height: 3px;
  border-radius: 0 0 3px 3px; background: var(--cs-wine); }
.aa-cs2__card--solution::after { content: ""; position: absolute; inset-inline-start: 22px; top: 0; width: 36px; height: 3px;
  border-radius: 0 0 3px 3px; background: var(--cs-blue); }

.aa-cs2__split { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 16px; }
.aa-cs2__feats { margin: 6px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.aa-cs2__feats li { display: flex; gap: 10px; align-items: flex-start; margin: 0; font-size: 15.5px; line-height: 1.55; color: var(--color-heading); }
.aa-cs2__feats li::before { content: none !important; }
.aa-cs2__feats svg { width: 20px; height: 20px; margin-top: 1px; padding: 3px; border-radius: 50%; color: #fff;
  background: linear-gradient(135deg, var(--cs-blue), color-mix(in srgb, var(--cs-blue) 45%, var(--cs-wine))); }
.aa-cs2__panel--outcome { border-color: color-mix(in srgb, var(--aa-accent) 38%, transparent);
  background: linear-gradient(160deg, color-mix(in srgb, var(--aa-accent) 10%, transparent), var(--aa-surface) 70%); }
.aa-cs2__panel .aa-cs2__value { color: var(--color-heading); font-weight: 600; font-size: 16.5px; margin: 0 0 10px; }
.aa-cs2__panel .aa-cs2__note { font-size: 14.5px; }

/* -------------------------------------------------------------- gallery */
.aa-cs2__gallery { padding: 0 0 clamp(28px, 4vw, 48px); }
.aa-cs2__h2--sm { font-size: 13px !important; letter-spacing: .1em; text-transform: uppercase; color: var(--color-body); margin-bottom: 12px !important; }
[dir="rtl"] .aa-cs2__h2--sm { font-size: 15px !important; letter-spacing: 0; }
.aa-cs2__shots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 0; padding: 0; list-style: none; }
.aa-cs2__shot { margin: 0; overflow: hidden; border-radius: 14px; border: 1px solid var(--aa-line); background: var(--aa-surface-2);
  aspect-ratio: 16 / 10; transition: transform .3s var(--aa-ease, ease), border-color .3s, box-shadow .3s; }
.aa-cs2__shot::before { content: none !important; }
.aa-cs2__shot-img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top center;
  transition: transform .75s var(--aa-in-ease, ease); }
.aa-cs2__shot:hover { transform: translateY(-4px); border-color: color-mix(in srgb, var(--aa-accent) 45%, var(--aa-line)); box-shadow: var(--aa-shadow-2); }
.aa-cs2__shot:hover .aa-cs2__shot-img { transform: scale(1.04); }
/* 2026-10c: Elementor's `.elementor img { height: auto }` (0,1,1) outranked the
   single-class rules above, so screenshots wider than 16:10 left an empty band
   under the image. Two classes win without !important. */
.aa-cs2 .aa-cs2__shot-img, .aa-cs2 .aa-cs2__nextcard-m img { height: 100%; }
.aa-cs2__gallery--phone .aa-cs2__shots { grid-template-columns: repeat(3, minmax(0, 220px)); justify-content: center; }
.aa-cs2__gallery--phone .aa-cs2__shot { aspect-ratio: 473 / 1024; border-radius: 22px; }

/* ------------------------------------------------- full write-up toggle */
.aa-cs2__more-sec { padding: 0 0 clamp(24px, 4vw, 40px); }
.aa-cs2__more { border: 1px solid var(--aa-line); border-radius: var(--cs-r); background: var(--aa-surface); }
.aa-cs2__more summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: 1fr auto; gap: 2px 16px; align-items: center;
  min-height: 64px; padding: 16px 22px; border-radius: var(--cs-r); }
.aa-cs2__more summary::-webkit-details-marker { display: none; }
.aa-cs2__more summary::after { content: ""; grid-column: 2; grid-row: 1 / span 2; width: 10px; height: 10px; margin: 0 6px;
  border: solid var(--color-heading); border-width: 0 2px 2px 0; transform: rotate(45deg); transition: transform .3s var(--aa-ease, ease); }
.aa-cs2__more[open] summary::after { transform: rotate(-135deg); }
.aa-cs2__more summary:hover .aa-cs2__more-t { color: var(--aa-accent); }
.aa-cs2__more-t { font-size: 16.5px; font-weight: 700; color: var(--color-heading); transition: color .25s; }
.aa-cs2__more-s { font-size: 14px; color: var(--color-body); }
.aa-cs2__full { border-top: 1px solid var(--aa-line); padding: 4px 0 8px; }
.aa-cs2__more[open] .aa-cs2__full { animation: aa-cs2-open .35s var(--aa-ease, ease); }
@keyframes aa-cs2-open { from { opacity: 0; transform: translateY(-6px); } }
/* the kept Elementor sections sit inside the panel: tighter rhythm, no second gutter */
.aa-cs2__full .aa-cs-sec { padding-block: clamp(18px, 3vw, 30px) !important; }
.aa-cs2__full .aa-cs-sec > .e-con-inner { width: min(100% - 44px, 1100px) !important; }

/* -------------------------------------------------------- end of page */
.aa-cs2__end { padding: 0 0 clamp(40px, 6vw, 72px); }
.aa-cs2__end-in { display: grid; gap: 16px; }
.aa-cs2__nextcard { display: grid; grid-template-columns: 200px minmax(0, 1fr) auto; align-items: center; gap: 20px;
  padding: 12px; padding-inline-end: 22px; border-radius: 22px; text-decoration: none !important;
  border: 1px solid var(--aa-line); background: var(--aa-surface);
  transition: transform .3s var(--aa-ease, ease), border-color .3s, box-shadow .3s; }
.aa-cs2__nextcard:hover { transform: translateY(-4px); border-color: color-mix(in srgb, var(--aa-accent) 50%, var(--aa-line)); box-shadow: var(--aa-shadow-2); }
.aa-cs2__nextcard-m { display: block; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 14px; background: var(--aa-surface-2); }
.aa-cs2__nextcard-m img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .75s var(--aa-in-ease, ease); }
.aa-cs2__nextcard:hover .aa-cs2__nextcard-m img { transform: scale(1.05); }
.aa-cs2__nextcard-b { display: grid; gap: 4px; min-width: 0; }
.aa-cs2__nextcard-k { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--aa-accent); }
[dir="rtl"] .aa-cs2__nextcard-k { letter-spacing: 0; font-size: 13px; }
.aa-cs2__nextcard-t { font-size: clamp(20px, 2.2vw, 26px); font-weight: 700; color: var(--color-heading); line-height: 1.25; }
.aa-cs2__nextcard-d { font-size: 15px; color: var(--color-body); line-height: 1.5; }
.aa-cs2__nextcard-i { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; color: var(--color-heading);
  border: 1px solid var(--aa-line); transition: background-color .3s, color .3s, transform .3s var(--aa-ease, ease); }
.aa-cs2__nextcard:hover .aa-cs2__nextcard-i { background: var(--aa-accent); color: #fff; border-color: transparent; transform: translateX(3px); }
[dir="rtl"] .aa-cs2__nextcard:hover .aa-cs2__nextcard-i { transform: translateX(-3px); }
.aa-cs2__end-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin: 0; }
.aa-cs2__link { display: inline-flex; align-items: center; min-height: 44px; font-size: 15px; font-weight: 600;
  color: var(--aa-accent) !important; text-decoration: none !important; background: linear-gradient(currentColor, currentColor) no-repeat 0 85% / 0 2px;
  transition: background-size .3s var(--aa-ease, ease); }
[dir="rtl"] .aa-cs2__link { background-position: 100% 85%; }
.aa-cs2__link:hover { background-size: 100% 2px; }

/* ----------------------------------------------------------- responsive */
@media (max-width: 991px) {
  .aa-cs2__hero-in { grid-template-columns: 1fr; }
  .aa-cs2__visual { order: 2; }
  .aa-cs2__grid { grid-template-columns: 1fr; }
  .aa-cs2__split { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .aa-cs2__wrap { width: min(100% - 32px, 1160px); }
  .aa-cs2__actions .aa-cs2__btn { flex: 1 1 100%; }
  .aa-cs2__card, .aa-cs2__panel { padding: 20px 18px 18px; }
  .aa-cs2__shots { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 82%; overflow-x: auto;
    scroll-snap-type: x mandatory; padding-bottom: 6px; overscroll-behavior-x: contain; }
  .aa-cs2__shot { scroll-snap-align: start; }
  .aa-cs2__gallery--phone .aa-cs2__shots { grid-template-columns: none; grid-auto-columns: 58%; justify-content: start; }
  .aa-cs2__nextcard { grid-template-columns: minmax(0, 1fr) auto; padding: 12px; padding-inline-end: 16px; }
  .aa-cs2__nextcard-m { grid-column: 1 / -1; }
  .aa-cs2__end-actions .aa-cs2__btn { flex: 1 1 100%; }
  .aa-cs2__end-actions .aa-cs2__link { margin-inline: auto; }
  .aa-cs2__full .aa-cs-sec > .e-con-inner { width: min(100% - 32px, 1100px) !important; }
  .aa-cs2__more summary { padding: 14px 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .aa-cs2 *, .aa-cs2 *::after { transition: none !important; animation: none !important; }
  .aa-cs2__card:hover, .aa-cs2__panel:hover, .aa-cs2__shot:hover, .aa-cs2__nextcard:hover,
  .aa-cs2__btn:hover, .aa-cs2__shot:hover .aa-cs2__shot-img, .aa-cs2__nextcard:hover .aa-cs2__nextcard-m img { transform: none; }
}

/* entrance: CSS only, so nothing waits for script and nothing stays hidden.
   The visual moves but never fades, so it can paint as the LCP at once. */
@media (prefers-reduced-motion: no-preference) {
  .aa-cs2__intro > * { animation: aa-cs2-rise .7s var(--aa-in-ease, cubic-bezier(.22,.68,.36,1)) both; }
  .aa-cs2__intro > :nth-child(2) { animation-delay: .05s; }
  .aa-cs2__intro > :nth-child(3) { animation-delay: .1s; }
  .aa-cs2__intro > :nth-child(4) { animation-delay: .15s; }
  .aa-cs2__intro > :nth-child(5) { animation-delay: .2s; }
  .aa-cs2__intro > :nth-child(6) { animation-delay: .25s; }
  .aa-cs2__visual { animation: aa-cs2-settle .9s var(--aa-in-ease, cubic-bezier(.22,.68,.36,1)) both; }
}
@keyframes aa-cs2-rise { from { opacity: 0; transform: translateY(14px); } }
@keyframes aa-cs2-settle { from { transform: translateY(18px) scale(.985); } }

/* Scroll reveal for the cards, one after another (inspired by the reveal-on-
   scroll pattern, written for this site). It runs on the `translate`
   property, not `transform`, so the hover lift above keeps working, and it
   exists only under html.aa-anim: with script blocked or reduced motion
   asked, everything is simply visible. */
html.aa-anim [data-aa-reveal] .aa-cs2__card,
html.aa-anim [data-aa-reveal] .aa-cs2__panel,
html.aa-anim [data-aa-reveal] .aa-cs2__shot {
  opacity: 0; translate: 0 22px;
  transition: opacity .65s var(--aa-in-ease, ease) var(--cs-d, 0s), translate .65s var(--aa-in-ease, ease) var(--cs-d, 0s),
    transform .3s var(--aa-ease, ease), border-color .3s, box-shadow .3s;
}
html.aa-anim [data-aa-reveal].is-in .aa-cs2__card,
html.aa-anim [data-aa-reveal].is-in .aa-cs2__panel,
html.aa-anim [data-aa-reveal].is-in .aa-cs2__shot { opacity: 1; translate: none; }
.aa-cs2__grid > :nth-child(2), .aa-cs2__shots > :nth-child(2) { --cs-d: .09s; }
.aa-cs2__grid > :nth-child(3), .aa-cs2__shots > :nth-child(3) { --cs-d: .18s; }
.aa-cs2__split > :nth-child(1) { --cs-d: .24s; }
.aa-cs2__split > :nth-child(2) { --cs-d: .32s; }
