/* AI交換日記 — shared screen chrome.
   Per-screen styles live in each page's own <style> block. */

* { box-sizing: border-box; }

html,
body {
  margin: 0;
  padding: 0;
}

/* Headings and paragraphs are spaced by their containers, not by UA margins. */
h1,
h2,
h3,
p {
  margin: 0;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

body {
  background: var(--surface-050);
  font-family: var(--font-sans);
  display: flex;
  justify-content: center;
  padding: 28px 16px;
  padding-top: calc(28px + env(safe-area-inset-top, 0px));
  padding-bottom: calc(28px + env(safe-area-inset-bottom, 0px));
}

/* The phone-sized frame every screen sits in. */
.screen {
  width: 375px;
  max-width: 100%;
  background: var(--surface-100);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

/* Screens that hold plain content rather than a full-bleed cover. */
.screen--padded { padding: var(--space-5); }

/* Back arrow + screen title. */
.topbar {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.topbar .back {
  color: var(--ink-muted);
  font-size: 20px;
  line-height: 1;
  text-decoration: none;
}

.topbar .title { color: var(--ink); }

/* Primary action: accent fill with dark text — accent is too light for white. */
.btn-primary {
  display: block;
  width: 100%;
  padding: 14px var(--space-4);
  background: var(--accent);
  color: var(--on-accent);
  border: none;
  border-radius: var(--radius-pill);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

/* Every interactive element keeps a visible focus ring; no hover animation. */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent-deep);
  outline-offset: 2px;
}

/* Text inputs share one shape across screens. */
.input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  background: var(--surface-100);
}

.input::placeholder { color: var(--ink-muted); }

.input:focus-visible {
  outline: 2px solid var(--accent-deep);
  outline-offset: 1px;
}
