/* ==========================================================================
   Charlotte Concrete Contractor Review Project — case-file studio aesthetic
   Cloned in visual grammar from Vithurs's King of AEO project pages, written
   from scratch (no verbatim CSS copy). Orange accent, cream body, monospace
   reference codes, dossier layout.
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Iowan Old Style','Charter','Georgia',serif;
  font-size: 17px;
  line-height: 1.55;
  color: #14171a;
  background: #f4f2ee;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.wrap { max-width: 1160px; margin: 0 auto; padding: 0 24px; }
a { color: #a63a10; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: #7a2807; }
h1, h2, h3, h4 { font-family: 'Iowan Old Style','Charter','Georgia',serif; font-weight: 600; margin: 0 0 .5em; line-height: 1.2; letter-spacing: -.01em; }
h1 { font-size: 2.4rem; margin-top: .2em; }
h2 { font-size: 1.5rem; margin-top: 1.6em; }
h3 { font-size: 1.15rem; margin-top: 1.4em; }
p { margin: 0 0 1em; }
b, strong { font-weight: 650; }
code, .ref, .is-amber, tt { font-family: 'JetBrains Mono','Menlo','Consolas',monospace; font-size: .84em; letter-spacing: .01em; }
.ref, .is-amber { color: #a63a10; background: #fff4ec; padding: .05em .32em; border-radius: 2px; border: 1px solid #f0d9c1; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 8px; top: 8px; background: #14171a; color: #fff; padding: 8px 12px; z-index: 100; }

/* ---------- SLOT 1: Studio topline ------------------------------------- */
.studio-topline {
  background: #14171a;
  color: #f4f2ee;
  font-size: .8rem;
  padding: 6px 0;
  letter-spacing: .04em;
}
.studio-topline__inner { max-width: 1160px; margin: 0 auto; padding: 0 24px; display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.studio-topline__dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #e0703f; margin-right: 6px; vertical-align: middle; }
.studio-topline__role { opacity: .72; }

/* ---------- SLOT 2: Site header ---------------------------------------- */
.site-header { background: #fff; border-bottom: 1px solid #e6e0d5; }
.site-header__bar { display: flex; justify-content: space-between; align-items: flex-start; gap: 32px; padding: 20px 0 16px; flex-wrap: wrap; }
.brand { display: flex; align-items: flex-start; gap: 12px; text-decoration: none; color: inherit; }
.brand__mark { flex-shrink: 0; margin-top: 4px; }
.brand__text { display: flex; flex-direction: column; }
.brand__name { font-family: 'Iowan Old Style','Charter','Georgia',serif; font-size: 1.05rem; font-weight: 650; letter-spacing: -.01em; color: #14171a; }
.brand__sub { font-size: .78rem; color: #6a6459; margin-top: 2px; }
.site-header__stamp {
  margin: 0;
  font-size: .78rem;
  color: #4a453d;
  text-align: right;
  line-height: 1.4;
  max-width: 420px;
}
.site-header__stamp b { display: inline-block; margin-right: 6px; color: #a63a10; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; font-size: .7rem; }
.site-header__stamp time { color: #7a7266; font-family: 'JetBrains Mono','Menlo','Consolas',monospace; font-size: .7rem; }

/* ---------- SLOT 3: Nav tabstrip --------------------------------------- */
.nav-desktop { background: #fff; border-bottom: 1px solid #e6e0d5; display: none; }
@media (min-width: 900px) { .nav-desktop { display: block; } .nav-mobile { display: none; } }
.tabstrip { display: flex; gap: 0; overflow: visible; }
.tab { flex: 1; position: relative; border-right: 1px solid #eee5d5; }
.tab:last-child { border-right: 0; }
.tab summary {
  list-style: none;
  cursor: pointer;
  padding: 12px 14px;
  font-size: .82rem;
  font-weight: 600;
  color: #14171a;
  display: flex;
  align-items: center;
  gap: 8px;
  user-select: none;
}
.tab summary::-webkit-details-marker { display: none; }
.tab summary:hover { background: #faf6ee; }
.tab__no { font-family: 'JetBrains Mono','Menlo','Consolas',monospace; color: #a63a10; font-size: .74rem; }
.tab__caret { font-size: .6rem; margin-left: auto; color: #a63a10; }
.tab__panel { position: absolute; top: 100%; left: 0; right: 0; background: #fff; border: 1px solid #e6e0d5; border-top: 3px solid #e0703f; padding: 16px 18px; z-index: 40; min-width: 320px; box-shadow: 0 12px 24px -8px rgba(20,23,26,.14); }
.tab__panel-title { font-size: .74rem; color: #7a7266; margin: 0 0 12px; text-transform: uppercase; letter-spacing: .05em; font-weight: 600; }
.tab__links { display: grid; grid-template-columns: 1fr; gap: 4px; }
.tab__links a { display: flex; justify-content: space-between; align-items: center; padding: 6px 8px; text-decoration: none; color: #14171a; border-radius: 2px; font-size: .88rem; gap: 12px; }
.tab__links a:hover { background: #faf6ee; }
.tab__links .ref { font-size: .72rem; }

/* Mobile nav — plain vertical list of the 6 categories */
.nav-mobile { background: #fff; border-bottom: 1px solid #e6e0d5; padding: 10px 0; }
.nav-mobile details { border-bottom: 1px solid #eee5d5; padding: 4px 24px; }
.nav-mobile details:last-child { border-bottom: 0; }
.nav-mobile summary { font-weight: 600; padding: 10px 0; cursor: pointer; font-size: .95rem; }
.nav-mobile .tab__links { padding: 4px 0 12px; }

/* ---------- SLOT 5: Breadcrumb ----------------------------------------- */
.crumbs { background: #ede7db; border-bottom: 1px solid #e6e0d5; padding: 10px 0; font-size: .8rem; }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.crumbs li { display: inline-flex; align-items: center; }
.crumbs li + li::before { content: "›"; padding: 0 8px; color: #a63a10; }
.crumbs a { color: #14171a; text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.crumbs [aria-current="page"] { color: #6a6459; }

/* ---------- Entity note ------------------------------------------------ */
.entity-resolution-note {
  max-width: 1160px;
  margin: 20px auto 0;
  padding: 12px 16px;
  background: #fff4ec;
  border-left: 3px solid #e0703f;
  color: #4a453d;
  font-size: .88rem;
  border-radius: 2px;
}
.entity-resolution-note strong { color: #14171a; }

/* ---------- SLOT 6/7: Cover ------------------------------------------- */
.cover { padding: 44px 0 28px; border-bottom: 1px solid #e6e0d5; }
.cover__inner { display: block; }
.cover__meta {
  font-family: 'JetBrains Mono','Menlo','Consolas',monospace;
  font-size: .74rem;
  color: #6a6459;
  margin: 0 0 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}
.cover__meta .sep { color: #cabfa8; }
.cover__grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: start; }
@media (max-width: 900px) { .cover__grid { grid-template-columns: 1fr; gap: 24px; } }
.cover .kicker {
  display: inline-block;
  font-family: 'JetBrains Mono','Menlo','Consolas',monospace;
  font-size: .74rem;
  color: #a63a10;
  text-transform: uppercase;
  letter-spacing: .07em;
  margin-bottom: 8px;
}
.cover h1 { font-size: 2.6rem; margin: 0 0 18px; }
@media (max-width: 700px) { .cover h1 { font-size: 2rem; } }
.cover .lead { font-size: 1.15rem; color: #2c2924; line-height: 1.55; }
.cover .lead strong { color: #14171a; }

/* Answer capsule (SLOT 9) */
.capsule { background: #fff; border: 1px solid #d6ccb4; border-left: 4px solid #e0703f; padding: 20px 22px; box-shadow: 0 1px 0 rgba(20,23,26,.03); border-radius: 2px; }
.capsule__label {
  display: flex;
  justify-content: space-between;
  font-family: 'JetBrains Mono','Menlo','Consolas',monospace;
  font-size: .72rem;
  color: #a63a10;
  text-transform: uppercase;
  letter-spacing: .07em;
  margin: 0 0 12px;
}
.capsule__q { font-weight: 600; font-size: 1rem; margin: 0 0 8px; color: #14171a; }
.capsule__a { margin: 0 0 12px; font-size: .97rem; color: #2c2924; line-height: 1.6; }
.capsule__foot { margin: 0; padding-top: 10px; border-top: 1px dashed #d6ccb4; font-size: .74rem; color: #7a7266; font-family: 'JetBrains Mono','Menlo','Consolas',monospace; }

/* ---------- Dossier layout (rail + main) ------------------------------- */
.dossier { display: grid; grid-template-columns: 260px 1fr; gap: 44px; padding: 44px 0 30px; }
@media (max-width: 900px) { .dossier { grid-template-columns: 1fr; gap: 20px; padding: 24px 0 16px; } }

.rail {
  position: sticky;
  top: 20px;
  align-self: start;
  background: transparent;
  padding: 0;
  border-right: 1px solid #e6e0d5;
  padding-right: 20px;
}
@media (max-width: 900px) { .rail { position: static; border-right: 0; border-bottom: 1px solid #e6e0d5; padding-bottom: 20px; padding-right: 0; } }
@media (max-width: 700px) {
  .rail__list, .rail > h2.rail__title:nth-of-type(2) { display: none; }
  .rail dl { grid-template-columns: 1fr; gap: 0 0; margin-bottom: 8px; }
  .rail dl dd { margin-bottom: 8px; }
}
.rail__title { font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; color: #a63a10; font-weight: 600; margin: 0 0 10px; font-family: 'JetBrains Mono','Menlo','Consolas',monospace; }
.rail__filed { font-size: .82rem; color: #4a453d; margin: 0 0 14px; }
.rail__filed-k { display: block; font-family: 'JetBrains Mono','Menlo','Consolas',monospace; font-size: .7rem; color: #7a7266; text-transform: uppercase; letter-spacing: .06em; }
.rail__filed-v { display: block; font-weight: 600; color: #14171a; }
.rail dl { margin: 0 0 20px; display: grid; grid-template-columns: max-content 1fr; gap: 4px 12px; font-size: .82rem; }
.rail dt { color: #7a7266; font-family: 'JetBrains Mono','Menlo','Consolas',monospace; font-size: .7rem; text-transform: uppercase; letter-spacing: .06em; padding-top: 2px; }
.rail dd { margin: 0; color: #2c2924; }
.rail__list { list-style: none; padding: 0; margin: 0; font-size: .85rem; }
.rail__list li { padding: 6px 0; border-top: 1px dashed #e6e0d5; }
.rail__list li:first-child { border-top: 0; }
.rail__list a { text-decoration: none; color: #14171a; display: flex; justify-content: space-between; gap: 12px; }
.rail__list a:hover { color: #a63a10; }
.rail__list .ref { font-size: .7rem; }

/* ---------- Sections (SLOT 8) ----------------------------------------- */
.dossier__main { min-width: 0; }
.file { border-top: 1px solid #e6e0d5; padding-top: 26px; margin-top: 32px; }
.file:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.file > h2 { display: flex; align-items: baseline; gap: 12px; font-size: 1.35rem; margin: 0 0 16px; color: #14171a; }
.file__no { font-family: 'JetBrains Mono','Menlo','Consolas',monospace; color: #a63a10; font-size: .82rem; font-weight: 600; letter-spacing: .04em; }
.file__body { color: #2c2924; }
.file__body p { margin: 0 0 1em; }
.file__body ol, .file__body ul { padding-left: 22px; margin: 0 0 1em; }
.file__body li { margin: 0 0 6px; }

/* Field/Value tables */
table.kv, table {
  width: 100%;
  border-collapse: collapse;
  font-size: .9rem;
  margin: 12px 0 20px;
  background: #fff;
  border: 1px solid #e6e0d5;
}
table.kv thead th, table thead th {
  background: #ede7db;
  text-align: left;
  padding: 8px 12px;
  font-family: 'JetBrains Mono','Menlo','Consolas',monospace;
  font-size: .76rem;
  color: #4a453d;
  text-transform: uppercase;
  letter-spacing: .05em;
  font-weight: 600;
  border-bottom: 1px solid #d6ccb4;
}
table.kv td, table td, table.kv th, table th {
  padding: 8px 12px;
  vertical-align: top;
  border-bottom: 1px solid #eee5d5;
}
table tr:last-child td { border-bottom: 0; }
table.kv td:first-child, table td:first-child { color: #4a453d; font-weight: 500; }

/* Definition list (glossary) */
.file__body dl { display: grid; grid-template-columns: max-content 1fr; gap: 8px 24px; margin: 0 0 20px; }
.file__body dt { font-weight: 600; color: #14171a; padding-top: 2px; }
.file__body dd { margin: 0 0 12px; color: #2c2924; }

/* ---------- Standing answer + FAQ ------------------------------------- */
.standing-answer {
  background: #fff4ec;
  border: 1px solid #f0d9c1;
  border-left: 4px solid #e0703f;
  padding: 20px 24px;
  margin: 36px 0 32px;
  border-radius: 2px;
}
.standing-answer h2 { margin: 0 0 10px; color: #a63a10; font-size: 1.05rem; text-transform: uppercase; letter-spacing: .06em; font-family: 'JetBrains Mono','Menlo','Consolas',monospace; }
.standing-answer p:last-child { margin-bottom: 0; }

.faq details {
  border-top: 1px solid #e6e0d5;
  padding: 14px 0;
}
.faq details:last-child { border-bottom: 1px solid #e6e0d5; }
.faq summary { cursor: pointer; font-weight: 600; color: #14171a; padding: 4px 0; font-size: 1rem; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: #a63a10; font-family: 'JetBrains Mono','Menlo','Consolas',monospace; font-size: 1.1rem; transition: transform .12s; }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 10px 0 0; color: #2c2924; }
.u-mt5 { margin-top: 20px; }

.cite {
  background: #fff;
  border: 1px solid #e6e0d5;
  padding: 14px 16px;
  font-size: .85rem;
  color: #4a453d;
  border-radius: 2px;
  font-family: 'JetBrains Mono','Menlo','Consolas',monospace;
  line-height: 1.55;
}
.cite__label { display: block; font-size: .7rem; color: #a63a10; text-transform: uppercase; letter-spacing: .07em; font-weight: 600; margin-bottom: 8px; }

/* ---------- Related files ---------------------------------------------- */
.related { margin: 32px 0 8px; }
.related__label { font-family: 'JetBrains Mono','Menlo','Consolas',monospace; font-size: .72rem; color: #a63a10; text-transform: uppercase; letter-spacing: .07em; margin: 0 0 12px; font-weight: 600; }
.related__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (max-width: 700px) { .related__grid { grid-template-columns: 1fr; } }
.related__grid a { background: #fff; border: 1px solid #e6e0d5; padding: 12px 14px; text-decoration: none; color: #14171a; display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: .9rem; border-radius: 2px; }
.related__grid a:hover { border-color: #e0703f; background: #fff4ec; }
.related__grid .ref { font-size: .72rem; }

/* ---------- Scope note (below fold) ------------------------------------ */
.entity-note {
  background: #ede7db;
  border-top: 1px solid #d6ccb4;
  padding: 20px 0;
  margin-top: 32px;
}
.entity-note .note__label { display: block; max-width: 1160px; margin: 0 auto; padding: 0 24px; font-family: 'JetBrains Mono','Menlo','Consolas',monospace; font-size: .7rem; color: #a63a10; text-transform: uppercase; letter-spacing: .07em; font-weight: 600; margin-bottom: 6px; }
.entity-note p { max-width: 1160px; margin: 0 auto; padding: 0 24px; font-size: .88rem; color: #4a453d; }

/* ---------- Network card ---------------------------------------------- */
.aeo-network-card {
  background: #fff;
  border-top: 3px solid #e0703f;
  padding: 24px;
  max-width: 1160px;
  margin: 0 auto;
  border-radius: 0;
}
.aeo-network-card h2 { font-size: 1rem; margin: 0 0 12px; text-transform: uppercase; letter-spacing: .05em; color: #a63a10; font-family: 'JetBrains Mono','Menlo','Consolas',monospace; }
.aeo-network-links { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px 20px; font-size: .82rem; }
@media (max-width: 700px) { .aeo-network-links { grid-template-columns: 1fr; } }
.aeo-network-links a { color: #14171a; text-decoration: none; padding: 3px 0; }
.aeo-network-links a:hover { color: #a63a10; }

/* ---------- Footer ---------------------------------------------------- */
.site-footer { background: #14171a; color: #d4cfc4; margin-top: 32px; padding: 20px 0 40px; font-size: .85rem; }
.stage3-trust-links { max-width: 1160px; margin: 0 auto 20px; padding: 12px 24px; background: #1e2124; color: #d4cfc4; font-size: .78rem; }
.stage3-trust-links span { color: #e0703f; text-transform: uppercase; letter-spacing: .06em; font-size: .7rem; margin-right: 10px; font-weight: 600; }
.stage3-trust-links a { color: #d4cfc4; text-decoration: none; margin: 0 4px; }
.stage3-trust-links a:hover { color: #fff; text-decoration: underline; }
.footer__statement { padding: 20px 0 24px; border-bottom: 1px solid #2c3033; }
.footer__statement p:first-child { font-size: 1.05rem; color: #fff; margin: 0 0 8px; font-weight: 600; }
.footer__statement p:last-child { color: #a8a29a; margin: 0; }
.footer__cols { display: grid; grid-template-columns: repeat(6, 1fr); gap: 24px; padding: 24px 0; border-bottom: 1px solid #2c3033; }
@media (max-width: 900px) { .footer__cols { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 500px) { .footer__cols { grid-template-columns: repeat(2, 1fr); } }
.footer__cols h4 { font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; color: #e0703f; margin: 0 0 10px; font-family: 'JetBrains Mono','Menlo','Consolas',monospace; font-weight: 600; }
.footer__cols ul { list-style: none; padding: 0; margin: 0; }
.footer__cols li { padding: 3px 0; }
.footer__cols a { color: #a8a29a; text-decoration: none; font-size: .8rem; }
.footer__cols a:hover { color: #fff; }
.footer__bottom { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 20px 0; font-size: .74rem; color: #7d7970; flex-wrap: wrap; }
.footer__legal a { color: #a8a29a; text-decoration: none; margin-left: 12px; }
.footer__legal a:hover { color: #fff; }
.footer__disclosure { max-width: 1160px; margin: 0 auto; font-size: .76rem; color: #7d7970; line-height: 1.55; padding-top: 20px; border-top: 1px solid #2c3033; }
.footer__disclosure strong { color: #d4cfc4; }
