/* Preview-only UI; the live site receives no banner or offset. */
:root { --preview-banner-height: 0px; }
.preview-site { padding-top: var(--preview-banner-height); }
.preview-site .navbar { top: var(--preview-banner-height); }
.preview-banner {
  position: fixed; inset: 0 0 auto; z-index: 1001;
  display: flex; align-items: center; justify-content: center; flex-wrap: wrap;
  gap: 4px 24px; padding: 9px 16px;
  background: var(--gold, #C9A96E); color: var(--navy, #272727);
  font-family: var(--font-sans, system-ui); font-size: .8rem; line-height: 1.5; text-align: center;
}
.preview-banner-text { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 4px 12px; }
.preview-banner strong { letter-spacing: .08em; }
.preview-banner a { font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.preview-banner a:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
.preview-site .about-photo-wrap { top: calc(var(--nav-height) + var(--preview-banner-height) + 32px); }
html:has(.preview-site) { scroll-padding-top: calc(var(--nav-height) + var(--preview-banner-height)); }
@media (max-width: 700px) {
  .preview-site .nav-links { position: absolute; top: 100%; max-height: calc(100dvh - var(--nav-height) - var(--preview-banner-height)); overflow-y: auto; }
  .preview-banner { gap: 3px 16px; }
}
/* The content renderer uses the existing card and type styles. */
.cms-paragraph { white-space: pre-line; }
.cms-education-list { display: grid; gap: 24px; }
.cms-contact-label { font-size: .78rem; color: var(--gray-400); margin-bottom: 2px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; }

/* Accessible text selection, independent of customized light or dark page colors. */
::selection { background: #1769AA; color: #FFFFFF; text-shadow: none; }
.cms-rich mark { background: #FFE08A; color: #171717; }
/* Optional header logo. Keep it within the existing fixed-height navigation. */
.nav-logo.cms-brand { display: inline-flex; align-items: center; gap: 9px; min-width: 0; max-width: 50%; line-height: 1.15; }
.cms-brand .cms-header-logo { display: block; flex: 0 0 auto; width: auto; height: auto; max-width: min(150px, 32vw); max-height: 40px; object-fit: contain; }
.cms-brand[data-brand-size="small"] .cms-header-logo { max-height: 27px; max-width: min(100px, 26vw); }
.cms-brand[data-brand-size="large"] .cms-header-logo { max-height: 52px; max-width: min(190px, 40vw); }
.cms-brand-name { min-width: 0; overflow-wrap: anywhere; }
.cms-brand[data-brand-layout="right"] { flex-direction: row-reverse; }
.cms-brand[data-brand-layout="logo"] .cms-brand-name { display: none; }
.cms-brand[data-brand-layout="above"], .cms-brand[data-brand-layout="below"] { flex-direction: column; gap: 2px; text-align: center; font-size: .82rem; }
.cms-brand[data-brand-layout="below"] { flex-direction: column-reverse; }
.cms-brand[data-brand-layout="above"] .cms-header-logo, .cms-brand[data-brand-layout="below"] .cms-header-logo { max-height: 30px; }
.cms-brand[data-brand-layout="above"][data-brand-size="small"] .cms-header-logo, .cms-brand[data-brand-layout="below"][data-brand-size="small"] .cms-header-logo { max-height: 20px; }
.cms-brand[data-brand-layout="above"][data-brand-size="large"] .cms-header-logo, .cms-brand[data-brand-layout="below"][data-brand-size="large"] .cms-header-logo { max-height: 36px; }
/* Image framing is stored separately in design.json and responds to actual viewport width. */
.hero-bg { background-position: var(--cms-hero-x, 50%) var(--cms-hero-y, 20%); background-size: var(--cms-hero-fit, cover); background-color: var(--navy); }
.cms-hero-layout { position: relative; z-index: 1; width: min(1120px, 100%); display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: center; gap: clamp(24px, 5vw, 72px); padding: calc(var(--nav-height) + 30px) clamp(20px, 4vw, 48px) 48px; text-align: start; }
.cms-hero-layout .hero-content { max-width: none; min-width: 0; padding: 0; }
.cms-hero-layout .hero-content .description { margin-inline: 0; }
.cms-hero-figure { min-width: 0; display: flex; align-items: center; justify-content: center; }
.cms-hero-photo { display: block; width: 100%; max-width: 390px; max-height: min(60vh, 520px); height: auto; object-fit: contain; filter: drop-shadow(0 5px 20px #0005); }
.cms-hero-layout[data-image-size="small"] .cms-hero-photo { max-width: 250px; max-height: min(48vh, 340px); }
.cms-hero-layout[data-image-size="large"] .cms-hero-photo { max-width: 500px; max-height: min(68vh, 620px); }
.cms-hero-layout[data-position="left"] { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); }
.cms-hero-layout[data-position="left"] .cms-hero-figure { grid-column: 1; grid-row: 1; }
.cms-hero-layout[data-position="left"] .hero-content { grid-column: 2; grid-row: 1; }
@media (max-width: 700px) {
  .nav-logo.cms-brand { max-width: calc(100% - 52px); }
  .hero-bg { background-position: var(--cms-hero-mobile-x, var(--cms-hero-x, 50%)) var(--cms-hero-mobile-y, var(--cms-hero-y, 20%)); }
  .cms-hero-layout, .cms-hero-layout[data-position="left"] { display: flex; flex-direction: column; text-align: center; padding: calc(var(--nav-height) + 24px) 24px 40px; gap: 26px; }
  .cms-hero-layout[data-mobile-position="above"] .cms-hero-figure { order: -1; }
  .cms-hero-layout .hero-content .description { margin-inline: auto; }
  .cms-hero-layout .cms-hero-figure { width: 100%; }
  .cms-hero-layout .cms-hero-photo { max-width: min(100%, 300px); max-height: min(44vh, 360px); }
  .cms-hero-layout[data-image-size="small"] .cms-hero-photo { max-width: min(100%, 200px); max-height: min(36vh, 250px); }
  .cms-hero-layout[data-image-size="large"] .cms-hero-photo { max-width: min(100%, 380px); max-height: min(52vh, 420px); }
}

/* Bootstrap icons are decorative; their badge contrast is computed from the actual theme. */
.cms-bi-badge { color: var(--cms-on-primary, #FFFFFF); }
.cms-bi-badge .bi { font-size: 1.35rem; line-height: 1; display: inline-flex; align-items: center; justify-content: center; }
.cms-bi-badge .bi::before { vertical-align: 0; }
