/*
 * Adapted for TerenceKearns.com from Sentinel Docs' Showcase stylesheet.
 * Licensed under Apache-2.0. See ../licenses/Apache-2.0.txt in the site kit.
 */
html[data-layout="atlas"] {
  --bg: #f6f8fb;
  --ink: #17263e;
  --line: #d4ddea;
  --accent: #235bcc;
  --code: #e9eef7;
  --card: #ffffff;
  --muted: #495b73;
  --input-border: #71839e;
  --button-ink: #ffffff;
}

html[data-layout="folio"] {
  --bg: #f1ebdf;
  --ink: #29291f;
  --line: #cbc3b1;
  --accent: #a63d24;
  --code: #e6dfd0;
  --card: #f7f3ea;
  --muted: #5d5547;
  --input-border: #867764;
  --button-ink: #ffffff;
}

html[data-layout="console"] {
  color-scheme: dark;
  --bg: #101b1c;
  --ink: #d4e9df;
  --line: #314644;
  --accent: #b3f36d;
  --code: #182829;
  --card: #142122;
  --muted: #aec8bd;
  --input-border: #627e74;
  --button-ink: #101b1c;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 1rem; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16.5px/1.72 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
::selection { background: var(--accent); color: var(--button-ink); }
a { color: inherit; text-underline-offset: 4px; }
a:hover { color: var(--accent); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
h1, h2, h3, p, li { overflow-wrap: break-word; }
h1 { margin: 0 0 24px; max-width: 22ch; font-size: clamp(30px, 4vw, 58px); line-height: 1.14; letter-spacing: -.03em; text-wrap: balance; }
h2 { margin: 0 0 18px; font-size: clamp(24px, 2.6vw, 30px); line-height: 1.25; }
h3 { margin: 0 0 12px; font-size: clamp(19px, 2vw, 22px); line-height: 1.3; }
p { max-width: 68ch; margin: 0 0 16px; }
blockquote { margin: 24px 0; padding: 10px 20px; border-inline-start: 3px solid var(--accent); background: var(--code); }
code { padding: 2px 5px; border-radius: 3px; background: var(--code); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; overflow-wrap: anywhere; }
img { max-width: 100%; height: auto; }
.skip { position: fixed; top: -80px; left: 10px; padding: 12px; background: var(--bg); z-index: 5; }
.skip:focus { top: 10px; }

.site-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding: 16px 4vw;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}
.brand { display: inline-flex; align-items: center; min-height: 44px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; }
.primary-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 0 20px; }
.primary-nav a { display: flex; align-items: center; min-height: 44px; padding: 6px 0; font-size: 14px; line-height: 1.45; text-decoration: none; }
.primary-nav a:hover, .primary-nav [aria-current="page"] { color: var(--accent); text-decoration: underline; }
.layout-picker { display: flex; align-items: center; gap: 12px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.layout-picker[hidden] { display: none; }

.wrap { width: min(1200px, 94%); margin: 40px auto 0; }
main, article { min-width: 0; max-width: 100%; }
main { padding: clamp(24px, 4vw, 48px); border: 1px solid var(--line); background: var(--card); box-shadow: 0 12px 40px #1c39600a; }
.hero { padding-block: 0 clamp(32px, 5vw, 56px); }
.lede { max-width: 65ch; color: var(--muted); font-size: clamp(17px, 2vw, 20px); }
.section { padding-block: clamp(30px, 5vw, 56px); border-top: 1px solid var(--line); }
main > .section:last-child { padding-bottom: 0; }
.prose { border-top: 0; min-height: 42vh; padding-top: 0; }
.service-grid, .contact-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.service-grid { margin-top: 28px; }
.service-card, .contact-card, .hero-offer, .offer-box { min-width: 0; border: 1px solid var(--line); border-radius: 6px; background: var(--bg); padding: clamp(16px, 2.6vw, 28px); }
.service-card { display: flex; flex-direction: column; align-items: flex-start; }
.service-card:last-child { grid-column: 1 / -1; }
.card-price { margin-top: auto; padding-top: 4px; font-size: .875rem; font-weight: 700; }
.about { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 6fr); gap: 1rem 3rem; }
.about h3 { margin-top: 24px; }
.selected-work { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; list-style: none; }
.selected-work li { border: 1px solid var(--line); border-radius: 4px; padding: .25rem .65rem; font-size: .875rem; }

.breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 16px; color: var(--muted); font-size: 14px; }
.breadcrumb a { padding-block: 10px; }
.service-hero, .offer-box, .addon { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); align-items: start; gap: 1rem clamp(24px, 4vw, 48px); }
.service-hero { align-items: center; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; margin-top: 22px; }
.actions > a:not(.button) { display: inline-flex; align-items: center; min-height: 44px; }
.button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  max-width: 100%;
  min-height: 44px;
  padding: 8px 16px;
  border: 1px solid transparent;
  border-radius: 4px;
  background: var(--accent);
  color: var(--button-ink);
  font: inherit;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}
.button:hover { background: var(--card); border-color: var(--accent); color: var(--accent); }
.price { margin: 0 0 8px; font-size: clamp(24px, 3vw, 38px); font-weight: 750; line-height: 1.2; letter-spacing: -.025em; color: var(--accent); overflow-wrap: anywhere; }
.price-caption { color: var(--muted); font-size: .875rem; font-weight: 650; }
.offer-box { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); margin-top: 20px; background: var(--code); }
.offer-box ol { margin: 0; padding-inline-start: 1.4em; }
.offer-box li { padding: .4rem 0 .4rem .25rem; }
.offer-box li + li { border-top: 1px solid var(--line); }
video { display: block; width: min(100%, 52rem); background: #101b1c; margin-bottom: 1rem; }
.fine { color: var(--muted); font-size: .875rem; }
.offer-box + .fine { margin-top: 1rem; }

.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 24px; padding-inline-start: 1.4em; }
.steps li { padding: 14px 4px 8px; border-top: 1px solid var(--line); }
.steps li::marker { color: var(--accent); font-weight: 700; }
.steps p { margin-bottom: 0; }
.faq details { margin: 12px 0; max-width: 56rem; padding: 0 16px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg); }
.faq summary { min-height: 44px; padding: 10px 0; cursor: pointer; font-weight: 650; }
.faq p { margin: 0 0 16px; }

.contact-card { display: flex; flex-direction: column; }
.contact-card form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding-top: 12px; margin-top: auto; }
.contact-card form > div { min-width: 0; }
.full { grid-column: 1 / -1; }
form label { display: block; margin-bottom: 4px; font-size: .875rem; font-weight: 650; }
input, select, textarea { max-width: 100%; min-height: 44px; padding: 8px 10px; border: 1px solid var(--input-border); border-radius: 4px; background: var(--card); color: var(--ink); font: inherit; }
form :is(input, select, textarea) { width: 100%; }
textarea { resize: vertical; }
form .fine { margin-bottom: 0; }

.site-footer { display: flex; justify-content: space-between; align-items: center; gap: 18px 28px; margin: 32px auto; padding: 24px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }
.site-footer p { margin-bottom: 4px; }
.footer-qr-link { display: inline-flex; align-items: center; gap: 16px; max-width: 100%; padding: 12px 16px; border: 1px solid var(--line); border-radius: 6px; background: var(--card); color: var(--ink); text-decoration: none; }
.footer-qr-link:hover { border-color: var(--accent); color: inherit; }
.footer-qr-link:hover strong { text-decoration: underline; }
.footer-qr-link img { flex: 0 0 auto; width: 88px; height: 88px; border-radius: 4px; background: #ffffff; border: 1px solid var(--line); }
.footer-qr-meta { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.footer-qr-meta strong { font-size: 15px; overflow-wrap: anywhere; }
.footer-qr-hint { font-size: 13px; color: var(--muted); }

html[data-layout="folio"] main { padding-inline: 0; border: 0; background: transparent; box-shadow: none; }
html[data-layout="folio"] :is(h1, h2, .lede, .price) { font-family: Georgia, serif; font-weight: 400; }
html[data-layout="folio"] h1 { font-size: clamp(36px, 6.5vw, 88px); }
html[data-layout="folio"] :is(.service-card, .contact-card, .hero-offer, .faq details) { background: var(--card); }
html[data-layout="console"] body { font: 15px/1.68 ui-monospace, SFMono-Regular, Menlo, monospace; }
html[data-layout="console"] .site-header { border-top: 4px solid var(--accent); }
html[data-layout="console"] h1 { font-family: system-ui, sans-serif; }

@media (max-width: 960px) {
  .service-hero, .contact-grid, .about { grid-template-columns: minmax(0, 1fr); }
  .contact-card form { margin-top: 0; }
}

@media (max-width: 760px) {
  body { font-size: 17px; line-height: 1.7; }
  html[data-layout="console"] body { font-size: 16px; }
  .site-header { flex-direction: column; align-items: stretch; gap: 4px; padding: 10px 16px 16px; }
  .primary-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; }
  .primary-nav a { font-size: 16px; overflow-wrap: anywhere; }
  .layout-picker { align-self: flex-start; margin-top: 4px; }
  .wrap { width: calc(100% - 24px); margin-top: 14px; }
  main { padding: 20px 16px; border-radius: 6px; box-shadow: none; }
  .service-grid, .offer-box, .addon, .steps { grid-template-columns: minmax(0, 1fr); }
  .site-footer { flex-direction: column; align-items: flex-start; margin-block: 24px; }
  input, select, textarea, .button { font-size: 16px; }
}

@media (max-width: 540px) {
  .contact-card form { grid-template-columns: minmax(0, 1fr); }
}
