/* InspectMedic marketing — static site for Cloudflare Pages */

:root {
  --bg: #0f1419;
  --surface: #1a222c;
  --text: #e8eef4;
  --muted: #8b9aad;
  --accent: #3d9a8b;
  --accent-dim: #2d7a6e;
  --border: #2a3544;
  --radius: 14px;
  --max: 640px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.wrap {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: clamp(1.25rem, 4vw, 2.5rem);
}

main {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: var(--max);
  margin: 0 auto;
  width: 100%;
}

.badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1rem;
}

/* Hero brand block — the logo image carries the InspectMedic wordmark, so the
   <h1> wraps the image (preserving SEO + screen-reader correctness) and the
   visible text is the logo itself. The image is cropped to a horizontal
   banner aspect so the wordmark fills the frame; no extra rounded corners or
   drop-shadow, because the logo's own dark surround blends with the page
   background and any chrome would re-introduce visible "empty space" around
   the mark. */
h1.brand {
  margin: 0 0 0.85rem;
  line-height: 0;
}

h1.brand img {
  display: block;
  /* Stretch to the same width as the "Why InspectMedic" card below it (the
     <main> column maxes out at --max = 640px, and the .why box uses that
     full width), so the hero banner and the value-prop card share an
     aligned vertical edge. */
  width: 100%;
  height: auto;
}

.lead {
  font-size: 1.05rem;
  color: var(--muted);
  margin: 0 0 1.75rem;
}

/* "Why InspectMedic" copy block — flowing paragraphs styled to read clearly
   on the dark surface without competing with the hero logo for attention. */
.why {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.35rem 1.5rem 1.4rem;
  margin: 0 0 1.75rem;
}

.why h2 {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 0.85rem;
  color: var(--text);
}

.why p {
  margin: 0 0 0.85rem;
  color: var(--muted);
  font-size: 0.97rem;
  line-height: 1.6;
}

.why p:last-child {
  margin-bottom: 0;
}

/* Status paragraph reads as a quiet aside, set off from the value-prop copy. */
.why p.why-status {
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--muted);
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
  margin-bottom: 1.5rem;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.card p + p {
  margin-top: 0.65rem;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1.15rem;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s ease, transform 0.1s ease;
}

.btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.btn-primary {
  background: var(--accent);
  color: #0a0f12;
}

.btn-primary:hover {
  background: var(--accent-dim);
  color: #fff;
  text-decoration: none;
}

.btn-ghost {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  color: var(--text);
  border-color: var(--muted);
  text-decoration: none;
}

footer {
  margin-top: auto;
  padding-top: 2rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--muted);
}

footer a {
  color: var(--muted);
}

footer a:hover {
  color: var(--text);
}

/* ------------------------------------------------------------------
 * Legal / long-form pages (e.g. /privacy)
 * ------------------------------------------------------------------
 * The marketing index uses a narrow 640px max-width which is right for a
 * short hero column but too cramped for paragraph-after-paragraph legal
 * reading. The .legal main column widens slightly and tightens type so a
 * privacy policy / terms page is comfortable to read on iPhone or desktop
 * without re-skinning the rest of the site.
 */
main.legal {
  max-width: 760px;
  display: block;
  padding-top: 1.25rem;
  padding-bottom: 2.5rem;
}

.legal-nav {
  margin: 0 0 1.25rem;
  font-size: 0.9rem;
}

.legal-nav a {
  color: var(--muted);
}

.legal-nav a:hover {
  color: var(--text);
  text-decoration: none;
}

.legal-title {
  font-size: clamp(1.6rem, 2.6vw, 2.1rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.2;
  margin: 0 0 0.35rem;
  color: var(--text);
}

.legal-updated {
  margin: 0 0 1.5rem;
  color: var(--muted);
  font-size: 0.9rem;
}

main.legal h2 {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 2rem 0 0.65rem;
  color: var(--text);
  padding-top: 0.2rem;
  border-top: 1px solid var(--border);
}

/* The first h2 sits directly under the intro; drop its top border so the
   section break does not feel doubled-up with the page-level intro hr. */
main.legal > h2:first-of-type,
main.legal > hr + h2 {
  border-top: none;
  padding-top: 0;
  margin-top: 1.25rem;
}

main.legal h3 {
  font-size: 1rem;
  font-weight: 600;
  margin: 1.3rem 0 0.45rem;
  color: var(--text);
}

main.legal p {
  margin: 0 0 0.9rem;
  color: var(--muted);
  font-size: 0.97rem;
  line-height: 1.65;
}

main.legal p strong,
main.legal li strong {
  color: var(--text);
  font-weight: 600;
}

main.legal a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

main.legal a:hover {
  color: #4fbfac;
}

main.legal ul {
  margin: 0 0 1rem;
  padding-left: 1.2rem;
  color: var(--muted);
  font-size: 0.97rem;
  line-height: 1.65;
}

main.legal li {
  margin-bottom: 0.35rem;
}

main.legal li::marker {
  color: var(--accent-dim);
}

main.legal hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 1.75rem 0;
}

main.legal p.addr {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.85rem 1rem;
  margin: 0.4rem 0 1rem;
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.5;
}

p.legal-disclaimer {
  color: var(--muted);
  font-size: 0.88rem;
  margin-top: 1.25rem;
}

/* Summary table inside the legal page. Horizontal-scrolls on very small
   viewports so long summary copy never breaks the layout. */
.table-wrap {
  width: 100%;
  overflow-x: auto;
  margin: 0 0 1rem;
  border-radius: 12px;
}

table.legal-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  font-size: 0.92rem;
  color: var(--muted);
}

table.legal-table thead {
  background: rgba(255, 255, 255, 0.03);
}

table.legal-table th,
table.legal-table td {
  text-align: left;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
  line-height: 1.5;
}

table.legal-table tbody tr:last-child th,
table.legal-table tbody tr:last-child td {
  border-bottom: none;
}

table.legal-table th {
  color: var(--text);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

table.legal-table td strong {
  color: var(--text);
}
