/* ============================================================
   App Monkey — 2026 Playful Redesign
   Design tokens + shared components. Loaded LAST in
   include/stylesheet.blade.php so it wins the cascade.
   Section styles are appended here as each section ships.
   ============================================================ */

/* ============ DESIGN TOKENS ============ */
:root {
  /* ---- BRAND ---- */
  --am-blue:        #1d4ed8;
  --am-blue-ink:    #1740b0;
  --am-blue-soft:   #eef3ff;
  --am-glow:        #eaf0ff;
  --am-yellow:      #ffd94d;
  --am-highlight:   #ffe08a;
  --am-green:       #22c55e;
  --am-vine:        #3f8f5a;

  /* ---- NEUTRALS (warm) ---- */
  --am-bg:          #fbfaf7;
  --am-surface:     #ffffff;
  --am-navy:        #0d1b3e;
  --am-ink:         #171310;
  --am-text:        #4a443c;
  --am-body:        #5a5248;
  --am-muted:       #6a6156;   /* AA-safe small text on cream (5.8:1) */
  --am-faint:       #8a8175;   /* large/bold labels only (3.7:1) */

  /* ---- BORDERS / TAGS ---- */
  --am-border:      #efe7d9;
  --am-border-2:    #e7dfd0;
  --am-border-blue: #e3e9ff;
  --am-tag-bg:      #f5efe3;

  /* ---- ICON TILES ---- */
  --am-tile-green:  #e8f7ee;
  --am-tile-blue:   #eef1ff;
  --am-tile-orange: #fdf2e4;
  --am-tile-lav:    #ede9fe;
  --am-tile-pink:   #ffeceb;

  /* ---- TYPE ---- */
  --am-font-display:'Bricolage Grotesque','Plus Jakarta Sans',system-ui,sans-serif;
  --am-font-body:   'Plus Jakarta Sans',system-ui,-apple-system,'Segoe UI',sans-serif;
  --fs-hero:    clamp(2.625rem, 5.4vw, 4.5rem);
  --fs-h2:      2.125rem;
  --fs-h3:      1.875rem;
  --fs-lead:    1.1875rem;
  --fs-title:   1.1875rem;
  --fs-title-sm:1.09375rem;
  --fs-body:    0.9375rem;
  --fs-sm:      0.875rem;
  --fs-meta:    0.8125rem;
  --fs-xs:      0.75rem;
  --lh-hero:    1.0;
  --lh-heading: 1.15;
  --lh-body:    1.6;
  --ls-hero:   -0.03em;
  --ls-h2:     -0.02em;
  --ls-h3:     -0.01em;

  /* ---- SPACING ---- */
  --sp-1:4px;  --sp-2:8px;  --sp-3:12px; --sp-4:16px; --sp-5:20px; --sp-6:24px;
  --sp-8:32px; --sp-10:40px; --sp-12:48px; --sp-14:56px; --sp-16:64px;
  --am-container:1180px;
  --am-gutter:24px;

  /* ---- RADIUS ---- */
  --r-sm:10px; --r-md:14px; --r-tile:15px; --r-lg:20px; --r-xl:24px; --r-pill:999px;

  /* ---- SHADOWS ---- */
  --sh-xs:0 1px 3px rgba(23,19,16,.06);
  --sh-sm:0 2px 8px rgba(23,19,16,.06);
  --sh-md:0 12px 28px rgba(23,19,16,.10);
  --sh-lg:0 16px 34px rgba(23,19,16,.10);
  --sh-blue:0 10px 24px rgba(29,78,216,.30);
  --sh-blue-sm:0 3px 12px rgba(29,78,216,.08);

  /* ---- MOTION ---- */
  --dur-fast:.15s; --dur:.18s; --dur-slow:.30s;
  --ease:cubic-bezier(.2,.7,.2,1);
  --lift:translateY(-5px);

  /* ---- FOCUS (a11y) ---- */
  --am-focus:0 0 0 3px rgba(29,78,216,.45);
}

/* ============ BASE (global foundation) ============ */
body {
  font-family: var(--am-font-body);
  background: var(--am-bg);
  color: var(--am-ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
::selection { background: var(--am-highlight); }

/* Accessible focus ring on every interactive element */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: none;
  box-shadow: var(--am-focus);
  border-radius: var(--r-sm);
}

/* Search fields already show focus via their wrapper's :focus-within border,
   so suppress the inner input's focus ring — otherwise you get a double outline. */
.search-input:focus,
.search-input:focus-visible,
.am-tp-search input:focus,
.am-tp-search input:focus-visible {
  box-shadow: none;
}

/* Article tag chips (post detail) — clean, readable hover instead of blue-on-blue */
.font-enforcer .all-stories-tags-scn .btn {
  background: var(--am-tag-bg);
  border: 1.5px solid var(--am-border-2);
  color: var(--am-text);
  border-radius: var(--r-sm);
  font-weight: 700;
  text-decoration: none;
}
.font-enforcer .all-stories-tags-scn .btn:hover,
.font-enforcer .all-stories-tags-scn .btn:focus {
  background: var(--am-blue-soft);
  border-color: var(--am-blue);
  color: var(--am-blue-ink);
  text-decoration: none;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
}

/* ============ LAYOUT HELPERS ============ */
.am-container {
  max-width: var(--am-container);
  margin-inline: auto;
  padding-inline: var(--am-gutter);
}

/* ============ KEYFRAMES ============ */
@keyframes am-bob     { 0%,100%{transform:translateY(0)}            50%{transform:translateY(-14px)} }
@keyframes am-swing   { 0%,100%{transform:rotate(-6deg)}           50%{transform:rotate(6deg)} }
@keyframes am-spin    { to{transform:rotate(360deg)} }
@keyframes am-wiggle  { 0%,100%{transform:rotate(0)} 25%{transform:rotate(-8deg)} 75%{transform:rotate(8deg)} }
@keyframes am-chip1   { 0%,100%{transform:translateY(0) rotate(-6deg)} 50%{transform:translateY(-16px) rotate(-6deg)} }
@keyframes am-chip2   { 0%,100%{transform:translateY(0) rotate(7deg)}  50%{transform:translateY(-12px) rotate(7deg)} }
@keyframes am-chip3   { 0%,100%{transform:translateY(0) rotate(-3deg)} 50%{transform:translateY(-20px) rotate(-3deg)} }

/* ============ BUTTONS (shared) ============ */
.am-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--am-font-body);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1;
  padding: 15px 26px;
  border-radius: var(--r-md);
  border: 1.5px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease),
              background var(--dur) var(--ease),
              border-color var(--dur) var(--ease);
}
.am-btn--primary { background: var(--am-blue); color: #fff; box-shadow: var(--sh-blue); }
.am-btn--primary:hover,
.am-btn--primary:focus { background: var(--am-blue-ink); color: #fff; text-decoration: none; }
.am-btn--ghost { background: var(--am-surface); border-color: var(--am-border-2); color: var(--am-ink); }
.am-btn--ghost:hover,
.am-btn--ghost:focus { border-color: var(--am-blue); color: var(--am-ink); transform: var(--lift); text-decoration: none; }
.am-peel:hover { animation: am-wiggle .5s ease; }

/* ============ HERO ============ */
.am-hero { position: relative; overflow: hidden; }
.am-hero__wash {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(120% 90% at 82% 8%, var(--am-glow) 0%, rgba(234,240,255,0) 55%);
}
.am-hero__banana { position: absolute; pointer-events: none; user-select: none; }
.am-hero__banana--1 { top: 70px; left: -30px; font-size: 90px; opacity: .10; animation: am-spin 26s linear infinite; }
.am-hero__banana--2 { bottom: 20px; left: 40%; font-size: 54px; opacity: .12; animation: am-bob 5s ease-in-out infinite; }

.am-hero__grid {
  position: relative;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 32px;
  align-items: center;
  padding-block: 60px 56px;
}
.am-hero__copy { min-width: 0; }

/* badge */
.am-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--am-surface); border: 1px solid var(--am-border-blue);
  color: var(--am-blue); font-weight: 700; font-size: var(--fs-meta);
  padding: 7px 12px 7px 7px; border-radius: var(--r-pill);
  margin-bottom: 24px; box-shadow: var(--sh-blue-sm);
}
.am-badge__pill { background: var(--am-blue-soft); border-radius: var(--r-pill); padding: 3px 9px; }
.am-badge__dot { width: 6px; height: 6px; border-radius: 50%; background: var(--am-green); display: inline-block; }

/* title */
.am-hero__title {
  font-family: var(--am-font-display); font-weight: 800;
  font-size: var(--fs-hero); line-height: var(--lh-hero); letter-spacing: var(--ls-hero);
  color: var(--am-ink); margin: 0;
}
.am-hero__accent { color: var(--am-blue); }
.am-mark { position: relative; white-space: nowrap; }
.am-mark::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 4px; height: 14px;
  background: var(--am-yellow); z-index: -1; border-radius: 6px; transform: rotate(-1deg);
}

.am-hero__sub {
  font-size: var(--fs-lead); line-height: var(--lh-body); color: var(--am-body);
  max-width: 500px; margin: 24px 0 30px;
}

/* CTAs */
.am-hero__ctas { display: flex; gap: 12px; flex-wrap: wrap; }

/* stats */
.am-hero__stats { display: flex; gap: 30px; margin-top: 38px; flex-wrap: wrap; }
.am-stat { display: flex; flex-direction: column; }
.am-stat__num { font-family: var(--am-font-display); font-weight: 800; font-size: 26px; color: var(--am-ink); }
.am-stat__label { font-size: var(--fs-meta); color: var(--am-muted); font-weight: 600; }

/* ============ HERO PLAYGROUND (decorative) ============ */
.am-hero__play { position: relative; height: 420px; }
.am-hero__vine {
  position: absolute; top: -60px; left: 50%; width: 5px; height: 130px;
  background: var(--am-vine); border-radius: 3px; transform-origin: top center;
  animation: am-swing 6s ease-in-out infinite;
}
.am-hero__orb {
  position: absolute; top: 56px; left: 50%; margin-left: -115px;
  width: 230px; height: 230px; border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #fff, var(--am-glow));
  border: 1px solid var(--am-border-blue);
  box-shadow: 0 30px 60px rgba(29,78,216,.18);
  display: grid; place-items: center;
  animation: am-bob 5s ease-in-out infinite;
}
.am-hero__monkey { font-size: 130px; line-height: 1; filter: drop-shadow(0 14px 22px rgba(0,0,0,.14)); }

.am-chip {
  position: absolute; display: flex; align-items: center; gap: 9px;
  background: var(--am-surface); border: 1px solid var(--am-border);
  border-radius: var(--r-md); padding: 11px 14px; box-shadow: var(--sh-md);
}
.am-chip__icon { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; font-size: 18px; flex: none; }
.am-chip__t { font-weight: 700; font-size: 13.5px; line-height: 1.15; color: var(--am-ink); }
.am-chip__s { font-size: 11px; color: var(--am-faint); font-weight: 600; line-height: 1.15; margin-top: 2px; }
.am-chip--1 { top: 8px; left: 2px; animation: am-chip1 6s ease-in-out infinite; }
.am-chip--2 { top: 150px; right: 0; animation: am-chip2 7s ease-in-out infinite; }
.am-chip--3 { bottom: 6px; left: 26px; animation: am-chip3 8s ease-in-out infinite; }

.am-hero__mini { position: absolute; }
.am-hero__mini--1 { top: 120px; left: 12px; font-size: 30px; animation: am-bob 4s ease-in-out infinite; }
.am-hero__mini--2 { bottom: 70px; right: 34px; font-size: 24px; animation: am-bob 4.6s ease-in-out infinite .4s; }

/* ============ HERO RESPONSIVE ============ */
@media (max-width: 991.98px) {
  .am-hero__grid { grid-template-columns: 1fr; gap: 0; padding-block: 48px; }
  .am-hero__play { display: none; }
  .am-hero__sub { max-width: none; }
}
@media (max-width: 767.98px) {
  .am-hero__grid { padding-block: 34px 38px; }
  .am-hero__sub { font-size: 1.0625rem; margin: 20px 0 26px; }
  .am-hero__stats { gap: 22px; margin-top: 28px; }
  .am-stat__num { font-size: 22px; }
  .am-hero__banana--1 { font-size: 58px; top: 24px; left: -18px; }
  .am-btn { padding: 14px 22px; }
}

/* ============ SECTION PRIMITIVES (shared) ============ */
.am-sec-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}
.am-eyebrow {
  display: inline-block;
  font-weight: 700;
  font-size: var(--fs-meta);
  color: var(--am-blue);
  letter-spacing: .04em;
  text-transform: uppercase;
}
.am-h2 {
  font-family: var(--am-font-display);
  font-weight: 800;
  font-size: var(--fs-h2);
  letter-spacing: var(--ls-h2);
  color: var(--am-ink);
  margin: 8px 0 0;
}
.am-viewall {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 700;
  font-size: .90625rem;
  color: var(--am-blue);
  text-decoration: none;
  transition: gap var(--dur) ease, color var(--dur) ease;
}
.am-viewall:hover,
.am-viewall:focus-visible { color: var(--am-blue-ink); text-decoration: none; gap: 8px; }

/* ============ POPULAR TOOLS ============ */
.am-tools { padding-block: 44px 24px; }
.am-tools-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }

.am-tool {
  display: flex;
  flex-direction: column;
  background: var(--am-surface);
  border: 1px solid var(--am-border);
  border-radius: var(--r-lg);
  padding: 22px;
  text-decoration: none;
  color: inherit;
  transition: transform var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease),
              border-color var(--dur) var(--ease);
}
.am-tool:hover,
.am-tool:focus-visible {
  transform: translateY(-6px);
  box-shadow: var(--sh-lg);
  border-color: var(--am-blue);
  text-decoration: none;
  color: inherit;
}
.am-tool__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.am-tool__icon {
  width: 52px;
  height: 52px;
  border-radius: var(--r-tile);
  display: grid;
  place-items: center;
  font-size: 26px;
  flex: none;
}
.am-tool__tag {
  font-size: 11px;
  font-weight: 700;
  color: var(--am-muted);
  background: var(--am-tag-bg);
  padding: 5px 10px;
  border-radius: var(--r-pill);
}
.am-tool__title {
  font-family: var(--am-font-display);
  font-weight: 700;
  font-size: var(--fs-title);
  letter-spacing: -.01em;
  color: var(--am-ink);
  margin: 0 0 6px;
}
.am-tool__desc {
  font-size: var(--fs-sm);
  line-height: 1.55;
  color: var(--am-muted);
  margin: 0 0 16px;
  flex: 1;
}
.am-tool__cta { font-weight: 700; font-size: var(--fs-sm); color: var(--am-blue); }

@media (min-width: 768px) and (max-width: 991.98px) {
  .am-tools-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 767.98px) {
  .am-tools { padding-block: 32px 16px; }
  .am-tools-grid { grid-template-columns: 1fr; gap: 14px; }
  .am-sec-head { flex-wrap: wrap; }
}

/* ============ EDITORIAL (featured + popular) ============ */
.am-editorial { padding-block: 40px; }
.am-editorial__grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 22px;
  align-items: start;
}
.am-editorial__side { display: flex; flex-direction: column; }

/* Big featured card */
.am-featured {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 360px;
  padding: 30px;
  border-radius: var(--r-xl);
  overflow: hidden;
  color: #fff;
  text-decoration: none;
  background-color: var(--am-navy);
  background-image: repeating-linear-gradient(135deg, rgba(255,255,255,.05) 0 12px, transparent 12px 24px);
  background-size: cover;
  background-position: center;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.am-featured:hover,
.am-featured:focus-visible { transform: translateY(-5px); box-shadow: var(--sh-lg); color: #fff; text-decoration: none; }
.am-featured__badge {
  position: absolute; top: 22px; left: 22px;
  background: var(--am-yellow); color: var(--am-ink);
  font-weight: 800; font-size: 12px; padding: 6px 12px; border-radius: var(--r-pill);
}
.am-featured__body { position: relative; z-index: 1; }
.am-featured__eyebrow { font-size: 12.5px; font-weight: 700; color: #8fb0ff; text-transform: uppercase; letter-spacing: .05em; }
.am-featured__title {
  font-family: var(--am-font-display); font-weight: 800; font-size: var(--fs-h3);
  line-height: 1.12; letter-spacing: -.02em; color: #fff; margin: 12px 0 10px; max-width: 460px;
}
.am-featured__excerpt { font-size: 14.5px; line-height: 1.55; color: rgba(255,255,255,.80); margin: 0 0 14px; max-width: 440px; }
.am-featured__meta { font-size: 13px; color: rgba(255,255,255,.66); font-weight: 600; }

/* Free Tools callout */
.am-freetools {
  display: flex; align-items: center; gap: 12px;
  padding: 16px; border-radius: var(--r-lg); margin-bottom: 20px;
  background: linear-gradient(135deg, #eef3ff 0%, #e0e7ff 100%);
  border: 1px solid var(--am-border-blue);
}
.am-freetools__icon { font-size: 1.6rem; line-height: 1; }
.am-freetools__label { font-family: var(--am-font-display); font-weight: 800; font-size: .95rem; color: var(--am-ink); }
.am-freetools__sub { font-size: .78rem; color: var(--am-muted); }
.am-freetools__btn {
  margin-left: auto; background: var(--am-blue); color: #fff; border: none;
  border-radius: var(--r-sm); padding: 8px 16px; font-weight: 700; font-size: .82rem;
  white-space: nowrap; text-decoration: none; transition: background var(--dur) ease;
}
.am-freetools__btn:hover,
.am-freetools__btn:focus { background: var(--am-blue-ink); color: #fff; text-decoration: none; }

/* Popular this week */
.am-popular { background: var(--am-surface); border: 1px solid var(--am-border); border-radius: var(--r-xl); padding: 24px; }
.am-popular__title {
  font-family: var(--am-font-display); font-weight: 800; font-size: 20px;
  margin: 0 0 8px; color: var(--am-ink); display: flex; align-items: center; gap: 8px;
}
.am-popular__list { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; counter-reset: pop; }
.am-popular__item { counter-increment: pop; border-top: 1px solid var(--am-border); }
.am-popular__item:first-child { border-top: 0; }
.am-popular__link { display: flex; gap: 14px; padding: 13px 0; text-decoration: none; }
.am-popular__rank { font-family: var(--am-font-display); font-weight: 800; font-size: 20px; color: #d4c6ad; flex: none; width: 24px; line-height: 1.35; }
.am-popular__rank::before { content: counter(pop); }
.am-popular__t { font-weight: 600; font-size: 14.5px; line-height: 1.35; color: var(--am-ink); transition: color var(--dur) ease; }
.am-popular__link:hover .am-popular__t,
.am-popular__link:focus-visible .am-popular__t { color: var(--am-blue); }
.am-popular__meta { font-size: 12px; color: var(--am-muted); margin-top: 4px; font-weight: 600; }

/* ============ LATEST ARTICLES ============ */
.am-latest { padding-block: 24px 64px; }
.am-latest__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }

.am-article {
  display: flex; flex-direction: column;
  background: var(--am-surface); border: 1px solid var(--am-border);
  border-radius: var(--r-lg); overflow: hidden;
  text-decoration: none; color: inherit;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.am-article:hover,
.am-article:focus-visible { transform: translateY(-5px); box-shadow: var(--sh-lg); border-color: var(--am-blue); color: inherit; text-decoration: none; }
.am-article__cover {
  height: 168px; position: relative; overflow: hidden;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--am-tile-blue), var(--am-tile-lav));
}
.am-article__img { width: 100%; height: 100%; object-fit: cover; display: block; }
.am-article__ph { font-size: 44px; opacity: .5; }
.am-article__body { padding: 18px 18px 20px; display: flex; flex-direction: column; flex: 1; }
.am-article__title {
  font-family: var(--am-font-display); font-weight: 700; font-size: var(--fs-title-sm);
  line-height: 1.24; letter-spacing: -.01em; color: var(--am-ink); margin: 0 0 10px;
  transition: color var(--dur) ease;
}
.am-article:hover .am-article__title { color: var(--am-blue); }
.am-article__excerpt { font-size: 13.5px; line-height: 1.5; color: var(--am-body); margin: 0 0 16px; flex: 1; }
.am-article__meta { font-size: 12.5px; color: var(--am-muted); font-weight: 600; }

.load-more-container { text-align: center; margin-top: 36px; }

/* ---- Editorial + Latest responsive ---- */
@media (min-width: 768px) and (max-width: 991.98px) {
  .am-latest__grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 991.98px) {
  .am-editorial__grid { grid-template-columns: 1fr; gap: 18px; }
}
@media (max-width: 767.98px) {
  .am-editorial { padding-block: 28px; }
  .am-latest { padding-block: 16px 44px; }
  .am-latest__grid { grid-template-columns: 1fr; gap: 16px; }
  .am-featured { min-height: 300px; padding: 22px; }
  .am-featured__title { font-size: 1.5rem; }
}

/* ============ FOOTER ============ */
.am-footer {
  background: var(--am-surface);
  border-top: 1px solid var(--am-border);
  margin-top: 32px;
}
.am-footer__inner {
  max-width: var(--am-container);
  margin-inline: auto;
  padding: 40px var(--am-gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.am-footer__brand { display: flex; align-items: center; gap: 10px; text-decoration: none; transition: opacity var(--dur) ease; }
.am-footer__brand:hover { opacity: .9; text-decoration: none; }
.am-footer__logo { height: 34px; width: auto; max-width: 120px; object-fit: contain; display: block; }
.am-footer__brand-text { display: flex; flex-direction: column; gap: 3px; line-height: 1.2; }
.am-footer__name { font-family: var(--am-font-display); font-weight: 800; font-size: 16px; color: var(--am-ink); }
.am-footer__tag { font-size: 12px; color: var(--am-muted); font-weight: 600; }
.am-footer__links { display: flex; gap: 22px; flex-wrap: wrap; font-size: 14px; font-weight: 600; }
.am-footer__links a { color: var(--am-body); text-decoration: none; transition: color var(--dur) ease; }
.am-footer__links a:hover,
.am-footer__links a:focus-visible { color: var(--am-blue); text-decoration: none; }
.am-footer__copy { font-size: 13px; color: var(--am-muted); font-weight: 600; }

@media (max-width: 767.98px) {
  .am-footer__inner { flex-direction: column; align-items: flex-start; gap: 18px; padding: 28px var(--am-gutter); }
}

/* ============================================================
   GLOBAL PAGE SKIN
   Restyles the shared shell used by every non-home page
   (tool pages, calculators, tools index, post detail,
   category, legal, about). Scoped under .font-enforcer — the
   layout's content wrapper — so it out-specifies the per-page
   inline styles that load after this file. No markup changes.
   ============================================================ */

/* Content headings → display face (font-family only; sizes untouched) */
.font-enforcer h1,
.font-enforcer h2,
.font-enforcer h3 { font-family: var(--am-font-display); letter-spacing: -.01em; }

/* ---- Tool / calculator / about / legal hero → inset rounded gradient card ---- */
@keyframes am-floaty { 0%,100%{ transform: translateY(0) rotate(-3deg); } 50%{ transform: translateY(-9px) rotate(3deg); } }
.font-enforcer .header-gradient {
  max-width: min(1180px, calc(100% - 48px));
  margin: 20px auto 40px;
  border-radius: 26px;
  background: linear-gradient(115deg, #1d4ed8 0%, #3b5bdb 45%, #6a5be0 100%);
  color: #fff;
  position: relative;
  overflow: hidden;
}
.font-enforcer .header-gradient::before {
  content: "🍌";
  position: absolute; left: 24px; bottom: -18px;
  font-size: 90px; opacity: .14; pointer-events: none;
  animation: am-floaty 7s ease-in-out infinite;
}
.font-enforcer .header-gradient::after {
  content: "🐵";
  position: absolute; right: 34px; top: 12px;
  font-size: 120px; opacity: .16; pointer-events: none;
  animation: am-floaty 6s ease-in-out infinite;
}
.font-enforcer .header-gradient .container { position: relative; z-index: 1; }
.font-enforcer .header-gradient h1,
.font-enforcer .header-gradient .lead,
.font-enforcer .header-gradient p { color: #fff; }
.font-enforcer .header-gradient .lead { opacity: .9; }
@media (max-width: 767.98px) {
  .font-enforcer .header-gradient { border-radius: 20px; margin-top: 12px; }
  .font-enforcer .header-gradient::after { font-size: 82px; right: 12px; }
  .font-enforcer .header-gradient::before { font-size: 60px; }
}

/* ---- Main tool card (was glassmorphism → solid playful card) ---- */
.font-enforcer .glass-card {
  background: var(--am-surface);
  border: 1px solid var(--am-border) !important;
  border-radius: 22px;
  box-shadow: 0 18px 40px rgba(23,19,16,.07);
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}

/* ---- Generic Bootstrap cards ---- */
.font-enforcer .card { border-radius: var(--r-lg); border-color: var(--am-border); }

/* ---- Buttons ---- */
.font-enforcer .btn { border-radius: var(--r-md); font-weight: 700; }
.font-enforcer .btn-blue,
.font-enforcer .btn-primary {
  background: var(--am-blue); border-color: var(--am-blue); color: #fff;
  box-shadow: var(--sh-blue-sm);
}
.font-enforcer .btn-blue:hover, .font-enforcer .btn-blue:focus,
.font-enforcer .btn-primary:hover, .font-enforcer .btn-primary:focus {
  background: var(--am-blue-ink); border-color: var(--am-blue-ink); color: #fff;
}
.font-enforcer .btn-purple { background: #6d28d9; border-color: #6d28d9; color: #fff; }
.font-enforcer .btn-purple:hover, .font-enforcer .btn-purple:focus { background: #5b21b6; border-color: #5b21b6; color: #fff; }

/* ---- Form controls ---- */
.font-enforcer .form-control {
  border-radius: var(--r-sm);
  border-color: var(--am-border-2);
  transition: border-color var(--dur) ease, box-shadow var(--dur) ease;
}
.font-enforcer .form-control:focus {
  border-color: var(--am-blue);
  box-shadow: var(--sh-blue-sm);
}

/* ============ TOOLS INDEX (assets/tools/tool-home.css overrides) ============ */
.font-enforcer .tools-hero {
  background: linear-gradient(135deg, var(--am-blue) 0%, #4f6ef2 55%, #7c6cf0 100%);
  color: #fff;
  border-radius: 0 0 32px 32px;
}
.font-enforcer .tools-hero h1 { color: #fff; }
.font-enforcer .tools-hero p { color: rgba(255,255,255,.92); }
.font-enforcer .category-section .category-title { color: var(--am-ink); }
.font-enforcer .category-section .category-subtitle { color: var(--am-muted); }
.font-enforcer .tool-card {
  background: var(--am-surface);
  border: 1px solid var(--am-border);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-sm);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.font-enforcer .tool-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--sh-lg);
  border-color: var(--am-blue);
}
.font-enforcer .tool-icon { color: var(--am-blue); }
.font-enforcer .tool-title { color: var(--am-ink); }
.font-enforcer .tool-description { color: var(--am-muted); }
.font-enforcer .tool-tag {
  background: var(--am-tag-bg);
  color: var(--am-muted);
  border-radius: var(--r-pill);
}

/* ============ POST DETAIL (article reading experience) ============ */
.font-enforcer .featured__image { border-radius: var(--r-lg); }
.font-enforcer .reveal p { line-height: 1.75; color: var(--am-body); }
.font-enforcer .reveal a { color: var(--am-blue); text-decoration: underline; text-underline-offset: 2px; }
.font-enforcer .reveal a:hover { color: var(--am-blue-ink); }
.font-enforcer .reveal img { border-radius: var(--r-md); max-width: 100%; height: auto; }
.font-enforcer .reveal h2,
.font-enforcer .reveal h3 { color: var(--am-ink); margin-top: 1.6em; }
.font-enforcer .reveal blockquote {
  border-left: 4px solid var(--am-yellow);
  background: var(--am-blue-soft);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  padding: 14px 18px;
  margin: 1.5em 0;
  color: var(--am-ink);
}
.font-enforcer .reveal pre {
  border-radius: var(--r-md);
  border: 1px solid var(--am-border);
}

/* ============ RELATED TOOLS — "Explore More Useful Tools" ============ */
.am-related {
  position: relative;
  overflow: hidden;
  margin-top: 56px;
  padding: 56px 0;
  border-top: 1px solid var(--am-border);
  background:
    radial-gradient(90% 60% at 12% 0%, #fff7dd 0%, rgba(255,247,221,0) 46%),
    radial-gradient(80% 70% at 100% 100%, var(--am-glow) 0%, rgba(234,240,255,0) 52%),
    var(--am-bg);
}
.am-related__banana { position: absolute; pointer-events: none; user-select: none; opacity: .13; }
.am-related__banana--1 { top: 22px; right: 6%; font-size: 64px; animation: am-bob 6s ease-in-out infinite; }
.am-related__banana--2 { bottom: 16px; left: 4%; font-size: 44px; animation: am-swing 7s ease-in-out infinite; }

.am-related__head { position: relative; text-align: center; max-width: 640px; margin: 0 auto 40px; padding: 0 var(--am-gutter); }
.am-related__eyebrow { display: inline-block; font-weight: 700; font-size: var(--fs-meta); color: var(--am-blue); letter-spacing: .04em; text-transform: uppercase; margin-bottom: 10px; }
.am-related__title { font-family: var(--am-font-display); font-weight: 800; font-size: var(--fs-h2); letter-spacing: var(--ls-h2); color: var(--am-ink); margin: 0 0 10px; }
.am-related__sub { font-size: 1.0625rem; color: var(--am-muted); margin: 0; }

.am-related__grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  max-width: var(--am-container);
  margin: 0 auto;
  padding: 0 var(--am-gutter);
}

.am-related-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--am-surface);
  border: 1px solid var(--am-border);
  border-radius: var(--r-lg);
  padding: 24px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.am-related-card::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--am-blue), var(--am-yellow));
  transform: scaleX(0); transform-origin: left;
  transition: transform var(--dur-slow) var(--ease);
}
.am-related-card:hover,
.am-related-card:focus-visible {
  transform: translateY(-6px);
  box-shadow: var(--sh-lg);
  border-color: var(--am-blue);
  text-decoration: none;
  color: inherit;
}
.am-related-card:hover::before,
.am-related-card:focus-visible::before { transform: scaleX(1); }

.am-related-card__icon {
  width: 56px; height: 56px;
  border-radius: var(--r-tile);
  display: grid; place-items: center;
  font-size: 1.6rem;
  margin-bottom: 18px;
  background: var(--am-tile-blue);
  color: var(--am-blue);
  transition: transform var(--dur) var(--ease);
}
.am-related-card:hover .am-related-card__icon { transform: rotate(-6deg) scale(1.08); }
/* playful rotating tile colors */
.am-related-card:nth-child(6n+1) .am-related-card__icon { background: var(--am-tile-green);  color: #16a34a; }
.am-related-card:nth-child(6n+2) .am-related-card__icon { background: var(--am-tile-blue);   color: var(--am-blue); }
.am-related-card:nth-child(6n+3) .am-related-card__icon { background: var(--am-tile-orange); color: #d97706; }
.am-related-card:nth-child(6n+4) .am-related-card__icon { background: var(--am-tile-lav);    color: #7c3aed; }
.am-related-card:nth-child(6n+5) .am-related-card__icon { background: var(--am-tile-pink);   color: #e11d48; }
.am-related-card:nth-child(6n+6) .am-related-card__icon { background: #fef9c3;                color: #ca8a04; }

.am-related-card__title { font-family: var(--am-font-display); font-weight: 700; font-size: var(--fs-title); letter-spacing: -.01em; color: var(--am-ink); line-height: 1.3; margin: 0 0 8px; }
.am-related-card__desc { font-size: var(--fs-sm); color: var(--am-muted); line-height: 1.55; margin: 0 0 18px; flex: 1; }
.am-related-card__cta { display: inline-flex; align-items: center; gap: 7px; font-weight: 700; font-size: var(--fs-sm); color: var(--am-blue); }
.am-related-card__cta i { transition: transform var(--dur) var(--ease); }
.am-related-card:hover .am-related-card__cta i { transform: translateX(4px); }

@media (max-width: 991.98px) {
  .am-related__grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
}
@media (max-width: 767.98px) {
  .am-related { padding: 40px 0; margin-top: 40px; }
  .am-related__grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .am-related-card { padding: 18px; }
  .am-related-card__icon { width: 48px; height: 48px; font-size: 1.4rem; margin-bottom: 14px; }
}
@media (max-width: 479.98px) {
  .am-related__grid { grid-template-columns: 1fr; }
}

/* staggered fade-in */
@media (prefers-reduced-motion: no-preference) {
  .am-related-card { animation: am-rise .5s var(--ease) backwards; }
  .am-related-card:nth-child(1) { animation-delay: .05s; }
  .am-related-card:nth-child(2) { animation-delay: .12s; }
  .am-related-card:nth-child(3) { animation-delay: .19s; }
  .am-related-card:nth-child(4) { animation-delay: .26s; }
  .am-related-card:nth-child(5) { animation-delay: .33s; }
  .am-related-card:nth-child(6) { animation-delay: .40s; }
  @keyframes am-rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }
}

/* ============ READ NEXT (article detail page) ============ */
.am-readnext { padding-block: 40px 8px; }
.am-readnext__head { margin-bottom: 22px; }
.am-readnext__head .am-eyebrow { margin-bottom: 2px; }
.am-readnext__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px; }
.am-readnext__card {
  display: flex;
  flex-direction: column;
  background: var(--am-surface);
  border: 1px solid var(--am-border);
  border-radius: var(--r-lg);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.am-readnext__card:hover,
.am-readnext__card:focus-visible {
  transform: translateY(-5px);
  box-shadow: var(--sh-lg);
  border-color: var(--am-blue);
  text-decoration: none;
  color: inherit;
}
.am-readnext__cover { height: 150px; background-size: cover; background-position: center; background-repeat: no-repeat; }
.am-readnext__cover--empty { display: grid; place-items: center; font-size: 42px; background: linear-gradient(135deg, var(--am-blue-soft) 0%, #e7ddff 100%); }
.am-readnext__body { display: flex; flex-direction: column; flex: 1; padding: 16px 18px 18px; }
.am-readnext__date { font-size: 12px; color: var(--am-muted); font-weight: 700; }
.am-readnext__title {
  font-family: var(--am-font-display);
  font-weight: 700;
  font-size: 1.0625rem;
  line-height: 1.28;
  letter-spacing: -.01em;
  color: var(--am-ink);
  margin: 8px 0 12px;
  flex: 1;
  transition: color var(--dur) ease;
}
.am-readnext__card:hover .am-readnext__title,
.am-readnext__card:focus-visible .am-readnext__title { color: var(--am-blue); }
.am-readnext__cta { font-weight: 700; font-size: var(--fs-sm); color: var(--am-blue); }

@media (max-width: 767.98px) {
  .am-readnext__grid { grid-template-columns: 1fr; gap: 14px; }
}

/* ============ REUSABLE TOOL HERO (gradient card) ============ */
.am-toolhero {
  position: relative;
  overflow: hidden;
  text-align: left;
  border-radius: 24px;
  background: linear-gradient(115deg, #1d4ed8 0%, #3b5bdb 45%, #5b46c9 100%);
  color: #fff;
  padding: 44px 40px;
}
.am-toolhero::before {
  content: "";
  position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255,255,255,.16) 1px, transparent 1.5px);
  background-size: 20px 20px;
  -webkit-mask-image: linear-gradient(120deg, #000, transparent 72%);
  mask-image: linear-gradient(120deg, #000, transparent 72%);
  opacity: .6;
}
.am-toolhero__badge {
  position: relative; display: inline-flex; align-items: center; gap: 7px;
  background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.24);
  color: #fff; font-weight: 700; font-size: 12px; letter-spacing: .03em; text-transform: uppercase;
  padding: 6px 12px; border-radius: 999px; margin-bottom: 14px;
}
.am-toolhero__title { position: relative; font-family: var(--am-font-display); font-weight: 800; font-size: clamp(1.9rem, 4vw, 2.75rem); line-height: 1.04; letter-spacing: -.02em; margin: 0; color: #fff; }
.am-toolhero__sub { position: relative; font-size: 1.0625rem; line-height: 1.6; color: rgba(255,255,255,.85); margin: 12px 0 0; max-width: 620px; }
@media (max-width: 767.98px) { .am-toolhero { padding: 32px 24px; border-radius: 20px; } }
