:root {
  --bg: #121212;
  --text: #EDEAE4;
  --panel: #1E1E1E;
  --border: #2E2E2E;
  --ring: #3A3A3A;
  --muted: #A8A49C;
  --secondary: #D6D2CA;
  --accent: #F2A33A;
  --mono: ui-monospace, monospace;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; background: var(--bg); color: var(--text); font-family: system-ui, sans-serif; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

.screen {
  display: flex; flex-direction: column;
  max-width: 480px; min-height: 100dvh; margin: 0 auto;
  padding: 52px 20px 28px;
}
h1 { margin: 0; font-size: 28px; font-weight: 700; }
h2 { margin: 16px 0 0; font-size: 24px; font-weight: 700; }
.sub { margin: 2px 0 0; font-size: 14px; color: var(--muted); }

.msg { margin: 8px 0 0; min-height: 1.2em; font-size: 14px; color: var(--secondary); }

/* Shoot */
.focal {
  flex: 1; display: flex; align-items: center; justify-content: center;
  font: 96px var(--mono); color: var(--border); user-select: none;
}
.shutter {
  align-self: center; width: 84px; height: 84px; padding: 0; border-radius: 50%;
  background: transparent; border: 4px solid var(--text);
  display: flex; align-items: center; justify-content: center;
}
.shutter span { width: 64px; height: 64px; border-radius: 50%; background: var(--accent); }
.shutter:active span { transform: scale(0.94); }
.shutter:disabled { opacity: 0.4; cursor: default; }
/* Always rendered so screen readers announce the text change; visually hidden until .shown */
.pill {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}
.pill.shown {
  position: fixed; width: auto; height: auto; overflow: visible; clip-path: none; z-index: 1; top: 12px; left: 50%; transform: translateX(-50%);
  display: flex; align-items: center; gap: 10px; padding: 8px 16px 8px 8px;
  background: var(--panel); border: 1px solid var(--border); border-radius: 14px; font-size: 15px;
}
.check {
  width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: var(--bg);
  display: flex; align-items: center; justify-content: center; font-weight: 700;
}

/* Develop */
.top { display: flex; justify-content: space-between; }
.text-btn {
  min-height: 44px; min-width: 44px; padding: 0 4px; background: none; border: 0; font-size: 15px;
}
.text-btn:disabled, .film:disabled { opacity: 0.5; cursor: default; }
.text-btn.muted { color: var(--muted); }
.photo {
  position: relative; flex: 1; min-height: 240px; margin-top: 4px; border-radius: 6px; background: #6E6A63; overflow: hidden;
}
canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }

.strip { display: flex; gap: 12px; margin-top: 14px; padding: 4px 2px; overflow-x: auto; }
.film {
  flex: none; display: flex; flex-direction: column; align-items: center; gap: 6px;
  background: none; border: 0; padding: 0; color: var(--muted);
}
.film .sw { width: 66px; height: 66px; border-radius: 12px; border: 1px solid var(--ring); }
.film span.lbl { font-size: 11px; max-width: 70px; white-space: nowrap; }
.film[aria-pressed="true"] { color: var(--text); }
.film[aria-pressed="true"] .sw { border: 3px solid var(--accent); }

.grain { margin-top: 12px; }
.grain-head { display: flex; justify-content: space-between; align-items: baseline; font-size: 15px; color: var(--secondary); }
.grain-head output { font: 13px var(--mono); color: var(--muted); }
input[type=range] { width: 100%; height: 44px; margin: 0; accent-color: var(--accent); }

.save {
  width: 100%; height: 56px; margin-top: 8px; border: 0; border-radius: 16px;
  background: var(--accent); color: var(--bg); font-size: 17px; font-weight: 600;
}
.save:disabled { opacity: 0.6; cursor: default; }
