/* Roberson, Kolker, Prentice, Burns — shared styles. Page layouts are inline from the approved Courthouse design. */
:root { color-scheme: dark; --bronze: #B08D57; --bronze-hi: #E2C690; --paper: #EDE6DA; --line: #3A342A; }
html { scroll-behavior: smooth; background: #111111; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: #111111; color: var(--paper); font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif; -webkit-text-size-adjust: 100%; }
a { color: #C9A56E; } a:hover { color: var(--bronze-hi); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid var(--bronze-hi); outline-offset: 3px; }
img, video { max-width: 100%; }
section[id] { scroll-margin-top: 12px; }

/* Intro film: first visit each session */
.intro { position: fixed; inset: 0; z-index: 50; background: #0A0A0A; transition: opacity 0.6s ease; }
.intro > div { height: 100% !important; }
.intro.leaving { opacity: 0; pointer-events: none; }
.no-intro .intro { display: none; }
html.intro-open, html.intro-open body { overflow: hidden; }
#enter-site { top: calc(40px + env(safe-area-inset-top, 0px)) !important; right: max(24px, calc(48px + env(safe-area-inset-right, 0px))) !important; cursor: pointer; }
.intro div[style*="bottom: 44px"] { bottom: calc(44px + env(safe-area-inset-bottom, 0px)) !important; right: max(24px, calc(48px + env(safe-area-inset-right, 0px))) !important; }

/* The intro film's titles sit on the left of the frame. Wide windows crop from the right only;
   squarish windows and portrait phones show the whole frame so no title is ever cut. */
.intro video { object-position: 0% 50% !important; }
@media (max-aspect-ratio: 13/10) {
  .intro video { object-fit: contain !important; object-position: 50% 50% !important; }
}

/* Contact form */
.contact-form { width: 100%; max-width: 680px; margin-top: 28px; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; text-align: left; scroll-margin-top: 24px; }
.contact-form .full { grid-column: 1 / -1; }
.contact-form label { display: flex; flex-direction: column; gap: 8px; font-size: 13px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: #C9A56E; }
.contact-form input, .contact-form textarea { font: 400 17px/1.5 'Inter', system-ui, sans-serif; color: var(--paper); background: #0D0C09; border: 1px solid var(--line); border-radius: 2px; padding: 13px 14px; min-height: 48px; box-sizing: border-box; width: 100%; }
.contact-form textarea { min-height: 150px; resize: vertical; }
.contact-form input:focus, .contact-form textarea:focus { border-color: var(--bronze); outline: none; }
.contact-form button { justify-self: center; min-height: 52px; padding: 0 34px; background: var(--bronze); color: #111111; border: 0; border-radius: 2px; font: 600 16px 'Inter', system-ui, sans-serif; letter-spacing: 0.04em; cursor: pointer; }
.contact-form button:hover { background: var(--bronze-hi); }
.contact-form .note { margin: 0; font-size: 13px; line-height: 1.5; color: #8F877A; text-align: center; }
.contact-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 640px) { .contact-form { grid-template-columns: 1fr; } }

/* Document viewer */
.doc { position: fixed; inset: 0; z-index: 60; background: rgba(6,6,6,0.985); display: flex; flex-direction: column; }
.doc[hidden] { display: none; }
.doc-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: calc(12px + env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) 12px max(16px, env(safe-area-inset-left, 0px)); border-bottom: 1px solid var(--line); background: #0A0A0A; }
.doc-title { margin: 0; font: italic 600 18px/1.3 'Lora', Georgia, serif; color: var(--paper); min-width: 0; }
.doc-close { flex: none; min-height: 44px; padding: 0 20px; background: transparent; border: 1px solid var(--bronze); color: var(--bronze-hi); font: 600 14px 'Inter', system-ui, sans-serif; letter-spacing: 0.08em; cursor: pointer; }
.doc-pages { flex: 1; overflow: auto; padding: 24px max(16px, env(safe-area-inset-right, 0px)) calc(32px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); display: flex; flex-direction: column; align-items: center; gap: 18px; }
.doc-pages img { width: 100%; max-width: 860px; height: auto; display: block; background: #fff; box-shadow: 0 8px 30px rgba(0,0,0,0.5); }
html.doc-open, html.doc-open body { overflow: hidden; }

/* Phone sizing for the design's large display type */
@media (max-width: 720px) {
  [style*="font-size: 220px"] { font-size: 140px !important; }
  [style*="font-size: 112px"] { font-size: 84px !important; }
  [style*="font-size: 108px"] { font-size: 68px !important; }
  [style*="font-size: 64px"] { font-size: 44px !important; }
  [style*="font-size: 60px"] { font-size: 42px !important; }
  [style*="font-size: 58px"] { font-size: 46px !important; }
  [style*="font-size: 56px"] { font-size: 40px !important; }
  [style*="font-size: 48px"] { font-size: 36px !important; }
  [style*="padding: 96px 24px"], [style*="padding: 104px 24px"] { padding-top: 64px !important; padding-bottom: 64px !important; }
  .intro span[style*="font-size: 22px"] { font-size: 16px !important; }
  .intro span[style*="font-size: 13px"] { font-size: 11px !important; }
}
