/* Sartschev & Associates — site styles. No external resources. */

/* Self-hosted fonts (SIL Open Font License, see /fonts/OFL-*.txt) */
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 500; font-display: swap; src: url(/fonts/cormorant-garamond-latin-500-normal.woff2) format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/cormorant-garamond-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-style: italic; font-weight: 500; font-display: swap; src: url(/fonts/cormorant-garamond-latin-500-italic.woff2) format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-style: normal; font-weight: 400; font-display: swap; src: url(/fonts/source-sans-3-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/source-sans-3-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Dancing Script"; font-style: normal; font-weight: 500; font-display: swap; src: url(/fonts/dancing-script-latin-500-normal.woff2) format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-style: italic; font-weight: 400; font-display: swap; src: url(/fonts/source-sans-3-latin-400-italic.woff2) format("woff2"); }

:root {
  --paper: #ffffff;
  --paper-2: #eef0f3;
  --white: #ffffff;
  --ink: #0b0d10;
  --muted: #23272d;
  --navy: #0f2240;
  --navy-2: #0a1830;
  --navy-3: #2a4166;
  --gold: #8a6a2a;
  --gold-text: #5c4515;
  --gold-light: #d8c08a;
  --rule: #9aa1ab;
  --display: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --wrap: 1120px;
  --ease: 160ms ease;
}

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.3rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--navy); text-decoration-color: var(--gold); text-underline-offset: 3px; transition: color var(--ease); }
a:hover { color: var(--gold); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.15; color: var(--navy); margin: 0 0 .5em; letter-spacing: .005em; }
h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.85rem; }
p { margin: 0 0 1em; }
strong { font-weight: 600; }

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

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; background: #fff; padding: 8px 12px; z-index: 10; }

/* Small caps label used above headings */
.eyebrow {
  font-family: var(--sans);
  font-size: .875rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold-text);
  margin: 0 0 .9em;
}

/* Short gold rule under headings */
.flourish { display: block; width: 56px; height: 2px; background: var(--gold); margin: 0 0 1.4em; border: 0; }
.center .flourish, .section-head .flourish { margin-left: auto; margin-right: auto; }

/* Top bar */
.topbar { background: var(--navy-2); color: #e4e8ee; font-size: 1rem; }
.topbar .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 24px; padding-top: 9px; padding-bottom: 9px; }
.topbar a { color: #fff; text-decoration: none; font-weight: 600; }
.topbar a:hover { color: var(--gold-light); }

/* Masthead */
.masthead { background: var(--white); border-bottom: 1px solid var(--rule); }
.masthead .wrap { text-align: center; padding-top: 30px; }
.brand { display: inline-flex; align-items: center; gap: 16px; text-decoration: none; color: var(--navy); text-align: left; }
.brand:hover { color: var(--navy); }
.brand-mark {
  flex: none;
  display: grid; place-items: center;
  width: 52px; height: 52px;
  border: 1px solid var(--gold);
  outline: 1px solid var(--gold); outline-offset: 3px;
  font-family: var(--display); font-size: 1.35rem; font-weight: 600; color: var(--navy);
}
.brand-name { display: block; font-family: var(--display); font-weight: 600; font-size: clamp(1.75rem, 4.5vw, 2.5rem); line-height: 1.05; }
/* The subtitle is never wider than the firm name: it takes the name's width and is spread to fill it. */
.brand-text { display: inline-grid; }
.brand-sub {
  display: block; width: 0; min-width: 100%;
  /* 0.296 x the firm name's size (clamp(1.75rem, 4.5vw, 2.5rem)) makes the two the same width. */
  font-size: clamp(.52rem, 1.33vw, .74rem); font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted);
  margin-top: 6px; text-align: justify; text-align-last: justify; white-space: nowrap;
}

.nav { margin-top: 24px; border-top: 1px solid var(--rule); }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; }
.nav a {
  display: block;
  padding: 14px 18px;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink);
  border-bottom: 2px solid transparent;
  transition: color var(--ease), border-color var(--ease);
}
.nav a:hover { color: var(--navy); border-bottom-color: var(--rule); }
.nav a[aria-current="page"] { color: var(--navy); border-bottom-color: var(--gold); }

/* Hero */
.hero { background: var(--paper); border-bottom: 1px solid var(--rule); }
.hero .wrap {
  display: grid; grid-template-columns: 1.55fr 1fr; gap: 64px;
  padding-top: 84px; padding-bottom: 84px; align-items: center;
}
.hero h1 { font-weight: 600; margin-bottom: .45em; }
.hero h1 span { display: block; font-style: normal; font-weight: 600; }
.hero .lead { font-size: 1.3rem; color: var(--ink); max-width: 34em; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.8em; }

.callbox {
  background: var(--white);
  border: 1px solid var(--rule);
  outline: 1px solid var(--rule); outline-offset: 6px;
  padding: 36px 32px;
  text-align: center;
}
.callbox .phone { display: block; font-family: var(--display); font-weight: 600; font-size: 2.3rem; color: var(--navy); text-decoration: none; line-height: 1.1; margin: 0 0 6px; }
.callbox .phone:hover { color: var(--gold); }
.callbox small { color: var(--muted); font-size: 1rem; }
.callbox hr { border: 0; border-top: 1px solid var(--rule); margin: 22px 0; }
.callbox address { color: var(--ink); line-height: 1.55; margin-bottom: .6em; }

/* Buttons */
.btn {
  display: inline-block;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 15px 28px;
  background: var(--navy);
  color: #fff;
  border: 1px solid var(--navy);
  transition: background var(--ease), color var(--ease), border-color var(--ease);
}
.btn:hover { background: var(--navy-2); border-color: var(--navy-2); color: #fff; }
.btn-outline { background: transparent; color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: #fff; }
.btn:disabled, .btn:disabled:hover { opacity: .45; cursor: not-allowed; background: transparent; color: var(--muted); border-color: var(--rule); }
.btn:not(.btn-outline):disabled { background: var(--navy); color: #fff; border-color: var(--navy); }
.btn-gold { background: var(--gold); border-color: var(--gold); color: #fff; }
.btn-gold:hover { background: #87692f; border-color: #87692f; }
.btn-ghost { background: transparent; border-color: rgba(255,255,255,.45); color: #fff; }
.btn-ghost:hover { background: #fff; border-color: #fff; color: var(--navy); }

/* Text link with arrow */
.more {
  font-size: 1.05rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
  text-decoration: none; color: var(--navy);
}
.more::after { content: " \2192"; display: inline-block; transition: transform var(--ease); }
.more:hover::after { transform: translateX(4px); }

/* Sections */
.section { padding: 88px 0; border-bottom: 1px solid var(--rule); }
.section-alt { background: var(--paper-2); }
.section-head { text-align: center; max-width: 42em; margin: 0 auto 52px; }
.section-head p:not(.eyebrow) { color: var(--muted); }

/* Practice areas as framed panels */
.practice { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.practice article {
  display: flex; flex-direction: column;
  background: var(--white);
  border: 2px solid var(--rule);
  border-top: 4px solid var(--navy);
  padding: 34px 30px 30px;
  transition: border-color var(--ease);
}
.practice article:hover { border-top-color: var(--gold); }
.numeral { font-family: var(--display); font-size: 1.6rem; font-weight: 600; color: var(--gold-text); display: block; margin-bottom: 4px; }
.practice p { color: var(--ink); flex: 1; }

/* Two column text + aside */
.split { display: grid; grid-template-columns: 1.6fr 1fr; gap: 64px; align-items: start; }

.quote {
  font-family: var(--display);
  font-size: 1.8rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--navy);
  border-left: 2px solid var(--gold);
  padding-left: 24px;
  margin: 1.4em 0;
}

.points { list-style: none; margin: 0; padding: 0; counter-reset: pt; }
.points li { position: relative; padding: 18px 0 18px 52px; border-bottom: 1px solid var(--rule); counter-increment: pt; }
.points li:first-child { border-top: 1px solid var(--rule); }
.points li::before {
  content: counter(pt, decimal-leading-zero);
  position: absolute; left: 0; top: 16px;
  font-family: var(--display); font-size: 1.6rem; font-weight: 600; color: var(--gold-text);
}
.points strong { display: block; font-family: var(--display); font-size: 1.6rem; color: var(--navy); line-height: 1.3; }
.points span { color: var(--muted); font-size: 1.1rem; }

/* Interior page title band */
.page-title { background: var(--navy); color: #fff; padding: 64px 0 60px; border-bottom: 3px solid var(--gold); }
.page-title h1 { color: #fff; margin: 0; font-weight: 500; }
.page-title .eyebrow { color: var(--gold-light); }

/* Service list in two columns with ruled items */
.checklist { list-style: none; margin: 0 0 1.5em; padding: 0; columns: 2; column-gap: 36px; }
.checklist li { break-inside: avoid; padding: 10px 0 10px 26px; border-bottom: 1px solid var(--rule); position: relative; }
.checklist li::before { content: "\00a7"; position: absolute; left: 2px; top: 8px; color: var(--gold); font-family: var(--display); font-size: 1.2rem; font-weight: 600; }

.split p:not(.eyebrow) + h2 { margin-top: 1.4em; }

.aside-box {
  background: var(--white);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--gold);
  padding: 30px;
}
.aside-box h3 { margin-bottom: .35em; }
.aside-box p { color: var(--ink); }
.aside-box p:last-child { margin-bottom: 0; }
aside { position: sticky; top: 24px; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.contact-grid > div { background: var(--white); border: 1px solid var(--rule); border-top: 3px solid var(--navy); padding: 32px 30px; }
.contact-grid .big { font-family: var(--display); font-size: 1.9rem; font-weight: 600; text-decoration: none; }
address { font-style: normal; }

.notice { background: var(--white); border: 1px solid var(--rule); border-left: 3px solid var(--gold); padding: 22px 26px; margin-top: 1.5em; }
.notice p:last-child { margin-bottom: 0; }

/* Client portal */
[hidden] { display: none !important; }
.portal-section { background: var(--paper-2); min-height: 60vh; }
.portal-app { padding-top: 48px; }
.portal-card {
  max-width: 480px; margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--navy);
  padding: 40px 36px;
}
.portal-card h1 { font-size: clamp(2.2rem, 5vw, 2.7rem); }
.portal-loading { text-align: center; color: var(--muted); }
.portal-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 16px; margin-bottom: 32px; }
.portal-bar h1 { margin: 0; }

.form .field { margin-bottom: 22px; }
.form label { display: block; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
.form input {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: #fff;
  border: 1px solid #a99f89;
  border-radius: 0;
  padding: 12px 14px;
}
.form input:focus { outline: 2px solid var(--gold); outline-offset: 1px; border-color: var(--navy); }
.form .btn { width: 100%; }
.form .btn[disabled] { opacity: .65; cursor: wait; }
.form-foot { margin: 20px 0 0; text-align: center; }
.hint { font-size: 1rem; color: var(--muted); margin: 6px 0 0; }
.setup-details { margin: 0 0 22px; padding: 14px 16px; background: var(--paper); border: 1px solid var(--rule); grid-template-columns: auto 1fr; }
.setup-details dd { overflow-wrap: anywhere; }
.confirmed { color: #2f6b3a; font-weight: 600; white-space: nowrap; }
.btn { font-family: var(--sans); cursor: pointer; }

.sr-only, .form .sr-only { position: absolute; padding: 0; border: 0; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.captcha { min-height: 65px; margin-bottom: 20px; }
.choices { border: 0; margin: 0 0 22px; padding: 0; }
.form .choice {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 16px; margin-bottom: 10px;
  background: #fff; border: 1px solid #a99f89; cursor: pointer;
}
.choice:has(input:checked) { border-color: var(--navy); outline: 1px solid var(--navy); }
.choice input { width: 20px; height: 20px; margin: 0; accent-color: var(--navy); flex: none; }
.linkbtn {
  font: inherit; color: var(--navy); background: none; border: 0; padding: 0; cursor: pointer;
  text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 3px;
}
.linkbtn:hover { color: var(--gold); }
.linkbtn[disabled] { opacity: .6; cursor: wait; }

.alert {
  border: 1px solid #d3aeae;
  border-left: 4px solid #8a2c2c;
  background: #fbf1f1;
  color: #5a1b1b;
  padding: 14px 18px;
  margin-bottom: 22px;
}
.alert:focus { outline: none; }
.alert-ok { border-color: #adc6b0; border-left-color: #2f6b3a; background: #f1f8f2; color: #1d4425; }

/* Portal app */
.nav-btn {
  display: block; padding: 14px 18px; background: none; border: 0; border-bottom: 2px solid transparent; cursor: pointer;
  font: 600 .92rem/1.7 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--gold-text);
}
.nav-btn:hover { color: var(--navy); border-bottom-color: var(--rule); }
.signed-in { text-align: right; color: var(--muted); font-size: 1rem; margin: -40px 0 24px; }
.view-head { margin-bottom: 24px; }
.view-head h1 { margin-bottom: .2em; }
.view-head h1:focus { outline: none; }

.subtabs { display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 1px solid var(--rule); margin-bottom: 28px; }
.subtabs a {
  padding: 12px 20px; text-decoration: none; font-weight: 600; color: var(--ink);
  border: 1px solid transparent; border-bottom: 0; margin-bottom: -1px;
}
.subtabs a:hover { color: var(--navy); background: rgba(255,255,255,.5); }
.subtabs a[aria-current="page"] { background: var(--white); border-color: var(--rule); border-top: 3px solid var(--gold); color: var(--navy); }
.count {
  display: inline-block; min-width: 1.5em; padding: 0 .45em; margin-left: 4px;
  background: var(--navy); color: #fff; border-radius: 1em; font-size: .85rem; text-align: center;
}

.request-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.request { background: var(--white); border: 1px solid var(--rule); border-left: 4px solid var(--gold); padding: 22px 26px; }
.request-completed { border-left-color: #2f6b3a; }
.request-submitted { border-left-color: var(--navy); }
.request-returned { border-left-color: #a5432a; }
.home-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 24px; align-items: start; }
.home-grid > *, .home-side > * { min-width: 0; margin: 0; }
.home-side { display: grid; gap: 24px; }
.home-todo .request-list { margin-bottom: 4px; }
.home-docs { list-style: none; margin: 0 0 12px; padding: 0; }
.home-docs li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--rule); }
.staff-home-grid { grid-template-columns: 1fr 1fr; margin-top: 28px; }
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 860px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
.tile { display: grid; gap: 4px; padding: 18px 20px; background: var(--white); border: 1px solid var(--rule); border-top: 3px solid var(--rule); text-decoration: none; color: var(--ink); }
.tile:hover, .tile:focus-visible { border-color: var(--navy); }
.tile-alert { border-top-color: var(--gold); }
.tile-n { font-size: 2.2rem; line-height: 1; font-weight: 600; color: var(--navy); font-variant-numeric: tabular-nums; }
.tile-label { font-weight: 600; }
.tile-hint { font-size: .9rem; color: var(--muted); }
@media (max-width: 860px) { .home-grid { grid-template-columns: 1fr; } }
.request-overdue .request-meta { color: #7a2f1d; font-weight: 600; }
.request-returned-note { font-weight: 600; color: #7a2f1d; }
.badge-returned { color: #7a2f1d; background: #fbeee9; border-color: #e0b1a2; }
.badge-cancelled, .badge-expired { color: var(--muted); background: #f3f3f1; border-color: var(--rule); }
.request-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 16px; }
.request-head h3 { margin: 0 0 .3em; }
.request-meta { color: var(--muted); font-size: 1rem; }
.request .btn { margin-top: 4px; }
.badge { font-size: .85rem; font-weight: 600; letter-spacing: .04em; padding: 3px 10px; border: 1px solid; white-space: nowrap; }
.badge-open { color: #7a4a00; background: #fbf3e2; border-color: #e0c48a; }
.badge-submitted { color: var(--navy); background: #eef2f8; border-color: #b8c4d8; }
.badge-completed { color: #1d4425; background: #f1f8f2; border-color: #adc6b0; }

.upload-form { max-width: 720px; }
.dropzone {
  display: block; text-align: center; cursor: pointer; margin-bottom: 18px;
  padding: 40px 24px; background: var(--white); border: 2px dashed #a99f89;
  transition: border-color var(--ease), background var(--ease);
}
.form .dropzone { font-weight: 400; }
.dropzone strong { color: var(--navy); text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 3px; }
.dropzone .hint { display: block; margin-top: 8px; }
.dropzone:hover, .dropzone.dragging { border-color: var(--navy); background: #fff; }
#files:focus-visible + .file-list, .dropzone:focus-within { outline: 2px solid var(--gold); }
.file-list { list-style: none; margin: 0 0 18px; padding: 0; }
.file {
  display: grid; grid-template-columns: 1fr auto auto; gap: 4px 16px; align-items: center;
  padding: 12px 16px; background: var(--white); border: 1px solid var(--rule); border-top: 0;
}
.file:first-child { border-top: 1px solid var(--rule); }
.file-name { overflow-wrap: anywhere; }
.file-size { color: var(--muted); font-size: .95rem; }
.file progress { grid-column: 1 / -1; width: 100%; height: 8px; accent-color: var(--navy); }
.file-status { grid-column: 1 / -1; font-size: .95rem; }
.file-status:empty { display: none; }
.file-ok .file-status { color: #2f6b3a; }
.file-error .file-status { color: #8a2c2c; }
.form textarea {
  width: 100%; font: inherit; color: var(--ink); background: #fff;
  border: 1px solid #a99f89; border-radius: 0; padding: 12px 14px; resize: vertical;
}
.form textarea:focus { outline: 2px solid var(--gold); outline-offset: 1px; border-color: var(--navy); }
.upload-form .btn { width: auto; }

.filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.filter button {
  font: 600 .95rem var(--sans); padding: 8px 16px; cursor: pointer;
  background: var(--white); color: var(--ink); border: 1px solid #a99f89;
}
.filter button[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }
.doc-table { width: 100%; border-collapse: collapse; background: var(--white); border: 1px solid var(--rule); }
.doc-table th { text-align: left; font-size: .85rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding: 12px 16px; border-bottom: 2px solid var(--rule); }
.doc-table td { padding: 14px 16px; border-bottom: 1px solid var(--rule); vertical-align: middle; }
.doc-name { overflow-wrap: anywhere; font-weight: 600; }
.doc-personal { color: var(--muted); }
[data-panel="files"] .doc-table td, [data-panel="files"] .doc-table th { padding-left: 12px; padding-right: 12px; }
[data-panel="files"] .doc-table td { font-size: 1.05rem; }
[data-panel="files"] .doc-name { min-width: 220px; }
.doc-table .btn-small { padding: 8px 12px; letter-spacing: .06em; }
.doc-action { text-align: right; white-space: nowrap; }
/* My Documents: keep the short columns (tax year, from, date, size) and headers on one line. */
[data-panel="files"] .doc-table th,
[data-panel="files"] .doc-table td:is(:nth-child(3), :nth-child(5)) { white-space: nowrap; }
.btn-small { padding: 9px 16px; font-size: .85rem; }
.doc-status { font-size: .95rem; color: var(--muted); }
.doc-rejected { color: #8a2c2c; }
.empty { color: var(--muted); padding: 24px 0; }
.details { display: grid; grid-template-columns: auto 1fr; gap: 6px 20px; margin: 0; }
.details dt { font-weight: 600; }
.details dd { margin: 0; overflow-wrap: anywhere; }

.form select {
  width: 100%; font: inherit; color: var(--ink); background: #fff;
  border: 1px solid #a99f89; border-radius: 0; padding: 11px 12px;
}
.form select:focus { outline: 2px solid var(--gold); outline-offset: 1px; border-color: var(--navy); }
.field-narrow { max-width: 360px; }
.doc-toolbar { display: grid; grid-template-columns: 1.6fr 1fr 1.3fr 1fr 1fr; gap: 0 16px; }
.doc-toolbar .field { margin-bottom: 16px; }
.sent-toolbar { grid-template-columns: 1.6fr 1fr 1fr 1fr; }
.activity-toolbar { grid-template-columns: 1.5fr 1.3fr 1fr 1fr 1fr; align-items: end; }
.activity-actions { grid-column: 1 / -1; display: flex; align-items: center; gap: 20px; margin-bottom: 16px; }
.activity-actions .btn { width: auto; }
#activity-count { margin: 0 0 12px; }
.doc-toolbar input, .doc-toolbar select { height: 52px; }
.doc-filterbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; margin-bottom: 18px; }
.doc-filterbar .filter { margin: 0; }
.doc-count { margin: 0; color: var(--muted); font-size: 1rem; }

.upload-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-bottom: 12px; }
.request .upload-form { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--rule); max-width: none; }
.dropzone { outline-offset: 2px; }
.upload-note { font-size: 1rem; color: var(--muted); border-left: 3px solid var(--gold); padding-left: 12px; margin: 0 0 18px; }

.settings { display: grid; gap: 24px; }
.settings-card { background: var(--white); border: 1px solid var(--rule); border-top: 3px solid var(--navy); padding: 26px 30px; }
.settings-card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 14px; }
.settings-card-head h2 { font-size: 1.85rem; margin: 0; }
.settings-card .details { grid-template-columns: minmax(140px, max-content) 1fr; }
.settings-card .details dd { white-space: pre-line; }
.settings-card > .hint { margin: 0 0 16px; }
.settings-form { margin-top: 8px; }
.field-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 18px; }
.field-grid .field-wide { grid-column: span 3; }
.field-grid input, .field-grid select { height: 54px; }
.card-head-actions { display: flex; gap: 18px; }
.view-head-actions { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 16px 24px; }
.view-head-actions .btn { flex: none; }
.back-link { margin: 0 0 10px; }
.send-kinds { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 26px; }
.kind {
  display: grid; gap: 4px; text-align: left; cursor: pointer; padding: 18px 20px;
  background: var(--white); border: 1px solid var(--rule); border-top: 3px solid var(--rule); color: var(--ink); font: inherit;
}
.kind strong { font-family: var(--display); font-size: 1.45rem; font-weight: 600; color: var(--navy); }
.kind span { color: var(--muted); font-size: 1rem; }
.kind:hover { border-top-color: var(--gold); }
.kind[aria-pressed="true"] { border-color: var(--navy); border-top-color: var(--gold); box-shadow: inset 0 0 0 1px var(--navy); }
#simple-actions .btn { width: auto; }
.share-limits { border: 1px solid var(--rule); background: var(--white); padding: 14px 18px 10px; margin: 0 0 20px; }
.share-limits legend { font-weight: 600; padding: 0 6px; }
.share-limits .inline-choice { font-weight: 400; margin-bottom: 8px; }
.expire-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.expire-row .inline-choice { margin-bottom: 0; }
.form .expire-row input[type="number"] { width: 90px; height: 44px; }
.form .expire-row select { width: auto; height: 44px; }
.share-limits .hint { margin-top: 8px; }
.business-list { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 14px; }
.business { border: 1px solid var(--rule); border-left: 4px solid var(--gold); padding: 18px 22px; background: #fff; }
.business h3 { margin: 0 0 .3em; }

/* PDF pages (signing and staff editor) */
.pdf-pages { display: grid; gap: 24px; justify-items: center; }
.pdf-page { position: relative; width: 100%; max-width: 900px; background: #fff; box-shadow: 0 1px 4px rgba(19, 33, 58, .18); }
.pdf-page canvas { display: block; width: 100%; height: 100%; }
.pdf-overlay { position: absolute; inset: 0; }

/* Client signing fields */
.sf {
  position: absolute; display: flex; align-items: center; justify-content: center; overflow: hidden;
  font: 600 clamp(.6rem, 1.4vw, .85rem) var(--sans); color: var(--navy);
  background: rgba(255, 233, 160, .75); border: 2px solid #c9a227; border-radius: 2px; padding: 0; cursor: pointer;
}
.sf:focus-visible { outline: 3px solid var(--navy); outline-offset: 1px; }
.sf.filled { background: rgba(255, 255, 255, .35); border: 1px dashed rgba(27, 46, 74, .35); }
.sf.sf-todo { animation: sf-pulse 1.6s ease-in-out infinite; }
@keyframes sf-pulse { 50% { box-shadow: 0 0 0 4px rgba(201, 162, 39, .35); } }
.sf canvas { width: 100%; height: 100%; object-fit: contain; }
.sf-auto { cursor: default; font-weight: 400; justify-content: flex-start; padding-left: 4px; white-space: nowrap; color: #0d1f4d; }
.sf-text { font: 400 clamp(.6rem, 1.4vw, .85rem) var(--sans); padding: 0 4px; cursor: text; color: #0d1f4d; }
.sf-text::placeholder { color: #6b5a1c; }
.sf-checkbox.filled { background: rgba(255, 255, 255, .5); }
.sf-checkbox.filled::after { content: "\2715"; font-size: clamp(.6rem, 1.6vw, 1rem); color: #0d1f4d; }
#sign-doc { padding-bottom: 150px; }
.sign-dock {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 5;
  background: var(--white); border-top: 3px solid var(--gold); box-shadow: 0 -4px 16px rgba(19, 33, 58, .12);
}
.sign-dock-inner { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px 28px; padding-top: 14px; padding-bottom: 14px; }
.sign-dock-status { display: flex; align-items: center; gap: 14px; }
.sign-dock-status p { margin: 0; font-weight: 600; white-space: nowrap; }
.sign-intent { margin: 0; font-size: .95rem; color: var(--muted); }
.sign-dock .btn:disabled { opacity: .5; cursor: not-allowed; }
.disclosure { white-space: pre-line; background: var(--paper); border: 1px solid var(--rule); padding: 18px 22px; margin-bottom: 20px; max-height: 320px; overflow: auto; }
#sign-consent .choice { margin-bottom: 18px; }
#sign-consent .btn { width: auto; }

/* Adopt-signature dialog */
.adopt { max-width: 680px; width: calc(100% - 32px); border: 1px solid var(--rule); border-top: 3px solid var(--navy); padding: 28px 30px; background: var(--white); color: var(--ink); }
.adopt::backdrop { background: rgba(18, 33, 58, .55); }
.adopt h2 { margin-bottom: .6em; }
.adopt-tabs { display: flex; gap: 6px; margin-bottom: 18px; border-bottom: 1px solid var(--rule); }
.adopt-tabs button { font: 600 1rem var(--sans); background: none; border: 0; border-bottom: 3px solid transparent; padding: 8px 16px; cursor: pointer; color: var(--ink); }
.adopt-tabs button[aria-selected="true"] { border-bottom-color: var(--gold); color: var(--navy); }
.adopt-fields { display: grid; grid-template-columns: 2fr 1fr; gap: 0 16px; }
.adopt-preview { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; min-height: 90px; padding: 12px 16px; border: 1px dashed #a99f89; background: #fff; margin-bottom: 14px; }
.adopt-preview canvas { max-width: 100%; height: 64px; }
.pad-label { display: flex; justify-content: space-between; font-weight: 600; margin: 0 0 6px; }
.pad { display: block; width: 100%; max-width: 600px; aspect-ratio: 600 / 160; background: #fff; border: 1px solid #a99f89; touch-action: none; cursor: crosshair; margin-bottom: 14px; }
.pad-small { max-width: 240px; aspect-ratio: 240 / 160; }
.adopt-error { color: #8a2c2c; min-height: 1.4em; margin: 0 0 8px; }

/* Staff editor */
.staff-form { max-width: none; margin-bottom: 24px; }
.staff-grid { display: grid; grid-template-columns: 1.5fr 1.4fr 1fr 1fr; gap: 0 16px; }
.staff-grid.staff-grid-2 { grid-template-columns: 1.6fr 1fr; }
.staff-grid input, .staff-grid select { height: 56px; }
.staff-grid label { white-space: nowrap; }
.require-id span { font-weight: 400; }
.require-id strong { font-weight: 600; }
.editor { display: grid; grid-template-columns: 260px 1fr; gap: 28px; align-items: start; }
.palette { position: sticky; top: 16px; background: var(--white); border: 1px solid var(--rule); border-top: 3px solid var(--navy); padding: 20px; }
.palette-title { font-weight: 600; margin: 0 0 10px; color: var(--navy); }
.tools { display: grid; gap: 8px; margin-bottom: 12px; }
.tools button { font: 600 1rem var(--sans); text-align: left; padding: 10px 14px; background: #fff; border: 1px solid #a99f89; cursor: pointer; color: var(--ink); }
.tools button[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }
.palette .hint { margin: 0 0 16px; }
.field-props { border-top: 1px solid var(--rule); padding-top: 14px; margin-bottom: 14px; }
.field-props .choice { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; cursor: pointer; }
.field-props .choice input { width: 18px; height: 18px; accent-color: var(--navy); }
.field-props .linkbtn { display: block; }
.field-props .field { margin-bottom: 12px; }
.field-count { color: var(--muted); font-size: 1rem; }
.palette .btn { width: 100%; }
.pdf-overlay.placing { cursor: crosshair; }
.ef {
  position: absolute; display: flex; align-items: center; justify-content: center; overflow: hidden; touch-action: none;
  background: rgba(42, 65, 102, .16); border: 2px solid var(--navy-3); cursor: move; user-select: none;
}
.ef-signature, .ef-initials { background: rgba(201, 162, 39, .22); border-color: #a8861c; }
.ef.optional { border-style: dashed; }
.ef.ef-sender { background: rgba(15, 34, 64, .1); border-color: var(--navy); }
.sender-entries { border-top: 1px solid var(--rule); padding-top: 14px; margin-bottom: 14px; }
.sender-entries .field { margin-bottom: 12px; }
.sender-entries .choice { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.sender-entries .choice input { width: 18px; height: 18px; accent-color: var(--navy); }
.ef.selected, .ef:focus-visible { outline: 3px solid var(--gold); outline-offset: 1px; }
.ef-label { font: 600 clamp(.55rem, 1.1vw, .8rem) var(--sans); color: var(--navy); white-space: nowrap; pointer-events: none; padding: 0 4px; }
.ef-checkbox .ef-label { display: none; }
.ef-resize { position: absolute; right: -1px; bottom: -1px; width: 12px; height: 12px; background: var(--navy); cursor: nwse-resize; }

/* Photo ID */
.id-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.form input[type="file"] { padding: 10px; background: #fff; }
#sign-id .notice { margin-bottom: 18px; }
#sign-id .choice, .require-id { display: flex; align-items: flex-start; gap: 10px; margin: 0 0 18px; cursor: pointer; font-weight: 400; }
#sign-id .choice input, .require-id input { width: 20px; height: 20px; margin-top: 3px; accent-color: var(--navy); flex: none; }
#sign-id .btn { width: auto; }
.id-review { margin-top: 28px; }
.id-images { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 14px; }
.id-images figure { margin: 0; background: var(--paper); border: 1px solid var(--rule); padding: 12px; }
.id-images figcaption { font-weight: 600; margin-bottom: 8px; }
.id-images img { display: block; width: 100%; max-height: 360px; object-fit: contain; background: #fff; margin-bottom: 8px; }
.reject-form { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--rule); max-width: 640px; }
.reject-form .btn { width: auto; }
.id-status { font-weight: 600; }
.cell-sub { display: block; font-weight: 400; font-size: .92rem; color: var(--muted); }
.pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; margin: 16px 0 8px; }
.pager-status { margin: 0; color: var(--muted); font-variant-numeric: tabular-nums; }
.pager-pages { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.pager-page { min-width: 40px; height: 40px; padding: 0 10px; border: 1px solid var(--rule); background: var(--white); color: var(--ink); font: inherit; cursor: pointer; font-variant-numeric: tabular-nums; }
.pager-page:hover:not([disabled]) { border-color: var(--navy); color: var(--navy); }
.pager-page[disabled] { opacity: .45; cursor: default; }
.pager-current, .pager-current[disabled] { background: var(--navy); border-color: var(--navy); color: #fff; opacity: 1; font-weight: 600; }
.pager-gap { padding: 0 4px; color: var(--muted); }
.pager-size { display: flex; align-items: center; gap: 8px; color: var(--muted); white-space: nowrap; }
.pager-size select { height: 40px; padding: 0 8px; }
.client-search { margin: 0; flex: 1 1 260px; max-width: 360px; }
.client-search input { height: 44px; }
.check-col { width: 44px; }
.check-col input { width: 18px; height: 18px; }
.file-panel { margin-top: 24px; }
.file-panel-list { margin: 0 0 16px; padding-left: 1.2em; color: var(--muted); overflow-wrap: anywhere; }
.req-body { display: grid; gap: 12px; align-content: start; }
.req-body h3 { margin: 12px 0 0; }
.req-facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 20px; margin: 0; }
.req-facts dt { font-weight: 600; color: var(--muted); }
.req-facts dd { margin: 0; overflow-wrap: anywhere; }
.req-files { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.req-files li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 16px; padding: 10px 0; border-bottom: 1px solid var(--rule); }
.timeline { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--rule); }
.timeline li { display: grid; grid-template-columns: 11.5em 1fr auto; gap: 4px 16px; padding: 8px 0 8px 16px; position: relative; }
.timeline li::before { content: ""; position: absolute; left: -6px; top: 14px; width: 10px; height: 10px; border-radius: 50%; background: var(--gold); }
.timeline-when { color: var(--muted); font-variant-numeric: tabular-nums; }
.timeline-ip { color: var(--muted); font-size: .9rem; white-space: nowrap; }
@media (max-width: 560px) { .timeline li { grid-template-columns: 1fr; } }
.req-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 16px; }
.req-form .field { flex: 1 1 260px; margin: 0; }
@media (max-width: 560px) { .req-facts { grid-template-columns: 1fr; gap: 0; } .req-facts dd { margin-bottom: 8px; } }
.row-muted td { color: var(--muted); }
.user-status { font-weight: 600; white-space: nowrap; }
.status-active { color: #2f6b3a; }
.status-invited { color: #7a4a00; }
.status-archived, .status-deactivated { color: #8a2c2c; }
.admin-form { margin-bottom: 24px; }
.admin-form h2 { font-size: 1.6rem; }
.admin-form .btn { width: auto; }
.admin-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 16px; }
.admin-grid-2 { grid-template-columns: minmax(0, 420px); }
.admin-grid input, .admin-grid select { height: 54px; }
.inline-choice { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 600; }
.inline-choice input { width: 18px; height: 18px; accent-color: var(--navy); }
.team-actions { align-items: center; }
.matrix-wrap { overflow-x: auto; margin-bottom: 16px; }
.matrix th, .matrix td { vertical-align: middle; }
.matrix .perm-name { font-weight: 600; text-transform: none; letter-spacing: 0; font-size: 1rem; color: var(--ink); min-width: 220px; }
.matrix th, .matrix td { padding-left: 10px; padding-right: 10px; }
.matrix .role-col { text-transform: none; letter-spacing: 0; font-size: 1rem; color: var(--ink); width: 160px; min-width: 150px; vertical-align: top; }
.matrix .role-name { width: 100%; font: 600 .92rem var(--sans); padding: 6px 7px; border: 1px solid #a99f89; background: #fff; }
.matrix .role-title { display: block; font-weight: 600; color: var(--navy); line-height: 1.3; }
.matrix .role-links { display: flex; gap: 12px; margin-top: 4px; font-size: .92rem; }
.nowrap { white-space: nowrap; }
.matrix .role-name:disabled { background: var(--paper); border-color: var(--rule); color: var(--navy); }
.matrix .perm-cell { text-align: center; }
.matrix input[type="checkbox"] { width: 22px; height: 22px; accent-color: var(--navy); cursor: pointer; }
.matrix input[type="checkbox"]:disabled { cursor: not-allowed; }
.roles-actions { margin-bottom: 28px; }
.team-table select { font: inherit; padding: 8px 10px; border: 1px solid #a99f89; background: #fff; }
.team-table input[type="checkbox"] { width: 20px; height: 20px; accent-color: var(--navy); }
.team-email { display: block; font-weight: 400; }
.team-perms { font-size: .95rem; color: var(--muted); }
.activity-detail { font-size: .9rem; color: var(--muted); overflow-wrap: anywhere; }
.id-submitted { color: #7a4a00; }
.id-verified { color: #2f6b3a; }
.id-rejected { color: #8a2c2c; }

/* Document viewer */
.doc-buttons { display: inline-flex; flex-wrap: nowrap; gap: 8px; justify-content: flex-end; }
.viewer { width: min(1040px, calc(100% - 24px)); height: calc(100vh - 32px); max-height: none; padding: 0; border: 1px solid var(--rule); border-top: 3px solid var(--navy); background: var(--paper-2); color: var(--ink); }
.viewer[open] { display: flex; flex-direction: column; }
.viewer::backdrop { background: rgba(18, 33, 58, .65); }
.viewer-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 12px 20px; padding: 18px 22px; background: var(--white); border-bottom: 1px solid var(--rule); }
.viewer-head h2 { font-size: 1.6rem; margin: 0; overflow-wrap: anywhere; }
.viewer-head .hint { margin: 2px 0 0; }
.viewer-body { flex: 1; overflow: auto; padding: 22px; }
.viewer-img { display: block; max-width: 100%; margin: 0 auto; background: #fff; box-shadow: 0 1px 4px rgba(19, 33, 58, .18); }
.viewer-text { white-space: pre-wrap; overflow-wrap: anywhere; background: #fff; border: 1px solid var(--rule); padding: 18px; margin: 0; font-size: .95rem; }

/* Searchable text boxes */
.combo { position: relative; }
.combo-list {
  position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 2px);
  max-height: 280px; overflow-y: auto; margin: 0; padding: 4px 0; list-style: none;
  background: #fff; border: 1px solid var(--navy); box-shadow: 0 6px 18px rgba(19, 33, 58, .16);
}
.combo-list [role="option"] { display: flex; flex-direction: column; padding: 8px 14px; cursor: pointer; }
.combo-list [role="option"] small { color: var(--muted); font-size: .9rem; }
.combo-list [role="option"]:hover, .combo-list [aria-selected="true"] { background: #eef2f8; }
.combo-list .combo-empty { padding: 8px 14px; color: var(--muted); font-size: .95rem; }
#tpl-save { margin-bottom: 10px; }
#sig-tpl-edit .editor { margin-top: 20px; }
.st-require { align-self: center; margin: 12px 0 0; }
.tpl-intro { align-items: center; margin-bottom: 18px; }
.tpl-intro p { margin: 0; max-width: 40em; }
.inline-edit { display: flex; gap: 8px; align-items: center; }
.inline-input { font: inherit; padding: 6px 10px; border: 1px solid #a99f89; min-width: 220px; }

/* Closing call-to-action band */
.cta { background: var(--navy); color: #eef1f5; padding: 72px 0; text-align: center; border-top: 3px solid var(--gold); }
.cta h2 { color: #fff; font-weight: 600; margin-bottom: .3em; }
.cta p { max-width: 36em; margin: 0 auto; }
.cta .actions { justify-content: center; }

/* Footer */
.footer { background: var(--navy-2); color: #dde2ea; font-size: 1.05rem; }
.footer .wrap { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 48px; padding-top: 60px; padding-bottom: 48px; }
.footer h2 { font-family: var(--sans); font-size: .875rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--gold-light); margin-bottom: 1.1em; }
.footer .footer-brand { font-family: var(--display); font-size: 1.6rem; font-weight: 600; color: #fff; display: block; margin-bottom: .4em; line-height: 1.2; }
.footer a { color: #fff; text-decoration-color: rgba(216,192,138,.6); }
.footer a:hover { color: var(--gold-light); }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li { margin-bottom: 8px; }
.footer-base { border-top: 1px solid #263755; font-size: .92rem; color: #c3cad5; }
.footer-base .wrap { display: block; padding-top: 18px; padding-bottom: 18px; }

/* Responsive */
@media (max-width: 860px) {
  .hero .wrap, .split, .footer .wrap { grid-template-columns: 1fr; gap: 40px; }
  .hero .wrap { padding-top: 52px; padding-bottom: 56px; }
  .practice, .contact-grid { grid-template-columns: 1fr; gap: 20px; }
  .checklist { columns: 1; }
  .signed-in { text-align: left; margin-top: -20px; }
  .doc-toolbar { grid-template-columns: 1fr 1fr; }
  .staff-grid { grid-template-columns: 1fr; }
  .admin-grid { grid-template-columns: 1fr; }
  .field-grid, .send-kinds { grid-template-columns: 1fr; }
  .field-grid .field-wide { grid-column: auto; }
  .id-photos, .id-images { grid-template-columns: 1fr; }
  .editor { grid-template-columns: 1fr; }
  .palette { position: static; }
  .adopt-fields { grid-template-columns: 1fr; }
  .sign-dock-inner { grid-template-columns: 1fr; gap: 8px; padding-top: 10px; padding-bottom: 12px; }
  .sign-dock-status { justify-content: space-between; }
  .sign-intent { font-size: .85rem; }
  #sign-doc { padding-bottom: 230px; }
  .settings-card { padding: 22px 18px; }
  .settings-card .details { grid-template-columns: 1fr; gap: 0; }
  .settings-card .details dd { margin-bottom: 10px; }
  .doc-toolbar .field:first-child { grid-column: 1 / -1; }
  .doc-table thead { display: none; }
  .doc-table, .doc-table tbody, .doc-table tr, .doc-table td { display: block; }
  .doc-table tr { padding: 12px 16px; border-bottom: 1px solid var(--rule); }
  .doc-table td { padding: 2px 0; border: 0; }
  .doc-table td.cell-empty { display: none; }
  .doc-table td[data-label]::before { content: attr(data-label) ": "; color: var(--muted); }
  .doc-action { text-align: left; padding-top: 8px !important; }
  .section { padding: 60px 0; }
  .cta { padding: 56px 0; }
  aside { position: static; }
}

@media (max-width: 560px) {
  .wrap { padding: 0 18px; }
  .brand { flex-direction: column; text-align: center; gap: 12px; }
  .brand-sub { white-space: normal; text-align: center; text-align-last: center; font-size: .7rem; line-height: 1.5; }
  .nav a { padding: 10px 9px; font-size: .85rem; letter-spacing: .05em; }
  .callbox { padding: 28px 20px; }
  .portal-card { padding: 32px 22px; }
  .callbox .phone { font-size: 2rem; }
  .actions .btn { flex: 1 1 100%; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}

@media print {
  .topbar, .nav, .footer, .cta { display: none; }
  body { background: #fff; }
}

