/* Elyvris — layers, response, design. */
:root {
  --paper: #F2EEE5;
  --ink: #131B23;
  --muted: #5D626B;
  --line: #D2CFC8;
  --dark: #131B23;
  --lime: #EFB653;
  --copper: #6A4D95;
  --earth: #6A4D95;
  --earth-light: #E8E0EF;
  --copper-light: #EFB653;
  --espresso: #131B23;
  --serif: 'Arial', 'Helvetica Neue', sans-serif;
  --lavender: #A38CD9;
  --amber: #EFB653;
}
body { background: var(--paper); color: var(--ink); font-family: 'Arial', 'Helvetica Neue', sans-serif; }
a, button, input, select, summary { -webkit-tap-highlight-color: transparent; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible, [tabindex]:focus-visible { outline: 3px solid #886ABA; outline-offset: 5px; }
::selection { background: var(--lavender); color: var(--ink); }
h1, h2, h3 { text-wrap: balance; }
h1, h2 { font-weight: 500; }
em { color: #6A4D95; font-style: normal; }
.wrap, .rn-wrap { max-width: 1248px; width: calc(100% - 112px); }
.site-header, .rn-header { height: 100px; gap: 28px; border-color: var(--line); }
.wordmark, .rn-wordmark { display: inline-flex; align-items: center; gap: 11px; flex-shrink: 0; white-space: nowrap; color: var(--ink); font: 600 30px/1 'Arial', sans-serif; letter-spacing: -1.6px; }
.wordmark:hover, .rn-wordmark:hover { text-decoration: none; }
.wordmark img, .rn-wordmark img { display: block; width: 34px; height: 38px; object-fit: contain; flex-shrink: 0; }
.site-header nav, .rn-header nav { display: flex; align-items: center; gap: 30px; font-size: 12px; }
.site-header nav>a, .rn-header nav>a { display: inline-block; }
.nav-contact { border: 0; padding: 0; border-radius: 0; }
.site-header nav a:hover, .rn-header nav a:hover, .text-link:hover { color: #6A4D95; }
.rn-header nav a[aria-current='page'] { border-color: #6A4D95; }
.eyebrow, .rn-eyebrow { color: #6A4D95; font: 500 10px/1.7 'Courier New', monospace; letter-spacing: 1.3px; }
.button, .rn-button { border-radius: 0; }
.button.primary:hover, .rn-button:hover { background: #3B3153; }
.skip { background: var(--amber); color: var(--ink); }
.text-link { border-color: currentColor; }
.rn-footer, .records-footer, .resume-footer, .lab-footer { color: var(--muted); border-color: var(--line); }
.rn-footer a, .records-footer a, .resume-footer a, .lab-footer a { color: var(--ink); }

/* The research record is deliberately quieter than the project front page. */
.rn-hero { padding-top: 66px; padding-bottom: 52px; }
.rn-hero h1, .records-intro h1 { font-size: clamp(54px, 7vw, 88px); font-weight: 500; letter-spacing: -4.5px; line-height: 1; margin-bottom: 22px; }
.rn-lead { font-size: 15px; line-height: 1.8; margin-bottom: 37px; }
.research-sections { gap: 28px; }
.research-sections a { border-color: var(--ink); padding-top: 19px; }
.research-sections strong { font-size: 21px; font-weight: 500; letter-spacing: -.65px; }
.research-sections span { color: #6A4D95; }
.research-section-heading h2 { font-weight: 500; font-size: clamp(30px, 3.4vw, 42px); letter-spacing: -1.6px; }
.research-papers { padding-top: 42px; padding-bottom: 58px; }
.research-paper-list { gap: 30px 56px; }
.research-paper-list h3 { font-size: 16px; line-height: 1.55; letter-spacing: -.25px; }
.research-paper-list .paper-year { color: #6A4D95; font-family: 'Courier New', monospace; }
.research-paper-list li { border-color: var(--line); }
.research-profile-links { font-size: 12px; }
.rn-anapoles { padding-top: 58px; }
.rn-article-header h2 { font-weight: 500; letter-spacing: -1.8px; }
.rn-article-header h2 em { color: #6A4D95; }
.anapole-condition .rn-equation { color: var(--ink); background: #E8E1EE; border: 0; padding: 29px 14px; }
.anapole-field-cycle, .anapole-temporal { border-color: #C8C4CD; border-radius: 0; background: #F9F6F0; }
.afc-heading, .at-heading { border-color: #D6D0DC; }
.afc-heading h3, .at-heading h3 { font-family: Arial, sans-serif; font-weight: 500; letter-spacing: -.65px; font-size: 23px; }
.afc-heading p, .at-heading p, .afc-plane, .anapole-field-cycle>figcaption, .at-source { color: var(--muted); }
.afc-controls, .at-current { background: #EAE4EF; border-color: #D2C9DE; }
.afc-controls button, .anapole-temporal button, .anapole-field-cycle button { color: var(--ink); border-color: #ADA3BA; border-radius: 0; }
.afc-controls button:hover:not(:disabled), .anapole-temporal button:hover:not(:disabled), .anapole-field-cycle button:hover:not(:disabled) { background: #DDD1EB; }
.afc-quarters button[aria-pressed='true'], .at-groups button[aria-pressed='true'] { color: var(--paper); background: var(--ink); border-color: var(--ink); }
.afc-phase-control input, .at-scrub input { accent-color: #6A4D95; }
.anapole-field-cycle summary, .at-source summary, .at-data>summary { color: #6A4D95; }
.anapole-field-cycle figcaption a, .at-source a, .anapole-paper-link a { color: var(--ink); border-color: #9B89B8; }
.at-data thead th { background: #EAE4EF; color: var(--ink); }
.at-data th, .at-data td { border-color: #D6D0DC; }
/* Field colour scales and E/H event colours retain their data meanings. */

.records-intro { padding-top: 64px; padding-bottom: 43px; }
.records-intro .eyebrow { color: #6A4D95; }
.records-intro h1 { margin: 0; }
.records-intro-grid { gap: 50px; }
.photo-collection-top { border-color: var(--line); }
.photo-filters button { border-radius: 0; padding: 10px 19px; }
.photo-filters button:hover { background: #E5DCEC; }
.photo-filters button[aria-pressed='true'] { background: var(--ink); color: var(--paper); }
.gallery-open, .gallery-piece[data-kind='illustration'] .gallery-open { border-radius: 0; background: #E4DFE7; }
.gallery-enlarge { background: #131B23E8; color: var(--paper); border-color: #F2EEE545; border-radius: 0; }
.gallery-caption h3 { font-family: Arial, sans-serif; font-weight: 500; font-size: 22px; letter-spacing: -.7px; }
.gallery-kind, .gallery-photo-context { color: #6A4D95; }
.photo-lightbox { border: 0; border-radius: 0; background: var(--paper); color: var(--ink); }
.photo-lightbox::backdrop { background: #080D14E8; }
.lightbox-toolbar, .lightbox-caption { border-color: #CCC6D0; }
.lightbox-kind, .lightbox-position, .lightbox-metadata { color: var(--muted); }
.lightbox-close, .lightbox-direction { border-radius: 0; background: var(--ink); color: var(--paper); }
.lightbox-stage { background: #161D27; }

.resume h1 { font-weight: 500; }
.resume h2 { font-weight: 500; letter-spacing: -1px; }
.resume .resume-tools>a { font-size: 12px; }
.resume-footer { padding: 24px 0; }
.lab-intro h1 { letter-spacing: -3.5px; }
.lab-intro h1 em { color: #6A4D95; }
.lab-tags span, .lab-tags a { color: #6A4D95; border-color: #C4B7D2; border-radius: 0; }
.explorer, .explorer-top, .explorer .controls, .explorer .results { border-color: #C8C1CE; }
.explorer, .explorer .controls { background: #EAE5EE; }
.explorer .results { background: #F8F5EF; }
.explorer input, .explorer select, .presets button { border-radius: 0; }
.explorer input[type='range'] { accent-color: #6A4D95; }
.lab-help>summary, .data-references a { color: var(--ink); }
@media (max-width: 1000px) {
  .wrap, .rn-wrap { width: calc(100% - 64px); }
}
@media (max-width: 700px) {
  .wrap, .rn-wrap { width: calc(100% - 40px); }
  .site-header, .rn-header { height: 82px; gap: 16px; }
  .wordmark, .rn-wordmark { gap: 8px; font-size: 26px; letter-spacing: -1.3px; }
  .wordmark img, .rn-wordmark img { width: 28px; height: 31px; }
  .site-header nav, .rn-header nav { gap: 20px; font-size: 11px; flex-shrink: 0; }
  .site-header nav>a, .rn-header nav>a:first-child, .rn-header nav>a:nth-child(3) { display: inline-block; }
  .rn-hero, .records-intro { padding-top: 42px; }
  .rn-hero h1, .records-intro h1 { font-size: 58px; letter-spacing: -3px; }
  .rn-lead { font-size: 13px; margin-bottom: 30px; }
  .research-sections { gap: 18px 26px; }
  .research-sections strong { font-size: 20px; }
  .research-papers { padding-top: 32px; padding-bottom: 42px; }
  .research-paper-list { gap: 24px; }
  .rn-anapoles { padding-top: 42px; }
  .rn-article-header h2 { font-size: 36px; }
  .afc-heading h3, .at-heading h3 { font-size: 21px; }
  .records-intro-grid { gap: 22px; }
  .records-footer { gap: 20px; flex-wrap: wrap; }
  .resume h1 { font-size: 50px; letter-spacing: -2.5px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
@media print {
  body { background: #FFF; color: #000; }
  .wrap, .rn-wrap { width: 100%; }
  .wordmark, .rn-wordmark { color: #000; }
  .rn-hero h1, .records-intro h1 { font-size: 44px; }
  .anapole-condition .rn-equation, .afc-controls, .at-current { background: #FFF; border: 1px solid #CCC; }
}
/* Photo captions stay readable outside the dark image stage. */
.lightbox-caption h2 { color: var(--ink); font-weight: 500; }
.lightbox-caption>div>p, .lightbox-metadata { color: var(--muted); }
.lightbox-metadata a { color: var(--ink); border-color: #9B89B8; }
.lightbox-close:hover, .lightbox-direction:hover { background: #3B3153; }
.photo-filters button:focus-visible, .gallery-open:focus-visible, .lightbox-close:focus-visible, .lightbox-direction:focus-visible, .lightbox-metadata a:focus-visible, .lightbox-caption:focus-visible, .anapole-temporal button:focus-visible, .anapole-temporal input:focus-visible, .anapole-field-cycle button:focus-visible, .anapole-field-cycle input:focus-visible, .at-plot-scroll:focus-visible { outline-color: #886ABA; }
