/* ============================================================
   QuickTools — premium UI stylesheet (v2)
   Complements Tailwind (Play CDN). No @apply is used here
   because the Tailwind Play CDN does not process this file.
   ============================================================ */

:root {
  --brand: #2563eb;
  --brand-2: #4f46e5;
  --brand-dark: #1d4ed8;
  --ring: rgba(59, 130, 246, 0.45);
  --card: rgba(255, 255, 255, 0.72);
  --border: rgba(255, 255, 255, 0.6);
  --shadow-soft: 0 10px 30px -14px rgba(15, 23, 42, 0.20);
  --shadow-lift: 0 28px 60px -26px rgba(30, 64, 175, 0.5);
}

* { -webkit-tap-highlight-color: transparent; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', 'Plus Jakarta Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  color: #0f172a;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  background-color: #f5f7fc;
  background-image:
    radial-gradient(900px 520px at 6% -10%, rgba(99, 102, 241, 0.18), transparent 60%),
    radial-gradient(820px 500px at 102% -4%, rgba(56, 189, 248, 0.16), transparent 55%),
    radial-gradient(760px 520px at 50% 118%, rgba(236, 72, 153, 0.10), transparent 60%);
  background-attachment: fixed;
}

h1, h2, h3, h4 { font-family: 'Plus Jakarta Sans', 'Inter', ui-sans-serif, system-ui, sans-serif; letter-spacing: -.02em; }

/* ---------- SPA view transitions ---------- */
.view { animation: viewIn 0.32s cubic-bezier(0.22, 0.61, 0.36, 1) both; }
.view.hidden { display: none !important; }

@keyframes viewIn {
  from { opacity: 0; transform: translateY(14px) scale(0.995); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes floaty {
  0%, 100% { translate: 0 0; }
  50%      { translate: 0 -8px; }
}

@keyframes blobFloat {
  0%   { transform: translate3d(0, 0, 0) scale(1); }
  33%  { transform: translate3d(46px, -34px, 0) scale(1.14); }
  66%  { transform: translate3d(-34px, 26px, 0) scale(0.92); }
  100% { transform: translate3d(0, 0, 0) scale(1); }
}

@keyframes shine {
  0%        { transform: translateX(-140%) skewX(-15deg); }
  60%, 100% { transform: translateX(240%) skewX(-15deg); }
}

/* ---------- Hero (animated mesh) ---------- */
.qt-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #0b1224 0%, #111a35 45%, #1b2a63 100%);
}
.qt-hero::before,
.qt-hero::after {
  content: "";
  position: absolute;
  border-radius: 9999px;
  filter: blur(72px);
  opacity: 0.62;
  pointer-events: none;
  z-index: 0;
}
.qt-hero::before {
  width: 540px; height: 540px; top: -190px; left: -130px;
  background: radial-gradient(circle at 30% 30%, #3b82f6, transparent 66%);
  animation: blobFloat 16s ease-in-out infinite;
}
.qt-hero::after {
  width: 470px; height: 470px; bottom: -210px; right: -110px;
  background: radial-gradient(circle at 60% 40%, #8b5cf6, transparent 66%);
  animation: blobFloat 22s ease-in-out infinite reverse;
}
.qt-hero > * { position: relative; z-index: 1; }

.animate-float { animation: floaty 4.6s ease-in-out infinite; }

/* ---------- Primary button ---------- */
.btn-primary {
  position: relative; overflow: hidden;
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  color: #fff; font-weight: 700; font-size: 1rem; letter-spacing: .01em;
  padding: .85rem 1.4rem; border-radius: 1rem; border: 1px solid rgba(255, 255, 255, .16);
  cursor: pointer; min-height: 48px;
  background-image: linear-gradient(135deg, #2563eb 0%, #4f46e5 55%, #7c3aed 120%);
  box-shadow: 0 14px 30px -12px rgba(79, 70, 229, .65), inset 0 1px 0 rgba(255, 255, 255, .28);
  transition: transform .18s ease, box-shadow .25s ease, filter .2s ease;
}
.btn-primary::before {
  content: ""; position: absolute; top: 0; left: 0; width: 45%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .55), transparent);
  transform: translateX(-140%) skewX(-15deg);
}
.btn-primary:hover::before { animation: shine .9s ease; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 22px 44px -16px rgba(79, 70, 229, .8); }
.btn-primary:active { transform: scale(.96); }
.btn-primary:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--ring), 0 14px 30px -12px rgba(79, 70, 229, .65); }
.btn-primary:disabled { opacity: .6; cursor: not-allowed; transform: none; filter: grayscale(.25); }

/* ---------- Secondary / copy button ---------- */
.btn-secondary {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  background: linear-gradient(180deg, #ffffff, #f8fafc); color: #1e293b;
  font-weight: 600; font-size: .875rem;
  padding: .55rem .95rem; border-radius: .8rem; border: 1px solid rgba(15, 23, 42, .12);
  cursor: pointer; min-height: 44px;
  box-shadow: 0 4px 12px -8px rgba(15, 23, 42, .4);
  transition: transform .15s ease, background .2s ease, border-color .2s ease, box-shadow .2s ease, color .2s ease;
}
.btn-secondary:hover { background: #fff; border-color: rgba(59, 130, 246, .5); box-shadow: 0 10px 22px -14px rgba(37, 99, 235, .6); }
.btn-secondary:active { transform: scale(.94); }
.btn-secondary:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--ring); }
.btn-secondary.copied,
.btn-secondary.copied:hover {
  background: linear-gradient(135deg, #16a34a, #22c55e);
  border-color: transparent; color: #fff;
  transform: scale(.94);
  box-shadow: 0 10px 24px -12px rgba(22, 163, 74, .7);
}

/* ---------- Inputs ---------- */
.input {
  width: 100%; font-size: 1rem; color: #0f172a;
  background: rgba(255, 255, 255, .85);
  padding: .8rem 1rem; border: 1px solid rgba(15, 23, 42, .10); border-radius: 1rem;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, .04);
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}
.input::placeholder { color: #94a3b8; }
.input:hover { border-color: rgba(15, 23, 42, .18); }
.input:focus {
  outline: none; background: #fff; border-color: #3b82f6;
  box-shadow: 0 0 0 4px var(--ring), inset 0 1px 2px rgba(15, 23, 42, .04);
}
textarea.input { resize: vertical; line-height: 1.65; }
.input:disabled { background: #f1f5f9; color: #94a3b8; }
select.input { cursor: pointer; }

/* ---------- Tool cards (glassmorphism) ---------- */
.tool-card {
  position: relative; display: block; height: 100%; overflow: hidden;
  padding: 1.6rem; border-radius: 1.25rem;
  background: var(--card);
  border: 1px solid var(--border);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  backdrop-filter: blur(14px) saturate(160%);
  box-shadow: var(--shadow-soft);
  transition: transform .3s cubic-bezier(.22, .61, .36, 1), box-shadow .3s ease, border-color .3s ease;
}
/* grids that opt in with items-start keep each card at its own height (home page exam card) */
.items-start > .tool-card { height: auto; }
.tool-card::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px;
  background: linear-gradient(135deg, rgba(59, 130, 246, .6), rgba(168, 85, 247, .5), transparent 62%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  opacity: 0; transition: opacity .3s ease; pointer-events: none;
}
.tool-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lift); border-color: rgba(191, 219, 254, .9); }
.tool-card:hover::after { opacity: 1; }
.tool-card:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--ring), var(--shadow-lift); }

/* ---------- Nav ---------- */
.nav-link {
  position: relative; padding: .5rem .85rem; border-radius: .7rem; font-weight: 600;
  color: #334155; font-size: .95rem;
  transition: color .2s ease, background .2s ease, box-shadow .2s ease;
}
.nav-link:hover { color: #0f172a; background: rgba(148, 163, 184, .16); }
.nav-link.active {
  color: #1d4ed8;
  background: linear-gradient(135deg, rgba(59, 130, 246, .14), rgba(99, 102, 241, .14));
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, .28);
}

/* ---------- Nav dropdown (PDF Tools) ---------- */
.nav-menu-item {
  display: flex; align-items: center; justify-content: space-between; gap: .5rem;
  padding: .55rem .75rem; border-radius: .7rem;
  font-size: .9rem; font-weight: 600; color: #334155;
  transition: background .18s ease, color .18s ease;
}
.nav-menu-item:hover,
.nav-menu-item:focus-visible { background: #f1f5f9; color: var(--brand); outline: none; }
.nav-menu-item.active {
  color: #1d4ed8;
  background: linear-gradient(135deg, rgba(59, 130, 246, .14), rgba(99, 102, 241, .14));
}
.soon-tag {
  flex: 0 0 auto; border-radius: 9999px; background: #f1f5f9; color: #64748b;
  font-size: .6rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  padding: .1rem .45rem;
}
[data-dropdown].is-open > button .fa-chevron-down { transform: rotate(180deg); }

/* ---------- Drop zone (file tools) ---------- */
.dropzone {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .25rem; text-align: center; cursor: pointer;
  padding: 2rem 1.25rem; border-radius: 1.25rem;
  border: 2px dashed rgba(15, 23, 42, .18);
  background: linear-gradient(180deg, rgba(255, 255, 255, .92), rgba(248, 250, 252, .78));
  transition: border-color .18s ease, background .18s ease, transform .18s ease;
}
.dropzone:hover { border-color: rgba(59, 130, 246, .55); }
.dropzone:focus-visible { outline: none; border-color: #3b82f6; box-shadow: 0 0 0 4px var(--ring); }
.dropzone.is-dragover { border-color: #2563eb; background: rgba(59, 130, 246, .08); transform: scale(1.01); }

/* ---------- Preset / mode pills (radio chips) ---------- */
.preset-pill {
  position: relative; display: flex; align-items: center; gap: .6rem;
  padding: .7rem .9rem; border-radius: .95rem; cursor: pointer;
  border: 1px solid rgba(15, 23, 42, .12);
  background: linear-gradient(180deg, #ffffff, #f8fafc);
  color: #334155; font-size: .9rem; font-weight: 600; line-height: 1.25;
  transition: background .18s ease, border-color .18s ease, color .18s ease, transform .12s ease, box-shadow .18s ease;
}
.preset-pill:hover { border-color: rgba(59, 130, 246, .5); transform: translateY(-1px); }
.preset-pill input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.preset-pill .preset-meta { display: block; margin-top: .1rem; font-size: .72rem; font-weight: 500; color: #64748b; }
.preset-pill.is-active {
  border-color: #2563eb; color: #1d4ed8;
  background: linear-gradient(135deg, rgba(37, 99, 235, .14), rgba(79, 70, 229, .14));
  box-shadow: 0 12px 26px -18px rgba(37, 99, 235, .75);
}
.preset-pill.is-active .preset-meta { color: #3730a3; }
.preset-pill:focus-within { outline: none; box-shadow: 0 0 0 4px var(--ring); }

/* ---------- File rows (multi-file tools) ---------- */
.file-item {
  display: flex; align-items: center; gap: .75rem;
  padding: .6rem .7rem; border-radius: .9rem;
  border: 1px solid rgba(15, 23, 42, .08); background: #fff;
  box-shadow: 0 6px 16px -14px rgba(15, 23, 42, .45);
  animation: fadeUp .35s cubic-bezier(.22, .61, .36, 1) both;
}
.file-item-thumb {
  flex: 0 0 auto; width: 56px; height: 56px; border-radius: .6rem;
  object-fit: cover; background: #f1f5f9;
}
.icon-btn {
  display: inline-grid; place-items: center; width: 34px; height: 34px;
  border-radius: .6rem; border: 1px solid rgba(15, 23, 42, .12);
  background: #fff; color: #475569; font-size: .82rem; cursor: pointer;
  transition: background .18s ease, color .18s ease, border-color .18s ease, transform .12s ease;
}
.icon-btn:hover { background: #f1f5f9; color: #1d4ed8; border-color: rgba(59, 130, 246, .45); }
.icon-btn:active { transform: scale(.92); }
.icon-btn:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--ring); }
.icon-btn:disabled { opacity: .35; cursor: not-allowed; }
.icon-btn:disabled:hover { background: #fff; color: #475569; border-color: rgba(15, 23, 42, .12); }
.file-item-badge {
  flex: 0 0 auto; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .15rem; width: 56px; height: 56px; border-radius: .6rem;
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  border: 1px solid rgba(220, 38, 38, .18); color: #dc2626;
  font-size: 1rem; line-height: 1;
}
.file-item-badge span { font-size: .55rem; font-weight: 800; letter-spacing: .08em; }

/* Dark mode for the dropdown + file tools */
html.dark .nav-menu-item { color: #cbd5e1; }
html.dark .nav-menu-item:hover,
html.dark .nav-menu-item:focus-visible { background: rgba(148, 163, 184, .16); color: #fff; }
html.dark .nav-menu-item.active {
  color: #93c5fd;
  background: linear-gradient(135deg, rgba(59, 130, 246, .22), rgba(99, 102, 241, .22));
}
html.dark .soon-tag { background: #1e293b; color: #94a3b8; }
html.dark .dropzone { border-color: rgba(148, 163, 184, .28); background: rgba(15, 23, 42, .5); }
html.dark .dropzone:hover,
html.dark .dropzone:focus-visible { border-color: rgba(96, 165, 250, .6); }
html.dark .dropzone.is-dragover { border-color: #60a5fa; background: rgba(59, 130, 246, .16); }
html.dark .file-item { background: #0f172a; border-color: rgba(148, 163, 184, .16); }
html.dark .file-item-thumb { background: #1e293b; }
html.dark .icon-btn { background: #1e293b; border-color: rgba(148, 163, 184, .24); color: #cbd5e1; }
html.dark .file-item-badge { background: linear-gradient(135deg, #1f2937, #111827); border-color: rgba(248, 113, 113, .3); color: #fca5a5; }
html.dark .icon-btn:hover { background: #334155; color: #93c5fd; }
html.dark .preset-pill { background: linear-gradient(180deg, #0f172a, #0b1220); border-color: rgba(148, 163, 184, .2); color: #cbd5e1; }
html.dark .preset-pill:hover { border-color: rgba(96, 165, 250, .55); }
html.dark .preset-pill .preset-meta { color: #94a3b8; }
html.dark .preset-pill.is-active {
  color: #93c5fd; border-color: rgba(96, 165, 250, .6);
  background: linear-gradient(135deg, rgba(59, 130, 246, .24), rgba(99, 102, 241, .24));
}
html.dark .preset-pill.is-active .preset-meta { color: #bfdbfe; }



/* ---------- Ad slots (hidden unless activated by core.js) ---------- */
.ad-slot { display: none; }
/* Reserved height when active -> prevents layout shift (CLS) as AdSense fills the slot */
.ad-slot.is-active { display: block; min-height: 100px; }
@media (min-width: 768px) { .ad-slot.is-active { min-height: 280px; } }
/* Dev-only opt-in box: add data-debug="1" to preview placement */
.ad-slot[data-debug="1"] {
  display: block; border: 2px dashed rgba(148, 163, 184, .7); background: #eef2f7;
  border-radius: 1rem; min-height: 100px; color: #64748b; text-align: center;
  padding: 1.4rem; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase;
}

/* ---------- Result cards (name grid + fancy rows) ---------- */
.result-row,
.fancy-card {
  display: flex; align-items: center; justify-content: space-between; gap: .6rem;
  background: linear-gradient(180deg, #ffffff, #f8fafc);
  border: 1px solid rgba(15, 23, 42, .08);
  border-radius: .85rem; padding: .7rem .9rem;
  box-shadow: 0 6px 16px -12px rgba(15, 23, 42, .4);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.result-row:hover,
.fancy-card:hover {
  transform: translateY(-2px);
  border-color: rgba(59, 130, 246, .35);
  box-shadow: 0 12px 26px -16px rgba(37, 99, 235, .55);
}
.result-row { animation: fadeUp .45s cubic-bezier(.22, .61, .36, 1) both; }
.result-row:nth-child(1) { animation-delay: .02s; }
.result-row:nth-child(2) { animation-delay: .07s; }
.result-row:nth-child(3) { animation-delay: .12s; }
.result-row:nth-child(4) { animation-delay: .17s; }
.result-row:nth-child(5) { animation-delay: .22s; }
.result-row:nth-child(6) { animation-delay: .27s; }
.result-row:nth-child(7) { animation-delay: .32s; }
.result-row:nth-child(8) { animation-delay: .37s; }
.result-row:nth-child(9) { animation-delay: .42s; }
.result-row:nth-child(10) { animation-delay: .47s; }
.result-text {
  flex: 1; min-width: 0; font-size: 1.12rem; font-weight: 700;
  color: #0f172a; word-break: break-word;
}

/* ---------- Fancy text stagger (built by JS inside #ftOutputs) ---------- */
#ftOutputs.fancy-stagger > .fancy-card { animation: fadeUp .45s cubic-bezier(.22, .61, .36, 1) both; }
#ftOutputs.fancy-stagger > .fancy-card:nth-child(1) { animation-delay: .02s; }
#ftOutputs.fancy-stagger > .fancy-card:nth-child(2) { animation-delay: .06s; }
#ftOutputs.fancy-stagger > .fancy-card:nth-child(3) { animation-delay: .10s; }
#ftOutputs.fancy-stagger > .fancy-card:nth-child(4) { animation-delay: .14s; }
#ftOutputs.fancy-stagger > .fancy-card:nth-child(5) { animation-delay: .18s; }
#ftOutputs.fancy-stagger > .fancy-card:nth-child(6) { animation-delay: .22s; }
#ftOutputs.fancy-stagger > .fancy-card:nth-child(7) { animation-delay: .26s; }
#ftOutputs.fancy-stagger > .fancy-card:nth-child(8) { animation-delay: .30s; }
#ftOutputs.fancy-stagger > .fancy-card:nth-child(9) { animation-delay: .34s; }
#ftOutputs.fancy-stagger > .fancy-card:nth-child(10) { animation-delay: .38s; }

/* ---------- Copy chip (icon-only) ---------- */
.copy-btn {
  flex: 0 0 auto; width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: .6rem; border: 1px solid rgba(37, 99, 235, .12);
  background: #eff6ff; color: #2563eb; font-size: .95rem;
  cursor: pointer;
  transition: background .18s ease, color .18s ease, transform .12s ease, border-color .18s ease;
}
.copy-btn:hover { background: #dbeafe; }
.copy-btn:active { transform: scale(.9); }
.copy-btn:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--ring); }
.copy-btn .copy-check { display: none; }
.copy-btn.copied { background: #dcfce7; color: #16a34a; border-color: rgba(22, 163, 74, .25); }
.copy-btn.copied .copy-icon { display: none; }
.copy-btn.copied .copy-check { display: inline-block; }

/* ---------- Toast ---------- */
#toast {
  position: fixed; left: 50%; bottom: 1.5rem; transform: translate(-50%, 160%);
  background: linear-gradient(135deg, #0f172a, #1e293b); color: #fff;
  padding: .75rem 1.15rem; border-radius: .85rem; font-size: .9rem; font-weight: 500;
  border: 1px solid rgba(255, 255, 255, .12);
  box-shadow: 0 18px 40px -14px rgba(0, 0, 0, .6);
  z-index: 100; opacity: 0; pointer-events: none;
  transition: transform .3s cubic-bezier(.22, .61, .36, 1), opacity .3s ease;
}
#toast.show { transform: translate(-50%, 0); opacity: 1; }

/* ---------- Header language switcher ---------- */
.lang-switch .separator { color: rgba(148, 163, 184, .7); user-select: none; }
html.dark .lang-switch .separator { color: rgba(148, 163, 184, .4); }

/* ---------- Soft language suggestion banner ---------- */
.lang-banner {
  position: fixed; left: 1rem; right: 1rem; bottom: 1rem; z-index: 95;
  display: none; align-items: center; gap: .75rem;
  padding: .7rem .75rem .7rem 1rem; border-radius: 1rem;
  background: linear-gradient(135deg, #0f172a, #1e293b); color: #fff;
  font-size: .9rem; line-height: 1.4;
  border: 1px solid rgba(255, 255, 255, .14);
  box-shadow: 0 18px 44px -16px rgba(0, 0, 0, .65);
  transform: translateY(160%); opacity: 0; pointer-events: none;
  transition: transform .38s cubic-bezier(.22, .61, .36, 1), opacity .38s ease;
}
.lang-banner.show { display: flex; transform: translateY(0); opacity: 1; pointer-events: auto; }
.lang-banner-text { flex: 1 1 auto; min-width: 0; }
.lang-banner-cta {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: .35rem;
  padding: .5rem .85rem; border-radius: .7rem; font-weight: 700; font-size: .82rem;
  background: linear-gradient(135deg, #93c5fd, #bfdbfe); color: #0b1224;
  white-space: nowrap; text-decoration: none;
  transition: transform .15s ease, filter .2s ease;
}
.lang-banner-cta:hover { filter: brightness(1.06); transform: translateY(-1px); }
.lang-banner-cta:active { transform: scale(.96); }
.lang-banner-close {
  flex: 0 0 auto; display: inline-grid; place-items: center; width: 44px; height: 44px;
  border-radius: .6rem; border: 1px solid rgba(255, 255, 255, .22);
  background: rgba(255, 255, 255, .08); color: #cbd5e1;
  font-size: 1rem; line-height: 1; cursor: pointer;
  transition: background .18s ease, color .18s ease, transform .12s ease;
}
.lang-banner-close:hover { background: rgba(255, 255, 255, .2); color: #fff; }
.lang-banner-close:active { transform: scale(.9); }
.lang-banner-cta:focus-visible,
.lang-banner-close:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--ring); }
.lang-banner-cta { min-height: 44px; }

@media (min-width: 640px) {
  .lang-banner { left: 1.5rem; right: auto; bottom: 1.5rem; max-width: 30rem; }
}
@media (max-width: 480px) {
  .lang-banner { flex-wrap: wrap; }
  .lang-banner-text { flex-basis: 100%; }
}

/* ---------- Legal / article typography ---------- */
.legal-content h2 { font-size: 1.3rem; font-weight: 700; color: #0f172a; margin: 1.6rem 0 .5rem; }
.legal-content h3 { font-size: 1.05rem; font-weight: 600; color: #1e293b; margin: 1.1rem 0 .4rem; }
.legal-content p  { margin: .6rem 0; line-height: 1.75; }
.legal-content ul, .legal-content ol { margin: .6rem 0 .6rem 1.25rem; line-height: 1.75; }
.legal-content ul { list-style: disc; }
.legal-content ol { list-style: decimal; }
.legal-content a  { color: var(--brand); text-decoration: underline; text-underline-offset: 2px; }

/* ---------- FAQ accordion ---------- */
.faq summary { list-style: none; cursor: pointer; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--ring); border-radius: .5rem; }

/* ---------- Metric tiles ---------- */
.metric {
  background: linear-gradient(180deg, rgba(255, 255, 255, .94), rgba(248, 250, 252, .85));
  border: 1px solid rgba(15, 23, 42, .08); border-radius: 1rem;
  padding: .85rem .95rem; text-align: center;
  box-shadow: 0 8px 22px -18px rgba(15, 23, 42, .45);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.metric:hover { transform: translateY(-2px); border-color: rgba(59, 130, 246, .3); box-shadow: 0 14px 30px -20px rgba(37, 99, 235, .55); }
.metric .value {
  font-size: 1.5rem; font-weight: 800; line-height: 1.15; word-break: break-word;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.metric .label { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: #64748b; margin-top: .15rem; }

/* ---------- Scrollbar ---------- */
* { scrollbar-width: thin; scrollbar-color: #cbd5e1 transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 9999px; border: 2px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; background-clip: content-box; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* ---------- Admin panel ---------- */
.admin-tab {
  padding: .55rem 1rem; border-radius: .7rem; font-weight: 600; font-size: .9rem;
  color: #475569; cursor: pointer; border: 1px solid transparent; background: transparent;
  transition: background .2s ease, color .2s ease, box-shadow .2s ease;
}
.admin-tab:hover { background: #f1f5f9; }
.admin-tab.is-active {
  background: #eff6ff; color: #1d4ed8;
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, .28);
}
.admin-switch {
  position: relative; flex: 0 0 auto; width: 46px; height: 26px; border-radius: 9999px;
  background: #cbd5e1; cursor: pointer; transition: background .2s ease;
}
.admin-switch::after {
  content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px;
  border-radius: 9999px; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3);
  transition: transform .2s ease;
}
input:checked + .admin-switch { background: #2563eb; }
input:checked + .admin-switch::after { transform: translateX(20px); }

/* SEO manager: category chips, edit drawer and the Google SERP preview. */
.admin-chip {
  padding: .3rem .7rem; border-radius: 9999px; font-weight: 600; font-size: .78rem;
  color: #475569; cursor: pointer; border: 1px solid rgba(15, 23, 42, .12); background: #fff;
  transition: background .2s ease, color .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.admin-chip:hover { border-color: rgba(59, 130, 246, .5); color: #1d4ed8; }
.admin-chip.is-active {
  background: #eff6ff; color: #1d4ed8; border-color: rgba(59, 130, 246, .45);
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, .2);
}
.admin-backdrop {
  position: fixed; inset: 0; z-index: 40; background: rgba(15, 23, 42, .5);
  animation: viewIn .2s ease both;
}
.admin-backdrop.hidden { display: none !important; }
.admin-drawer {
  position: fixed; top: 0; right: 0; z-index: 50; height: 100%; width: 100%; max-width: 34rem;
  overflow-y: auto; background: #fff; border-left: 1px solid #e5e7eb;
  box-shadow: -24px 0 60px -30px rgba(15, 23, 42, .55);
  transform: translateX(102%); transition: transform .3s cubic-bezier(.22, .61, .36, 1);
}
.admin-drawer.is-open { transform: none; }
.serp-card {
  border: 1px solid #e5e7eb; border-radius: .9rem; padding: .85rem 1rem; background: #fff;
}
.serp-url { display: flex; align-items: center; gap: .45rem; font-size: .78rem; color: #334155; }
.serp-favicon {
  display: grid; place-items: center; width: 1.35rem; height: 1.35rem; border-radius: 9999px;
  background: linear-gradient(135deg, #2563eb, #4f46e5); color: #fff; font-size: .68rem; font-weight: 800;
}
.serp-title { color: #1a0dab; font-size: 1.05rem; line-height: 1.35; font-weight: 500; }
.serp-desc { color: #4d5156; font-size: .85rem; line-height: 1.45; }

/* ============================================================
   Dark mode (class-based: `html.dark`)
   ============================================================ */
html { color-scheme: light; }
html.dark { color-scheme: dark; }

body, header, footer, .tool-card, .result-row, .fancy-card, .metric, .input, .btn-secondary, .admin-tab, .nav-link {
  transition: background-color .3s ease, color .3s ease, border-color .3s ease;
}

html.dark body {
  color: #e2e8f0;
  background-color: #070b17;
  background-image:
    radial-gradient(900px 520px at 6% -10%, rgba(79, 70, 229, 0.22), transparent 60%),
    radial-gradient(820px 500px at 102% -4%, rgba(14, 165, 233, 0.16), transparent 55%),
    radial-gradient(760px 520px at 50% 118%, rgba(236, 72, 153, 0.12), transparent 60%);
}
html.dark h1, html.dark h2, html.dark h3, html.dark h4 { color: #e2e8f0; }

/* Component overrides */
html.dark .tool-card { background: rgba(15, 23, 42, .72); border-color: rgba(148, 163, 184, .16); box-shadow: 0 14px 34px -22px rgba(0, 0, 0, .85); }
html.dark .tool-card:hover { border-color: rgba(96, 165, 250, .5); }
html.dark .result-row, html.dark .fancy-card { background: linear-gradient(180deg, #0f172a, #0b1220); border-color: rgba(148, 163, 184, .14); }
/* .result-text carries a hardcoded near-black colour, so without this the generated names
   were #0f172a on the #0f172a row above - 1:1 contrast, i.e. invisible in dark mode. */
html.dark .result-text { color: #e2e8f0; }
html.dark .metric { background: linear-gradient(180deg, rgba(15, 23, 42, .95), rgba(11, 18, 32, .9)); border-color: rgba(148, 163, 184, .14); }
html.dark .metric .label { color: #94a3b8; }
html.dark .input { background: rgba(15, 23, 42, .8); color: #e2e8f0; border-color: rgba(148, 163, 184, .22); }
html.dark .input::placeholder { color: #64748b; }
html.dark .input:hover { border-color: rgba(148, 163, 184, .35); }
html.dark select.input option { background: #0f172a; color: #e2e8f0; }
html.dark .btn-secondary { background: linear-gradient(180deg, #1e293b, #0f172a); color: #e2e8f0; border-color: rgba(148, 163, 184, .24); }
html.dark .btn-secondary:hover { background: #1e293b; border-color: rgba(96, 165, 250, .5); }
html.dark .nav-link { color: #cbd5e1; }
html.dark .nav-link:hover { background: rgba(148, 163, 184, .16); color: #fff; }
html.dark .nav-link.active { color: #93c5fd; background: linear-gradient(135deg, rgba(59, 130, 246, .22), rgba(99, 102, 241, .22)); box-shadow: inset 0 0 0 1px rgba(96, 165, 250, .35); }
html.dark .legal-content h2 { color: #e2e8f0; }
html.dark .legal-content h3 { color: #cbd5e1; }
html.dark .legal-content a { color: #93c5fd; }
html.dark #toast { background: linear-gradient(135deg, #1e293b, #0f172a); }
html.dark .ad-slot[data-debug="1"] { background: rgba(30, 41, 59, .6); border-color: rgba(148, 163, 184, .4); }
html.dark .admin-tab { color: #cbd5e1; }
html.dark .admin-tab:hover { background: #1e293b; }
html.dark .admin-tab.is-active { background: #1e293b; color: #93c5fd; }
html.dark .admin-switch { background: #334155; }
html.dark .admin-chip { background: #0f172a; color: #cbd5e1; border-color: rgba(148, 163, 184, .24); }
html.dark .admin-chip:hover { border-color: rgba(96, 165, 250, .55); color: #93c5fd; }
html.dark .admin-chip.is-active { background: #1e293b; color: #93c5fd; border-color: rgba(96, 165, 250, .45); }
html.dark .admin-drawer { background: #0b1220; border-color: #1e293b; }
html.dark .admin-drawer .btn-secondary { background: linear-gradient(180deg, #1e293b, #0f172a); }
html.dark .serp-card { background: #0f172a; border-color: #1e293b; }
html.dark .serp-url { color: #94a3b8; }
html.dark .serp-url .text-slate-700 { color: #cbd5e1; }
html.dark .serp-title { color: #8ab4f8; }
html.dark .serp-desc { color: #cbd5e1; }

/* Tailwind utility overrides used across the pages */
html.dark .bg-gray-50 { background-color: #070b17; }
html.dark .bg-white { background-color: #0f172a; }
html.dark .bg-white\/90 { background-color: rgba(15, 23, 42, .9); }
html.dark .bg-white\/10 { background-color: rgba(255, 255, 255, .06); }
html.dark .bg-gray-100 { background-color: #1e293b; }
html.dark .bg-slate-900 { background-color: #020617; }
html.dark .border-gray-200 { border-color: #1e293b; }
html.dark .border-slate-700 { border-color: #1e293b; }
html.dark .text-slate-900, html.dark .text-slate-800 { color: #e2e8f0; }
html.dark .text-slate-700 { color: #cbd5e1; }
html.dark .text-slate-600, html.dark .text-slate-500, html.dark .text-slate-400 { color: #94a3b8; }
html.dark .text-blue-600, html.dark .text-blue-700 { color: #93c5fd; }
html.dark .text-red-600 { color: #fca5a5; }
html.dark .text-emerald-700, html.dark .text-emerald-800 { color: #6ee7b7; }
html.dark .bg-emerald-50 { background-color: rgba(16, 185, 129, .12); }
html.dark .border-emerald-200 { border-color: rgba(16, 185, 129, .3); }
html.dark .hover\:text-blue-600:hover, html.dark .hover\:text-blue-700:hover { color: #93c5fd; }
html.dark .hover\:bg-gray-100:hover { background-color: #1e293b; }

html.dark .border-amber-200 { border-color: rgba(251, 191, 36, .3); }
html.dark .bg-amber-50 { background-color: rgba(251, 191, 36, .12); }
html.dark .text-amber-800 { color: #fcd34d; }

/* ============================================================
   Couple Name Combiner (couple-name-combiner.html)
   Page-scoped `cn-` classes: gradients, the range thumb, the
   segmented control, result cards, Love Meter and keyframes.
   Everything colours itself with html.dark, like the rest of
   the site. Structure still comes from Tailwind utilities.
   ============================================================ */

:root {
  --cn-rose: #e11d48;
  --cn-violet: #7c3aed;
  --cn-ring: rgba(225, 29, 72, .35);
}

/* ---------- buttons ---------- */
.cn-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  height: 3rem; padding: 0 1.35rem; border-radius: .9rem;
  font-size: .95rem; font-weight: 600; white-space: nowrap; cursor: pointer;
  border: 1px solid transparent;
  transition: transform .16s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease;
}
.cn-btn:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--cn-ring); }
.cn-btn:active { transform: scale(.97); }

.cn-btn-primary {
  color: #fff;
  background-image: linear-gradient(135deg, var(--cn-rose) 0%, #db2777 45%, var(--cn-violet) 100%);
  box-shadow: 0 16px 34px -16px rgba(190, 24, 93, .75);
}
.cn-btn-primary:hover { transform: translateY(-2px); box-shadow: 0 22px 44px -18px rgba(190, 24, 93, .85); }

.cn-btn-ghost { color: #334155; background: #fff; border-color: rgba(15, 23, 42, .12); }
.cn-btn-ghost:hover { border-color: rgba(225, 29, 72, .45); color: #be123c; }
html.dark .cn-btn-ghost { background: rgba(15, 23, 42, .7); color: #e2e8f0; border-color: rgba(148, 163, 184, .28); }
html.dark .cn-btn-ghost:hover { border-color: rgba(244, 63, 94, .6); color: #fda4af; }

/* ---------- inputs ---------- */
.cn-input {
  width: 100%; height: 3rem; padding: 0 .95rem; border-radius: .9rem;
  border: 1px solid rgba(15, 23, 42, .14); background: #fff; color: #0f172a; font-size: 1rem;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.cn-input::placeholder { color: #94a3b8; }
.cn-input:focus { outline: none; border-color: var(--cn-rose); box-shadow: 0 0 0 4px var(--cn-ring); }
html.dark .cn-input { background: rgba(15, 23, 42, .75); border-color: rgba(148, 163, 184, .28); color: #e2e8f0; }
html.dark .cn-input:focus { border-color: #fb7185; }

/* ---------- blend ratio slider ---------- */
.cn-range { -webkit-appearance: none; appearance: none; width: 100%; height: 1.6rem; background: transparent; cursor: pointer; }
.cn-range::-webkit-slider-runnable-track {
  height: .6rem; border-radius: 9999px;
  background: linear-gradient(90deg, #38bdf8 0%, #a855f7 50%, #fb7185 100%);
}
.cn-range::-moz-range-track {
  height: .6rem; border-radius: 9999px;
  background: linear-gradient(90deg, #38bdf8 0%, #a855f7 50%, #fb7185 100%);
}
.cn-range::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none; margin-top: -.55rem;
  width: 1.7rem; height: 1.7rem; border-radius: 9999px; background: #fff;
  border: 3px solid var(--cn-rose); box-shadow: 0 6px 16px -6px rgba(15, 23, 42, .6);
}
.cn-range::-moz-range-thumb {
  width: 1.4rem; height: 1.4rem; border-radius: 9999px; background: #fff;
  border: 3px solid var(--cn-rose); box-shadow: 0 6px 16px -6px rgba(15, 23, 42, .6);
}
.cn-range:focus-visible { outline: none; }
.cn-range:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 5px var(--cn-ring); }
.cn-range:focus-visible::-moz-range-thumb { box-shadow: 0 0 0 5px var(--cn-ring); }

/* ---------- segmented control (Length) ---------- */
.cn-seg { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .5rem; }
.cn-seg-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.cn-seg-text {
  display: block; padding: .6rem .8rem; border-radius: .85rem; cursor: pointer;
  border: 1px solid rgba(15, 23, 42, .12); background: #fff; color: #334155;
  font-size: .8rem; line-height: 1.3; transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}
.cn-seg-text strong { display: block; font-size: .9rem; font-weight: 700; color: #0f172a; }
.cn-seg-text span { color: #475569; }
.cn-seg-input:checked + .cn-seg-text {
  border-color: rgba(225, 29, 72, .55); background: rgba(244, 63, 94, .09);
  box-shadow: 0 10px 24px -18px rgba(190, 24, 93, .9);
}
.cn-seg-input:checked + .cn-seg-text strong { color: #be123c; }
.cn-seg-input:focus-visible + .cn-seg-text { box-shadow: 0 0 0 4px var(--cn-ring); }
html.dark .cn-seg-text { background: rgba(15, 23, 42, .7); border-color: rgba(148, 163, 184, .28); color: #cbd5e1; }
html.dark .cn-seg-text span { color: #cbd5e1; }
html.dark .cn-seg-text strong { color: #e2e8f0; }
html.dark .cn-seg-input:checked + .cn-seg-text strong { color: #fda4af; }

/* ---------- select ---------- */
.cn-select {
  width: 100%; height: 3rem; padding: 0 .95rem; border-radius: .9rem;
  border: 1px solid rgba(15, 23, 42, .14); background: #fff; color: #0f172a; font-size: .95rem;
}
.cn-select:focus { outline: none; border-color: var(--cn-rose); box-shadow: 0 0 0 4px var(--cn-ring); }
html.dark .cn-select { background: rgba(15, 23, 42, .75); border-color: rgba(148, 163, 184, .28); color: #e2e8f0; }

/* ---------- result cards ---------- */
.cn-card {
  border: 1px solid rgba(15, 23, 42, .10); background: #fff; border-radius: 1rem; padding: 1rem;
  box-shadow: 0 10px 26px -22px rgba(15, 23, 42, .5);
  animation: cnPop .38s cubic-bezier(.22, .61, .36, 1) both;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.cn-card:hover { transform: translateY(-3px); border-color: rgba(244, 63, 94, .4); box-shadow: 0 20px 40px -24px rgba(190, 24, 93, .55); }
html.dark .cn-card { background: rgba(15, 23, 42, .72); border-color: rgba(148, 163, 184, .22); }
html.dark .cn-card:hover { border-color: rgba(244, 63, 94, .5); }

.cn-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .75rem; }
.cn-name { font-size: 1.32rem; font-weight: 800; color: #0f172a; overflow-wrap: anywhere; }
html.dark .cn-name { color: #f1f5f9; }
.cn-meta { margin-top: .2rem; font-size: .72rem; color: #64748b; }
html.dark .cn-meta { color: #94a3b8; }

/* ---------- copy buttons ---------- */
.cn-icon-btn, .cn-copyable {
  display: inline-flex; align-items: center; justify-content: center; gap: .35rem;
  height: 2.2rem; padding: 0 .6rem; border-radius: .7rem; cursor: pointer;
  border: 1px solid rgba(15, 23, 42, .12); background: #fff; color: #475569;
  font-size: .74rem; font-weight: 600; white-space: nowrap;
  transition: border-color .16s ease, color .16s ease, background .16s ease;
}
.cn-icon-btn:hover, .cn-copyable:hover { border-color: rgba(244, 63, 94, .45); color: #be123c; }
.cn-icon-btn:focus-visible, .cn-copyable:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--cn-ring); }
html.dark .cn-icon-btn, html.dark .cn-copyable { background: rgba(15, 23, 42, .7); border-color: rgba(148, 163, 184, .24); color: #cbd5e1; }
html.dark .cn-icon-btn:hover, html.dark .cn-copyable:hover { border-color: rgba(244, 63, 94, .55); color: #fda4af; }

/* ---------- hashtag chips ---------- */
.cn-tags { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .8rem; }
.cn-tag {
  display: inline-flex; align-items: center; gap: .35rem; cursor: pointer;
  border: 1px solid rgba(15, 23, 42, .10); background: #f8fafc; color: #475569;
  border-radius: 9999px; padding: .32rem .62rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .71rem; font-weight: 600;
  transition: border-color .16s ease, color .16s ease, background .16s ease;
}
.cn-tag:hover { border-color: rgba(244, 63, 94, .45); color: #be123c; background: #fff1f2; }
.cn-tag:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--cn-ring); }
html.dark .cn-tag { background: rgba(30, 41, 59, .8); border-color: rgba(148, 163, 184, .24); color: #cbd5e1; }
html.dark .cn-tag:hover { background: rgba(244, 63, 94, .16); color: #fda4af; }

/* ---------- copy feedback: swap the copy icon for a check ---------- */
.cn-ico { width: .95rem; height: .95rem; flex: 0 0 auto; }
[data-copy] .cn-ico:nth-of-type(2), .cn-copyable .cn-ico:nth-of-type(2) { display: none; }
[data-copy].copied .cn-ico:nth-of-type(1), .cn-copyable.copied .cn-ico:nth-of-type(1) { display: none; }
[data-copy].copied .cn-ico:nth-of-type(2), .cn-copyable.copied .cn-ico:nth-of-type(2) { display: block; }
[data-copy].copied, .cn-copyable.copied {
  border-color: rgba(22, 163, 74, .45); color: #16a34a; background: rgba(34, 197, 94, .12);
}

/* ---------- Love Meter ---------- */
.cn-love {
  border-radius: 1.25rem; padding: 1.25rem;
  border: 1px solid rgba(244, 63, 94, .25);
  background-image: linear-gradient(135deg, rgba(244, 63, 94, .12), rgba(168, 85, 247, .12) 55%, rgba(56, 189, 248, .12));
  box-shadow: 0 24px 50px -34px rgba(190, 24, 93, .55);
}
html.dark .cn-love { background-color: rgba(15, 23, 42, .6); border-color: rgba(244, 63, 94, .3); }
.cn-score {
  font-size: 2.5rem; line-height: 1; font-weight: 800; font-variant-numeric: tabular-nums;
  background-image: linear-gradient(135deg, #e11d48, #a855f7);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.cn-love-track { margin-top: 1rem; height: .85rem; border-radius: 9999px; background: rgba(15, 23, 42, .10); overflow: hidden; }
html.dark .cn-love-track { background: rgba(148, 163, 184, .20); }
.cn-love-bar {
  position: relative; height: 100%; width: 0%; border-radius: 9999px; overflow: hidden;
  background-image: linear-gradient(90deg, #fb7185, #a855f7, #38bdf8);
  transition: width .9s cubic-bezier(.22, .61, .36, 1);
}
.cn-love-bar::after {
  content: ''; position: absolute; inset: 0;
  background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, .55), transparent);
  animation: cnShine 2.4s linear infinite;
}

/* ---------- category headers ---------- */
.cn-block-icon {
  display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: .85rem; color: #fff;
  background-image: linear-gradient(135deg, #e11d48, #a855f7);
  box-shadow: 0 12px 26px -14px rgba(190, 24, 93, .8);
}
.cn-block-icon svg { width: 1.25rem; height: 1.25rem; }
.cn-count {
  display: none; align-items: center; justify-content: center;
  min-width: 1.6rem; height: 1.6rem; padding: 0 .45rem; border-radius: 9999px;
  background: rgba(244, 63, 94, .12); color: #be123c; font-size: .75rem; font-weight: 700;
}
.cn-count:not(:empty) { display: inline-flex; }
html.dark .cn-count { background: rgba(244, 63, 94, .2); color: #fda4af; }

.cn-empty { grid-column: 1 / -1; padding: .9rem 0; font-size: .85rem; color: #64748b; }
html.dark .cn-empty { color: #94a3b8; }

/* ---------- animations ---------- */
@keyframes cnPop { from { opacity: 0; transform: translateY(10px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes cnShine { 0% { transform: translateX(-120%); } 60%, 100% { transform: translateX(220%); } }

@media (prefers-reduced-motion: reduce) {
  .cn-card { animation: none; }
  .cn-love-bar { transition: none; }
  .cn-love-bar::after { animation: none; }
}

/* ---------- Print ---------- */
@media print {
  header, footer, .ad-slot, .no-print { display: none !important; }
  body { background: #fff; }
}

/* ---------- Mobile accessibility and scroll behavior ---------- */
:root { --sticky-header-height: 6rem; }
[id] { scroll-margin-top: calc(var(--sticky-header-height) + 16px); }

.lang-switch a,
footer a,
main nav[aria-label="Breadcrumb"] a,
main nav[aria-label="ब्रेडक्रंब"] a,
.related-tool-links > a,
.exam-choice-links > a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

.nav-link,
.nav-menu-item { min-height: 44px; }

.site-brand,
header.sticky #themeToggle { min-height: 44px; }

#mobileMenu > :not([hidden]) ~ :not([hidden]),
#mobileMenu .space-y-1 > :not([hidden]) ~ :not([hidden]) { margin-top: 8px; }

.admin-page .btn-primary,
.admin-page .btn-secondary,
.admin-tab,
.admin-chip {
  min-height: 44px;
}

#viewApp .btn-secondary,
#viewApp .admin-tab { font-size: 1rem; }

.admin-chart-scroll {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-inline: contain;
}

.seo-cards { display: none; }
.seo-card {
  min-width: 0;
  border-top: 1px solid #e5e7eb;
  padding: 1rem;
  overflow-wrap: anywhere;
}
.seo-card:first-child { border-top: 0; }
.seo-card-label { color: #64748b; font-size: .75rem; font-weight: 700; margin-bottom: .25rem; }

@media (max-width: 767px) {
  input, select, textarea { font-size: 16px !important; }
  main button { min-height: 44px; }
  main input[type="range"] { height: 44px; }
  #mobileMenu {
    max-height: calc(100vh - var(--mobile-menu-top, 6rem) - 8px);
    max-height: calc(100dvh - var(--mobile-menu-top, 6rem) - 8px);
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }
  .seo-table-scroll { display: none; }
  .seo-cards { display: block; }
}
