/* the logo's rounded face; the file holds only the letters in "vConnect" (Fredoka, SIL Open Font License) */
@font-face {
  font-family: "Fredoka Logo";
  font-weight: 700;
  font-display: block;
  src: url("/static/fredoka-logo.woff2") format("woff2");
}

:root {
  --bg: #2a2a3e;
  --surface: #34344c;
  --line: #4a4a66;
  --text: #ece5d3;
  --muted: #b6b1c8;
  --accent: #cdad6f;
  --accent-ink: #1d1c2b;
  --twitch: #9146ff;
  --logo-outline: #1d1c2b;
  --radius: 12px;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--text); font: 16px/1.55 system-ui, sans-serif; }
a { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.bar { display: flex; justify-content: space-between; align-items: center; padding: 16px 24px; border-bottom: 1px solid var(--line); }
.brand { display: block; border-radius: 8px; text-decoration: none; }
.logo { display: block; height: 36px; width: auto; }
.logo-text { font: 700 88px "Fredoka Logo", system-ui, sans-serif; }
.logo-outline { fill: none; stroke: var(--logo-outline); stroke-width: 14px; stroke-linejoin: round; }
.wrap { max-width: 880px; margin: 0 auto; padding: 48px 24px; }

.hero { text-align: center; padding-block: 64px; }
.hero h1 { font-size: clamp(2rem, 5vw, 3rem); line-height: 1.1; margin: 0 0 16px; }
.lead { color: var(--muted); font-size: 1.15rem; max-width: 42ch; margin: 0 auto 32px; }
.fine { color: var(--muted); font-size: 0.9rem; margin: 8px 0 0; }
.notice { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; max-width: 42ch; margin: 0 auto 24px; }

.btn { display: inline-flex; align-items: center; min-height: 44px; padding: 0 20px; border-radius: 8px; border: 1px solid transparent; font: 600 1rem/1 system-ui, sans-serif; text-decoration: none; cursor: pointer; }
.btn-twitch { background: var(--twitch); color: #fff; }
.btn-twitch:hover { filter: brightness(1.1); }
.btn-quiet { background: transparent; color: var(--text); border-color: var(--line); }
.btn-quiet:hover { background: var(--surface); }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; margin-bottom: 24px; }
.panel h1, .panel h2 { margin: 0; }
.who { display: flex; gap: 16px; align-items: center; }
.who img { border-radius: 50%; }

.notice { margin-inline: 0; max-width: none; }
.hero .notice { margin-inline: auto; max-width: 42ch; }
.notice-ok { border-color: var(--accent); }

.btn-main { background: var(--accent); color: var(--accent-ink); }
.btn-main:hover { filter: brightness(1.08); }

.week-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; }
.tabs { display: flex; gap: 4px; }
.tabs a { padding: 8px 14px; border-radius: 8px; color: var(--muted); text-decoration: none; }
.tabs a:hover { color: var(--text); }
.tabs a[aria-current="page"] { background: var(--bg); color: var(--text); }

.days { list-style: none; margin: 24px 0 0; padding: 0; }
.day { padding: 16px 0; border-top: 1px solid var(--line); }
.day h3 { margin: 0 0 4px; font-size: 1rem; }
.day > .fine { margin: 0; }
.stream { padding: 8px 0; }
.stream p { margin: 0; }
.stream-time { color: var(--accent); font-weight: 600; }
.stream-title { overflow-wrap: break-word; }

.edit summary { cursor: pointer; color: var(--muted); margin-top: 6px; width: fit-content; }
.edit summary:hover { color: var(--text); }
.edit[open] { background: var(--bg); border-radius: 8px; padding: 12px 16px 16px; margin-top: 8px; }
.edit form + form { margin-top: 12px; }

.stack { display: grid; gap: 16px; margin-top: 16px; }
.fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); gap: 12px 16px; }
.fields .wide { grid-column: 1 / -1; }
label, .field { display: grid; gap: 6px; color: var(--muted); font-size: 0.95rem; }
label.check { display: flex; align-items: center; gap: 10px; color: var(--text); }
input[type="text"], input[type="time"], select {
  min-height: 44px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--line);
  background: var(--bg); color: var(--text); font: inherit; min-width: 0; width: 100%;
}
input[type="checkbox"] { flex-shrink: 0; width: 20px; height: 20px; accent-color: var(--accent); }
input::placeholder { color: var(--muted); opacity: 0.7; }

/* time zone picker (zone-picker.js) */
.zp { position: relative; }
.zp-button {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; width: 100%; min-height: 44px;
  padding: 0 12px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: var(--text);
  font: inherit; text-align: left; cursor: pointer;
}
.zp-button:hover { border-color: var(--muted); }
.zp-button[aria-expanded="true"] { border-color: var(--accent); }
.zp-chevron { flex-shrink: 0; color: var(--muted); transition: transform 0.15s ease; }
.zp-button[aria-expanded="true"] .zp-chevron { transform: rotate(180deg); }
.zp-pop {
  position: absolute; z-index: 10; top: calc(100% + 6px); left: 0; width: min(100%, 460px);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 12px 32px rgb(0 0 0 / 0.35); padding: 12px;
}
.zp-search:focus-visible { outline-offset: 0; }
.zp-search {
  width: 100%; min-height: 44px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--accent);
  background: var(--bg); color: var(--text); font: inherit;
}
.zp-list { list-style: none; margin: 8px 0 0; padding: 0; max-height: 320px; overflow-y: auto; }
.zp-group { padding: 12px 10px 6px; font-weight: 600; color: var(--text); }
.zp-option {
  display: flex; justify-content: space-between; gap: 16px; padding: 10px; border-radius: 8px;
  color: var(--text); cursor: pointer;
}
.zp-name { display: grid; gap: 2px; min-width: 0; }
.zp-cities { color: var(--muted); font-size: 0.85rem; }
.zp-cities:empty { display: none; }
.zp-option .zp-time { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; align-self: center; }
.zp-option:hover, .zp-option.is-active { background: var(--bg); }
.zp-option[aria-selected="true"] { background: var(--accent); color: var(--accent-ink); }
.zp-option[aria-selected="true"] .zp-time,
.zp-option[aria-selected="true"] .zp-cities { color: var(--accent-ink); }
.zp-note { padding: 12px 10px 4px; color: var(--muted); font-size: 0.9rem; }
@media (prefers-reduced-motion: reduce) { .zp-chevron { transition: none; } }

.schedule-image { display: block; width: 100%; max-width: 560px; height: auto; margin-top: 16px; border-radius: var(--radius); }

.share { display: grid; gap: 10px; margin-top: 16px; }
.share textarea {
  width: 100%; padding: 12px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg);
  color: var(--text); font: 0.9rem/1.5 ui-monospace, SFMono-Regular, Consolas, monospace; resize: vertical;
}
.share-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
