/* Launch Readiness Checker (/tools/launch-checker). Uses the site's tokens,
   so light and dark themes come for free. */

.lc-hero {
  position: relative;
  padding-block: 40px 52px;
  border-bottom: 1px solid var(--border);
  background:
    radial-gradient(900px 320px at 50% -60px, var(--accent-soft), transparent 70%),
    var(--bg);
  text-align: center;
}
.lc-crumbs { font-size: var(--step--1); color: var(--text-faint); margin-bottom: 18px; text-align: left; }
.lc-crumbs a { color: var(--text-muted); }
.lc-title { font-size: clamp(2rem, 5vw, 3.1rem); line-height: 1.1; letter-spacing: -0.02em; margin: 6px 0 14px; }
.lc-lead { max-width: 640px; margin: 0 auto; }

.lc-form { margin: 30px auto 0; max-width: 720px; }
.lc-form__row {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 8px 8px 16px;
  background: var(--surface);
  border: 1.5px solid var(--border-strong, var(--border));
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-lg);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.lc-form__row:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft), var(--shadow-lg); }
.lc-form__icon { width: 22px; height: 22px; flex: none; color: var(--text-faint); }
.lc-form .lc-form__input,
.lc-form .lc-form__input:focus {
  flex: 1; min-width: 0; width: auto; border: 0; outline: 0; box-shadow: none; background: transparent;
  font: inherit; font-size: 1.125rem; color: var(--text); padding: 10px 4px; border-radius: 0;
}
.lc-form__input::placeholder { color: var(--text-faint); }
.lc-form__btn { flex: none; }
.lc-form__error { margin: 12px 0 0; color: var(--danger); font-weight: 600; font-size: var(--step--1); }
.lc-form__facts { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 22px; list-style: none; padding: 0; margin: 16px 0 0; font-size: var(--step--1); color: var(--text-muted); }
.lc-form__facts li::before { content: "\2713"; color: var(--success); font-weight: 700; margin-right: 6px; }

@media (max-width: 560px) {
  .lc-form__row { flex-wrap: wrap; border-radius: var(--radius); padding: 10px; }
  .lc-form__icon { display: none; }
  .lc-form__input { flex-basis: 100%; padding: 8px 6px; }
  .lc-form__btn { width: 100%; }
}

/* ---------- results ---------- */
.lc-results-wrap { padding-block: 36px 8px; scroll-margin-top: 72px; }
.lc-loading { display: flex; align-items: center; gap: 16px; padding: 22px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.lc-loading__title { margin: 0; font-weight: 700; word-break: break-all; }
.lc-loading__step { margin: 2px 0 0; color: var(--text-muted); font-size: var(--step--1); }
.lc-spinner { width: 34px; height: 34px; flex: none; border: 3px solid var(--border); border-top-color: var(--accent); border-radius: 50%; animation: lc-spin .8s linear infinite; }
@keyframes lc-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .lc-spinner { animation-duration: 2.4s; } }

.lc-summary {
  display: grid; grid-template-columns: auto 1fr; gap: 24px; align-items: center;
  padding: 24px; border: 1px solid var(--border); border-radius: var(--radius-lg);
  background: var(--surface); box-shadow: var(--shadow);
}
.lc-ring { position: relative; width: 120px; height: 120px; }
.lc-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.lc-ring__track { fill: none; stroke: var(--border); stroke-width: 10; }
.lc-ring__bar { fill: none; stroke-width: 10; stroke-linecap: round; transition: stroke-dashoffset .9s ease; }
.lc-ring__num { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--font-display); font-size: 2.1rem; font-weight: 700; }
.lc-ring__num small { display: block; font-size: .75rem; font-weight: 600; color: var(--text-faint); margin-top: -6px; text-align: center; }
.lc-grade { margin: 0; font-family: var(--font-display); font-size: var(--step-2); font-weight: 700; line-height: 1.2; }
.lc-url { margin: 4px 0 12px; color: var(--text-muted); font-size: var(--step--1); word-break: break-all; }
.lc-tally { display: flex; flex-wrap: wrap; gap: 8px; }
.lc-tally span { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: var(--radius-pill); font-size: var(--step--1); font-weight: 600; }
.lc-tally .is-pass { background: var(--success-soft); color: var(--success); }
.lc-tally .is-warn { background: var(--warn-soft); color: var(--warn); }
.lc-tally .is-fail { background: var(--danger-soft); color: var(--danger); }
.lc-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
@media (max-width: 560px) {
  .lc-summary { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .lc-tally, .lc-actions { justify-content: center; }
}

.lc-previews { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 18px; }
@media (max-width: 760px) { .lc-previews { grid-template-columns: 1fr; } }
.lc-preview { padding: 18px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); min-width: 0; }
.lc-preview__label { margin: 0 0 12px; font-size: .6875rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--text-faint); }

/* Google-style result. Fixed light colours, like the real thing. */
.lc-serp { background: #fff; color: #202124; border-radius: 10px; padding: 14px; font-family: Arial, Helvetica, sans-serif; border: 1px solid #ececec; }
.lc-serp__site { display: flex; align-items: center; gap: 10px; }
.lc-serp__fav { width: 28px; height: 28px; border-radius: 50%; background: #f1f3f4; display: grid; place-items: center; overflow: hidden; flex: none; border: 1px solid #e3e3e3; }
.lc-serp__fav img { width: 18px; height: 18px; object-fit: contain; }
.lc-serp__fav svg { width: 16px; height: 16px; color: #70757a; }
.lc-serp__name { font-size: 14px; line-height: 1.3; color: #202124; }
.lc-serp__crumb { font-size: 12px; color: #4d5156; word-break: break-all; }
.lc-serp__title { margin: 8px 0 4px; font-size: 20px; line-height: 1.3; color: #1a0dab; font-weight: 400; overflow-wrap: anywhere; }
.lc-serp__desc { margin: 0; font-size: 14px; line-height: 1.58; color: #4d5156; overflow-wrap: anywhere; }

/* Share card */
.lc-share { border: 1px solid #dfe3e8; border-radius: 12px; overflow: hidden; background: #fff; color: #0f1419; font-family: -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }
.lc-share__img { aspect-ratio: 1.91 / 1; background: #eef1f4; display: grid; place-items: center; overflow: hidden; }
.lc-share__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lc-share__noimg { padding: 12px; text-align: center; font-size: 13px; color: #8b98a5; }
.lc-share__body { padding: 10px 12px 12px; border-top: 1px solid #eef1f4; }
.lc-share__domain { margin: 0; font-size: 12px; color: #536471; text-transform: lowercase; }
.lc-share__title { margin: 2px 0 2px; font-size: 15px; font-weight: 700; line-height: 1.3; overflow-wrap: anywhere; }
.lc-share__desc { margin: 0; font-size: 13px; line-height: 1.4; color: #536471; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* Sections and checks */
.lc-section { margin-top: 18px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.lc-section > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 12px; padding: 16px 18px; }
.lc-section > summary::-webkit-details-marker { display: none; }
.lc-section > summary::after { content: ""; width: 9px; height: 9px; margin-left: auto; flex: none; border-right: 2px solid var(--text-faint); border-bottom: 2px solid var(--text-faint); transform: rotate(45deg); transition: transform .15s ease; }
.lc-section[open] > summary::after { transform: rotate(-135deg); }
.lc-section__title { margin: 0; font-size: var(--step-1); font-weight: 700; }
.lc-section__intro { margin: 2px 0 0; font-size: var(--step--1); color: var(--text-muted); }
.lc-section__badges { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.lc-section__badges span { font-size: .75rem; font-weight: 700; padding: 2px 9px; border-radius: var(--radius-pill); }
@media (max-width: 560px) { .lc-section > summary { flex-wrap: wrap; } .lc-section__badges { justify-content: flex-start; } }

.lc-check { display: grid; grid-template-columns: 26px 1fr; gap: 12px; padding: 14px 18px; border-top: 1px solid var(--border); }
.lc-check__icon { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 800; color: #fff; margin-top: 1px; }
.lc-check--pass .lc-check__icon { background: var(--success); }
.lc-check--warn .lc-check__icon { background: var(--warn); }
.lc-check--fail .lc-check__icon { background: var(--danger); }
.lc-check--info .lc-check__icon { background: var(--text-faint); }
.lc-check__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.lc-check__label { margin: 0; font-weight: 700; }
.lc-check__value { font-size: var(--step--1); color: var(--text-muted); overflow-wrap: anywhere; }
.lc-check__detail { margin: 4px 0 0; font-size: var(--step--1); color: var(--text-muted); line-height: 1.6; overflow-wrap: anywhere; }
.lc-check__fix { margin: 8px 0 0; padding: 9px 12px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: var(--step--1); line-height: 1.6; overflow-wrap: anywhere; }
.lc-check__fix strong { color: var(--text); }
.lc-checked-at { margin: 14px 2px 0; font-size: .8125rem; color: var(--text-faint); }

/* ---------- content ---------- */
.lc-content { padding-block: 44px 20px; }
.lc-block { margin-bottom: 52px; }
.lc-block > h2 { font-size: var(--step-3); margin-bottom: 12px; }
.lc-block > p { color: var(--text-muted); line-height: 1.75; }
.lc-muted { color: var(--text-muted); }
.lc-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 20px; }
@media (max-width: 640px) { .lc-cards { grid-template-columns: 1fr; } }
.lc-card { padding: 20px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.lc-card h3 { font-size: var(--step-1); margin: 0 0 6px; }
.lc-card p { margin: 0 0 10px; color: var(--text-muted); font-size: var(--step--1); }
.lc-card ul { margin: 0; padding-left: 18px; font-size: var(--step--1); line-height: 1.8; }
.lc-steps { counter-reset: lc; list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 14px; }
.lc-steps li { counter-increment: lc; position: relative; padding: 16px 18px 16px 62px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); line-height: 1.65; color: var(--text-muted); }
.lc-steps li strong { color: var(--text); }
.lc-steps li::before { content: counter(lc); position: absolute; left: 18px; top: 15px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font-weight: 700; }
.lc-block.prose ul { padding-left: 20px; margin-top: 12px; }
.lc-block.prose li { margin-bottom: 6px; }
.lc-code-title { font-size: var(--step-0); margin: 22px 0 8px; }
.lc-code { margin: 0; padding: 16px 18px; border-radius: var(--radius); background: #0f1320; color: #dfe4f2; font-family: var(--font-mono); font-size: .8125rem; line-height: 1.65; overflow-x: auto; border: 1px solid var(--border); }
.lc-code code { font-size: inherit; background: none; color: inherit; }
.lc-cta { text-align: center; padding: 36px 20px; margin-bottom: 40px; border-radius: var(--radius-lg); background: var(--accent-soft); }
.lc-cta h2 { font-size: var(--step-2); margin-bottom: 6px; }
.lc-cta p { color: var(--text-muted); margin: 0 0 16px; }
