/* Oregon: an evergreen band on top, then one centred column of cards. */

:root {
  color-scheme: light dark;
  --evergreen: #1F4D3A;
  --evergreen-light: #2E6B52;
  --snow: #F5F7F4;
  --page: #F3F6F4;
  --card: #FFFFFF;
  --text: #16231C;
  --muted: #5A6B62;
  --line: #E2E9E5;
  --button: var(--evergreen);
  --button-hover: var(--evergreen-light);
  --secondary: #E5EEE9;
  --secondary-hover: #D8E6DE;
  --secondary-text: var(--evergreen);
  --badge: #E1EDE6;
  --badge-text: var(--evergreen);
  --notice: #FBF0DC;
  --notice-text: #5C3D00;
  --focus: var(--evergreen-light);
  --shadow: 0 1px 2px rgba(15, 26, 21, 0.06), 0 6px 20px rgba(15, 26, 21, 0.05);
}

@media (prefers-color-scheme: dark) {
  :root {
    --page: #0F1A15;
    --card: #17251E;
    --text: #E7EEEA;
    --muted: #9AADA3;
    --line: #25372E;
    --button: var(--evergreen-light);
    --button-hover: #387D60;
    --secondary: #213229;
    --secondary-hover: #2A3F34;
    --secondary-text: var(--snow);
    --badge: #23392E;
    --badge-text: #CDE3D6;
    --notice: #3A2D15;
    --notice-text: #F3D8A8;
    --focus: #7DB89B;
    --shadow: none;
  }
}

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

[hidden] {
  display: none !important;
}

html {
  background: var(--page);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

/* Header band: runs up under the status bar, whose text is white (black-translucent). */
.bar {
  position: relative;
  background: var(--evergreen);
  color: #FFFFFF;
  padding: env(safe-area-inset-top) max(16px, env(safe-area-inset-right)) 0 max(16px, env(safe-area-inset-left));
}

/* Keeps the top dark when the page is pulled down past its top edge. */
.bar::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: 100vh;
  background: var(--evergreen);
}

.bar-inner {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 560px;
  min-height: 56px;
  margin: 0 auto;
}

.bar-icon {
  display: block;
  width: 30px;
  height: 30px;
  border-radius: 7px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.bar-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

main {
  padding: 20px max(16px, env(safe-area-inset-right)) max(24px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
}

.column {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 560px;
  margin: 0 auto;
}

.card {
  padding: 24px 20px;
  border-radius: 16px;
  background: var(--card);
  box-shadow: var(--shadow);
}

h1 {
  margin: 0 0 16px;
  font-size: 26px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 20px;
}

.center {
  text-align: center;
}

.loading p {
  margin: 0;
  color: var(--muted);
  text-align: center;
}

button {
  -webkit-appearance: none;
  appearance: none;
  display: block;
  width: 100%;
  min-height: 50px;
  margin: 0;
  padding: 12px 20px;
  border: 0;
  border-radius: 12px;
  background: var(--button);
  color: #FFFFFF;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

button.secondary {
  background: var(--secondary);
  color: var(--secondary-text);
}

@media (hover: hover) {
  button:hover:enabled {
    background: var(--button-hover);
  }

  button.secondary:hover:enabled {
    background: var(--secondary-hover);
  }
}

button:active:enabled {
  opacity: 0.85;
}

button:disabled {
  opacity: 0.55;
  cursor: default;
}

button:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.hint {
  margin: 12px 0 0;
  font-size: 15px;
  color: var(--muted);
}

.label {
  margin: 0 0 4px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.people {
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.people li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
}

.you {
  flex: none;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--badge);
  color: var(--badge-text);
  font-size: 13px;
  font-weight: 600;
}

.notice {
  margin: 0;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--notice);
  color: var(--notice-text);
  font-size: 15px;
}

.install {
  padding: 16px 20px;
}

.install h2 {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 600;
}

.install p {
  margin: 0;
  font-size: 15px;
  color: var(--muted);
}
