/* StoreCheck.io — Shared Styles */

/* Theme variables */
:root {
  --bg: #fff;
  --bg-secondary: #f8f9fa;
  --bg-hover: #f3f4f6;
  --text: #1a1a1a;
  --text-secondary: #6b7280;
  --text-muted: #9ca3af;
  --text-subtle: #374151;
  --border: #e5e7eb;
  --border-light: #f3f4f6;
  --card-shadow: 0 1px 3px rgba(0,0,0,0.04);
  --accent: #22c55e;
  --accent-hover: #16a34a;
  --btn-disabled-bg: #d1d5db;
  --btn-disabled-color: #9ca3af;
  --spinner-border: #e5e7eb;

  /* Brand palette for hero gradient (deep teal → muted blue) */
  --brand-1: #1f4250;
  --brand-2: #2f6c7e;
  --brand-3: #3e8194;
  --brand-deep: #0f2a33;
  --brand-pill-bg: rgba(255,255,255,0.08);
  --brand-pill-border: rgba(255,255,255,0.12);
  --hero-text-muted: rgba(255,255,255,0.78);
  --hero-text-soft: rgba(255,255,255,0.62);
}

[data-theme="dark"] {
  --bg: #0a0a0a;
  --bg-secondary: #1a1a1a;
  --bg-hover: #222;
  --text: #e5e5e5;
  --text-secondary: #888;
  --text-muted: #666;
  --text-subtle: #ccc;
  --border: #333;
  --border-light: #1a1a1a;
  --card-shadow: none;
  --accent: #22c55e;
  --accent-hover: #16a34a;
  --btn-disabled-bg: #333;
  --btn-disabled-color: #666;
  --spinner-border: #333;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

/* ============================================================
   LEGACY NAV (kept for the eight tool pages we are not redesigning)
   ============================================================ */
nav.legacy-nav,
body:not(.brand-page) > nav {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
body:not(.brand-page) > nav a { color: var(--text-secondary); text-decoration: none; font-size: 0.875rem; transition: color 0.2s; }
body:not(.brand-page) > nav a:hover { color: var(--text); }
body:not(.brand-page) > nav .brand { color: var(--text); font-weight: 700; font-size: 1rem; }
body:not(.brand-page) > nav .brand span { color: var(--accent); }

/* Legacy nav-dropdown (Tools menu used on non-redesigned pages) */
body:not(.brand-page) .nav-dropdown { position: relative; }
body:not(.brand-page) .nav-dropdown-toggle {
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-family: inherit;
  cursor: pointer;
  padding: 0.35rem 0.75rem;
  transition: border-color 0.2s, color 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
body:not(.brand-page) .nav-dropdown-toggle:hover { border-color: var(--accent); color: var(--text); }
body:not(.brand-page) .nav-dropdown-toggle::after { content: '\25BE'; font-size: 0.75em; }
body:not(.brand-page) .nav-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
  min-width: 200px;
  padding: 0.5rem 0;
  z-index: 100;
  flex-direction: column;
}
[data-theme="dark"] body:not(.brand-page) .nav-dropdown-menu { box-shadow: 0 4px 16px rgba(0,0,0,0.4); }
body:not(.brand-page) .nav-dropdown:hover .nav-dropdown-menu { display: flex; }
body:not(.brand-page) .nav-dropdown-menu a {
  display: block;
  padding: 0.45rem 1rem;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  transition: background 0.15s, color 0.15s;
  white-space: nowrap;
}
body:not(.brand-page) .nav-dropdown-menu a:hover { background: var(--bg-hover); color: var(--text); }

/* Legacy theme toggle */
body:not(.brand-page) .theme-toggle {
  margin-left: auto;
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.35rem 0.5rem;
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  color: var(--text-secondary);
  transition: border-color 0.2s, color 0.2s;
}
body:not(.brand-page) .theme-toggle:hover { border-color: var(--accent); color: var(--text); }

/* ============================================================
   NEW BRANDED HERO LAYOUT (homepage, schema, hreflang)
   Body must have class="brand-page"
   ============================================================ */

body.brand-page {
  background: var(--bg);
  display: block;
}

.hero-wrap {
  position: relative;
  width: 100%;
  background:
    radial-gradient(ellipse at top, var(--brand-3) 0%, var(--brand-2) 35%, var(--brand-1) 70%, var(--brand-deep) 100%);
  color: #fff;
  padding: 0 2rem 4rem;
  overflow: hidden;
  min-height: 70vh;
  min-height: 70dvh;
  display: flex;
  flex-direction: column;
}
.hero-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 30%, rgba(255,255,255,0.06), transparent 60%);
  pointer-events: none;
}

.brand-nav {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 1.5rem 0 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

/* Brand name on the left — bigger, prominent */
.brand-name-large {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  line-height: 1;
  transition: opacity 0.15s;
}
.brand-name-large:hover { opacity: 0.92; }
.brand-name-large .check-icon {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(255,255,255,0.16);
  border: 1.5px solid rgba(255,255,255,0.8);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 900;
  color: #fff;
}
.brand-name-large .brand-tld {
  color: rgba(255,255,255,0.65);
  font-weight: 600;
}

/* Brand switcher on the right — prominent pill button */
.brand-switcher { position: relative; }
.brand-switcher-toggle {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.16);
  color: #fff;
  cursor: pointer;
  font-family: inherit;
  padding: 0.55rem 0.95rem;
  border-radius: 999px;
  transition: background 0.15s, border-color 0.15s;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  line-height: 1;
  font-size: 0.9rem;
  font-weight: 600;
}
.brand-switcher-toggle:hover,
.brand-switcher.open .brand-switcher-toggle {
  background: rgba(255,255,255,0.14);
  border-color: rgba(255,255,255,0.28);
}
.brand-switcher-toggle .brand-switcher-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 0 2px rgba(255,255,255,0.08);
}
.brand-switcher-toggle .brand-switcher-arrow {
  font-size: 0.7em;
  color: rgba(255,255,255,0.7);
  margin-left: 0.15rem;
  transition: transform 0.15s;
}
.brand-switcher.open .brand-switcher-toggle .brand-switcher-arrow {
  transform: rotate(180deg);
}

.brand-switcher-menu {
  position: absolute;
  top: calc(100% + 0.6rem);
  right: 0;
  background: #fff;
  color: var(--text);
  border-radius: 12px;
  box-shadow: 0 12px 36px rgba(0,0,0,0.22);
  min-width: 280px;
  padding: 0.5rem;
  display: none;
  z-index: 50;
  text-align: left;
}
.brand-switcher.open .brand-switcher-menu { display: block; }

/* "Discover all StoreChecks" hint — hand-drawn arrow pointing at the switcher */
.switcher-hint {
  position: absolute;
  top: calc(100% + 0.4rem);
  right: 0.5rem;
  z-index: 3;
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  color: #fff;
  pointer-events: none;
  font-family: 'Bradley Hand', 'Caveat', 'Marker Felt', 'Segoe Script', cursive;
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  transform-origin: top right;
  animation: switcherHintBob 3.2s ease-in-out 1.2s infinite;
}
.switcher-hint.dismissed {
  opacity: 0;
  transform: translate(8px, -4px) scale(0.96);
  animation: none;
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.switcher-hint-text {
  white-space: nowrap;
  padding-top: 1.4rem;
  text-shadow: 0 2px 8px rgba(0,0,0,0.45);
}
.switcher-hint-arrow {
  width: 96px;
  height: 64px;
  margin-top: -0.3rem;
  transform: rotate(-2deg);
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.35));
}
.switcher-hint-arrow .hint-line,
.switcher-hint-arrow .hint-head {
  stroke: #fff;
  stroke-width: 2.4;
}
.switcher-hint-arrow .hint-line {
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  animation: switcherHintDraw 0.7s ease-out 0.15s forwards;
}
.switcher-hint-arrow .hint-head {
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  animation: switcherHintDraw 0.25s ease-out 0.75s forwards;
}

@keyframes switcherHintDraw {
  0% { stroke-dashoffset: 100; opacity: 1; }
  100% { stroke-dashoffset: 0; opacity: 1; }
}
@keyframes switcherHintTextIn {
  from { opacity: 0; transform: translateX(-6px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes switcherHintBob {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  50%      { transform: translate(2px, -4px) rotate(-0.6deg); }
}

@media (max-width: 900px) {
  .switcher-hint { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .switcher-hint,
  .switcher-hint-text,
  .switcher-hint-arrow .hint-line,
  .switcher-hint-arrow .hint-head { animation: none; }
  .switcher-hint-text { opacity: 1; }
  .switcher-hint-arrow .hint-line { stroke-dashoffset: 0; }
  .switcher-hint-arrow .hint-head { stroke-dashoffset: 0; opacity: 1; }
}

.brand-switcher-item {
  display: grid;
  grid-template-columns: 14px 1fr auto;
  align-items: center;
  gap: 0.7rem;
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  text-decoration: none;
  color: inherit;
  transition: background 0.12s;
}
.brand-switcher-item:hover { background: var(--bg-hover); }
.brand-switcher-item.disabled { cursor: not-allowed; opacity: 0.6; }
.brand-switcher-item.disabled:hover { background: transparent; }

.brand-switcher-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--text-muted);
}
.brand-switcher-dot.green { background: #22c55e; }
.brand-switcher-dot.blue { background: #3b82f6; }
.brand-switcher-dot.purple { background: #a855f7; }
.brand-switcher-dot.amber { background: #f59e0b; }

.brand-switcher-text {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
}
.brand-switcher-text strong {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
}
.brand-switcher-text span {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 500;
}
.brand-switcher-meta {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: lowercase;
}
.brand-switcher-check {
  color: var(--text-secondary);
  font-weight: 700;
}

/* Hero copy */
.hero-copy {
  text-align: center;
  padding: 5.5rem 0 2rem;
  position: relative;
  z-index: 1;
}
.hero-copy h1 {
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #fff;
  line-height: 1.2;
}
.hero-copy p {
  margin-top: 0.75rem;
  color: var(--hero-text-muted);
  font-size: 0.98rem;
  line-height: 1.6;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

/* Hero card (URL input form, lives on dark hero) */
.hero-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 800px;
  margin: 1.75rem auto auto;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.18);
  overflow: hidden;
  color: var(--text);
}
/* Vertically center hero content (copy + card) within the 100vh hero.
   .brand-nav stays at the top in natural flow. */
.hero-copy { margin-top: auto; }

.hero-tabs {
  display: flex;
  gap: 0.25rem;
  padding: 0.85rem 1rem 0;
  border-bottom: 1px solid var(--border-light);
}
.hero-tab {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0.6rem 0.9rem;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: color 0.15s, border-color 0.15s;
}
.hero-tab.active { color: var(--brand-1); border-bottom-color: var(--brand-1); }
.hero-tab:hover:not(.active) { color: var(--text); }

.hero-form {
  display: flex;
  gap: 0.5rem;
  padding: 1rem;
}
.hero-form input {
  flex: 1;
  padding: 0.85rem 1rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.hero-form input:focus {
  border-color: var(--brand-2);
  box-shadow: 0 0 0 3px rgba(47,108,126,0.15);
}
.hero-form input::placeholder { color: var(--text-muted); }

.hero-form button {
  padding: 0.85rem 1.25rem;
  border-radius: 10px;
  border: none;
  background: var(--brand-1);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.15s;
}
.hero-form button:hover { background: var(--brand-2); }
.hero-form button:disabled { background: var(--btn-disabled-bg); color: var(--btn-disabled-color); cursor: not-allowed; }

.hero-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1rem 0.75rem;
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* Remember-URL checkbox row, sits at the bottom of the hero-card */
.hero-save-url {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0 1rem 1rem;
  font-size: 0.8rem;
  color: var(--text-secondary);
  cursor: pointer;
  user-select: none;
}
.hero-save-url input {
  accent-color: var(--brand-1);
  cursor: pointer;
  width: 14px;
  height: 14px;
  margin: 0;
}
.hero-save-url:hover { color: var(--text); }
.hero-save-url.is-saved {
  color: var(--brand-1);
  font-weight: 500;
}
.hero-meta-left {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

/* ============================================================
   TOOLS LANDING — homepage grid of all validators
   ============================================================ */
body.tools-landing .hero-wrap {
  min-height: auto;
  display: block;
  padding-bottom: 5rem;
}

.tools-landing-intro {
  text-align: center;
  padding: 4rem 0 2rem;
  position: relative;
  z-index: 1;
}
.tools-landing-intro h1 {
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #fff;
  line-height: 1.2;
  max-width: 760px;
  margin: 0 auto;
}
.tools-landing-intro p {
  margin-top: 0.85rem;
  color: var(--hero-text-muted);
  font-size: 1.02rem;
  line-height: 1.6;
  max-width: 660px;
  margin-left: auto;
  margin-right: auto;
}
.tools-landing-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.65);
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  margin-bottom: 1.25rem;
}
.tools-landing-eyebrow .dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 3px rgba(34,197,94,0.2);
}

.tool-grid {
  position: relative;
  z-index: 1;
  max-width: 1160px;
  margin: 1.5rem auto 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.tool-grid-card {
  position: relative;
  background: rgba(255,255,255,0.045);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 14px;
  padding: 1.4rem 1.5rem 1.3rem;
  color: #fff;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  transition: background 0.18s, border-color 0.18s, transform 0.18s;
  overflow: hidden;
}
.tool-grid-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(255,255,255,0.06), rgba(255,255,255,0) 60%);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.18s;
}
.tool-grid-card:hover {
  background: rgba(255,255,255,0.085);
  border-color: rgba(255,255,255,0.28);
  transform: translateY(-2px);
}
.tool-grid-card:hover::before { opacity: 1; }

.tool-grid-card-head {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 0.15rem;
}
.tool-grid-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 0 3px rgba(255,255,255,0.08);
}
.tool-grid-dot.green  { background: #22c55e; }
.tool-grid-dot.blue   { background: #3b82f6; }
.tool-grid-dot.purple { background: #a855f7; }
.tool-grid-dot.amber  { background: #f59e0b; }

.tool-grid-card h2 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.005em;
}
.tool-grid-card-sub {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.5);
  margin-left: auto;
  white-space: nowrap;
  font-weight: 500;
}
.tool-grid-card p {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.74);
  line-height: 1.55;
  flex-grow: 1;
}
.tool-grid-card .tool-grid-cta {
  margin-top: 0.6rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(255,255,255,0.85);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: gap 0.15s, color 0.15s;
}
.tool-grid-card:hover .tool-grid-cta {
  color: #fff;
  gap: 0.55rem;
}

@media (max-width: 980px) {
  .tool-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .tool-grid { grid-template-columns: 1fr; }
  .tools-landing-intro { padding: 2.5rem 0 1.5rem; }
  .tools-landing-intro h1 { font-size: 1.75rem; }
}

/* Examples strip — clean white-area chip row, no icons */
.examples-strip {
  background: #fff;
  padding: 2.25rem 2rem 2.5rem;
}
.examples-strip-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.65rem;
}
.examples-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  font-weight: 700;
  margin-right: 0.5rem;
}
.example-chip {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  color: var(--text-subtle);
  font-size: 0.83rem;
  padding: 0.32rem 0.75rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 500;
  line-height: 1.3;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}
a.example-chip:hover {
  border-color: var(--brand-2);
  color: var(--brand-1);
  background: #fff;
}

/* Hero error / spinner */
.hero-error {
  max-width: 620px;
  margin: 0.75rem auto 0;
  color: #fecaca;
  background: rgba(220,38,38,0.18);
  border: 1px solid rgba(220,38,38,0.35);
  border-radius: 10px;
  padding: 0.55rem 0.9rem;
  text-align: center;
  font-size: 0.85rem;
  position: relative;
  z-index: 1;
  display: none;
}

/* Info strip (3-column white area below hero) */
.info-strip {
  background: #fff;
  padding: 3rem 2rem;
  border-top: 1px solid var(--border-light);
}
.info-strip-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 3rem;
}
.info-col h3 {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.75rem;
}
.info-col p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.65;
}
.info-col a.info-link {
  display: inline-block;
  margin-top: 0.75rem;
  font-size: 0.85rem;
  color: var(--brand-2);
  text-decoration: none;
  font-weight: 600;
}
.info-col a.info-link:hover { text-decoration: underline; }

@media (max-width: 800px) {
  .info-strip-inner { grid-template-columns: 1fr; gap: 2rem; }
  .hero-copy { padding: 3.5rem 0 1rem; }
  .hero-copy h1 { font-size: 1.75rem; }
}

/* ============================================================
   RESULT VIEW (used on schema + hreflang results pages)
   When body has class="result-view" the dark hero is replaced
   by a slim white results header.
   ============================================================ */

body.brand-page.result-view .hero-wrap {
  background: var(--brand-1);
  padding: 1.5rem 2rem;
  min-height: 80px;
  display: block;
}
body.brand-page.result-view .brand-nav {
  padding: 0;
}
body.brand-page.result-view .hero-copy,
body.brand-page.result-view .hero-card,
body.brand-page.result-view .hero-pills,
body.brand-page.result-view .hero-error,
body.brand-page.result-view .switcher-hint { display: none; }

.result-header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  padding: 1.4rem 2rem;
}
.result-header-inner {
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto auto 1fr auto;
  align-items: center;
  gap: 1rem;
  font-size: 0.95rem;
}
.result-header button.icon-btn {
  background: none;
  border: 1px solid var(--border);
  cursor: pointer;
  color: var(--text-secondary);
  font-size: 1.05rem;
  padding: 0.4rem 0.55rem;
  border-radius: 8px;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.result-header button.icon-btn:hover {
  background: var(--bg-hover);
  color: var(--text);
  border-color: var(--text-secondary);
}
.result-header span.icon-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.result-header .result-url {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text);
  word-break: break-all;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.result-header .test-another {
  background: none;
  border: 1px solid var(--border);
  cursor: pointer;
  color: var(--text-secondary);
  font-size: 0.95rem;
  padding: 0.4rem 0.6rem;
  border-radius: 8px;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.result-header .test-another:hover {
  color: var(--brand-1);
  background: var(--bg-hover);
  border-color: var(--text-secondary);
}

/* Result toolbar — quick-jump to another tool with the same URL */
.result-toolbar {
  display: none;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  padding: 0.8rem 2rem;
  position: relative;
}
body.brand-page.result-view .result-toolbar { display: block; }

.result-toolbar-inner {
  max-width: 1180px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 0.9rem;
  flex-wrap: wrap;
}
.result-toolbar-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  flex-shrink: 0;
}
.result-toolbar-chips {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}
.result-toolbar-save {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-left: auto;
  font-size: 0.8rem;
  color: var(--text-secondary);
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  padding-left: 0.5rem;
  border-left: 1px solid var(--border);
}
.result-toolbar-save input {
  accent-color: var(--brand-1);
  cursor: pointer;
  width: 14px;
  height: 14px;
  margin: 0;
}
.result-toolbar-save:hover { color: var(--text); }
.result-toolbar-save.is-saved { color: var(--brand-1); font-weight: 500; }

@media (max-width: 800px) {
  .result-toolbar-save {
    margin-left: 0;
    padding-left: 0;
    border-left: none;
    width: 100%;
    padding-top: 0.5rem;
    border-top: 1px solid var(--border);
  }
}
.result-toolbar-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.4rem 0.85rem;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.83rem;
  color: var(--text-subtle);
  text-decoration: none;
  font-weight: 500;
  transition: border-color 0.15s, color 0.15s, transform 0.15s, background 0.15s;
  white-space: nowrap;
}
.result-toolbar-chip:hover {
  border-color: var(--brand-2);
  color: var(--brand-1);
  transform: translateY(-1px);
}
.result-toolbar-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.result-toolbar-dot.green  { background: #22c55e; }
.result-toolbar-dot.blue   { background: #3b82f6; }
.result-toolbar-dot.purple { background: #a855f7; }
.result-toolbar-dot.amber  { background: #f59e0b; }

@media (max-width: 700px) {
  .result-toolbar { padding: 0.7rem 1rem; }
  .result-toolbar-chips { overflow-x: auto; flex-wrap: nowrap; max-width: 100%; }
  .result-toolbar-chip { flex-shrink: 0; }
}

.result-body {
  background: var(--bg-secondary);
  min-height: calc(100vh - 200px);
  padding: 2rem 2rem 4rem;
}
.result-body-inner {
  max-width: 1180px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Status card (the big summary card at top of results) */
.status-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: start;
  gap: 1rem;
}
.status-icon {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  font-size: 0.95rem;
  flex-shrink: 0;
}
.status-icon.ok { background: #22c55e; }
.status-icon.warn { background: #f59e0b; }
.status-icon.error { background: #ef4444; }
.status-text { display: flex; flex-direction: column; gap: 0.2rem; }
.status-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text);
}
.status-title .source-tag {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: var(--bg-hover);
  color: var(--text-secondary);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
}
.status-meta {
  font-size: 0.8rem;
  color: var(--text-secondary);
}
.status-meta .sep { margin: 0 0.4rem; color: var(--text-muted); }
.status-link {
  font-size: 0.82rem;
  color: var(--brand-2);
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
}
.status-link:hover { text-decoration: underline; }

/* Section card with header */
.section-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}
.section-card-header {
  padding: 0.6rem 1rem;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-secondary);
  background: var(--bg-secondary);
}
.section-card-body { padding: 0.5rem; }

.detail-row {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.65rem 0.75rem;
  border-radius: 8px;
  font-size: 0.85rem;
  color: var(--text);
}
.detail-row + .detail-row { border-top: 1px solid var(--border-light); border-radius: 0; }

.lang-row {
  display: grid;
  grid-template-columns: 80px 1fr auto;
  align-items: center;
  gap: 0.85rem;
  padding: 0.7rem 0.85rem;
  border-radius: 8px;
  font-size: 0.85rem;
}
.lang-row + .lang-row { border-top: 1px solid var(--border-light); border-radius: 0; }
.lang-row .lang-tag {
  background: var(--bg-hover);
  color: var(--text-subtle);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.5rem;
  border-radius: 5px;
  text-align: center;
  width: fit-content;
}
.lang-row .lang-tag.x-default {
  background: rgba(168,85,247,0.1);
  color: #7c3aed;
}
.lang-row .lang-url {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.8rem;
  color: var(--text-subtle);
  word-break: break-all;
}
.lang-row .lang-status {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: #16a34a;
}
.lang-row .lang-status.self { color: var(--text-muted); }
.lang-row .lang-status.error { color: #ef4444; }
.lang-row .lang-status .dot {
  width: 14px; height: 14px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 0.6rem;
  font-weight: 900;
  background: #22c55e;
}
.lang-row .lang-status.self .dot { background: var(--text-muted); }
.lang-row .lang-status.error .dot { background: #ef4444; }

/* Issue row */
.issue-row {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.7rem 0.85rem;
  border-radius: 8px;
}
.issue-row + .issue-row { border-top: 1px solid var(--border-light); border-radius: 0; }
.issue-row.info {
  background: rgba(59,130,246,0.04);
}
.issue-row.warn { background: rgba(245,158,11,0.05); }
.issue-row.error { background: rgba(239,68,68,0.05); }
.issue-row .issue-icon {
  flex-shrink: 0;
  margin-top: 0.1rem;
  font-size: 0.95rem;
}
.issue-row .issue-content { display: flex; flex-direction: column; gap: 0.15rem; min-width: 0; flex: 1; }
.issue-row .issue-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: #1e40af;
  line-height: 1.4;
}
.issue-row.warn .issue-title { color: #92400e; }
.issue-row.error .issue-title { color: #991b1b; }
.issue-row .issue-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.72rem;
  color: var(--text-muted);
}
.issue-row .issue-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Schema-specific result items */
.schema-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1.25rem;
}
.schema-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
}
.schema-card-title {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
}
.source-badge {
  padding: 0.12rem 0.45rem;
  border-radius: 4px;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
}
.source-badge.json-ld { background: rgba(168,85,247,0.12); color: #7c3aed; }
.source-badge.microdata { background: rgba(234,179,8,0.15); color: #a16207; }
.schema-type-list {
  display: flex; flex-wrap: wrap; gap: 0.35rem;
  margin-top: 0.5rem;
}
.type-badge {
  background: rgba(47,108,126,0.1);
  color: var(--brand-1);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
}
.json-preview {
  background: var(--bg-secondary);
  border-radius: 8px;
  padding: 0.7rem 0.85rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.72rem;
  color: var(--text-subtle);
  overflow-x: auto;
  max-height: 200px;
  white-space: pre-wrap;
  word-break: break-word;
  margin-top: 0.5rem;
}

/* Stat summary tiles (compact) */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
}
.stat-tile {
  background: var(--bg-secondary);
  border-radius: 8px;
  padding: 0.65rem 0.5rem;
  text-align: center;
}
.stat-tile .label {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  font-weight: 600;
}
.stat-tile .value {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-top: 0.2rem;
}

@media (max-width: 600px) {
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .lang-row { grid-template-columns: 60px 1fr; }
  .lang-row .lang-status { grid-column: 1 / -1; justify-content: flex-start; }
}

/* ============================================================
   LEGACY shared utilities (used by remaining tool pages)
   ============================================================ */

main {
  width: 100%;
  max-width: 1100px;
  padding: 0 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  margin: 0 auto;
}
body:not(.brand-page) main { padding: 0 2rem; }
body.brand-page main { max-width: none; padding: 0; display: block; }

header {
  padding: 3rem 0 2rem;
  text-align: center;
}
body:not(.brand-page) header h1 {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text);
}
body:not(.brand-page) header h1 span { color: var(--accent); }
body:not(.brand-page) header p {
  margin-top: 0.5rem;
  color: var(--text-secondary);
  font-size: 1rem;
}

.search-box {
  display: flex;
  gap: 0.5rem;
  width: 100%;
  max-width: 720px;
}
.search-box input {
  flex: 1;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-secondary);
  color: var(--text);
  font-size: 1rem;
  outline: none;
  transition: border-color 0.2s;
}
.search-box input:focus { border-color: var(--accent); }
.search-box input::placeholder { color: var(--text-muted); }
.search-box button {
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  border: none;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.2s;
}
.search-box button:hover { background: var(--accent-hover); }
.search-box button:disabled { background: var(--btn-disabled-bg); color: var(--btn-disabled-color); cursor: not-allowed; }

.private-check {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  cursor: pointer;
  user-select: none;
}
.private-check input { accent-color: var(--accent); }

#error {
  margin-top: 1rem;
  color: #ef4444;
  font-size: 0.875rem;
  text-align: center;
}

#result { margin-top: 2rem; width: 100%; }

.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: var(--card-shadow);
}

.summary-row { display: flex; gap: 1rem; flex-wrap: wrap; }
.stat {
  flex: 1;
  min-width: 100px;
  background: var(--bg-secondary);
  border-radius: 8px;
  padding: 0.75rem;
  text-align: center;
}
.stat-label { font-size: 0.75rem; color: var(--text-secondary); text-transform: uppercase; }
.stat-value { font-size: 1.25rem; font-weight: 700; margin-top: 0.25rem; }

.history { margin-top: 2rem; width: 100%; padding-bottom: 3rem; }
.history h3 {
  font-size: 0.875rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.75rem;
}
.history-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.625rem 0.5rem;
  border-bottom: 1px solid var(--border-light);
  font-size: 0.875rem;
  cursor: pointer;
  border-radius: 6px;
  transition: background 0.15s;
}
.history-item:hover { background: var(--bg-secondary); }
.history-url { color: var(--text-subtle); font-family: monospace; font-size: 0.8rem; }
.history-meta { display: flex; gap: 0.75rem; align-items: center; }
.history-time { color: var(--text-muted); font-size: 0.75rem; }

.spinner {
  display: inline-block;
  width: 18px; height: 18px;
  border: 2px solid var(--spinner-border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}
.spinner.dark {
  border-color: rgba(255,255,255,0.4);
  border-top-color: #fff;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================================
   LEGACY footer (kept for any non-brand pages — none ship today)
   ============================================================ */
body:not(.brand-page) footer {
  width: 100%;
  margin-top: auto;
  border-top: 1px solid var(--border);
  background: var(--bg-secondary);
}
body:not(.brand-page) .footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2.5rem 2rem 1.5rem;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 2rem;
}
body:not(.brand-page) .footer-brand a { font-weight: 700; font-size: 1rem; color: var(--text); text-decoration: none; }
body:not(.brand-page) .footer-brand a span { color: var(--accent); }
body:not(.brand-page) .footer-brand p { margin-top: 0.5rem; font-size: 0.85rem; color: var(--text-secondary); line-height: 1.5; }
body:not(.brand-page) .footer-brand p a { color: var(--accent); text-decoration: none; }
body:not(.brand-page) .footer-brand p a:hover { text-decoration: underline; }
body:not(.brand-page) .footer-col { display: flex; flex-direction: column; gap: 0.4rem; }
body:not(.brand-page) .footer-col h4 { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-secondary); margin-bottom: 0.25rem; font-weight: 600; }
body:not(.brand-page) .footer-col a { font-size: 0.85rem; color: var(--text-subtle); text-decoration: none; transition: color 0.2s; }
body:not(.brand-page) .footer-col a:hover { color: var(--accent); }
body:not(.brand-page) .footer-bottom { max-width: 1100px; margin: 0 auto; padding: 1rem 2rem; border-top: 1px solid var(--border); font-size: 0.8rem; color: var(--text-muted); }
body:not(.brand-page) .footer-bottom a { color: var(--accent); text-decoration: none; }
body:not(.brand-page) .footer-bottom a:hover { text-decoration: underline; }

@media (max-width: 600px) {
  body:not(.brand-page) .footer-inner { grid-template-columns: 1fr; gap: 1.5rem; }
}

/* ============================================================
   BRAND FOOTER — matches hero gradient. Used on all brand-page tools.
   ============================================================ */
.brand-footer {
  position: relative;
  width: 100%;
  margin-top: auto;
  background:
    linear-gradient(180deg, var(--brand-1) 0%, var(--brand-deep) 100%);
  color: rgba(255,255,255,0.85);
  overflow: hidden;
}
.brand-footer::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 70% -20%, rgba(255,255,255,0.06), transparent 60%);
  pointer-events: none;
}

.brand-footer-inner {
  position: relative;
  z-index: 1;
  max-width: 1180px;
  margin: 0 auto;
  padding: 4rem 2rem 1.5rem;
  display: grid;
  grid-template-columns: 1.4fr 1.1fr 1.1fr 1fr;
  gap: 3rem;
}

/* Brand column (left) */
.brand-footer-brand { display: flex; flex-direction: column; gap: 1rem; }
.brand-footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 700;
  font-size: 1.1rem;
  color: #fff;
  text-decoration: none;
  line-height: 1;
}
.brand-footer-logo .check-icon {
  width: 18px; height: 18px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  border: 1.5px solid rgba(255,255,255,0.75);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 900;
  color: #fff;
}
.brand-footer-tagline {
  font-size: 0.92rem;
  color: var(--hero-text-muted);
  line-height: 1.55;
  max-width: 320px;
}
.brand-footer-tagline a { color: #fff; text-decoration: none; font-weight: 600; }
.brand-footer-tagline a:hover { text-decoration: underline; }

.brand-footer-meta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
  font-size: 0.75rem;
  color: rgba(255,255,255,0.85);
  width: fit-content;
}
.brand-footer-meta .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 3px rgba(34,197,94,0.18);
}

/* Link columns */
.brand-footer-col h3 {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.55);
  margin-bottom: 1rem;
}
.brand-footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 0;
}
.brand-footer-col a {
  color: rgba(255,255,255,0.82);
  text-decoration: none;
  font-size: 0.88rem;
  line-height: 1.4;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  transition: color 0.15s, transform 0.15s;
}
.brand-footer-col a:hover { color: #fff; transform: translateX(2px); }
.brand-footer-col a .dot-color {
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
  opacity: 0.85;
}
.brand-footer-col a .dot-color.green { background: #22c55e; }
.brand-footer-col a .dot-color.blue { background: #3b82f6; }
.brand-footer-col a .dot-color.purple { background: #a855f7; }
.brand-footer-col a .dot-color.amber { background: #f59e0b; }

/* Bottom row */
.brand-footer-bottom {
  position: relative;
  z-index: 1;
  max-width: 1180px;
  margin: 0 auto;
  padding: 1.25rem 2rem;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.55);
  gap: 1rem;
  flex-wrap: wrap;
}
.brand-footer-bottom a {
  color: rgba(255,255,255,0.72);
  text-decoration: none;
  transition: color 0.15s;
}
.brand-footer-bottom a:hover { color: #fff; }
.brand-footer-bottom-right {
  display: inline-flex;
  align-items: center;
  gap: 1.25rem;
}
.brand-footer-bottom-right .social {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px; height: 28px;
  border-radius: 6px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.7);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.brand-footer-bottom-right .social:hover {
  background: rgba(255,255,255,0.12);
  color: #fff;
  border-color: rgba(255,255,255,0.18);
}

@media (max-width: 900px) {
  .brand-footer-inner { grid-template-columns: 1fr 1fr; gap: 2.5rem; padding-top: 3rem; }
  .brand-footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .brand-footer-inner { grid-template-columns: 1fr; gap: 2rem; }
  .brand-footer-bottom { flex-direction: column; align-items: flex-start; gap: 0.75rem; }
}

/* ============================================================
   SCHEMA RESULTS — Google Rich Results Test style
   ============================================================ */

/* Crawl status bar */
.schema-crawl-status {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.85rem 1.25rem;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  color: #15803d;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
}
.schema-crawl-status.warn {
  color: #92400e;
  background: #fffbeb;
  border-color: #fde68a;
}
.schema-crawl-icon {
  width: 24px; height: 24px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 900;
  color: #fff;
  background: #22c55e;
  flex-shrink: 0;
}
.schema-crawl-status.warn .schema-crawl-icon {
  background: #f59e0b;
}
.schema-crawl-time {
  margin-left: auto;
  font-size: 0.78rem;
  font-weight: 400;
  color: var(--text-muted);
}

/* Empty state */
.schema-empty-state {
  padding: 3rem 1.5rem;
  text-align: center;
  color: var(--text-secondary);
}
.schema-empty-icon {
  font-size: 2.5rem;
  font-weight: 300;
  color: var(--text-muted);
  margin-bottom: 1rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}
.schema-empty-state strong {
  display: block;
  font-size: 1.05rem;
  color: var(--text);
  margin-bottom: 0.5rem;
}
.schema-empty-state p {
  font-size: 0.88rem;
  line-height: 1.6;
  max-width: 480px;
  margin: 0 auto;
}
.schema-empty-link {
  display: inline-block;
  margin-top: 1rem;
  font-size: 0.85rem;
  color: var(--brand-2);
  text-decoration: none;
  font-weight: 600;
}
.schema-empty-link:hover { text-decoration: underline; }

/* Type groups container */
.schema-type-groups {
  padding: 0;
}

/* Expandable type row */
.schema-type-row {
  display: grid;
  grid-template-columns: 28px 1fr auto auto;
  align-items: center;
  gap: 0.75rem;
  padding: 0.9rem 1.15rem;
  cursor: pointer;
  transition: background 0.12s;
  border-bottom: 1px solid var(--border-light);
  user-select: none;
}
.schema-type-row:last-of-type { border-bottom: none; }
.schema-type-row:hover { background: var(--bg-hover); }

.schema-type-icon {
  width: 28px; height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 900;
  color: #fff;
  flex-shrink: 0;
}
.schema-type-icon.ok { background: #22c55e; }
.schema-type-icon.warn { background: #f59e0b; }

.schema-type-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  min-width: 0;
}
.schema-type-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
}

.schema-type-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.15rem;
}
.schema-type-count {
  font-size: 0.8rem;
  color: var(--text-secondary);
  white-space: nowrap;
}
.schema-type-warn {
  font-size: 0.75rem;
  color: #b45309;
  font-weight: 500;
}

.schema-type-chevron {
  font-size: 0.7rem;
  color: var(--text-muted);
  transition: transform 0.2s;
  flex-shrink: 0;
}
.schema-type-row.expanded .schema-type-chevron {
  transform: rotate(180deg);
}

/* Items list (hidden by default, shown on expand) */
.schema-items-list {
  display: none;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-light);
}
.schema-items-list.open { display: block; }

/* Individual item row */
.schema-item-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.7rem 1.15rem 0.7rem 2.75rem;
  cursor: pointer;
  transition: background 0.12s;
  border-bottom: 1px solid var(--border-light);
  user-select: none;
}
.schema-item-row:hover { background: var(--bg-hover); }

.schema-item-icon {
  width: 20px; height: 20px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  font-weight: 900;
  color: #fff;
  flex-shrink: 0;
}
.schema-item-icon.ok { background: #22c55e; }
.schema-item-icon.warn { background: #f59e0b; }

.schema-item-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
}
.schema-item-issue-count {
  font-size: 0.75rem;
  color: #b45309;
  background: rgba(245,158,11,0.1);
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  font-weight: 600;
}
.schema-item-chevron {
  margin-left: auto;
  font-size: 0.65rem;
  color: var(--text-muted);
  transition: transform 0.2s;
  flex-shrink: 0;
}
.schema-item-row.expanded .schema-item-chevron {
  transform: rotate(180deg);
}

/* Item detail panel */
.schema-item-detail {
  display: none;
  padding: 0 1.15rem 0 2.75rem;
  background: var(--bg-secondary);
}
.schema-item-detail.open { display: block; padding-bottom: 0.75rem; }

/* Warning rows within item */
.schema-item-issues {
  margin-bottom: 0.5rem;
}
.schema-warning-row {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: rgba(245,158,11,0.08);
  border: 1px solid rgba(245,158,11,0.18);
  border-radius: 8px;
  font-size: 0.82rem;
  color: #92400e;
  line-height: 1.45;
  margin-bottom: 0.35rem;
}
.schema-warning-icon {
  flex-shrink: 0;
  font-size: 0.85rem;
  margin-top: 0.05rem;
}

/* Property table */
.schema-props-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 0.5rem;
}
.schema-props-table.nested {
  background: transparent;
  border: 1px solid var(--border-light);
  margin: 0.25rem 0 0.35rem;
}
.schema-props-table tr { border-bottom: 1px solid var(--border-light); }
.schema-props-table tr:last-child { border-bottom: none; }

.schema-props-table .prop-key {
  padding: 0.45rem 0.75rem;
  font-weight: 600;
  color: var(--text-secondary);
  font-size: 0.8rem;
  white-space: nowrap;
  vertical-align: top;
  width: 180px;
  background: var(--bg-secondary);
  border-right: 1px solid var(--border-light);
}
.schema-props-table .prop-value {
  padding: 0.45rem 0.75rem;
  color: var(--text);
  word-break: break-word;
  vertical-align: top;
}
.schema-props-table .prop-null,
.schema-props-table .prop-empty {
  color: var(--text-muted);
  font-style: italic;
}
.schema-props-table .prop-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.78rem;
  background: var(--bg-secondary);
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
}
.schema-props-table .prop-link {
  color: var(--brand-2);
  text-decoration: none;
  word-break: break-all;
  font-size: 0.82rem;
}
.schema-props-table .prop-link:hover { text-decoration: underline; }

.schema-props-table .prop-count {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-hover);
  padding: 0.05rem 0.35rem;
  border-radius: 999px;
  margin-left: 0.3rem;
}

/* Expandable nested rows */
.schema-props-table .prop-expandable {
  cursor: pointer;
  transition: background 0.12s;
}
.schema-props-table .prop-expandable:hover { background: var(--bg-hover); }
.schema-props-table .prop-expand-hint {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.schema-props-table .prop-chevron {
  font-size: 0.6rem;
  color: var(--text-muted);
  transition: transform 0.2s;
}
.schema-props-table .prop-expandable.expanded .prop-chevron {
  transform: rotate(180deg);
}

.schema-props-table .prop-nested-row {
  display: none;
}
.schema-props-table .prop-nested-row.open { display: table-row; }
.schema-props-table .prop-nested-row > td {
  padding: 0.35rem 0.75rem;
  background: var(--bg-secondary);
}
.schema-props-table .prop-nested-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 0.3rem 0 0.15rem;
}

.schema-props-table .type-badge.small {
  font-size: 0.68rem;
  padding: 0.1rem 0.4rem;
}

/* ListItem cards (itemListElement rendering) */
.prop-listitems-cell {
  padding: 0 !important;
  background: transparent;
}
.prop-listitems-header {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.55rem 0.75rem;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-light);
}
.schema-list-items {
  display: flex;
  flex-direction: column;
}
.schema-list-card {
  border-bottom: 1px solid var(--border-light);
}
.schema-list-card:last-child { border-bottom: none; }
.schema-list-card-head {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.65rem 0.75rem;
  cursor: pointer;
  transition: background 0.12s;
  user-select: none;
}
.schema-list-card-head:hover { background: var(--bg-hover); }
.schema-list-pos {
  width: 26px; height: 26px;
  border-radius: 6px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-secondary);
  flex-shrink: 0;
}
.schema-list-thumb {
  width: 36px; height: 36px;
  border-radius: 6px;
  object-fit: cover;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  flex-shrink: 0;
}
.schema-list-card-info {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex: 1;
  min-width: 0;
}
.schema-list-card-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.schema-list-chevron {
  font-size: 0.65rem;
  color: var(--text-muted);
  transition: transform 0.2s;
  flex-shrink: 0;
  margin-left: auto;
}
.schema-list-card.expanded .schema-list-chevron {
  transform: rotate(180deg);
}
.schema-list-card-body {
  display: none;
  padding: 0 0.75rem 0.65rem;
}
.schema-list-card-body.open { display: block; }

/* Image thumbnail in property rows */
.prop-image-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.prop-thumb {
  width: 32px; height: 32px;
  border-radius: 4px;
  object-fit: cover;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  flex-shrink: 0;
}

/* Raw JSON toggle within item */
.schema-raw-toggle {
  margin-top: 0.25rem;
}
.schema-raw-toggle > summary {
  cursor: pointer;
  font-size: 0.78rem;
  color: var(--text-secondary);
  padding: 0.3rem 0;
  user-select: none;
}
.schema-raw-toggle > summary:hover { color: var(--text); }

@media (max-width: 700px) {
  .schema-type-row {
    grid-template-columns: 24px 1fr auto;
    gap: 0.5rem;
    padding: 0.75rem 0.85rem;
  }
  .schema-type-meta { display: none; }
  .schema-item-row { padding-left: 1.5rem; }
  .schema-item-detail { padding-left: 1.5rem; }
  .schema-props-table .prop-key { width: 120px; }
}

/* ============================================================
   SERP RICH RESULT PREVIEW
   ============================================================ */

.serp-preview {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}
.serp-preview .section-card-header {
  padding: 0.6rem 1rem;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-secondary);
  background: var(--bg-secondary);
}

.serp-result {
  padding: 1.25rem 1.25rem 1rem;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0 1.25rem;
  font-family: Arial, sans-serif;
}

.serp-main {
  min-width: 0;
}

.serp-url {
  font-size: 0.82rem;
  color: #202124;
  line-height: 1.4;
  margin-bottom: 0.15rem;
}
.serp-url cite {
  color: #4d5156;
  font-style: normal;
  font-size: 0.82rem;
}

.serp-breadcrumbs {
  font-size: 0.82rem;
  color: #4d5156;
  line-height: 1.4;
  margin-bottom: 0.15rem;
}
.serp-breadcrumbs .serp-bc-sep {
  margin: 0 0.15rem;
  color: #70757a;
}

.serp-title {
  font-size: 1.25rem;
  font-weight: 400;
  color: #1a0dab;
  line-height: 1.3;
  margin-bottom: 0.25rem;
  cursor: pointer;
  text-decoration: none;
  display: block;
}
.serp-title:hover {
  text-decoration: underline;
}

.serp-rating {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.82rem;
  color: #70757a;
  line-height: 1.4;
  margin-bottom: 0.15rem;
}
.serp-stars {
  color: #fbbc04;
  font-size: 0.9rem;
  letter-spacing: -0.5px;
}
.serp-rating-value {
  font-weight: 600;
  color: #70757a;
}
.serp-rating-count {
  color: #70757a;
}

.serp-price {
  font-size: 0.82rem;
  color: #202124;
  line-height: 1.4;
  margin-bottom: 0.15rem;
}
.serp-price .serp-price-value {
  font-weight: 600;
}
.serp-price .serp-availability {
  color: #188038;
  font-weight: 500;
}
.serp-price .serp-availability.out-of-stock {
  color: #c5221f;
}
.serp-price .serp-dot {
  margin: 0 0.35rem;
  color: #70757a;
}

.serp-description {
  font-size: 0.87rem;
  color: #4d5156;
  line-height: 1.58;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.serp-thumb {
  width: 92px;
  height: 92px;
  border-radius: 8px;
  object-fit: cover;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  grid-row: 1 / -1;
  align-self: start;
}

.serp-org-logo {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: contain;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  vertical-align: middle;
  margin-right: 0.4rem;
}

/* FAQ accordion */
.serp-faq {
  grid-column: 1 / -1;
  border: 1px solid #dadce0;
  border-radius: 8px;
  margin-top: 0.6rem;
  overflow: hidden;
  font-family: Arial, sans-serif;
}
.serp-faq-q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.7rem 0.85rem;
  font-size: 0.87rem;
  color: #202124;
  cursor: pointer;
  user-select: none;
  border-bottom: 1px solid #dadce0;
  transition: background 0.12s;
}
.serp-faq-q:last-child,
.serp-faq-row:last-child .serp-faq-q {
  border-bottom: none;
}
.serp-faq-row.expanded .serp-faq-q {
  border-bottom: 1px solid #dadce0;
}
.serp-faq-q:hover {
  background: #f8f9fa;
}
.serp-faq-chevron {
  font-size: 0.7rem;
  color: #70757a;
  transition: transform 0.2s;
  flex-shrink: 0;
  margin-left: 0.5rem;
}
.serp-faq-row.expanded .serp-faq-chevron {
  transform: rotate(180deg);
}
.serp-faq-a {
  display: none;
  padding: 0.65rem 0.85rem;
  font-size: 0.82rem;
  color: #4d5156;
  line-height: 1.55;
  background: #f8f9fa;
  border-bottom: 1px solid #dadce0;
}
.serp-faq-row:last-child .serp-faq-a {
  border-bottom: none;
}
.serp-faq-row.expanded .serp-faq-a {
  display: block;
}

@media (max-width: 600px) {
  .serp-result {
    grid-template-columns: 1fr;
  }
  .serp-thumb {
    display: none;
  }
}
