/* ==========================================================================
   Interactive Lion - v2 theme
   Ported from the approved static design samples (home.html / interpage.html).
   Shared by HomePageV2.master and InteriorPageV2.master.
   ========================================================================== */

:root{
  --font-display:'Sora','Segoe UI',system-ui,-apple-system,sans-serif;
  --font-body:'Inter','Segoe UI',system-ui,-apple-system,sans-serif;

  --bg:#ffffff;
  --bg-alt:#f2f8fc;
  --bg-dark:#071429;
  --bg-dark-2:#0c2140;
  --card:#ffffff;
  --card-border:#e2ecf4;
  --ink:#0b1524;
  --ink-soft:#4c5c72;
  --ink-faint:#7c8ba1;
  --border:#e1eaf2;

  --brand-blue:#0b5fa5;
  --brand-blue-bright:#1f86e0;
  --brand-blue-deep:#063a67;
  --brand-lime:#33ab52;
  --brand-lime-bright:#4fd377;

  /* Body-copy link colour. --brand-blue passes on the light background but
     measures 2.79:1 on the dark one, so each theme defines its own. */
  --link:var(--brand-blue);
  --link-hover:var(--brand-blue-deep);

  --white:#ffffff;
  --shadow-sm:0 1px 2px rgba(11,21,36,.06), 0 1px 1px rgba(11,21,36,.04);
  --shadow-md:0 8px 24px -6px rgba(11,21,36,.12), 0 2px 8px rgba(11,21,36,.06);
  --shadow-lg:0 24px 48px -12px rgba(7,20,41,.28);

  --radius-sm:10px;
  --radius-md:16px;
  --radius-lg:22px;

  --container:1200px;

  --fs-h1:clamp(2.4rem, 1.4rem + 4.6vw, 4.4rem);
  --fs-h2:clamp(1.8rem, 1.35rem + 2vw, 2.75rem);
  --fs-h3:clamp(1.25rem, 1.1rem + .6vw, 1.55rem);
  --fs-lead:clamp(1.05rem, .95rem + .5vw, 1.25rem);

  --fs-h1-interior:clamp(2.1rem, 1.5rem + 2.6vw, 3.2rem);
  --fs-h2-interior:clamp(1.6rem, 1.3rem + 1.2vw, 2.1rem);

  color-scheme: light;
}

[data-theme="dark"]{
  --bg:#0b1524; --bg-alt:#0f1e33; --bg-dark:#040a15; --bg-dark-2:#08152a;
  --card:#101f36; --card-border:#203350; --ink:#eef3f9; --ink-soft:#aebdd2; --ink-faint:#7f90a8; --border:#1e2f4a;
  --link:#7fb9ec; --link-hover:#a8d0f5;
  --shadow-md:0 8px 24px -6px rgba(0,0,0,.45), 0 2px 8px rgba(0,0,0,.3);
  --shadow-lg:0 24px 48px -12px rgba(0,0,0,.55);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]){
    --bg:#0b1524; --bg-alt:#0f1e33; --bg-dark:#040a15; --bg-dark-2:#08152a;
    --card:#101f36; --card-border:#203350; --ink:#eef3f9; --ink-soft:#aebdd2; --ink-faint:#7f90a8; --border:#1e2f4a;
  --link:#7fb9ec; --link-hover:#a8d0f5;
    --shadow-md:0 8px 24px -6px rgba(0,0,0,.45), 0 2px 8px rgba(0,0,0,.3);
    --shadow-lg:0 24px 48px -12px rgba(0,0,0,.55);
    color-scheme: dark;
  }
}

*,*::before,*::after{box-sizing:border-box;}
html{scroll-behavior:smooth;}
body{
  margin:0;font-family:var(--font-body);background:var(--bg);color:var(--ink);
  -webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;
  transition:background .25s ease, color .25s ease; overflow-x:hidden;
}
img{max-width:100%;display:block;}
a{color:inherit;}
h1,h2,h3,h4{font-family:var(--font-display);margin:0;line-height:1.15;font-weight:700;letter-spacing:-.01em;}
p{margin:0;color:var(--ink-soft);line-height:1.75;}
.container{max-width:var(--container);margin:0 auto;padding:0 24px;}
section{position:relative;}

.eyebrow{
  display:inline-flex;align-items:center;gap:8px;font-family:var(--font-body);font-weight:700;
  font-size:.78rem;letter-spacing:.14em;text-transform:uppercase;color:var(--brand-blue-bright);
}
.eyebrow::before{content:"";width:22px;height:2px;background:var(--brand-lime);border-radius:2px;}

/* ---------- Buttons ---------- */
.btn{
  --btn-fg:#fff;display:inline-flex;align-items:center;justify-content:center;gap:8px;
  font-family:var(--font-body);font-weight:600;font-size:.95rem;padding:13px 26px;border-radius:999px;
  border:1px solid transparent;text-decoration:none;cursor:pointer;white-space:nowrap;
  transition:transform .18s ease, box-shadow .18s ease, background-color .18s ease, border-color .18s ease, color .18s ease;
}
.btn-primary{background:linear-gradient(135deg,var(--brand-blue-bright),var(--brand-blue-deep));color:var(--btn-fg);box-shadow:0 10px 24px -8px rgba(11,95,165,.55);}
.btn-primary:hover{transform:translateY(-2px);box-shadow:0 16px 30px -8px rgba(11,95,165,.6);}
.btn-lime{background:linear-gradient(135deg,var(--brand-lime-bright),var(--brand-lime));color:#052b12;box-shadow:0 10px 24px -8px rgba(51,171,82,.5);}
.btn-lime:hover{transform:translateY(-2px);box-shadow:0 16px 30px -8px rgba(51,171,82,.55);}
.btn-ghost{background:transparent;color:var(--ink);border-color:var(--border);}
.btn-ghost:hover{border-color:var(--brand-blue-bright);color:var(--brand-blue-bright);transform:translateY(-2px);}
.btn-on-dark{background:rgba(255,255,255,.06);color:#fff;border-color:rgba(255,255,255,.25);backdrop-filter:blur(6px);}
.btn-on-dark:hover{background:rgba(255,255,255,.14);border-color:rgba(255,255,255,.5);transform:translateY(-2px);}
.btn-sm{padding:9px 18px;font-size:.85rem;}
.btn-block{width:100%;}

/* ---------- Header ---------- */
header.site{
  position:sticky;top:0;z-index:100;
  background:color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter:blur(14px) saturate(1.4);-webkit-backdrop-filter:blur(14px) saturate(1.4);
  border-bottom:1px solid var(--border);transition:background .25s ease, border-color .25s ease;
}
.nav-row{display:flex;align-items:center;justify-content:space-between;padding-block:14px;gap:24px;}
.brand{display:flex;align-items:center;gap:10px;text-decoration:none;flex:0 0 auto;}
.brand img{height:34px;width:auto;flex:0 0 auto;max-width:none;object-fit:contain;}

.logo-dark{display:none;}
[data-theme="dark"] .logo-light{display:none;}
[data-theme="dark"] .logo-dark{display:inline-block;}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]) .logo-light{display:none;}
  :root:not([data-theme="light"]) .logo-dark{display:inline-block;}
}

/* ---------- Main nav (fed by the MainMenu component -> phMainMenu) ----------
   The component renders a <ul><li><a><span>Label</span></a>...</ul> (and,
   for menu items with children, a nested <ul> per level). The rules below
   reset that list markup to read the same as the flat <a> row in the design,
   and add a light hover dropdown for any nested levels the design itself
   never had to show. */
nav.main-nav{display:flex;align-items:center;gap:2px;}
nav.main-nav ul{list-style:none;margin:0;padding:0;display:flex;align-items:center;gap:2px;flex-wrap:wrap;}
nav.main-nav li{list-style:none;position:relative;}
nav.main-nav a{
  font-weight:600;font-size:.92rem;text-decoration:none;color:var(--ink-soft);
  padding:10px 14px;border-radius:999px;transition:background .18s ease, color .18s ease;display:inline-block;
}
nav.main-nav a:hover{color:var(--ink); background:var(--bg-alt);}
nav.main-nav a.current{color:var(--brand-blue-bright); background:var(--bg-alt);}
nav.main-nav li > ul{
  list-style:none;margin:0;padding:8px;position:absolute;top:100%;left:0;min-width:200px;
  background:var(--card);border:1px solid var(--card-border);border-radius:var(--radius-sm);
  box-shadow:var(--shadow-md);display:none;flex-direction:column;gap:2px;z-index:50;
}
nav.main-nav li:hover > ul, nav.main-nav li:focus-within > ul{display:flex;}
nav.main-nav li > ul a{padding:8px 12px;}
.nav-actions{display:flex;align-items:center;gap:10px;flex:0 0 auto;}

.icon-btn{
  width:38px;height:38px;border-radius:999px;border:1px solid var(--border);
  background:var(--card);display:inline-flex;align-items:center;justify-content:center;
  cursor:pointer;color:var(--ink-soft);transition:all .18s ease;flex:0 0 auto;
}
.icon-btn:hover{color:var(--brand-blue-bright);border-color:var(--brand-blue-bright);transform:translateY(-1px);}
.icon-btn svg{width:18px;height:18px;}
[data-theme="dark"] .icon-sun{display:inline-block;}
[data-theme="dark"] .icon-moon{display:none;}
.icon-moon{display:inline-block;}
.icon-sun{display:none;}
.menu-toggle{display:none;}

/* ---------- Header search (carried over from v1, restyled) ---------- */
.search-form{display:flex;align-items:center;gap:6px;}
.search-field{
  width:150px;padding:9px 13px;border-radius:999px;border:1px solid var(--border);
  background:var(--bg-alt);color:var(--ink);font-family:var(--font-body);font-size:.85rem;
  transition:border-color .18s ease, background .18s ease, width .18s ease;
}
.search-field:focus{outline:none;border-color:var(--brand-blue-bright);background:var(--bg);width:190px;}
.search-button{
  width:38px;height:38px;border-radius:999px;border:1px solid var(--border);background:var(--card);
  cursor:pointer;flex:0 0 auto;padding:0;
}
@media (max-width:900px){ .search-form{display:none;} }

/* ---------- Hero ---------- */
.hero{
  background:
    radial-gradient(60% 55% at 82% 8%, rgba(51,171,82,.16), transparent 60%),
    radial-gradient(70% 60% at 10% 0%, rgba(31,134,224,.30), transparent 60%),
    linear-gradient(180deg, var(--bg-dark), var(--bg-dark-2));
  color:#fff; overflow:hidden;
}
.hero-inner{padding-block:112px 96px; display:grid; grid-template-columns:1.1fr .9fr; gap:48px; align-items:center; position:relative;}
.hero-watermark{
  position:absolute; right:4%; top:50%; transform:translateY(-50%);
  width:460px; max-width:38vw; opacity:0.066; pointer-events:none;
}
.hero h1{color:#fff; font-size:var(--fs-h1); max-width:15ch;}
.hero h1 .accent{background:linear-gradient(100deg,#7fd6ff,#4fd377); -webkit-background-clip:text; background-clip:text; color:transparent;}
.hero p.lead{color:#c4d3e6; font-size:var(--fs-lead); max-width:46ch; margin-top:20px;}
.hero-cta{display:flex;flex-wrap:wrap;gap:14px;margin-top:34px;}
.hero-meta{margin-top:44px; display:grid; grid-template-columns:repeat(3,minmax(0,auto)); gap:28px; color:#9fb2c9; font-size:.85rem;}
@media (max-width:900px){ .hero-meta{display:flex; flex-wrap:wrap;} }
.hero-meta strong{display:block;color:#fff;font-family:var(--font-display);font-size:1.3rem;}

.hero-card{
  background:rgba(255,255,255,.05); border:1px solid rgba(255,255,255,.14);
  border-radius:var(--radius-lg); padding:26px; backdrop-filter:blur(8px); box-shadow:var(--shadow-lg);
}
.hero-card .window-dots{display:flex;gap:6px;margin-bottom:16px;}
.hero-card .window-dots span{width:10px;height:10px;border-radius:50%;background:rgba(255,255,255,.25);}
.hero-card .term-line{font-family:'SFMono-Regular',Consolas,'Liberation Mono',monospace;font-size:.82rem;color:#9fe6b0;line-height:1.9;}
.hero-card .term-line .muted{color:#7f90a8;}
.hero-card .term-line .prompt{color:#7fd6ff;}
.hero-card .badges{display:flex;gap:8px;margin-top:18px;flex-wrap:wrap;}
.hero-card .badge{
  font-size:.72rem;font-weight:700;letter-spacing:.04em;text-transform:uppercase;
  padding:6px 10px;border-radius:999px;background:rgba(255,255,255,.08);color:#dce8f5;border:1px solid rgba(255,255,255,.14);
}

/* ---------- Section shells ---------- */
.section{padding:96px 0;}
.section-alt{background:var(--bg-alt);}
.section-head{max-width:640px;margin-bottom:52px;}
.section-head h2{margin-top:14px;}
.section-head p{margin-top:16px;font-size:var(--fs-lead);}
.section-head.center{margin-left:auto;margin-right:auto;text-align:center;}

/* ---------- Services grid (fed by the FeaturedServices component -> phFeaturedServices) ---------- */
.services-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:22px;}
.service-card{
  background:var(--card);border:1px solid var(--card-border);border-radius:var(--radius-md);
  padding:30px 26px;transition:transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.service-card:hover{transform:translateY(-6px);box-shadow:var(--shadow-md);border-color:var(--brand-blue-bright);}
.service-icon{
  width:48px;height:48px;border-radius:14px;display:flex;align-items:center;justify-content:center;
  background:linear-gradient(135deg,var(--brand-blue-bright),var(--brand-blue-deep));color:#fff;margin-bottom:20px;
}
.service-icon svg{width:24px;height:24px;}
.service-card h3{font-size:1.15rem;margin-bottom:10px;}
.service-card p{font-size:.92rem;}

/* ---------- Process / Why-Lion / Contact-CTA (fed by the Content component -> phContent) ---------- */
.process-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:0;position:relative;}
.process-step{padding:0 22px;position:relative;}
.process-step:not(:last-child)::after{
  content:"";position:absolute;top:26px;right:-4px;width:calc(100% - 44px);height:2px;
  background:repeating-linear-gradient(90deg, var(--border) 0 6px, transparent 6px 12px);
}
.process-num{
  width:52px;height:52px;border-radius:50%;display:flex;align-items:center;justify-content:center;
  font-family:var(--font-display);font-weight:700;font-size:1.15rem;
  background:var(--bg-dark);color:#fff;margin-bottom:20px;position:relative;z-index:1;
}
.process-step h3{font-size:1.05rem;margin-bottom:8px;}
.process-step p{font-size:.9rem;}

.lion-band{padding:84px 0;}
.lion-band-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:52px;align-items:center;}
.lion-band-frame{
  position:relative;width:100%;max-width:520px;border-radius:var(--radius-lg);
  overflow:hidden;border:1px solid var(--card-border);box-shadow:var(--shadow-lg);
}
.lion-band-frame img{width:100%;height:auto;display:block;}
.lion-band-frame::after{
  content:"";position:absolute;inset:0;border-radius:inherit;pointer-events:none;
  box-shadow:inset 0 0 0 1px rgba(127,214,255,.22), inset 0 0 70px rgba(31,134,224,.14);
}
.lion-band-copy h2{font-size:var(--fs-h2);margin-bottom:16px;}
.lion-band-copy p{margin-bottom:14px;}
.lion-band-copy p:last-of-type{margin-bottom:0;}
@media (max-width:860px){
  .lion-band{padding:56px 0;}
  .lion-band-grid{grid-template-columns:1fr;gap:32px;}
  .lion-band-frame{max-width:100%;margin:0 auto;}
}

.cta-band{
  background:linear-gradient(120deg,var(--brand-blue-deep),var(--bg-dark) 60%);
  color:#fff;border-radius:var(--radius-lg);
  padding:64px 56px;display:flex;align-items:center;justify-content:space-between;gap:32px;flex-wrap:wrap;
  position:relative;overflow:hidden;
}
.cta-band::before{content:"";position:absolute;inset:0;background:radial-gradient(50% 90% at 90% 100%, rgba(79,211,119,.28), transparent 60%);}
.cta-band > *{position:relative;z-index:1;}
.cta-band h2{color:#fff;font-size:var(--fs-h2);max-width:14ch;}
.cta-band p{color:#c4d3e6;margin-top:12px;max-width:40ch;}
.cta-band-mark{
  position:absolute;left:0;bottom:0;width:290px;transform:scaleX(-1);z-index:0;pointer-events:none;
  -webkit-mask-image:linear-gradient(to left, #000 0, #000 72%, transparent 100%);
  mask-image:linear-gradient(to left, #000 0, #000 72%, transparent 100%);
}
@media (min-width:901px){ .cta-band{padding-left:330px;} }
@media (max-width:900px){ .cta-band-mark{display:none;} }

/* ---------- Spotlight (fed by the FeaturedNews component -> phFeaturedNews) ---------- */
.spotlight{background:linear-gradient(180deg, var(--bg-dark), var(--bg-dark-2));color:#fff;}
.spotlight-grid{display:grid;grid-template-columns:1fr 1fr;gap:56px;align-items:center;}
.spotlight h2{color:#fff;}
.spotlight p{color:#c4d3e6;}
.spotlight-tags{display:flex;gap:10px;margin:20px 0 8px;flex-wrap:wrap;}
.tag{
  font-size:.75rem;font-weight:700;letter-spacing:.03em;padding:6px 12px;border-radius:999px;
  background:rgba(255,255,255,.08);border:1px solid rgba(255,255,255,.16);color:#dce8f5;
}
.spotlight-copy p.lead{font-size:var(--fs-lead);color:#dbe6f2;margin:18px 0 26px;}
.spotlight-cta{margin-top:30px;display:flex;gap:14px;flex-wrap:wrap;}
.spotlight-mark-row{display:flex;align-items:center;gap:14px;margin-top:14px;}
.spotlight-mark-row img{width:40px;height:auto;flex:0 0 auto;}
.spotlight-mark-row h2{margin:0;}

.app-mock{background:#0e1c33;border:1px solid rgba(255,255,255,.12);border-radius:var(--radius-lg);overflow:hidden;box-shadow:var(--shadow-lg);}
.app-mock .bar{display:flex;align-items:center;gap:6px;padding:12px 16px;background:#0a1628;border-bottom:1px solid rgba(255,255,255,.08);}
.app-mock .bar span{width:10px;height:10px;border-radius:50%;background:rgba(255,255,255,.2);}
.app-mock .body{padding:22px;display:grid;gap:14px;}
.app-mock .row{display:flex;gap:12px;align-items:flex-start;}
.app-mock .avatar{width:30px;height:30px;border-radius:9px;flex:0 0 auto;background:linear-gradient(135deg,var(--brand-blue-bright),var(--brand-lime));}
.app-mock .bubble{background:rgba(255,255,255,.06);border:1px solid rgba(255,255,255,.08);border-radius:12px;padding:12px 14px;font-size:.82rem;color:#cdd9e8;line-height:1.6;flex:1;}
.app-mock .bubble.highlight{border-color:rgba(79,211,119,.4);background:rgba(79,211,119,.08);}
.app-mock .waveform{display:flex;gap:3px;align-items:flex-end;height:26px;margin-top:4px;}
.app-mock .waveform span{width:3px;border-radius:2px;background:var(--brand-lime-bright);opacity:.85;}

/* ---------- Portfolio (fed by the FeaturedClients component -> phFeaturedClients) ---------- */
.portfolio-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:22px;}
.p-card{
  background:var(--card);border:1px solid var(--card-border);border-radius:var(--radius-md);
  overflow:hidden;text-decoration:none;display:flex;flex-direction:column;
  transition:transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.p-card:hover{transform:translateY(-6px);box-shadow:var(--shadow-md);border-color:var(--brand-blue-bright);}
.p-thumb{
  height:150px;display:flex;align-items:center;justify-content:center;
  font-family:var(--font-display);font-weight:800;font-size:2rem;color:#fff;letter-spacing:-.02em;
  position:relative;overflow:hidden;
}
.p-thumb::after{content:"";position:absolute;inset:0;background:radial-gradient(120% 120% at 100% 0%, rgba(255,255,255,.22), transparent 55%);pointer-events:none;}
.p-thumb span{position:relative;z-index:1;}
.p-thumb.featured{background:linear-gradient(135deg,#1f86e0,#33ab52);}
.p-thumb img{width:100%;height:100%;object-fit:cover;display:block;}
.p-body{padding:20px;display:flex;flex-direction:column;gap:8px;flex:1;}
.p-kicker{font-size:.72rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--brand-blue-bright);}
.p-card h3{font-size:1.05rem;}
.p-card p{font-size:.86rem;flex:1;}
.p-more{font-size:.82rem;font-weight:700;color:var(--brand-blue-bright);display:inline-flex;align-items:center;gap:6px;margin-top:6px;}
.p-card:hover .p-more{gap:9px;}
.p-more svg{width:14px;height:14px;transition:transform .18s ease;}
.portfolio-foot{margin-top:44px;text-align:center;}

/* ---------- Interior title band ---------- */
.title-band{background:linear-gradient(180deg,var(--bg-dark),var(--bg-dark-2));color:#fff;padding:44px 0 56px;position:relative;overflow:hidden;}
.title-band .watermark{
  /* sized off the band's own height and vertically centred, so it can
     never be clipped by a short title band the way a fixed 300px
     width was */
  position:absolute; right:4%; top:50%; transform:translateY(-50%);
  height:76%; width:auto; max-width:30vw; opacity:.14; pointer-events:none;
}
.title-row{display:flex;justify-content:space-between;align-items:flex-end;gap:24px;flex-wrap:wrap;position:relative;z-index:1;}
.title-band h1{color:#fff;font-size:var(--fs-h1-interior);max-width:18ch;}
.title-band .sub{color:#c4d3e6;font-size:var(--fs-lead);margin-top:12px;max-width:52ch;}

/* ---------- Interior layout ---------- */
.layout{display:grid;grid-template-columns:1fr 340px;gap:56px;padding:64px 0 96px;align-items:start;}
main.article{min-width:0;}
.article-section{margin-bottom:44px;}
.article-section h2{font-size:var(--fs-h2-interior);margin-bottom:16px;}
.article-section p{font-size:1rem;margin-bottom:14px;}
.article-section p:last-child{margin-bottom:0;}
.article-section p strong{color:var(--ink);}

.download-card{
  background:linear-gradient(120deg,var(--brand-blue-deep),var(--bg-dark) 65%);
  border-radius:var(--radius-lg);padding:36px;color:#fff;margin:48px 0;position:relative;overflow:hidden;
}
.download-card::before{content:"";position:absolute;inset:0;background:radial-gradient(50% 90% at 90% 100%, rgba(79,211,119,.25), transparent 60%);}
.download-card > *{position:relative;z-index:1;}
.download-card h3{color:#fff;font-size:1.35rem;margin-bottom:8px;}
.download-card p{color:#c4d3e6;margin-bottom:22px;}
.download-row{display:flex;gap:14px;flex-wrap:wrap;}
.download-card-mark{position:absolute;right:16px;bottom:16px;width:150px;max-width:26%;opacity:.16;z-index:0;pointer-events:none;}

.next-project{display:flex;justify-content:space-between;align-items:center;gap:20px;flex-wrap:wrap;padding-top:32px;border-top:1px solid var(--border);margin-top:16px;}
.next-project a{text-decoration:none;color:var(--ink);font-weight:600;display:inline-flex;align-items:center;gap:8px;}
.next-project a:hover{color:var(--brand-blue-bright);}
.next-project .label{display:block;font-size:.75rem;color:var(--ink-faint);font-weight:500;text-transform:uppercase;letter-spacing:.06em;margin-bottom:4px;}

/* ---------- Sidebar ---------- */
aside.sidebar{display:grid;gap:24px;position:sticky;top:96px;}
.side-card{background:var(--card);border:1px solid var(--card-border);border-radius:var(--radius-md);padding:26px;box-shadow:var(--shadow-sm);}
.side-card h3{font-size:1.05rem;margin-bottom:6px;}
.side-card p.note{font-size:.85rem;margin-bottom:18px;}

/* Reskin the generic FormDisplay component (phQuoteForm) to the v2 look
   without depending on its exact internal markup. */
.side-card form{margin:0;}
.side-card fieldset{border:0;margin:0;padding:0;}
.side-card label{display:block;font-size:.78rem;font-weight:600;color:var(--ink-soft);margin-bottom:6px;}
.side-card input[type="text"], .side-card input[type="email"], .side-card input[type="tel"],
.side-card textarea, .side-card select{
  width:100%;padding:11px 13px;border-radius:10px;border:1px solid var(--border);
  background:var(--bg-alt);color:var(--ink);font-family:var(--font-body);font-size:.9rem;
  margin-bottom:14px;box-sizing:border-box;transition:border-color .18s ease, background .18s ease;
}
.side-card input:focus, .side-card textarea:focus, .side-card select:focus{outline:none;border-color:var(--brand-blue-bright);background:var(--bg);}
.side-card textarea{resize:vertical;min-height:80px;}
.side-card .buttonContainer{margin-top:4px;}
.side-card .button, .side-card input[type="submit"], .side-card button[type="submit"]{
  width:100%;display:inline-flex;align-items:center;justify-content:center;gap:8px;
  font-family:var(--font-body);font-weight:600;font-size:.95rem;padding:13px 26px;border-radius:999px;
  border:1px solid transparent;background:linear-gradient(135deg,var(--brand-blue-bright),var(--brand-blue-deep));
  color:#fff;box-shadow:0 10px 24px -8px rgba(11,95,165,.55);cursor:pointer;text-decoration:none;
  transition:transform .18s ease, box-shadow .18s ease;
}
.side-card .button:hover, .side-card input[type="submit"]:hover, .side-card button[type="submit"]:hover{transform:translateY(-2px);}

/* Reskin the generic MenuDisplay component (phSideMenu) to the v2 side-list look. */
.side-menu ul{list-style:none;margin:0;padding:0;display:grid;gap:8px;}
.side-menu li{list-style:none;}
.side-menu ul a{
  display:block;font-weight:600;font-size:.88rem;color:var(--ink);text-decoration:none;
  padding:8px;border-radius:10px;transition:background .18s ease, color .18s ease;
}
.side-menu ul a:hover{background:var(--bg-alt);color:var(--brand-blue-bright);}
.side-menu ul ul{margin-top:6px;padding-left:14px;gap:4px;}
.side-menu ul ul a{font-weight:500;font-size:.82rem;color:var(--ink-soft);}
.side-menu h2{font-size:1.05rem;margin-bottom:6px;}

.side-social{display:flex;gap:8px;margin-top:4px;}
/* Full bleed inside the Follow Us card: the negative margins cancel the card's
   26px padding so the photo reaches all four edges, and .side-card already sets
   overflow:hidden so the card's rounded corners do the clipping. The corner
   fade is gone by request; the drop shadow went with it, since it only existed
   to sell the floating-photo look that no longer applies once the image is
   flush to the edges. */
.lion-photo-accent{
  display:block;
  width:calc(100% + 52px);
  max-width:none;
  height:auto;
  margin:20px -26px -26px -26px;
}

/* ---------- Footer ---------- */
footer.site{background:var(--bg-alt);border-top:1px solid var(--border);padding:64px 0 28px;margin-top:96px;}
/* Two children only (brand + footer-nav). The original 4-track grid was written
   for a four-column link layout that the wired menu does not produce, so tracks
   3 and 4 rendered as dead space across the right half of the footer. The nav
   column carries its own internal 3-up grid instead. */
.footer-grid{display:grid;grid-template-columns:minmax(240px,1.1fr) 2fr;gap:40px;padding-bottom:44px;}
.footer-brand img{height:32px;margin-bottom:16px;}
.footer-brand p{font-size:.9rem;max-width:32ch;}
.footer-social{display:flex;gap:10px;margin-top:20px;}
footer h4{font-family:var(--font-body);font-size:.82rem;text-transform:uppercase;letter-spacing:.08em;color:var(--ink-faint);margin-bottom:16px;}

/* Footer nav (fed by the FooterMenu component -> phFooterMenu).
   IMPORTANT: MenuDisplay.ascx wraps its <ul> in a <div> panel, so the direct
   child combinator ".footer-nav > ul" never matched anything -- the footer
   rendered as a bullet list of default underlined links. Every selector here
   is therefore a descendant selector. Keep it that way.
   The wired menu is flat (no child items), so top-level items ARE the links;
   they flow into a multi-column grid that fills the footer instead of
   stacking in one narrow strip beside a half-empty row. */
.footer-nav ul{list-style:none;margin:0;padding:0;}
.footer-nav li{list-style:none;}
.footer-nav ul li::marker{content:"";}
/* Multi-column rather than a 3-track grid: a grid fills row-major, so a
   menu read across as "Home About Services" instead of down each column,
   and left the last column short. columns balances the items and keeps
   menu order reading top-to-bottom. */
.footer-nav > div > ul,
.footer-nav > ul{columns:3;column-gap:32px;}
.footer-nav li{break-inside:avoid;}
.footer-nav a{
  font-size:.9rem;color:var(--ink-soft);text-decoration:none;transition:color .18s ease;
  display:block;padding:7px 0;
}
.footer-nav a:hover{color:var(--brand-blue-bright);}
/* A menu that does have children: the parent becomes the column header and its
   children the list beneath it. */
.footer-nav li:has(> ul) > a{
  font-family:var(--font-body);font-size:.82rem;text-transform:uppercase;letter-spacing:.08em;
  color:var(--ink-faint);font-weight:700;margin-bottom:8px;
}
.footer-nav ul ul{display:block;}
.footer-nav ul ul a{font-size:.9rem;color:var(--ink-soft);text-transform:none;letter-spacing:0;font-weight:400;}

.footer-bottom{
  border-top:1px solid var(--border);padding-top:24px;
  display:flex;justify-content:space-between;align-items:center;flex-wrap:wrap;gap:12px;
  font-size:.82rem;color:var(--ink-faint);
}
.footer-bottom a{color:var(--ink-faint);text-decoration:none;}
.footer-bottom a:hover{color:var(--brand-blue-bright);}

/* ---------- Reveal animation ---------- */
.reveal{opacity:0;transform:translateY(18px);transition:opacity .6s ease, transform .6s ease;}
.reveal.in{opacity:1;transform:translateY(0);}

/* ---------- Responsive ---------- */
@media (max-width:1080px){
  .services-grid{grid-template-columns:repeat(2,1fr);}
  .portfolio-grid{grid-template-columns:repeat(2,1fr);}
  .process-grid{grid-template-columns:repeat(2,1fr);row-gap:36px;}
  .process-step:nth-child(2)::after{display:none;}
  .footer-grid{grid-template-columns:minmax(220px,1fr) 1.8fr;}
}
@media (max-width:980px){
  .layout{grid-template-columns:1fr;}
  aside.sidebar{position:static;grid-template-columns:1fr 1fr;}
  .footer-grid{grid-template-columns:minmax(220px,1fr) 1.8fr;}
}
@media (max-width:900px){
  .hero-inner{grid-template-columns:1fr;padding-block:88px 64px;}
  /* Headings first on mobile. The console is decoration; leading with it
     means the first screen says nothing about what the company does. */
  .spotlight-grid{grid-template-columns:1fr;}
  .spotlight .app-mock{order:-1;}
}
@media (max-width:760px){
  nav.main-nav{
    display:none;position:fixed;top:0; left:0; width:100vw; height:100vh; height:100dvh;z-index:200;background:var(--bg);
    flex-direction:column;align-items:stretch;padding:88px 24px 24px;overflow-y:auto;
  }
  nav.main-nav.open{display:flex;}
  nav.main-nav ul{flex-direction:column;align-items:stretch;gap:6px;}
  nav.main-nav li > ul,
  nav.main-nav li:hover > ul,
  nav.main-nav li:focus-within > ul{display:none;}
  nav.main-nav a{
    /* The desktop rule sets display:inline-block for the pill shape, so without
       this each link shrank to its text and the divider under it stopped at the
       end of the word instead of spanning the menu. */
    display:block;
    font-family:var(--font-display);font-size:1.3rem;font-weight:700;padding:14px 4px;
    border-bottom:1px solid var(--border);border-radius:0;
  }
  nav.main-nav li{display:block;}
  .nav-actions .btn-primary{display:none;}
  .menu-toggle{display:inline-flex;}
  .services-grid{grid-template-columns:1fr;}
  .portfolio-grid{grid-template-columns:1fr;}
  .process-grid{grid-template-columns:1fr;}
  .process-step::after{display:none;}
  .footer-grid{grid-template-columns:1fr;gap:32px;}
  .footer-nav > div > ul,
  .footer-nav > ul{columns:2;}
  .cta-band{padding:44px 28px;flex-direction:column;text-align:center;}
  .cta-band p{margin-left:auto;margin-right:auto;}
  .section{padding:64px 0;}
  aside.sidebar{grid-template-columns:1fr;}
  .title-band{padding:32px 0 40px;}
  .layout{padding:40px 0 64px;gap:36px;}
  .download-card{padding:26px;}
  /* Tap targets: the header's icon buttons (theme toggle, search, menu) sit
     just under the 40x40 CSS px minimum on touch. */
  .icon-btn{width:44px;height:44px;}
  /* Micro-text badges dip under 12px at the base size; keep it legible on
     small screens without changing the desktop badge/kicker look. */
  .badge,.p-kicker{font-size:12px;}
  /* Footer and side-menu links are inline text ~17px tall, which is below the
     24px WCAG 2.2 target minimum on its own -- it only passes via row spacing.
     Making them block-level with vertical padding gives a real 40px touch row
     on phones; desktop is untouched because this is inside the 760px query. */
  .footer-nav ul ul a,
  .footer-bottom a,
  .side-menu a{display:block;padding:10px 0;}
  .footer-nav ul ul{gap:0;}
  .footer-bottom{gap:0;}
}
@media (max-width:520px){
  .footer-grid{grid-template-columns:1fr;}
  .footer-nav > div > ul,
  .footer-nav > ul{columns:1;}
}

/* ---------- Legacy CMS body content ----------------------------------------
   Content rows authored against the v1 design carry plain h1/h2/p/ul markup
   with no layout classes of their own. This gives that markup the v2 type
   scale and rhythm inside the standard container, so old content still reads
   correctly in the new shell without having to be rewritten first. */
.cms-body { padding-block: 56px; }
/* .cms-body is the no-sidebar homepage case. Without an auto inline margin
   the 72ch prose column pins to the left edge of a 1200px container and
   leaves ~40%% of the width empty, while every other section on the page is
   centred -- it read as a layout fault. Interior pages are unaffected: there
   .cms-content sits in a sidebar grid column where left alignment is right. */
.cms-body .cms-content{margin-inline:auto;}

.cms-content { max-width: 72ch; }
.cms-content > *:first-child { margin-top: 0; }
.cms-content h1,
.cms-content h2,
.cms-content h3 { font-family: var(--font-display); color: var(--ink); line-height: 1.2; margin: 1.6em 0 .5em; }
.cms-content h1 { font-size: clamp(1.75rem, 3vw, 2.35rem); }
.cms-content h2 { font-size: clamp(1.4rem, 2.4vw, 1.8rem); }
.cms-content h3 { font-size: 1.15rem; }
.cms-content p,
.cms-content li { color: var(--ink-soft); line-height: 1.75; }
.cms-content p { margin: 0 0 1.1em; }
.cms-content ul,
.cms-content ol { margin: 0 0 1.3em; padding-left: 1.35em; }
.cms-content li { margin-bottom: .45em; }
.cms-content a { color: var(--brand-blue); text-decoration: underline; text-underline-offset: 2px; }
.cms-content a:hover { color: var(--brand-blue-deep); }
.cms-content img { max-width: 100%; height: auto; border-radius: var(--radius-md); }
.cms-content iframe,
.cms-content embed,
.cms-content object,
.cms-content video { max-width: 100%; }
.cms-content table { width: 100%; max-width: 100%; border-collapse: collapse; margin: 0 0 1.3em; display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.cms-content th,
.cms-content td { border: 1px solid var(--border); padding: 10px 12px; text-align: left; }

/* Legacy authored rows carry HTML width="NNN" attributes and inline
   style="width:NNNpx" sized for the old wide v1 layout. Cap both to the
   column instead of stripping them -- nothing is forced narrower than it
   was authored, only ever narrower than the viewport allows. */
.cms-content [width],
.cms-content [style*="width"] { max-width: 100% !important; }
.cms-content * { max-width: 100%; }

/* ---------- Mobile-safety net for #pageContent (InteriorPageV2.master) -----
   InteriorPageV2.master renders the same legacy CMS body straight into
   #pageContent with no .cms-content wrapper of its own (only
   HomePageV2.master's Content component gets that class), so none of the
   protections above ever reached interior pages. Mirror them here scoped to
   #pageContent so the 17 audited pages with fixed-width-markup, plus the
   plain-HTML forms/tables other interior pages carry, are safe on mobile. */
#pageContent { max-width: 72ch; }
#pageContent > *:first-child { margin-top: 0; }
#pageContent h1, #pageContent h2, #pageContent h3 { font-family: var(--font-display); color: var(--ink); line-height: 1.2; margin: 1.6em 0 .5em; }
#pageContent h1 { font-size: clamp(1.75rem, 3vw, 2.35rem); }
#pageContent h2 { font-size: clamp(1.4rem, 2.4vw, 1.8rem); }
#pageContent h3 { font-size: 1.15rem; }
#pageContent p, #pageContent li { color: var(--ink-soft); line-height: 1.75; }
#pageContent p { margin-bottom: 1em; }
#pageContent p:last-child { margin-bottom: 0; }
#pageContent ul, #pageContent ol { margin: 0 0 1.3em; padding-left: 1.35em; }
#pageContent li { margin-bottom: .45em; }
#pageContent a { color: var(--link); text-decoration: underline; text-underline-offset: 2px; }
#pageContent a:hover { color: var(--link-hover); }
#pageContent img { max-width: 100%; height: auto; border-radius: var(--radius-md); }
#pageContent iframe,
#pageContent embed,
#pageContent object,
#pageContent video { max-width: 100%; }
#pageContent table { width: 100%; max-width: 100%; border-collapse: collapse; margin: 0 0 1.3em; display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
#pageContent th,
#pageContent td { border: 1px solid var(--border); padding: 10px 12px; text-align: left; }
#pageContent [width],
#pageContent [style*="width"] { max-width: 100% !important; }
#pageContent * { max-width: 100%; }

/* The FormDisplay component (contact/quote forms dropped straight into
   #pageContent rather than a .side-card) carries the same 600px-fieldset v1
   form.css sizing that .side-card already had to contain below. */
#pageContent .formContainer,
#pageContent .columnLayout,
#pageContent fieldset,
#pageContent .fieldContainer,
#pageContent .fieldContainer.oneColumn,
#pageContent .fieldContainer.twoColumn {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    float: none !important;
    box-sizing: border-box;
}
#pageContent input[type="text"],
#pageContent input[type="email"],
#pageContent input[type="tel"],
#pageContent select,
#pageContent textarea {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box;
}

/* ---------- Sidebar form containment -------------------------------------
   The quote form is rendered by the shared FormDisplay component, whose markup
   is styled by the v1 theme's form.css / form-grid-min.css with widths sized
   for the old wide layout (600px fieldsets). Dropped into the narrow v2
   sidebar that pushed the whole page into horizontal scroll. These rules keep
   the component's own markup inside the card without touching the shared
   stylesheets, which other templates still rely on. */
.side-card { overflow: hidden; }
.side-card .formContainer,
.side-card .columnLayout,
.side-card fieldset,
.side-card .fieldContainer,
.side-card .fieldContainer.oneColumn,
.side-card .fieldContainer.twoColumn {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    float: none !important;
    box-sizing: border-box;
}
.side-card fieldset { border: 0; padding: 0; margin: 0; }
.side-card legend { padding: 0; }
.side-card input[type="text"],
.side-card input[type="email"],
.side-card input[type="tel"],
.side-card select,
.side-card textarea {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box;
}
.side-card textarea { resize: vertical; }
.side-card table { width: 100% !important; table-layout: fixed; }
.side-card img { max-width: 100%; height: auto; }
/* ...except the full-bleed lion, which deliberately overhangs the card padding.
   This sits after the rule above because both are (0,1,1) specificity and the
   later one wins; putting it with the other .lion-photo-accent declarations
   further up the file would silently lose. */
.side-card img.lion-photo-accent{max-width:none;}

/* ---------- Main-column form skin ------------------------------------------
   contact-us and request-more-information render the shared FormDisplay
   component straight into #pageContent. The containment rules above stopped it
   overflowing, but it still wore the v1 look: hairline fieldset box, tiny bold
   labels, square grey inputs, and the operating system's default Submit button
   -- directly opposite the fully themed sidebar quote card asking for the same
   information. Skin it to match the .side-card form. */
#pageContent fieldset { border: 0; padding: 0; margin: 0 0 8px; }
#pageContent legend { padding: 0; font-family: var(--font-display); font-weight: 700; color: var(--ink); margin-bottom: 12px; }
#pageContent .fieldContainer label,
#pageContent label {
    display: block; font-size: .78rem; font-weight: 600; color: var(--ink-soft);
    margin-bottom: 6px; float: none !important; width: auto !important; text-align: left !important;
}
#pageContent input[type="text"],
#pageContent input[type="email"],
#pageContent input[type="tel"],
#pageContent input[type="password"],
#pageContent select,
#pageContent textarea {
    padding: 11px 13px; border-radius: 10px; border: 1px solid var(--border);
    background: var(--bg-alt); color: var(--ink); font-family: var(--font-body); font-size: .9rem;
    margin-bottom: 14px; transition: border-color .18s ease, background .18s ease;
}
#pageContent input:focus, #pageContent textarea:focus, #pageContent select:focus {
    outline: none; border-color: var(--brand-blue-bright); background: var(--bg);
}
#pageContent textarea { resize: vertical; min-height: 96px; }
#pageContent .button,
#pageContent input[type="submit"],
#pageContent button[type="submit"] {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    width: auto !important; min-width: 180px;
    font-family: var(--font-body); font-weight: 600; font-size: .95rem; padding: 13px 26px;
    border-radius: 999px; border: 1px solid transparent;
    background: linear-gradient(135deg, var(--brand-blue-bright), var(--brand-blue-deep));
    color: #fff; box-shadow: 0 10px 24px -8px rgba(11,95,165,.55); cursor: pointer;
    transition: transform .18s ease, box-shadow .18s ease;
}
#pageContent .button:hover,
#pageContent input[type="submit"]:hover { transform: translateY(-2px); }
/* the legacy markup tables contact details into hairline-bordered cells;
   inside prose they should read as a plain definition list */
#pageContent table.contact,
#pageContent table[border="0"] { display: table; }

/* ---------- Portfolio index (portfolio.aspx) --------------------------------
   The index reuses the homepage's .p-card grid inside the interior article
   column. The 72ch prose cap and the homepage's 4-up track count both fight a
   card grid in a ~790px column, so lift the cap when a grid is present and run
   the grid 2-up (1-up on phones). Items with no screenshot yet render a
   monogram tile on the brand gradient instead of an empty image box. */
main.article:has(.portfolio-grid) #pageContent { max-width: none; }
#pageContent .portfolio-grid { grid-template-columns: repeat(2, 1fr); margin-top: 24px; }
#pageContent .portfolio-grid a { text-decoration: none; color: inherit; }
#pageContent .p-card h3 { margin: 0; }
@media (max-width: 700px) { #pageContent .portfolio-grid { grid-template-columns: 1fr; } }
.p-thumb.mono {
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--brand-blue-deep), var(--bg-dark-2));
    color: rgba(255,255,255,.85); font-family: var(--font-display);
    font-size: 2.6rem; font-weight: 700; letter-spacing: .02em;
}

/* If the homepage's per-page body slot has no content, the empty section still
   renders its padding as a blank band. Judge emptiness inside .cms-content --
   the wrap/cms-content shells themselves are always present. */
section.cms-body:not(:has(.cms-content *)) { display: none; }

/* The full-screen nav overlay covers the header, and the header is where
   the toggle lives. Without this the button is painted under the overlay
   and there is no way to close the menu on a touch device, where Escape
   is not available. */
.menu-toggle{position:relative;z-index:201;}

/* ---------- Product family menu ----------
   Same disclosure as the product sites, but written against this theme's own
   tokens rather than copied, because Interactive Lion is the only one of the
   four with a dark mode. Everything here resolves through --card, --border,
   --ink and friends, so it follows the theme toggle with no extra rules. */
.family-menu{position:relative;}
.family-menu > summary{
  list-style:none;cursor:pointer;
}
.family-menu > summary::-webkit-details-marker{display:none;}
.family-menu > summary::marker{content:"";}
.family-menu[open] > summary{color:var(--brand-blue-bright);background:var(--bg-alt);}

.family-panel{
  position:absolute;top:calc(100% + 10px);right:0;z-index:1200;
  width:300px;padding:14px;
  background:var(--card);
  border:1px solid var(--card-border);
  border-radius:14px;
  box-shadow:0 24px 60px -20px rgba(0,0,0,.45);
}
.family-parent{
  display:block;padding:12px;margin-bottom:6px;
  border-radius:10px;background:var(--bg-alt);text-decoration:none;
}
.family-parent img{height:26px;width:auto;display:block;margin-bottom:8px;}
.family-parent .fam-note{display:block;font-size:.76rem;color:var(--ink-soft);line-height:1.4;}
.family-parent.is-here{cursor:default;}
.family-parent .fam-badge{
  float:right;font-size:.66rem;font-weight:600;color:var(--ink-faint);letter-spacing:.02em;
}

.family-heading{
  display:block;padding:10px 12px 6px;
  font-weight:700;font-size:.68rem;letter-spacing:.06em;
  text-transform:uppercase;color:var(--ink-faint);
}
.family-item{
  display:grid;grid-template-columns:28px 1fr;grid-template-rows:auto auto;
  column-gap:11px;align-items:center;
  padding:9px 12px;border-radius:10px;
  border-left:3px solid var(--fam);
  text-decoration:none;transition:background .18s ease;
}
.family-emblem{grid-row:1 / span 2;width:28px;height:28px;object-fit:contain;display:block;}
.family-item strong{grid-column:2;align-self:end;font-weight:700;font-size:.92rem;color:var(--ink);line-height:1.3;}
.family-item span{grid-column:2;align-self:start;font-size:.76rem;color:var(--ink-soft);line-height:1.4;}
a.family-item:hover{background:var(--bg-alt);}
.fam-lc{--fam:#6FBB22;}
.fam-oc{--fam:#2B62C4;}
.fam-bc{--fam:#CDA73E;}

/* The lion lockup has a light and a dark artwork; reuse the site's own swap. */
.family-parent .logo-dark{display:none;}
[data-theme="dark"] .family-parent .logo-light{display:none;}
[data-theme="dark"] .family-parent .logo-dark{display:block;}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]) .family-parent .logo-light{display:none;}
  :root:not([data-theme="light"]) .family-parent .logo-dark{display:block;}
}

/* Phones: stop anchoring to the trigger, which sits near the right edge. */
@media (max-width:560px){
  .family-menu{position:static;}
  .family-panel{
    position:fixed;top:76px;left:12px;right:12px;width:auto;
    max-height:calc(100vh - 92px);overflow-y:auto;
  }
}

/* Hide the panel explicitly when the disclosure is closed rather than relying
   on the browser's <details> semantics. Those semantics do not reliably cover
   an out-of-flow child: with the panel position:fixed and its parent static on
   mobile, Chrome lays the closed panel out as a 30x562 sliver, and Safari on
   iOS is looser still. One line removes the whole class of problem. */
.family-menu:not([open]) .family-panel{display:none;}

/* Mobile sidebar order: section menu first, then the quote form, then Follow Us.
   The menu is navigation and the form is a conversion ask; making a visitor
   scroll past an entire form before they can see the rest of the section is
   backwards on a phone. Desktop keeps the form first, where both are visible
   at once and the form is the priority. */
@media (max-width: 980px){
  aside.sidebar{display:flex;flex-direction:column;min-width:0;}
  aside.sidebar > .side-card{min-width:0;max-width:100%;}
  aside.sidebar .side-card-menu{order:-1;}
}
/* Grid and flex children refuse to shrink below their content unless told to.
   The quote form carries fixed pixel widths from the application's own markup,
   so without this the sidebar drags the whole document wider than the screen. */
.layout > *{min-width:0;}

/* Footer link under an article list: the way through to the news archive and
   back. Set apart from the last article with a rule above it so it reads as a
   destination rather than another item in the list. */
#listItems .list-footer-link{
  margin:28px 0 0;
  padding-top:22px;
  border-top:1px solid var(--border);
}
#listItems .list-footer-link a{
  display:inline-flex;align-items:center;gap:8px;
  font-family:var(--font-display);font-weight:700;font-size:.95rem;
  color:var(--brand-blue-bright);text-decoration:none;
}
#listItems .list-footer-link a::after{content:"→";}
#listItems .list-footer-link a:hover{text-decoration:underline;}
