:root {
  /* Docon-style palette: bright blue chrome, tan/cream tap-chips, maroon for
     an actively-selected symptom/finding, green for an added medicine. */
  --primary: #2f6fed;
  --primary-dark: #1f56c4;
  --bg: #f5f7fb;
  --card: #ffffff;
  --text: #1f2937;
  --muted: #6b7280;
  --border: #e5e7eb;
  --danger: #dc2626;
  --ok: #16a34a;
  --radius: 12px;
  --chip-tan-border: #d8b877;
  --chip-tan-bg: #fdf8ec;
  --chip-selected-maroon: #7a1f2b;
  --chip-selected-green: #1a7a4c;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --font-heading: "Sora", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { color-scheme: light; }

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  padding-bottom: 70px;
}

h1, h2, h3, .brand {
  font-family: var(--font-heading);
}

button, input, select, textarea {
  font-family: inherit;
}

header.topbar {
  background: var(--primary);
  color: #fff;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 10;
}

header.topbar .brand-logo {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: contain;
  background: #fff;
  flex-shrink: 0;
}
header.topbar .brand-text { flex: 1; min-width: 0; }
header.topbar .brand { font-weight: 700; font-size: 1.05rem; }
header.topbar .sub { font-size: 0.72rem; opacity: 0.85; }
header.topbar button {
  background: rgba(255,255,255,0.15);
  border: none;
  color: #fff;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 0.85rem;
}

main {
  max-width: 520px;
  margin: 0 auto;
  padding: 16px;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 14px;
}

h1, h2, h3 { margin-top: 0; }
h2 { font-size: 1.1rem; }
h3 { font-size: 0.95rem; color: var(--muted); }

label { display: block; font-size: 0.85rem; margin: 10px 0 4px; color: var(--muted); }

input, select, textarea {
  width: 100%;
  padding: 11px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  font-size: 1rem;
  background: #fff;
  color: var(--text);
}

button.btn {
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 8px;
  background: var(--primary);
  color: #fff;
  font-size: 1rem;
  font-weight: 600;
  margin-top: 14px;
  cursor: pointer;
}
button.btn:active { background: var(--primary-dark); }
button.btn.secondary { background: #fff; color: var(--primary); border: 1px solid var(--primary); }
button.btn.danger { background: var(--danger); }
button.btn:disabled { opacity: 0.5; }

.grid-branches {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.branch-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
  text-align: center;
  background: #fff;
  cursor: pointer;
}
.branch-card.selected { border-color: var(--primary); background: #f0fdfa; }
.branch-card .city { font-size: 0.72rem; color: var(--muted); }

.slot-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 8px;
}
.slot {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px;
  text-align: center;
  background: #fff;
  cursor: pointer;
  font-size: 0.9rem;
}
.slot.full { opacity: 0.4; cursor: not-allowed; }
.slot.selected { border-color: var(--primary); background: #f0fdfa; }
.slot small { display: block; color: var(--muted); }

.appt-item, .list-item {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 10px;
  background: #fff;
}
.badge {
  display: inline-block;
  font-size: 0.72rem;
  padding: 3px 8px;
  border-radius: 20px;
  background: #e0f2f1;
  color: var(--primary-dark);
  font-weight: 600;
}
.badge.cancelled { background: #fee2e2; color: var(--danger); }
.badge.completed { background: #dcfce7; color: var(--ok); }
.badge.confirmed { background: #dcfce7; color: var(--ok); }
.badge.booked { background: #fef3c7; color: #92400e; }

/* Tap-driven chip picker (symptoms/diagnoses/medicines on the EMR consultation
   screen) — Docon's own language: full-oval tan/cream pills at rest, solid
   maroon with a visible "x" once tapped/selected. */
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.chip {
  border: 1.5px solid var(--chip-tan-border);
  background: var(--chip-tan-bg);
  color: var(--text);
  border-radius: 999px;
  padding: 8px 16px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s, color 0.12s, box-shadow 0.12s, transform 0.06s;
}
.chip:active { transform: scale(0.97); }
.chip.selected {
  background: var(--chip-selected-maroon);
  border-color: var(--chip-selected-maroon);
  color: #fff;
  box-shadow: 0 2px 6px rgba(122, 31, 43, 0.35);
}
.chip-removable.selected::after { content: " \00d7"; font-weight: 800; margin-left: 4px; }
.chip.empty-hint { color: var(--muted); font-size: 0.78rem; border-style: dashed; cursor: default; background: #fff; border-color: var(--border); }

/* Dose-amount picker — round tap-targets so a fraction (1/2, 3/4) reads the
   way it's written by hand on a paper Rx, instead of as a rectangular chip. */
.dose-circle-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; align-items: center; }
.dose-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--chip-tan-border);
  background: var(--chip-tan-bg);
  color: var(--text);
  font-size: 0.76rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: background 0.12s, border-color 0.12s, color 0.12s, transform 0.06s;
}
.dose-circle:active { transform: scale(0.94); }
.dose-circle.selected {
  background: var(--chip-selected-maroon);
  border-color: var(--chip-selected-maroon);
  color: #fff;
}
.dose-circle-custom { width: auto; border-radius: 999px; padding: 0 14px; font-weight: 600; }

/* A dose-slot chip can be "selected" (part of this medicine's regimen) while
   not being the one currently edited — the active one gets a visible ring
   so it's clear which slot the dose-amount row below applies to. */
.chip.dose-slot-active { box-shadow: 0 0 0 2px #fff inset, 0 0 0 4px var(--chip-selected-maroon); }

/* Common-drug / vitals-type quick-add tiles — Docon's "added" state (green
   pill, dose/frequency shown as a subtitle line) once tapped. */
.chip-tile {
  border-radius: 999px;
  padding: 9px 16px;
  font-size: 0.82rem;
  font-weight: 700;
  background: #fff;
  border-color: color-mix(in srgb, var(--primary) 30%, var(--border));
  color: var(--primary-dark);
}
.chip-tile.selected {
  background: var(--chip-selected-green);
  border-color: var(--chip-selected-green);
  color: #fff;
  box-shadow: 0 3px 8px rgba(26, 122, 76, 0.4);
}
.chip-tile .chip-tile-sub { display: block; font-size: 0.68rem; font-weight: 600; opacity: 0.85; margin-top: 1px; }

/* Docon-style duration picker: rectangular grid tiles, not ovals */
.dur-tile {
  border-radius: 8px;
  background: #fff;
  border-color: var(--border);
  color: var(--text);
  padding: 8px 12px;
  min-width: 56px;
  text-align: center;
}
.dur-tile.selected { background: var(--primary); border-color: var(--primary); color: #fff; box-shadow: none; }

/* Docon-style Print Settings toggle list */
.ios-toggle-list { border: 1px solid var(--border); border-radius: 10px; margin-top: 8px; overflow: hidden; }
.ios-toggle-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px; font-size: 0.85rem; margin: 0;
  border-bottom: 1px solid var(--border);
}
.ios-toggle-row:last-child { border-bottom: none; }
.ios-toggle { position: relative; display: inline-block; width: 44px; height: 26px; flex-shrink: 0; }
.ios-toggle input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.ios-toggle-track {
  position: absolute; inset: 0; background: #d1d5db; border-radius: 999px; transition: background 0.15s;
  pointer-events: none;
}
.ios-toggle-track::before {
  content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px;
  background: #fff; border-radius: 50%; transition: transform 0.15s; box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.ios-toggle input:checked + .ios-toggle-track { background: var(--primary); }
.ios-toggle input:checked + .ios-toggle-track::before { transform: translateX(18px); }

/* Docon-style symptom severity picker */
.sev-chip.sev-mild.selected { background: #d97706; border-color: #d97706; box-shadow: 0 2px 6px rgba(217, 119, 6, 0.35); }
.sev-chip.sev-moderate.selected { background: #ea580c; border-color: #ea580c; box-shadow: 0 2px 6px rgba(234, 88, 12, 0.35); }
.sev-chip.sev-severe.selected { background: #b91c1c; border-color: #b91c1c; box-shadow: 0 2px 6px rgba(185, 28, 28, 0.35); }

/* Docon-style "1-0-1" frequency grid on the Rx row */
.rx-freq-grid { border: 1px solid var(--border); border-radius: 12px; padding: 12px; background: #fafcfb; }
.rx-freq-grid-readout { font-size: 1.05rem; font-weight: 800; color: var(--primary); letter-spacing: 0.02em; }
.rx-freq-grid-slot {
  width: 48px; height: 48px; border-radius: 50%;
  border: 2px solid var(--border); background: #fff; color: var(--text);
  font-weight: 800; font-size: 0.95rem; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background 0.12s, border-color 0.12s, color 0.12s;
}
.rx-freq-grid-slot.active { border-color: var(--primary); background: var(--primary); color: #fff; }
.rx-freq-more-toggle {
  background: none; border: none; color: var(--primary); font-size: 0.75rem;
  font-weight: 600; padding: 6px 0 0; cursor: pointer; text-align: left;
}
.rx-freq-more-toggle::before { content: "\25B8\A0"; white-space: pre; }
.rx-freq-more-toggle.open::before { content: "\25BE\A0"; white-space: pre; }
.rx-freq-more { margin-top: 6px; }
.suggestion-box {
  border: 1px solid var(--primary);
  background: #e0f2f1;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.85rem;
}
.suggestion-box .caption { color: var(--muted); font-size: 0.72rem; margin-top: 4px; }

/* EMR "Prescription" landing screen: All Patients + Today's Queue vs. the
   search/add-patient area. Single column on phones (search first, since
   that's the action you reach for on a small screen); a real two-column
   layout on tablet+ once there's room — the patient/queue lists move to a
   left-hand rail, freeing the right side for the working area. */
.emr-landing-grid { display: flex; flex-direction: column; }
.emr-landing-side { order: 2; }
.emr-landing-main { order: 1; }
.emr-date-heading {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin: 14px 0 6px;
}
.emr-date-heading:first-child { margin-top: 0; }

/* New Consultation form + its live "how it'll print" preview. Single column
   on phones (preview follows the form); a real side-by-side layout on
   tablet+ once there's room — see the min-width:700px override below. */
.consult-grid { display: flex; flex-direction: column; }
.rx-preview-wrap {
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: auto;
  background: #fff;
  /* A4 aspect ratio (210:297) so the sheet reads like an actual page, not
     just an arbitrary card. */
  aspect-ratio: 210 / 297;
  max-height: 600px;
}
#rxPreviewSheet {
  padding: 16px;
  font-size: 0.8rem;
  color: var(--text);
  min-height: 100%;
}
#rxPreviewSheet table th, #rxPreviewSheet table td { padding: 3px 4px; border-bottom: 1px solid var(--border); }

/* History tab: A4-shaped slider through a patient's past prescriptions */
.rx-slider-frame {
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  background: #fff;
  aspect-ratio: 210 / 297;
  max-height: 600px;
}

/* Docon-standard boxed patient timeline: each vital trend in its own
   bordered card, with a horizontally-scrolling row of small per-date
   reading boxes underneath the line chart. */
.timeline-box {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  margin-top: 12px;
  background: #fafbfc;
}
.timeline-box-title { font-size: 0.8rem; font-weight: 700; color: var(--text); }
.timeline-reading-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
}
.timeline-reading-box {
  flex: 0 0 auto;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  padding: 6px 10px;
  min-width: 80px;
  text-align: center;
}
.timeline-reading-date { font-size: 0.65rem; color: var(--muted); margin-bottom: 3px; white-space: nowrap; }
.timeline-reading-cell { font-size: 0.78rem; font-weight: 700; display: flex; align-items: center; justify-content: center; gap: 4px; white-space: nowrap; }
.timeline-reading-dot { width: 6px; height: 6px; border-radius: 50%; display: inline-block; flex-shrink: 0; }

/* Docon-style small tappable timeline boxes — collapsed by default, tap to
   reveal the full trend chart underneath the row. */
.timeline-mini-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  background: #fff;
  padding: 8px 10px;
  min-width: 76px;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s, color 0.12s;
}
.timeline-mini-title { font-size: 0.66rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.02em; text-align: center; }
.timeline-mini-latest { font-size: 0.85rem; font-weight: 800; color: var(--text); }
.timeline-mini-box.selected {
  background: var(--primary);
  border-color: var(--primary);
  box-shadow: 0 2px 6px rgba(47, 111, 237, 0.35);
}
.timeline-mini-box.selected .timeline-mini-title,
.timeline-mini-box.selected .timeline-mini-latest { color: #fff; }
/* Latest reading is above its normal reference range */
.timeline-high-value { color: #dc2626; }

/* Medicine names display in caps everywhere they're shown (chips, rows,
   history, preview, print) — purely visual, the underlying value/data stays
   whatever case it was typed/stored in. */
.med-caps { text-transform: uppercase; }

nav.tabbar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: #fff;
  border-top: 1px solid var(--border);
  display: flex;
  max-width: 520px;
  margin: 0 auto;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
nav.tabbar button {
  flex: 1 0 auto;
  min-width: 72px;
  border: none;
  background: none;
  padding: 12px 8px;
  font-size: 0.78rem;
  color: var(--muted);
  white-space: nowrap;
}
nav.tabbar button.active { color: var(--primary); font-weight: 700; }

.msg { font-size: 0.85rem; margin-top: 8px; padding: 8px 10px; border-radius: 8px; }
.msg.error { background: #fee2e2; color: var(--danger); }
.msg.ok { background: #dcfce7; color: #166534; }

.hidden { display: none !important; }

.home-hero {
  text-align: center;
  padding: 40px 20px;
}
.home-hero h1 { font-size: 1.6rem; }
.home-hero p { color: var(--muted); }
.home-links { display: flex; gap: 12px; margin-top: 24px; }
.home-links a {
  flex: 1;
  padding: 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--text);
  text-align: center;
  font-weight: 600;
}

table.staff-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}
table.staff-table th, table.staff-table td {
  text-align: left;
  padding: 8px 6px;
  border-bottom: 1px solid var(--border);
}

.app-footer {
  text-align: center;
  color: var(--muted);
  font-size: 0.75rem;
  padding: 18px 16px;
}

.cat-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.cat-general   { background: #dbeafe; color: #1e40af; }   /* light blue */
.cat-emergency { background: #fecaca; color: #991b1b; }   /* light red */
.cat-relatives { background: #dcfce7; color: #166534; }   /* light green */
.cat-vip       { background: #ffedd5; color: #9a3412; }   /* orange */
.cat-poor      { background: #fef9c3; color: #854d0e; }   /* yellow */

.cat-editor {
  margin-top: 8px;
  padding: 10px;
  border: 1px dashed var(--border);
  border-radius: 8px;
  background: #fafafa;
}
.cat-editor select, .cat-editor input {
  margin-top: 4px;
}

.badge.src-online { background: #dbeafe; color: #1e40af; }  /* blue */
.badge.src-walkin { background: #dcfce7; color: #166534; }  /* green */

table.staff-table td.num, table.staff-table th.num { text-align: center; }

/* Role identity — logo-inspired palette. The whole header is tinted per user
   type (not just a badge) so it's unmistakable at a glance whose dashboard
   you're in: yellow for patients, light pink for doctors, cyan for staff,
   gold for admin, mint green for reception. */
header.topbar.role-patient,
header.topbar.role-doctor,
header.topbar.role-staff,
header.topbar.role-admin,
header.topbar.role-reception {
  color: #1f2937;
}
header.topbar.role-patient   { background: #fde047; }  /* yellow */
header.topbar.role-doctor    { background: #f9a8d4; }  /* light pink */
header.topbar.role-staff     { background: #67e8f9; }  /* cyan */
header.topbar.role-admin     { background: #fbbf24; }  /* gold, from the logo ring */
header.topbar.role-reception { background: #86efac; }  /* mint green, from the logo cross */

header.topbar.role-patient .sub,
header.topbar.role-doctor .sub,
header.topbar.role-staff .sub,
header.topbar.role-admin .sub,
header.topbar.role-reception .sub {
  color: #1f2937;
  opacity: 0.75;
}
header.topbar.role-patient button,
header.topbar.role-doctor button,
header.topbar.role-staff button,
header.topbar.role-admin button,
header.topbar.role-reception button {
  background: rgba(31, 41, 55, 0.14);
  color: #1f2937;
}

/* Small role-name pill, kept inside the (now tinted) header for the role label itself. */
.role-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 20px;
  font-size: 0.66rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-left: 6px;
  vertical-align: middle;
  background: rgba(31, 41, 55, 0.14);
  color: #1f2937;
}

/* Tablet+ layout: the bottom tab bar becomes a fixed left side panel instead
   of a thumb-reachable bottom strip (which only makes sense on a phone-width
   screen), and the content area gets a wider column to use the extra space
   instead of staying phone-width in the middle of a tablet screen. */
@media (min-width: 700px) {
  body { padding-bottom: 0; }

  /* Only push the header/main/footer over once the sidebar is actually
     showing (i.e. logged in) — on the login screen nav.tabbar stays
     .hidden, and the login card should stay centered, not shifted left. */
  body:has(nav.tabbar:not(.hidden)) header.topbar { margin-left: 190px; }
  body:has(nav.tabbar:not(.hidden)) main { margin-left: 190px; max-width: 760px; padding: 24px; }
  body:has(nav.tabbar:not(.hidden)) .app-footer { margin-left: 190px; }

  nav.tabbar {
    top: 0;
    bottom: 0;
    left: 0;
    right: auto;
    width: 190px;
    max-width: none;
    margin: 0;
    flex-direction: column;
    overflow-x: hidden;
    overflow-y: auto;
    border-top: none;
    border-right: 1px solid var(--border);
    padding-top: 64px; /* clears the sticky header, which stays full-width above */
  }
  nav.tabbar button {
    flex: none;
    width: 100%;
    text-align: left;
    padding: 13px 20px;
    border-left: 3px solid transparent;
  }
  nav.tabbar button.active { border-left-color: var(--primary); background: #f0fdfa; }

  /* The open tab stays pinned at the top; every other tab (JS keeps them as
     siblings 2+ after reordering — see reorderTabbarForActive) gets pushed
     all the way down to the bottom of the sidebar as a group, not just
     packed directly under the active one. */
  nav.tabbar button:nth-child(2) { margin-top: auto; }

  /* A small icon next to each tab label — only worth the visual weight once
     there's room for a labeled sidebar (tablet+); the bottom bar stays
     icon-free/text-only on phones. Plain emoji, no icon-font dependency. */
  nav.tabbar button::before { margin-right: 8px; }
  nav.tabbar button[data-tab="appointments"]::before { content: "📅"; }
  nav.tabbar button[data-tab="reception"]::before { content: "🛎️"; }
  nav.tabbar button[data-tab="clinic"]::before { content: "🏥"; }
  nav.tabbar button[data-tab="lab"]::before { content: "🧪"; }
  nav.tabbar button[data-tab="emr"]::before { content: "📋"; }
  nav.tabbar button[data-tab="settings"]::before { content: "⚙️"; }
  nav.tabbar button[data-tab="book"]::before { content: "🗓️"; }
  nav.tabbar button[data-tab="vitals"]::before { content: "❤️"; }
  nav.tabbar button[data-tab="reports"]::before { content: "🧾"; }
  nav.tabbar button[data-tab="records"]::before { content: "📋"; }
  nav.tabbar button[data-tab="notices"]::before { content: "📢"; }
  nav.tabbar button[data-tab="profile"]::before { content: "👤"; }

  /* EMR landing screen: real two columns once there's room — patient/queue
     lists on the left, the search/add-patient working area on the right. */
  .emr-landing-grid { display: grid; grid-template-columns: 300px 1fr; gap: 16px; align-items: start; }
  .emr-landing-side, .emr-landing-main { order: initial; }

  /* New Consultation: form on the left, live print preview on the right —
     sticky so it stays in view while scrolling a long form. */
  .consult-grid { display: grid; grid-template-columns: 1fr 320px; gap: 16px; align-items: start; }
  .consult-preview { position: sticky; top: 76px; }

  /* Collapsed to icons-only while the Prescription screen's two-column
     layout is open (see reorderTabbarForActive's sibling, the "collapsed"
     class toggle in renderSubTabGroup) — gives that layout the extra width.
     Trick: zero the button's own font-size so its text node disappears,
     while the icon (its own box, via ::before) keeps its own explicit size. */
  nav.tabbar.collapsed { width: 56px; }
  nav.tabbar.collapsed button { font-size: 0; padding: 13px 0; text-align: center; }
  nav.tabbar.collapsed button::before { font-size: 20px; margin-right: 0; }
  body:has(nav.tabbar.collapsed:not(.hidden)) header.topbar,
  body:has(nav.tabbar.collapsed:not(.hidden)) main,
  body:has(nav.tabbar.collapsed:not(.hidden)) .app-footer { margin-left: 56px; }
  /* Actually use the width the collapse freed up, not just shift the same
     760px cap over. */
  body:has(nav.tabbar.collapsed:not(.hidden)) main { max-width: 900px; }
}
