/* San Marcos Personal Injury Attorney — University Commons
   Collegiate blue · cream · terracotta · classic serif. Zero external assets. */

:root {
  --blue: #1d3f8c;
  --blue-deep: #15306e;
  --blue-ink: #0e1f47;
  --cream: #f7f1e2;
  --cream-light: #fcf8ee;
  --cream-dark: #efe4cf;
  --terra: #c1552e;
  --terra-deep: #9c4220;
  --terra-tint: #f4e2d6;
  --ink: #22293b;
  --muted: #5a6172;
  --line: rgba(29, 63, 140, .22);
  --line-soft: rgba(29, 63, 140, .12);
  --serif: "Palatino Linotype", "Book Antiqua", Palatino, Georgia, serif;
  --body: Georgia, "Iowan Old Style", "Times New Roman", serif;
  --sans: "Avenir Next", Avenir, "Helvetica Neue", Helvetica, Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--body);
  background: var(--cream);
  color: var(--ink);
  line-height: 1.72;
  font-size: 1.02rem;
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--terra); color: var(--cream-light); }
img { max-width: 100%; display: block; }
a { color: var(--blue); }
:focus-visible { outline: 2px solid var(--terra); outline-offset: 3px; border-radius: 2px; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.serif { font-family: var(--serif); }

/* ---------- header ---------- */
header.top {
  background: var(--cream-light);
  border-bottom: 1px solid var(--line-soft);
}
.top-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-top: 16px;
  padding-bottom: 16px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-logo { width: 46px; height: 46px; flex: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-name {
  font-family: var(--serif);
  font-size: 1.22rem;
  color: var(--blue-deep);
  letter-spacing: .01em;
}
.brand-sub {
  font-family: var(--sans);
  font-size: .68rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--terra-deep);
  margin-top: 3px;
}
.top-right { display: flex; align-items: center; gap: 22px; }
.head-phone {
  font-family: var(--sans);
  font-weight: 700;
  font-size: .98rem;
  color: var(--blue-deep);
  text-decoration: none;
  letter-spacing: .02em;
  white-space: nowrap;
}
.head-phone:hover { color: var(--terra); }

/* ---------- buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 700;
  font-size: .84rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 13px 26px;
  text-decoration: none;
  border-radius: 3px;
  transition: background .22s ease, color .22s ease, border-color .22s ease;
  border: 1px solid transparent;
  cursor: pointer;
}
.btn-terra { background: var(--terra); color: var(--cream-light); }
.btn-terra:hover { background: var(--terra-deep); color: #fff; }
.btn-outline { border-color: var(--blue); color: var(--blue); background: transparent; }
.btn-outline:hover { background: var(--blue); color: var(--cream-light); }
.btn-cream { background: var(--cream-light); color: var(--blue-deep); }
.btn-cream:hover { background: var(--cream-dark); }

/* ---------- nav ---------- */
nav.main {
  background: var(--blue-deep);
  border-top: 3px solid var(--terra);
}
.nav-inner { display: flex; flex-wrap: wrap; gap: 2px 26px; padding-top: 0; padding-bottom: 0; }
.nav-inner a {
  font-family: var(--sans);
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #dbe3f5;
  text-decoration: none;
  padding: 13px 2px 11px;
  border-bottom: 3px solid transparent;
  margin-bottom: -3px;
  transition: color .2s ease, border-color .2s ease;
}
.nav-inner a:hover { color: #fff; }
.nav-inner a.active { color: #fff; border-bottom-color: var(--terra); }

/* ---------- kickers + headings ---------- */
.kicker {
  font-family: var(--sans);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--terra-deep);
}
.kicker.blue { color: var(--blue); }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 400; color: var(--blue-deep); }
.h-rule {
  width: 52px;
  height: 4px;
  background: var(--terra);
  border-radius: 2px;
  margin: 14px 0 18px;
}
.h-rule.center { margin-left: auto; margin-right: auto; }
.lede { font-size: 1.1rem; color: var(--muted); max-width: 46rem; }

/* ---------- hero (index) ---------- */
.hero {
  padding: 72px 0 64px;
  background: var(--cream);
  border-bottom: 1px solid var(--line-soft);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 52px;
  align-items: center;
}
.hero h1 {
  font-size: clamp(2.15rem, 4.4vw, 3.35rem);
  line-height: 1.14;
  margin: 16px 0 20px;
  color: var(--blue-ink);
  letter-spacing: -.005em;
}
.hero h1 em { font-style: italic; color: var(--terra-deep); }
.hero .sub { font-size: 1.09rem; max-width: 33rem; color: var(--muted); }
.hero .sub strong { color: var(--blue-deep); }
.hero .ctas { display: flex; gap: 14px; margin-top: 34px; flex-wrap: wrap; }
.hero .fine {
  margin-top: 24px;
  font-family: var(--sans);
  font-size: .8rem;
  letter-spacing: .06em;
  color: var(--muted);
  display: flex;
  gap: 10px 22px;
  flex-wrap: wrap;
}
.hero .fine span::before { content: "·"; margin-right: 10px; color: var(--terra); font-weight: 700; }

/* campus-map panel */
.map-panel {
  background: var(--cream-light);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 18px;
  box-shadow: 14px 14px 0 var(--terra-tint);
}
.map-panel svg { width: 100%; height: auto; display: block; }
.map-caption {
  font-family: var(--sans);
  font-size: .68rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 10px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

/* ---------- tile band ---------- */
.tile-band {
  height: 14px;
  background-color: var(--terra);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='14' viewBox='0 0 28 14'%3E%3Cpath d='M0 7h28M14 0v14' stroke='%239c4220' stroke-width='1' fill='none' opacity='.55'/%3E%3C/svg%3E");
}

/* ---------- sections ---------- */
section { padding: 76px 0; }
section.alt { background: var(--cream-light); border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.sec-head { margin-bottom: 40px; }
.sec-head h2 {
  font-size: clamp(1.7rem, 3.2vw, 2.4rem);
  line-height: 1.18;
}
.sec-head .lede { margin-top: 12px; }

/* San Marcos angle */
.angle-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 44px;
  align-items: start;
}
.angle-note {
  background: var(--cream-light);
  border: 1px solid var(--line);
  border-left: 4px solid var(--terra);
  border-radius: 4px;
  padding: 22px 24px;
  font-size: .95rem;
  color: var(--muted);
}
.angle-note strong { color: var(--blue-deep); }
.corridor-list { list-style: none; margin-top: 14px; }
.corridor-list li {
  padding: 9px 0;
  border-bottom: 1px dashed var(--line);
  font-size: .97rem;
  display: flex;
  gap: 10px;
  align-items: baseline;
}
.corridor-list li::before { content: "↘"; color: var(--terra); font-family: var(--sans); font-size: .85rem; }
.corridor-list li:last-child { border-bottom: none; }
.corridor-list b { color: var(--blue-deep); font-family: var(--serif); font-weight: 600; }

/* practice department cards */
.dept-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.dept-card {
  background: var(--cream-light);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 26px 24px 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.dept-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 34px rgba(21, 48, 110, .12);
  border-color: var(--blue);
}
.dept-code {
  font-family: var(--sans);
  font-size: .66rem;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--terra-deep);
  background: var(--terra-tint);
  border-radius: 3px;
  padding: 4px 9px;
  align-self: flex-start;
}
.dept-card .icon { color: var(--terra); width: 44px; height: 44px; flex: none; }
.dept-card .icon svg { width: 100%; height: 100%; display: block; }
.dept-card h3 { font-size: 1.28rem; line-height: 1.25; }
.dept-card p { font-size: .93rem; color: var(--muted); }
.dept-card .card-link {
  margin-top: auto;
  font-family: var(--sans);
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--blue);
}
.dept-card .card-link:hover { color: var(--terra-deep); }
.dept-grid.two { grid-template-columns: repeat(2, 1fr); }

/* firm section */
.firm-grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: 52px;
  align-items: center;
}
.portrait-frame { position: relative; max-width: 360px; }
.portrait-frame .offset {
  position: absolute;
  inset: 0;
  transform: translate(12px, 12px);
  background: var(--blue-deep);
  border-radius: 6px;
}
.portrait-frame img {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 6px;
}
.portrait-frame .caption {
  margin-top: 16px;
  font-family: var(--serif);
  font-style: italic;
  font-size: .9rem;
  color: var(--muted);
}
.pillars { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.pillar {
  border-top: 2px solid var(--terra);
  padding-top: 14px;
}
.pillar h3 { font-size: 1.12rem; margin-bottom: 6px; }
.pillar p { font-size: .93rem; color: var(--muted); }

/* statute chips */
.statutes { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.stat-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--cream-light);
  border: 1px solid var(--line);
  border-left: 4px solid var(--terra);
  border-radius: 4px;
  padding: 9px 14px;
  font-family: var(--sans);
  font-size: .78rem;
  letter-spacing: .03em;
  color: var(--ink);
}
.stat-chip b { color: var(--blue-deep); font-weight: 700; }
.stat-chip .sec { color: var(--terra-deep); font-weight: 700; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--blue-ink); color: #dbe3f5; padding: 58px 0; }
.cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
}
.cta-inner h2 { color: #fff; font-size: clamp(1.5rem, 2.8vw, 2.1rem); line-height: 1.25; }
.cta-inner h2 em { color: #e8b09a; font-style: italic; }
.cta-inner .cta-sub { color: #a9b7d8; margin-top: 8px; max-width: 34rem; font-size: .95rem; }
.cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.cta-phone {
  font-family: var(--serif);
  font-size: 1.9rem;
  color: #fff;
  text-decoration: none;
  letter-spacing: .01em;
}
.cta-phone:hover { color: #e8b09a; }

/* ---------- page head (inner pages) ---------- */
.page-head {
  background: var(--cream-light);
  border-bottom: 1px solid var(--line-soft);
  padding: 56px 0 44px;
}
.page-head h1 {
  font-size: clamp(1.9rem, 3.8vw, 2.9rem);
  line-height: 1.16;
  margin: 14px 0 14px;
}
.crumbs {
  font-family: var(--sans);
  font-size: .72rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}
.crumbs a { color: var(--blue); text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.crumbs span + span::before { content: " / "; color: var(--terra); }

/* ---------- prose ---------- */
.prose { max-width: 46rem; }
.prose h2 {
  font-size: clamp(1.4rem, 2.6vw, 1.85rem);
  margin: 38px 0 12px;
  padding-top: 30px;
  border-top: 1px solid var(--line);
}
.prose h2:first-child { border-top: none; padding-top: 0; margin-top: 0; }
.prose h3 { font-size: 1.18rem; margin: 24px 0 8px; color: var(--ink); }
.prose p { margin: 0 0 16px; }
.prose ul { margin: 0 0 18px 22px; }
.prose li { margin-bottom: 8px; }
.prose .stat-chip { margin: 4px 0 18px; }
.legal-line {
  font-size: .8rem;
  color: var(--muted);
  font-style: italic;
  border-top: 1px dashed var(--line);
  margin-top: 30px;
  padding-top: 16px;
}
.strip {
  background: var(--terra-tint);
  border-left: 4px solid var(--terra);
  border-radius: 4px;
  padding: 16px 20px;
  font-size: .95rem;
  margin: 28px 0;
}
.strip a { font-weight: 700; }

/* two-col page layout: prose + aside */
.page-cols { display: grid; grid-template-columns: 1fr 300px; gap: 56px; align-items: start; }
.aside { position: sticky; top: 24px; }
.aside-card {
  background: var(--cream-light);
  border: 1px solid var(--line);
  border-top: 4px solid var(--terra);
  border-radius: 6px;
  padding: 22px;
  margin-bottom: 20px;
}
.aside-card h3 { font-size: 1.05rem; margin-bottom: 10px; }
.aside-card p { font-size: .88rem; color: var(--muted); }
.aside-card .aside-phone {
  display: block;
  font-family: var(--serif);
  font-size: 1.25rem;
  color: var(--terra-deep);
  text-decoration: none;
  margin: 10px 0 4px;
}
.aside-card ul { list-style: none; font-size: .88rem; }
.aside-card ul li { padding: 6px 0; border-bottom: 1px dashed var(--line-soft); }
.aside-card ul li:last-child { border-bottom: none; }
.aside-card ul a { text-decoration: none; }
.aside-card ul a:hover { text-decoration: underline; }

/* ---------- FAQ ---------- */
.faq-list { max-width: 48rem; }
.faq-q {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--cream-light);
  padding: 22px 26px;
  margin-bottom: 18px;
}
.faq-q h2 {
  font-size: 1.16rem;
  line-height: 1.35;
  border: none;
  padding: 0;
  margin: 0 0 10px;
}
.faq-q p { font-size: .97rem; color: var(--muted); margin: 0; }
.faq-q .q-no {
  font-family: var(--sans);
  font-size: .64rem;
  font-weight: 700;
  letter-spacing: .2em;
  color: var(--terra-deep);
  display: block;
  margin-bottom: 8px;
}

/* ---------- contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
.office-card {
  background: var(--cream-light);
  border: 1px solid var(--line);
  border-top: 4px solid var(--blue);
  border-radius: 6px;
  padding: 26px;
}
.office-card .city { font-family: var(--serif); font-size: 1.4rem; color: var(--blue-deep); }
.office-card .addr { color: var(--muted); margin-top: 8px; font-size: .96rem; }
.office-card .directions {
  display: inline-block;
  margin-top: 12px;
  font-family: var(--sans);
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--blue);
  text-decoration: none;
}
.office-card .directions:hover { color: var(--terra-deep); }
.form-card {
  background: var(--cream-light);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 28px;
}
.form-card label {
  display: block;
  font-family: var(--sans);
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--blue-deep);
  margin: 16px 0 6px;
}
.form-card h3 { font-family: var(--serif); font-size: 1.35rem; color: var(--blue-deep); margin: 0 0 4px; }
.form-card input, .form-card textarea, .form-card select {
  width: 100%;
  font-family: var(--body);
  font-size: .98rem;
  color: var(--ink);
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 11px 13px;
}
.form-card input:focus, .form-card textarea:focus, .form-card select:focus {
  outline: 2px solid var(--terra);
  outline-offset: 1px;
  border-color: var(--terra);
}
.form-card .form-note { font-size: .8rem; color: var(--muted); margin-top: 14px; margin-bottom: 0; }
.form-card .form-note.first { margin-top: 2px; }
.form-card .btn { margin-top: 20px; width: 100%; text-align: center; }
.form-card .req { color: var(--terra-deep); }

/* ---------- 404 ---------- */
.notfound { text-align: center; padding: 110px 0 90px; }
.notfound .code {
  font-family: var(--serif);
  font-size: clamp(3.4rem, 9vw, 6rem);
  color: var(--terra);
  line-height: 1;
}
.notfound h1 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin: 14px 0 14px; }
.notfound p { color: var(--muted); max-width: 30rem; margin: 0 auto 26px; }
.notfound .links { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ---------- footer ---------- */
footer {
  background: var(--blue-ink);
  color: #aeb9d8;
  padding: 60px 0 40px;
  font-size: .88rem;
}
.foot-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr 1.35fr;
  gap: 40px;
}
.foot-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.foot-brand img { width: 38px; height: 38px; }
.foot-brand .fb-text { line-height: 1.25; }
.foot-brand .fb-name { font-family: var(--serif); font-size: 1.02rem; color: #fff; }
.foot-brand .fb-sub {
  font-family: var(--sans);
  font-size: .62rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #8fa0c9;
  margin-top: 3px;
}
footer h3 {
  font-family: var(--sans);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #e8b09a;
  margin-bottom: 14px;
}
footer ul { list-style: none; }
footer ul li { margin-bottom: 7px; }
footer ul a { color: #aeb9d8; text-decoration: none; font-size: .87rem; }
footer ul a:hover { color: #fff; text-decoration: underline; }
footer .addr-line { margin-bottom: 7px; line-height: 1.5; }
.foot-legal {
  border-top: 1px solid rgba(174, 185, 216, .18);
  margin-top: 40px;
  padding-top: 20px;
  font-size: .76rem;
  color: #7e8db5;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  line-height: 1.6;
}

/* ---------- motion ---------- */
@media (prefers-reduced-motion: no-preference) {
  .dept-card, .pillar, .office-card, .faq-q { transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
}

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .hero-grid, .angle-grid, .firm-grid, .page-cols { grid-template-columns: 1fr; }
  .dept-grid { grid-template-columns: repeat(2, 1fr); }
  .foot-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .aside { position: static; }
  .portrait-frame { max-width: 320px; }
}
@media (max-width: 620px) {
  .wrap { padding: 0 18px; }
  .top-right { gap: 12px; }
  .top-right .btn { display: none; }
  .dept-grid, .dept-grid.two, .pillars, .contact-grid, .foot-grid { grid-template-columns: 1fr; }
  section { padding: 56px 0; }
  .hero { padding: 48px 0 48px; }
  .nav-inner { gap: 2px 16px; }
  .nav-inner a { font-size: .72rem; letter-spacing: .06em; }
  .cta-phone { font-size: 1.5rem; }
  .foot-legal { flex-direction: column; }
}
