:root {
  color-scheme: dark;
  --bg: #0c1528;
  --panel: #14223b;
  --line: #4d6385;
  --ink: #edf4ff;
  --muted: #b0c2de;
  --accent: #8bbaff;
  --button-bg: #8bbaff;
  --button-hover: #b5d3ff;
  --button-ink: #0c1c3a;
  --social-bg: #20385d;
  --social-line: #456da1;
  --error: #ff9e8a;
  --mono: "IBM Plex Mono", monospace;
  --display: "Archivo Black", "Arial Black", sans-serif;
  font-family: "DM Sans", system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink);
  scroll-behavior: smooth;
}
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f1f6ff;
  --panel: #fff;
  --line: #9aaec9;
  --ink: #142442;
  --muted: #425676;
  --accent: #154eb5;
  --button-bg: #1d55c4;
  --button-hover: #1746a4;
  --button-ink: #fff;
  --social-bg: #e3edff;
  --social-line: #adc1ea;
  --error: #9f3027;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; }
[hidden] { display: none !important; }
a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .65; cursor: wait; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.wrap { width: min(1160px, calc(100% - 2 * clamp(20px, 5vw, 72px))); margin-inline: auto; }
.top { border-bottom: 1px solid var(--line); }
.top-inner, .footer-inner, .dialog-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.top-inner { min-height: 78px; flex-wrap: wrap; }
.wordmark { font: 1.25rem var(--display); letter-spacing: -.07em; white-space: nowrap; }
.wordmark span { color: var(--accent); }
.site-logo { display: inline-grid; place-items: center; width: 44px; height: 44px; flex: 0 0 auto; }
.site-logo img { display: block; }
nav { display: flex; gap: clamp(12px, 3vw, 36px); align-items: center; font-size: .9rem; }
nav a:hover, .footer-inner > a:last-child:hover { color: var(--accent); }
.outline, .button { display: inline-flex; align-items: center; justify-content: center; gap: 14px; padding: .75rem 1rem; min-height: 44px; border: 1px solid var(--line); background: transparent; color: var(--ink); font-weight: 700; }
.outline:hover { border-color: var(--accent); color: var(--accent); }
.button { background: var(--button-bg); color: var(--button-ink); border-color: var(--accent); padding-inline: 1.2rem; }
.button:hover { background: var(--button-hover); }
[data-theme="light"] .theme-toggle { color: var(--accent); border-color: var(--accent); background: var(--social-bg); }
.hero { display: grid; grid-template-columns: 1.3fr 1fr; align-items: center; gap: clamp(30px, 5vw, 78px); padding: clamp(46px, 8vw, 110px) 0 50px; }
.eyebrow { display: flex; align-items: center; gap: 10px; margin: 0 0 16px; font: 500 .78rem var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.dot { width: 8px; height: 8px; background: var(--accent); display: inline-block; border-radius: 50%; }
h1, .contact h2, .admin h2 { font-family: var(--display); line-height: .98; letter-spacing: -.09em; margin: 0; }
h1 { font-size: clamp(3.4rem, 9vw, 8rem); }
h1 span, .contact h2 span, .admin h2 span { color: var(--accent); }
.lede, .contact > div > p:not(.eyebrow) { color: var(--muted); font-size: clamp(1rem, 1.7vw, 1.22rem); line-height: 1.6; max-width: 38ch; margin: 22px 0 28px; }
.hero-photo { margin: 0; min-width: 0; aspect-ratio: 1.06; overflow: hidden; border: 1px solid var(--line); }
.hero-photo img, .gallery-grid img { width: 100%; height: 100%; display: block; object-fit: cover; }
.hero-photo img { object-position: 68% 45%; }
.socials, .gallery, .contact, .admin { scroll-margin-top: 24px; }
.socials { padding: 23px 0 52px; }
.social-grid, .admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.social-grid a { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 16px; padding: 16px 20px; background: var(--panel); border: 1px solid var(--line); }
.social-grid a:hover { border-color: var(--accent); }
.social-grid strong { display: block; font-size: 1.12rem; }
.social-grid small { color: var(--muted); font: .8rem var(--mono); }
.social-icon { display: grid; place-items: center; width: 43px; height: 43px; border: 1px solid var(--social-line); background: var(--social-bg); color: var(--accent); font-size: 1.65rem; font-weight: 700; }
.arrow { color: var(--accent); font-size: 1.35rem; }
.camera { position: relative; width: 17px; height: 17px; border: 1.7px solid currentColor; border-radius: 5px; }
.camera::before { content: ""; position: absolute; inset: 3px; border: 1.4px solid currentColor; border-radius: 50%; }
.camera::after { content: ""; position: absolute; top: 1px; right: 2px; width: 2px; height: 2px; border-radius: 50%; background: currentColor; }
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: 25px; padding: 52px 0; border-top: 1px solid var(--line); }
.gallery { padding: 46px 0 52px; border-top: 1px solid var(--line); }
.gallery h2 { margin: 0 0 22px; font: clamp(2.4rem, 5vw, 4.5rem)/.98 var(--display); letter-spacing: -.09em; }
.gallery h2 span { color: var(--accent); }
.gallery-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.gallery-grid a { overflow: hidden; border: 1px solid var(--line); aspect-ratio: 4 / 5; }
.gallery-grid a:hover { border-color: var(--accent); }
.gallery-grid img { object-position: center 60%; }
.gallery-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.gallery-controls { display: flex; gap: 8px; }
.gallery-controls button[aria-disabled="true"] { opacity: .5; cursor: default; }
.gallery-grid.gallery-scroll {
  display: flex;
  overflow-x: auto;
  padding-bottom: 10px;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-color: var(--line) transparent;
}
.gallery-scroll > * { flex: 0 0 calc((100% - 28px) / 3); min-width: 0; scroll-snap-align: start; }
@media (max-width: 760px) {
  .gallery-scroll > * { flex-basis: 72%; }
}
@media (prefers-reduced-motion: reduce) {
  .gallery-grid.gallery-scroll { scroll-behavior: auto; }
}
.contact h2, .admin h2 { font-size: clamp(2.4rem, 5vw, 4.5rem); }
.panel, dialog { padding: clamp(20px, 4vw, 32px); border: 1px solid var(--line); background: var(--panel); min-width: 0; }
.panel h3 { margin: 0 0 10px; font-size: 1.25rem; }
.panel p, .hint { color: var(--muted); line-height: 1.5; }
.text-button { border: 0; background: none; color: var(--accent); padding: .7rem .4rem; text-decoration: underline; text-underline-offset: .25em; }
form label { display: grid; gap: 7px; margin-bottom: 14px; font-weight: 600; }
input, textarea { width: 100%; border: 1px solid var(--line); color: var(--ink); background: var(--bg); padding: .72rem; border-radius: 0; }
textarea { resize: vertical; }
.hint, .status { font-size: .86rem; }
.status:empty { display: none; }
.status[data-error="true"] { color: var(--error); }
.admin { padding: 38px 0 58px; border-top: 1px solid var(--line); }
.admin > button { margin: 18px 0; }
.admin-grid { align-items: start; }
.entry { border-top: 1px solid var(--line); padding: 15px 0; overflow-wrap: anywhere; }
.entry h4, .entry p { margin: 0 0 8px; }
.entry .message-body { color: var(--ink); white-space: pre-wrap; }
.entry .hint { margin-bottom: 12px; }
footer { border-top: 1px solid var(--line); }
.footer-inner { min-height: 72px; }
.footer-inner > a:last-child { color: var(--muted); font: .78rem var(--mono); }
dialog { width: min(440px, calc(100vw - 32px)); color: var(--ink); }
dialog::backdrop { background: #000b; }
.dialog-top { margin-bottom: 20px; }
.dialog-top h2 { margin: 0; font-family: var(--display); font-size: 1.45rem; }
@media (max-width: 760px) {
  .top-inner { flex-wrap: wrap; padding: 14px 0; }
  nav { flex-wrap: wrap; gap: 12px; }
  .hero, .contact, .admin-grid { grid-template-columns: 1fr; }
  .hero { padding-bottom: 24px; }
  h1 { font-size: clamp(3.55rem, 15vw, 6rem); }
  .hero-photo { aspect-ratio: 1.2; }
}
@media (max-width: 480px) {
  .social-grid { grid-template-columns: 1fr; }
  .gallery-grid { gap: 7px; }
}
@media (prefers-reduced-motion: reduce) { :root { scroll-behavior: auto; } }

.video-ad { width: min(560px, calc(100% - 24px)); max-height: calc(100% - 24px); }
.video-ad-header, .video-ad-actions { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.video-ad-header h2 { margin: 0; font: 1.3rem var(--display); }
.video-ad-progress { margin: 0; color: var(--muted); font: .8rem var(--mono); }
.video-ad video { display: block; width: 100%; height: min(62dvh, 660px); margin: 14px 0; background: #000; object-fit: contain; }

nav a[aria-current="page"] { color: var(--accent); }
.about-intro { padding: clamp(48px, 9vw, 112px) 0 48px; }
.about-intro h1 { font-size: clamp(2.8rem, 10vw, 7rem); }
.about-copy { max-width: 72ch; margin: 24px 0; font-size: 1.13rem; line-height: 1.65; overflow-wrap: anywhere; }
.about-copy p { color: inherit; }
.about-copy:empty { margin-bottom: 0; }
.about-editor, .about-upload { max-width: 820px; }
.about-upload { margin-bottom: 24px; }
.editor-toolbar, .editor-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.editor-toolbar label { display: flex; align-items: center; gap: 8px; margin: 0; }
.editor-toolbar select { padding: 8px; color: var(--ink); background: var(--bg); border: 1px solid var(--line); font: inherit; }
.editor-toolbar input[type="color"] { width: 44px; height: 44px; padding: 4px; }
.editor-input { max-width: none; padding: 16px; min-height: 210px; background: var(--bg); border: 1px solid var(--line); }
.about-photos:not(:empty) + .about-photos { margin-top: 14px; }
.about-photos a { display: block; }
.about-photos button { margin: 8px 0 12px; }
@media (max-width: 620px) {
  .about-photos { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.live-photo-hero { min-height: min(650px, 75vh); }
.live-photo-hero h1 { font-size: clamp(2.75rem, 7.1vw, 6.5rem); }
.live-photo-hero .hint { color: var(--muted); }
.live-photo-steps h2 { margin-top: 0; font: clamp(1.35rem, 3vw, 2rem) var(--display); }
.live-photo-steps ol { padding-left: 1.45rem; line-height: 1.55; }
.live-photo-steps li + li { margin-top: .7rem; }
.live-photo-steps li::marker { color: var(--accent); font-family: var(--mono); }
