/* Waardenboom — Chiara's watercolor is the chrome. Atlas tokens only for
   focus/type so the overlay stays readable. No four-surface Oji header. */

:root {
  --cream: #f3ead4;
  --ink: #153937;
  --ink-muted: #4f6c67;
  --ochre: #e6a24a;
  --sand: #f2d6a2;
  --font-ui: system-ui, -apple-system, "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  height: 100%;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-ui);
}

body {
  overflow: hidden;
}

.hidden {
  display: none !important;
}

.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 300;
  padding: 0.65rem 0.9rem;
  background: var(--sand);
  color: var(--ink);
  border: 2px solid var(--ink);
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.boom-stage {
  position: relative;
  display: block;
  width: max-content;
  max-width: 100vw;
  max-height: 100dvh;
  margin: 0 auto;
}

.boom-stage img {
  display: block;
  max-width: 100vw;
  max-height: 100dvh;
  width: auto;
  height: auto;
  object-fit: contain;
}

.boom-nav,
.boom-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.boom-nav.is-locked {
  pointer-events: none;
}

.boom-overlay {
  display: block;
}

.boom-overlay .press {
  cursor: pointer;
}

.boom-overlay .press rect {
  fill: transparent;
  stroke: transparent;
  stroke-width: 0.45;
}

.boom-overlay .press:hover rect,
.boom-overlay .press:focus-visible rect {
  fill: rgba(230, 162, 74, 0.14);
  stroke: var(--ochre);
}

.boom-overlay .press:focus {
  outline: none;
}

.boom-overlay .press:focus-visible {
  outline: none;
}

.account-wrap {
  position: fixed;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 40;
}

.account-chip {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 44px;
  padding: 0.35rem 0.7rem;
  background: var(--sand);
  color: var(--ink);
  border: 2px solid var(--ink);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.account-chip:focus-visible {
  outline: 3px solid var(--ochre);
  outline-offset: 3px;
}

.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.6rem;
  height: 1.6rem;
  background: var(--ink);
  color: var(--sand);
  font-size: 0.75rem;
}

.email-text {
  max-width: 16rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.85rem;
}

.account-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 0.35rem);
  min-width: 16rem;
  padding: 0.7rem;
  background: var(--sand);
  border: 2px solid var(--ink);
}

.menu-section {
  font-size: 0.75rem;
  color: var(--ink-muted);
  margin-bottom: 0.25rem;
}

.menu-account-email {
  color: var(--ink);
  font-weight: 600;
  margin-bottom: 0.7rem;
  word-break: break-all;
}

.account-menu button {
  min-height: 44px;
  width: 100%;
  padding: 0.4rem 0.6rem;
  background: var(--cream);
  color: var(--ink);
  border: 2px solid var(--ink);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.account-menu button:focus-visible,
.signin-wrap button:focus-visible,
.access-denied button:focus-visible,
.roots-back:focus-visible,
.room-dialog button:focus-visible,
.room-dialog a:focus-visible {
  outline: 3px solid var(--ochre);
  outline-offset: 3px;
}

.signin-wrap,
.access-denied {
  position: fixed;
  z-index: 50;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(28rem, calc(100vw - 2rem));
  padding: 1.4rem 1.3rem 1.2rem;
  background: rgba(243, 234, 212, 0.94);
  border: 2px solid var(--ink);
  color: var(--ink);
}

.signin-kicker {
  margin: 0 0 0.35rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.signin-headline,
.access-denied h2,
.room-dialog h2 {
  margin: 0 0 0.6rem;
  font-size: 1.55rem;
  font-weight: 700;
  line-height: 1.2;
}

.signin-prose,
.access-denied p,
.room-dialog p {
  margin: 0 0 1rem;
  line-height: 1.45;
}

#g_id_signin {
  min-height: 44px;
}

.signin-error,
.error-strip {
  margin: 0.75rem 0 0;
  color: #75281e;
  font-weight: 600;
}

.error-strip {
  position: fixed;
  z-index: 60;
  left: 50%;
  bottom: 1rem;
  transform: translateX(-50%);
  width: min(36rem, calc(100vw - 2rem));
  padding: 0.7rem 0.9rem;
  background: #efd0bd;
  border: 2px solid #a63d2f;
}

.email-shown {
  font-weight: 700;
}

.access-denied button,
.roots-back,
.room-dialog button {
  min-height: 44px;
  min-width: 44px;
  padding: 0.45rem 0.9rem;
  background: var(--sand);
  color: var(--ink);
  border: 2px solid var(--ink);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.roots-back {
  position: fixed;
  z-index: 35;
  left: 0.75rem;
  bottom: calc(0.75rem + env(safe-area-inset-bottom, 0px));
}

.room-dialog {
  width: min(32rem, calc(100vw - 2rem));
  max-height: min(80dvh, 40rem);
  overflow: auto;
  padding: 1.2rem 1.2rem 1rem;
  background: var(--cream);
  color: var(--ink);
  border: 2px solid var(--ink);
}

.room-dialog::backdrop {
  background: rgba(21, 57, 55, 0.28);
}

.room-dialog ul {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
}

.room-dialog li {
  margin: 0 0 0.45rem;
}

.room-dialog a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--ink);
  font-weight: 700;
}

@media (max-width: 720px) {
  .email-text {
    max-width: 40vw;
  }

  .boom-stage {
    width: 100vw;
  }

  .boom-stage img {
    width: 100vw;
    height: auto;
    max-height: 100dvh;
  }
}

@media (prefers-reduced-motion: reduce) {
  .skip-link,
  .signin-wrap,
  .access-denied {
    transition: none;
  }
}

@media (forced-colors: active) {
  .boom-overlay .press:focus-visible rect,
  .boom-overlay .press:hover rect {
    fill: Highlight;
    stroke: HighlightText;
  }

  .account-chip,
  .skip-link,
  .signin-wrap,
  .room-dialog {
    border: 2px solid CanvasText;
  }
}
