:root {
  color-scheme: light;
  --paper: #fff;
  --cream: #f8f7f2;
  --ink: #26332b;
  --muted: #54625a;
  --green: #365645;
  --border: #dfe4dd;
  --focus: #426c50;
  --serif: Georgia, serif;
  --gutter: clamp(1rem, 4vw, 4rem);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font: 1rem/1.5 system-ui, sans-serif;
}

h1 {
  margin: 0 0 .75rem;
  font: 400 clamp(2.125rem, 4vw, 2.625rem)/1.1 var(--serif);
}

p { margin: 0; color: var(--muted); }
a { color: var(--green); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }

.masthead, .sidebar {
  background: var(--paper);
  padding: 1.25rem var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.masthead { border-bottom: 1px solid var(--border); }

.wordmark {
  font: 600 clamp(1.125rem, 2.6vw, 1.5rem)/1.2 var(--serif);
  color: var(--ink);
  text-decoration: none;
}

.nav-link { flex-shrink: 0; }

.page {
  width: 100%;
  max-width: 86rem;
  margin-inline: auto;
  padding: clamp(2rem, 5vw, 4rem) var(--gutter);
}

.panel {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: .5rem;
  padding: clamp(1rem, 4vw, 2rem);
}

.sign-in { max-width: 30rem; }

.button {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  border: 1px solid var(--green);
  border-radius: .375rem;
  padding: .5rem .875rem;
  background: var(--green);
  color: var(--paper);
  text-decoration: none;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

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

.workspace {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
}

.sidebar {
  flex-direction: column;
  align-items: flex-start;
  padding: 1.5rem 1rem;
  border-right: 1px solid var(--border);
}

@media (max-width: 680px) {
  .workspace { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr; }
  .sidebar {
    flex-direction: row;
    align-items: center;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }
}
