/* TR Lighting — shared styles */
:root {
  --bg: #0a0908;
  --bg-soft: #15130f;
  --fg: #f3ece0;
  --fg-mute: rgba(243, 236, 224, 0.55);
  --fg-faint: rgba(243, 236, 224, 0.28);
  --rule: rgba(243, 236, 224, 0.14);
  --champagne: #d9c9a8;
  --gold: #b8a274;
  --serif: "Cormorant Garamond", "EB Garamond", Georgia, serif;
  --sans: "Inter", ui-sans-serif, system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
}

[data-palette="ivory"] {
  --bg: #f3ece0;
  --bg-soft: #ece4d4;
  --fg: #1c1814;
  --fg-mute: rgba(28, 24, 20, 0.55);
  --fg-faint: rgba(28, 24, 20, 0.25);
  --rule: rgba(28, 24, 20, 0.14);
  --champagne: #8a7a5c;
  --gold: #6b5a3a;
}

[data-palette="oyster"] {
  --bg: #ebe7df;
  --bg-soft: #e2ddd2;
  --fg: #1a1a1a;
  --fg-mute: rgba(26, 26, 26, 0.55);
  --fg-faint: rgba(26, 26, 26, 0.25);
  --rule: rgba(26, 26, 26, 0.12);
  --champagne: #7a7568;
  --gold: #5e574a;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { background: var(--bg); color: var(--fg); }
body {
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "ss01", "cv11";
  transition: background-color 1.6s cubic-bezier(.22,.61,.36,1), color 1.6s cubic-bezier(.22,.61,.36,1);
  min-height: 100vh;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

.serif { font-family: var(--serif); font-weight: 400; letter-spacing: -0.01em; }
.mono { font-family: var(--mono); font-feature-settings: "tnum"; }
.label {
  font-family: var(--sans);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--fg-mute);
}

/* ───────── Header ───────── */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 22px 40px;
  pointer-events: none;
  mix-blend-mode: normal;
}
.header > * { pointer-events: auto; }

.header__logo {
  font-family: var(--serif);
  font-size: 17px;
  letter-spacing: 0.02em;
  display: flex; align-items: center; gap: 10px;
  color: var(--fg);
}
.header__logo .mark {
  width: 8px; height: 8px;
  background: var(--champagne);
  border-radius: 50%;
  box-shadow: 0 0 18px var(--champagne);
}

.header__nav {
  display: flex; gap: 28px;
  justify-self: center;
  font-size: 11.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.header__nav a {
  color: var(--fg-mute);
  position: relative;
  padding: 6px 0;
  transition: color .35s ease;
}
.header__nav a:hover, .header__nav a.is-active { color: var(--fg); }
.header__nav a.is-active::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0;
  height: 1px; background: var(--champagne);
}

.header__meta {
  justify-self: end;
  display: flex; gap: 18px; align-items: center;
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--fg-mute);
}
.header__meta .dot {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--champagne);
  box-shadow: 0 0 8px var(--champagne);
}

.header__theme {
  justify-self: end;
  display: flex;
  align-items: center;
}
.theme-toggle {
  border: 1px solid var(--rule);
  background: rgba(255,255,255,0.03);
  color: var(--fg-mute);
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 9px 12px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: color .35s ease, border-color .35s ease, background-color .35s ease, transform .35s ease;
}
.theme-toggle:hover {
  color: var(--fg);
  border-color: var(--champagne);
  background: color-mix(in srgb, var(--champagne) 10%, transparent);
  transform: translateY(-1px);
}
.theme-toggle__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--champagne);
  box-shadow: 0 0 10px var(--champagne);
}
[data-palette="dark"] .theme-toggle {
  color: var(--fg);
  border-color: rgba(243, 236, 224, 0.24);
}

/* ───────── Footer ───────── */
.footer {
  border-top: 1px solid var(--rule);
  padding: 80px 40px 40px;
  display: grid;
  grid-template-columns: minmax(280px, 1.6fr) minmax(140px, .6fr) minmax(240px, .9fr);
  gap: 40px;
}
.footer__col h4 {
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 400;
  margin-bottom: 18px;
  color: var(--fg-mute);
  letter-spacing: 0.02em;
}
.footer__col ul { list-style: none; display: flex; flex-direction: column; gap: 8px; font-size: 13px; }
.footer__col ul a { color: var(--fg); opacity: .8; transition: opacity .25s ease; }
.footer__col ul a:hover { opacity: 1; }
.footer__brand .serif {
  font-size: 36px;
  line-height: 1;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}
.footer__brand p { color: var(--fg-mute); max-width: 36ch; font-size: 13px; }
.footer__base {
  grid-column: 1 / -1;
  border-top: 1px solid var(--rule);
  padding-top: 24px;
  margin-top: 40px;
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--fg-faint);
}

/* ───────── Cinema-style placeholder ───────── */
.plate {
  position: relative;
  overflow: hidden;
  background: var(--bg-soft);
  isolation: isolate;
}
.plate::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      90deg,
      transparent 0 6px,
      rgba(217, 201, 168, 0.06) 6px 7px
    ),
    radial-gradient(ellipse at var(--lx, 70%) var(--ly, 35%),
      rgba(217, 201, 168, 0.28) 0%,
      rgba(217, 201, 168, 0.08) 30%,
      transparent 65%);
  z-index: 0;
}
[data-palette="ivory"] .plate::before,
[data-palette="oyster"] .plate::before {
  background:
    repeating-linear-gradient(
      90deg,
      transparent 0 6px,
      rgba(28, 24, 20, 0.04) 6px 7px
    ),
    radial-gradient(ellipse at var(--lx, 70%) var(--ly, 35%),
      rgba(184, 162, 116, 0.32) 0%,
      rgba(184, 162, 116, 0.10) 32%,
      transparent 70%);
}
.plate__caption {
  position: absolute;
  left: 14px; bottom: 12px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--fg-mute);
  z-index: 2;
  display: flex;
  gap: 10px;
  align-items: center;
}
.plate__caption .tick {
  width: 6px; height: 6px; border: 1px solid var(--fg-mute);
}
.plate__corner {
  position: absolute;
  top: 12px; right: 14px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--fg-mute);
  z-index: 2;
}

/* page transition */
.page-enter {
  animation: pageIn .9s cubic-bezier(.22,.61,.36,1) both;
}
@keyframes pageIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

/* utility */
.container { padding: 0 40px; }
.rule { height: 1px; background: var(--rule); }
button { font-family: inherit; }


/* JSON project images */
.plate__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  filter: none;
  opacity: 1;
}


.plate--image::before {
  z-index: 1;
  opacity: .18;
  mix-blend-mode: soft-light;
}

.plate--image::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(to bottom, rgba(0,0,0,.02), rgba(0,0,0,.08));
  pointer-events: none;
}


[data-palette="ivory"] .plate--image::after,
[data-palette="oyster"] .plate--image::after {
  background: linear-gradient(to bottom, rgba(255,255,255,.06), rgba(0,0,0,.18));
}
.data-loading {
  min-height: 60vh;
  display: grid;
  place-items: center;
  padding-top: 140px;
  color: var(--fg-mute);
}

/* Public mobile menu — replaces the theme toggle in production */
.mobile-burger{
  justify-self:end;
  width:44px;
  height:44px;
  border:1px solid var(--rule);
  background:color-mix(in srgb, var(--bg) 76%, transparent);
  color:var(--fg);
  display:none;
  align-items:center;
  justify-content:center;
  flex-direction:column;
  gap:6px;
  cursor:pointer;
  backdrop-filter:blur(12px);
  -webkit-backdrop-filter:blur(12px);
  transition:border-color .35s ease, background-color .35s ease, transform .35s ease;
}
.mobile-burger:hover{
  border-color:var(--champagne);
  background:color-mix(in srgb, var(--champagne) 10%, transparent);
}
.mobile-burger span{
  width:17px;
  height:1px;
  background:currentColor;
  display:block;
  transform-origin:center;
  transition:transform .35s ease, opacity .35s ease;
}
.mobile-burger[aria-expanded="true"] span:first-child{transform:translateY(3.5px) rotate(38deg);}
.mobile-burger[aria-expanded="true"] span:last-child{transform:translateY(-3.5px) rotate(-38deg);}
.mobile-menu{
  position:fixed;
  top:72px;
  left:18px;
  right:18px;
  z-index:49;
  display:none;
  flex-direction:column;
  align-items:flex-end;
  gap:18px;
  padding:20px 0;
  border-top:1px solid var(--rule);
  border-bottom:1px solid var(--rule);
  background:color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter:blur(18px);
  -webkit-backdrop-filter:blur(18px);
}
.mobile-menu.is-open{display:flex;}
.mobile-menu a{
  font-family:var(--mono);
  font-size:11px;
  letter-spacing:.16em;
  text-transform:uppercase;
  color:var(--fg-mute);
}
.mobile-menu a:hover,.mobile-menu a.is-active{color:var(--fg);}
@media (max-width:900px){
  .mobile-burger{display:flex;}
  .header__theme{display:none!important;}
}
@media (min-width:901px){
  .mobile-menu{display:none!important;}
}


/* Final nav simplification — direct links on mobile, no burger */
@media (max-width:900px){
  .header{grid-template-columns:1fr auto;}
  .header__nav{display:flex!important;justify-self:end;gap:16px;font-size:10px;letter-spacing:.12em;}
  .header__nav a{padding:7px 0;}
  .mobile-burger,.mobile-menu,.header__theme,.theme-toggle{display:none!important;}
}

.footer__he{margin-top:12px;color:var(--muted);font-size:13px;line-height:1.7;}

/* ─────────────────────────────────────────────
   Typography scale normalization — small text layer
   Keeps major serif headings intact; normalizes labels/meta/supporting copy.
───────────────────────────────────────────── */
:root{
  --type-micro:10px;
  --type-label:11px;
  --type-meta:13px;
  --type-support:15px;
  --type-body:16px;
  --track-label:.14em;
}

.label,
.header__nav,
.header__meta,
.theme-toggle,
.footer__base{
  font-size:var(--type-label);
}

.header__nav,
.header__meta,
.theme-toggle,
.footer__base{
  letter-spacing:var(--track-label);
}

.footer__col ul,
.footer__brand p,
.footer__he{
  font-size:var(--type-meta);
  line-height:1.65;
}

.footer__col h4{
  font-size:var(--type-support);
}

@media(max-width:900px){
  .header__nav{
    font-size:var(--type-label) !important;
    letter-spacing:.1em !important;
  }
}
