/* ==========================================================================
   timothysmith.dev: styles.css (v2)
   Light + automatic dark mode via prefers-color-scheme.
   Bold grotesque headlines (Archivo), clean sans body (IBM Plex Sans),
   mono labels (IBM Plex Mono).
   Accent: burnt orange (deliberately deeper than HubSpot's coral).
   Signature: pulsing green availability dot; green stays green in both
   modes because green universally means "online".
   ========================================================================== */

:root {
  color-scheme: light dark;

  /* ---- Light mode (default) ---- */
  --ink:       #22292E;   /* headlines, body text */
  --muted:     #5D686F;   /* secondary text */
  --paper:     #FCFBF9;   /* page background */
  --tint:      #F4F1EC;   /* tinted section background */
  --line:      #E4E0D8;   /* hairlines and borders */
  --accent:    #C14E12;   /* burnt orange: links, CTAs */
  --accent-dk: #9C3F0E;   /* hover state */
  --on-accent: #FFFFFF;   /* text on accent backgrounds */
  --status:    #178A5B;   /* availability green (both modes) */

  /* Type */
  --font-display: "Archivo", sans-serif;
  --font-body:    "IBM Plex Sans", system-ui, sans-serif;
  --font-mono:    "IBM Plex Mono", monospace;

  /* Layout */
  --measure: 60ch;
  --page-max: 920px;
  --space-section: clamp(3.5rem, 9vw, 7rem);
}

/* ---- Dark mode: follows the visitor's system setting ---- */
@media (prefers-color-scheme: dark) {
  :root {
    --ink:       #E9E6E0;
    --muted:     #9AA3A9;
    --paper:     #15181B;
    --tint:      #1D2126;
    --line:      #2C3238;
    --accent:    #F0834A;  /* brighter orange for dark-background contrast */
    --accent-dk: #F79B6B;  /* hover: lighter, not darker, on dark bg */
    --on-accent: #1A0E06;
    --status:    #35B37F;
  }
}

/* ---- Reset & base ---- */
*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  overflow-x: hidden; /* guard: full-bleed tinted section uses 100vw */
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.25rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* height:auto keeps photos in proportion when width/height attributes are set */
img { max-width: 100%; height: auto; display: block; }
sup { font-size: 0.65em; }

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

/* ---- Typography ---- */
h1, h2, h3 {
  font-family: var(--font-display);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
}

h1 { font-weight: 900; font-size: clamp(2.4rem, 7vw, 4.25rem); }
h2 { font-weight: 800; font-size: clamp(1.8rem, 4.5vw, 2.75rem); }
h3 { font-weight: 700; font-size: 1.25rem; letter-spacing: -0.01em; }

p { margin: 0 0 1em; max-width: var(--measure); }

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-dk); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 1.1rem;      /* section labels (About, FAQ...): large enough to spot easily */
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 1rem;
}

.disclosure {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: var(--muted);
  max-width: none;
}

/* ---- Buttons ---- */
.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.0625rem;
  color: var(--on-accent);
  background: var(--accent);
  padding: 0.85rem 1.75rem;
  border-radius: 999px;
  text-decoration: none;
  transition: background 0.15s ease;
}
.btn:hover { background: var(--accent-dk); color: var(--on-accent); }
.btn-small { padding: 0.55rem 1.2rem; font-size: 1rem; }
.btn-large { padding: 1rem 2.25rem; font-size: 1.2rem; }
.btn-ghost {
  background: transparent;
  color: var(--accent);
  border: 1.5px solid var(--accent);
}
.btn-ghost:hover { background: var(--accent); color: var(--on-accent); }

/* ---- Layout shell ---- */
.site-header, main, .site-footer {
  width: min(var(--page-max), 100% - 2.5rem);
  margin-inline: auto;
}

/* Anchor links (What I do, Clients, FAQ) land below the sticky header */
html { scroll-padding-top: 5rem; }

.section { padding-block: var(--space-section) 0; }

/* ---- Header (sticky: stays at the top while scrolling) ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding-block: 0.9rem;
  /* Full-width background so page content doesn't show beside the header
     when scrolling; the inner content still lines up with the page column. */
  width: 100%;
  padding-inline: max(1.25rem, (100% - var(--page-max)) / 2);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.wordmark {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-decoration: none;
  margin-right: auto;
}
.wordmark-dot { color: var(--accent); }

.site-nav { display: flex; gap: 1.25rem; }
.site-nav a {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  color: var(--muted);
  text-decoration: none;
}
.site-nav a:hover { color: var(--ink); }

/* ---- Hero: text + portrait ---- */
.hero {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
  padding-block: clamp(1.5rem, 3.5vw, 2.5rem) 0; /* tighter top gap under the header */
}

.status-line {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.5rem;
}

/* Signature: pulsing availability dot */
.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--status);
  position: relative;
}
.status-dot::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1.5px solid var(--status);
  opacity: 0;
  animation: pulse 2.4s ease-out infinite;
}
@keyframes pulse {
  0%   { transform: scale(0.6); opacity: 0.8; }
  70%  { transform: scale(1.4); opacity: 0; }
  100% { transform: scale(1.4); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .status-dot::after { animation: none; }
}

.hero-sub {
  font-size: clamp(1.3rem, 2.6vw, 1.55rem);
  font-weight: 600;
  margin-top: 1.25rem;
}

.hero-context { color: var(--muted); }

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.25rem 1.75rem;
  margin-top: 1.75rem;
}

/* Short line under the Book a call buttons explaining what the call is */
.cta-note { font-size: 1rem; color: var(--muted); margin: 0.9rem 0 0; }
.final-cta .cta-note { margin-top: 1rem; }

/* ---- Social links (icon + label) ---- */
.social-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.1rem;
  flex-wrap: wrap;
}
.social-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--muted);
  text-decoration: none;
  /* generous tap target for mobile */
  padding: 0.35rem 0.1rem;
}
.social-links a:hover { color: var(--accent); }
.social-links svg { flex-shrink: 0; }

.about .social-links { margin-top: 1.5rem; }

/* ---- Photos ---- */
.photo-placeholder {
  aspect-ratio: 4 / 5;
  width: 100%;
  border-radius: 14px;
  background: var(--tint);
  border: 1px dashed var(--line);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 3rem;
  color: var(--line);
}
/* Keep the hero portrait modest: the headline is the star, not the photo */
.hero-photo {
  width: clamp(200px, 24vw, 250px);
  align-self: start;
  margin-top: 0.4rem; /* lines the photo's top up with the H1 */
}
.hero-text { min-width: 0; } /* stops long content from widening the grid */

.hero-photo img, .about-photo img {
  width: 100%;
  border-radius: 14px;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

/* ---- Platform bar ---- */
.platform-bar {
  margin-top: var(--space-section);
  padding-block: 1.5rem 1.1rem;
  border-block: 1px solid var(--line);
}
.platform-row {
  display: flex;
  align-items: baseline;
  gap: 2rem;
  flex-wrap: wrap;
}
.platform-row .eyebrow { margin: 0; color: var(--muted); }
.platform-row ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.75rem;
  flex-wrap: wrap;
}
.platform-row li {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: -0.01em;
  color: var(--muted);
}
.platform-row li a {
  color: inherit;
  text-decoration: none;
}
.platform-row li a:hover { color: var(--accent); }
.platform-row sup { color: var(--accent); }
.platform-bar .disclosure { margin: 0.9rem 0 0; }

/* ---- Stats ---- */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  padding-block: var(--space-section) 0;
}
.stat { display: flex; flex-direction: column; gap: 0.35rem; }
.stat-number {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2rem, 5vw, 3rem);
  letter-spacing: -0.02em;
}
.stat-label {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

/* ---- Services ---- */
.services {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  margin-top: 2.5rem;
}
.service p { font-size: 1.125rem; color: var(--muted); }
.section-cta { margin-top: 2.5rem; }

/* ---- Testimonials (full-bleed tinted band) ---- */
.section-tinted {
  background: var(--tint);
  width: 100vw;
  margin-left: calc(50% - 50vw);
  padding-inline: calc(50vw - min(var(--page-max), 100vw - 2.5rem) / 2);
  padding-block: var(--space-section);
  margin-top: var(--space-section);
}

.quotes {
  display: grid;
  gap: 2.25rem;
  margin-top: 2.25rem;
}
.quote { margin: 0; border-left: 3px solid var(--accent); padding-left: 1.4rem; }
.quote blockquote { margin: 0; }
.quote blockquote p {
  font-style: italic;
  font-size: 1.25rem;
  max-width: 62ch;
}
.quote figcaption {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

/* ---- About ---- */
.about {
  display: grid;
  grid-template-columns: 1.7fr 1fr;
  gap: 3rem;
  align-items: start;
}
.about-text { min-width: 0; } /* stops long content from widening the grid */

/* ---- FAQ ---- */
.faq-item {
  border-bottom: 1px solid var(--line);
  padding-block: 1.1rem;
}
.faq-item:first-of-type { border-top: 1px solid var(--line); margin-top: 2rem; }

.faq-item summary {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.2rem;
  line-height: 1.35;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  /* comfortable tap target */
  padding-block: 0.2rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-family: var(--font-mono);
  font-size: 1.3rem;
  color: var(--accent);
  flex-shrink: 0;
  transition: transform 0.2s ease;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p { margin-top: 1rem; color: var(--muted); }

/* ---- Final CTA ---- */
.final-cta {
  text-align: center;
  padding-block: var(--space-section);
  /* keep clear of a future chat widget in the bottom-right corner */
}
.final-cta p { margin-inline: auto; color: var(--muted); }
.final-cta .btn { margin-top: 1rem; }

/* ---- Footer ---- */
.site-footer {
  border-top: 1px solid var(--line);
  padding-block: 2rem 3rem;
}
.footer-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1rem;
}
.site-footer .footer-row p {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--muted);
  margin: 0;
}

/* ==========================================================================
   Responsive: mobile-first polish
   ========================================================================== */
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; }
  .hero-photo { width: 160px; margin-top: 0; } /* small portrait on phones and tablets */
  .about { grid-template-columns: 1fr; }
  .about-photo { max-width: 280px; }
}

@media (max-width: 700px) {
  body { font-size: 1.125rem; }

  .site-nav { display: none; } /* keep header minimal on small screens */

  .stats { grid-template-columns: 1fr; gap: 1.5rem; }
  .services { grid-template-columns: 1fr; gap: 2rem; }

  .hero-actions { gap: 1rem; }
  .hero-actions .btn { width: 100%; text-align: center; }

  .platform-row { gap: 0.9rem; flex-direction: column; }
  .platform-row ul { gap: 1.1rem 1.5rem; }
  .platform-row li { font-size: 1.1rem; }

  .quote blockquote p { font-size: 1.15rem; }

  .final-cta .btn { width: 100%; }
  .footer-row { flex-direction: column; }
}
