@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap");

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: #f6f7f9;
  color: #1c1c1e;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

@media (prefers-color-scheme: dark) {
  html, body { background: #131316; color: #eaeaea; }
  .panel { background: #1c1c1f !important; box-shadow: 0 1px 2px rgba(0,0,0,.4) !important; border-color: #28282b !important; }
  input, select, textarea { background: #1f1f22 !important; color: #eaeaea !important; border-color: #2d2d31 !important; }
  pre { background: #0e0e10 !important; color: #d6d6da !important; }
  .btn { background: #2a2a2e !important; color: #eaeaea !important; border-color: #3a3a3f !important; }
  .btn-primary { background: #3a76ff !important; color: #fff !important; border-color: #3a76ff !important; }
  .hint { color: #8d8d92 !important; }
  hr { border-color: #28282b !important; }
}

.shell { max-width: 1080px; margin: 0 auto; padding: 32px 20px 60px; }

h1 {
  font-size: 26px;
  letter-spacing: -.02em;
  margin: 0 0 4px;
}
.subtitle { color: #6b6b70; margin: 0 0 24px; font-size: 14px; }

.layout {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 24px;
}
@media (max-width: 880px) {
  .layout { grid-template-columns: 1fr; }
}

.panel {
  background: #fff;
  border: 1px solid #ececef;
  border-radius: 12px;
  padding: 22px 22px 18px;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
}

.panel h2 {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: #888;
  font-weight: 600;
  margin: 0 0 14px;
}

.row { display: flex; gap: 12px; margin: 0 0 12px; }
.row > .field { flex: 1; }
.field-tz { flex: 2; }
.field { display: block; margin: 0 0 12px; }
.field label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: #6b6b70;
  margin: 0 0 4px;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #d8d8dc;
  border-radius: 8px;
  background: #fff;
  font: inherit;
  color: inherit;
  outline: none;
  transition: border-color .12s, box-shadow .12s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: #3a76ff;
  box-shadow: 0 0 0 3px rgba(58,118,255,.2);
}
.field textarea { resize: vertical; min-height: 80px; font-family: inherit; }
.checkrow { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.checkrow input[type="checkbox"] {
  width: auto;
  min-width: 16px;
  height: 16px;
  margin: 0;
  padding: 0;
  border-radius: 4px;
  flex: 0 0 auto;
  accent-color: #1c1c1e;
  box-shadow: none;
}
.field-allday .checkrow {
  margin-bottom: 10px;
  font-size: 14px;
  font-weight: 500;
  color: #3b3b3f;
}
.field-allday-line {
  margin: 2px 0 12px;
}
.field-allday-line .checkrow {
  display: inline-flex;
  margin: 0;
  font-size: 14px;
  font-weight: 500;
  color: #3b3b3f;
}
.hint { font-size: 12px; color: #888; margin: 4px 0 0; }

.actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}
.btn {
  appearance: none;
  border: 1px solid #d8d8dc;
  background: #fff;
  color: #1c1c1e;
  padding: 9px 14px;
  border-radius: 8px;
  font: inherit;
  font-weight: 500;
  cursor: pointer;
  transition: background .12s, border-color .12s;
}
.btn:hover { background: #f4f4f6; }
.btn-primary { background: #1c1c1e; color: #fff; border-color: #1c1c1e; }
.btn-primary:hover { background: #000; }

pre {
  background: #f3f3f5;
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 12.5px;
  overflow-x: auto;
  margin: 0;
  white-space: pre-wrap;
  word-break: break-all;
  border: 1px solid #ececef;
}

.outblock { margin-bottom: 16px; }
.outblock h3 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #888;
  font-weight: 600;
  margin: 0 0 6px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.outblock h3 button { font-size: 11px; padding: 4px 8px; }

hr { border: none; border-top: 1px solid #ececef; margin: 16px 0; }

.note { font-size: 12px; color: #888; margin: 6px 0 0; }
.note code { background: #f3f3f5; padding: 1px 6px; border-radius: 4px; font-size: 11.5px; }
@media (prefers-color-scheme: dark) { .note code { background: #2a2a2e; } }

.demo-fab {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 10;
  box-shadow: 0 10px 24px rgba(0,0,0,.18);
}
