/* A Lighter Workday: site styles.
   Palette: change the custom properties below to restyle the whole site. */
:root {
  --bg: #FAFAF7;
  --surface: #FFFFFF;
  --text: #1F2933;
  --muted: #52606D;
  --accent: #0369A1;
  --accent-hover: #075985;
  --accent-text: #FFFFFF;
  --border: #E4E7EB;
  --focus: #0369A1;
  --error: #B42318;
  --radius: 10px;

  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --measure: 40rem;
  --wide: 52rem;
  --space: 1.25rem;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121619;
    --surface: #1B2126;
    --text: #E8EBEE;
    --muted: #A9B4BF;
    --accent: #7CC4F0;
    --accent-hover: #A5D8F7;
    --accent-text: #0B1B26;
    --border: #2E363D;
    --focus: #A5D8F7;
    --error: #FF9C94;
  }
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  overflow-wrap: break-word;
}

h1, h2, h3 { line-height: 1.25; margin: 0 0 0.75rem; font-weight: 700; }
h1 { font-size: clamp(1.75rem, 6vw + 0.5rem, 2.6rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.35rem, 2vw + 0.9rem, 1.75rem); }
h3 { font-size: 1.1rem; }
p { margin: 0 0 1rem; }
ul, ol { margin: 0 0 1rem; padding-left: 1.25rem; }
li { margin-bottom: 0.5rem; }
img { max-width: 100%; height: auto; display: block; }

a { color: var(--accent); text-decoration: underline; text-underline-offset: 0.15em; }
a:hover { color: var(--accent-hover); }

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

/* Layout */
.wrap { width: 100%; max-width: var(--measure); margin: 0 auto; padding: 0 var(--space); }
.wrap-wide { max-width: var(--wide); }

.section { padding: 2.5rem 0; border-top: 1px solid var(--border); }

/* Skip link */
.skip-link {
  position: absolute;
  left: 0.75rem;
  top: -4rem;
  z-index: 10;
  padding: 0.75rem 1rem;
  background: var(--accent);
  color: var(--accent-text);
  border-radius: var(--radius);
  font-weight: 600;
}
.skip-link:focus { top: 0.75rem; color: var(--accent-text); }

/* Header */
.site-header { border-bottom: 1px solid var(--border); }
.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  column-gap: 1rem;
  max-width: var(--wide);
}
.brand,
.header-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.brand { color: var(--text); font-weight: 700; text-decoration: none; }
.brand:hover { color: var(--text); }
.header-nav { display: flex; flex-wrap: wrap; column-gap: 1rem; }
.header-nav a { font-size: 0.95rem; }

/* Hero */
.hero { padding: 1.5rem 0 2rem; }
.eyebrow {
  margin-bottom: 0.5rem;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.subhead { font-size: 1.1rem; }
.lead { font-size: 1.15rem; }
.jump-link { display: inline-flex; align-items: center; min-height: 44px; }

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.75rem 1.25rem;
  border: 2px solid var(--accent);
  border-radius: var(--radius);
  font: inherit;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}
.button-primary { background: var(--accent); color: var(--accent-text); }
.button-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-text); }
.button-secondary { background: transparent; color: var(--accent); }
.button-secondary:hover { color: var(--accent-hover); border-color: var(--accent-hover); }
.button[disabled] { cursor: not-allowed; }

/* Signup form (static preview and MailerLite embed) */
.signup {
  margin-top: 1.25rem;
  padding: 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.signup-form label { font-weight: 600; }
.signup-form input[type="email"] {
  display: block;
  width: 100%;
  min-height: 48px;
  margin: 0.35rem 0 0.75rem;
  padding: 0.6rem 0.8rem;
  font: inherit;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--muted);
  border-radius: var(--radius);
}
.consent {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  margin-bottom: 0.85rem;
  font-size: 0.875rem;
  line-height: 1.45;
}
.consent input {
  flex: none;
  width: 1.25rem;
  height: 1.25rem;
  margin: 0.1rem 0 0;
  accent-color: var(--accent);
}
.signup-form label.consent { font-weight: 400; }
.signup-form .button { width: 100%; }
.note { margin: 0.75rem 0 0; color: var(--muted); font-size: 0.875rem; line-height: 1.5; }

/* MailerLite embed. MailerLite's own stylesheet is not used, so these rules
   style its markup (.ml-form-embedContainer and friends) without !important. */
.signup .ml-form-embedContainer,
.signup .ml-form-embedWrapper,
.signup .ml-form-embedBody { width: 100%; margin: 0; padding: 0; }
.signup .ml-form-checkboxRow { margin-bottom: 0.85rem; }
.signup .ml-form-embedSubmit .button { width: 100%; }
.signup .ml-form-successContent p { margin: 0; font-weight: 600; }
.ml-form-embedSubmitLoad {
  display: inline-block;
  width: 1.25rem;
  height: 1.25rem;
  border: 3px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: ml-spin 1.2s linear infinite;
}
@keyframes ml-spin { to { transform: rotate(360deg); } }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
/* Validation errors from MailerLite: thicker border and outline, not colour alone. */
.signup .ml-error input[type="email"] { border: 2px solid var(--error); }
.signup .ml-form-checkboxRow.ml-error input { outline: 2px solid var(--error); outline-offset: 2px; }
.signup .ml-form-checkboxRow.ml-error .label-description { color: var(--error); }

/* Cards and lists */
.items { list-style: none; padding: 0; margin: 0; display: grid; gap: 1rem; }
.items li {
  margin: 0;
  padding: 1rem 1.1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.items h3 { margin-bottom: 0.35rem; }
.items p { margin: 0; }

.fit { display: grid; gap: 1.5rem; }
.fit h3 { font-size: 1.15rem; }
.fit ul { margin: 0; }

.chapters li { padding-left: 0.25rem; }

/* Book version options */
.options { display: grid; gap: 1rem; margin-bottom: 1.25rem; }
.option {
  display: flex;
  flex-direction: column;
  padding: 1.25rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.option h3 { margin-bottom: 0.25rem; }
.price { font-size: 1.75rem; font-weight: 700; margin-bottom: 0.5rem; }
.option .button { margin-top: auto; width: 100%; }
.small { color: var(--muted); font-size: 0.9rem; }
.small strong { color: var(--text); }

/* Printables */
.signup-intro { margin-bottom: 0.75rem; font-weight: 600; }
.printables { list-style: none; padding: 0; margin: 0 0 1.25rem; display: grid; gap: 1rem; }
.printable {
  display: grid;
  grid-template-columns: 6rem 1fr;
  gap: 1rem;
  align-items: start;
  margin: 0;
  padding: 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.printable img { width: 100%; height: auto; border-radius: 6px; border: 1px solid var(--border); }
.printable h3 { margin-bottom: 0.35rem; }
.printable p { margin-bottom: 0.75rem; }
.downloads { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0; }
.downloads .button { min-height: 44px; padding: 0.5rem 0.9rem; font-size: 0.95rem; }

/* FAQ */
.faq details { border-bottom: 1px solid var(--border); }
.faq details:first-of-type { border-top: 1px solid var(--border); }
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 48px;
  padding: 0.6rem 0;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+" / "";
  flex: none;
  font-size: 1.35rem;
  line-height: 1;
  color: var(--accent);
}
.faq details[open] summary::after { content: "\2212" / ""; }
.faq details p { margin: 0 0 1rem; }

/* Footer */
.site-footer {
  padding: 2rem 0 2.5rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.95rem;
}
.footer-links {
  list-style: none;
  padding: 0;
  margin: 0 0 0.75rem;
  display: flex;
  flex-wrap: wrap;
  column-gap: 1rem;
}
.footer-links li { margin: 0; }
.footer-links li + li::before { content: "·" / ""; margin-right: 1rem; }
.footer-links a,
.site-footer .contact a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.footer-links a { color: var(--accent); }

/* Page-level text (privacy, 404) */
.page { padding: 2rem 0 3rem; }
.page h2 { margin-top: 2rem; font-size: 1.3rem; }
.updated { color: var(--muted); font-size: 0.9rem; }

/* Wider screens */
@media (min-width: 40em) {
  :root { --space: 1.5rem; }
  .hero { padding: 3.5rem 0 3rem; }
  .section { padding: 3.5rem 0; }
  .fit { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .options { grid-template-columns: 1fr 1fr; }
  .printables { grid-template-columns: repeat(3, 1fr); }
  .printable { grid-template-columns: 1fr; }
  .signup { padding: 1.5rem; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}
