:root {
  color-scheme: light;
  --bg: #f5f7f4;
  --surface: #ffffff;
  --text: #17211e;
  --muted: #61706b;
  --line: #dfe6e1;
  --primary: #25635a;
  --primary-dark: #194942;
  --accent: #c05b37;
  --warn: #9a6a13;
  --soft: #edf4f1;
  --shadow: 0 10px 32px rgba(30, 48, 43, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100%;
  color: var(--text);
  background: var(--bg);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

button,
input,
textarea {
  font: inherit;
}

button {
  touch-action: manipulation;
}

.shell {
  width: min(100%, 720px);
  margin: 0 auto;
  padding: 18px 16px 40px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0 18px;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 24px;
  letter-spacing: 0;
}

h2 {
  font-size: 20px;
  letter-spacing: 0;
}

.eyebrow {
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: 18px;
}

.login-copy {
  display: grid;
  gap: 6px;
  margin-bottom: 18px;
}

.login-copy p,
.section-head p,
.detail-sub,
.meta {
  color: var(--muted);
  font-size: 14px;
}

.stack {
  display: grid;
  gap: 14px;
}

.field {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.privacy-note {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.6;
}

input,
textarea {
  width: 100%;
  border: 1px solid #cfd9d4;
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  padding: 14px 13px;
  font-size: 16px;
}

textarea {
  min-height: 92px;
  resize: vertical;
}

input:focus,
textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 90, 0.16);
  outline: none;
}

.primary-button,
.search-row button,
.ghost-button,
.text-button {
  min-height: 48px;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 800;
}

.primary-button,
.search-row button {
  background: var(--primary);
  color: #fff;
  padding: 0 18px;
}

.primary-button:active,
.search-row button:active {
  background: var(--primary-dark);
}

.ghost-button {
  background: #e9efec;
  color: var(--primary-dark);
  padding: 0 14px;
}

.text-button {
  background: transparent;
  color: var(--primary);
  padding: 0;
  min-height: 36px;
}

.hidden {
  display: none !important;
}

.message {
  margin-bottom: 14px;
  border-radius: 8px;
  padding: 12px 14px;
  background: #fff6de;
  border: 1px solid #efd18d;
  color: #604206;
  font-weight: 700;
}

.user-strip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  border-radius: 8px;
  padding: 12px 14px;
  background: var(--soft);
  border: 1px solid #d8e5df;
}

.user-name {
  font-weight: 800;
}

.role-badge,
.sync-note,
.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 800;
}

.role-badge {
  margin-left: 6px;
  color: var(--primary-dark);
  background: #dcebe6;
}

.sync-note {
  color: #6b3c22;
  background: #f8e6d5;
  white-space: nowrap;
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 92px;
  gap: 10px;
  margin-bottom: 16px;
}

.list,
.room-list {
  display: grid;
  gap: 12px;
}

.property-button,
.room-button {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  cursor: pointer;
  padding: 15px;
  text-align: left;
}

.property-button:active,
.room-button:active {
  background: var(--soft);
}

.item-title {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  font-size: 17px;
  font-weight: 900;
}

.item-body {
  display: grid;
  gap: 5px;
  margin-top: 7px;
}

.room-meta-list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.room-meta {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 10px;
  align-items: baseline;
  color: var(--muted);
  font-size: 14px;
}

.room-meta-label {
  color: #40504b;
  font-weight: 800;
  white-space: nowrap;
}

.room-meta-value {
  min-width: 0;
  overflow-wrap: anywhere;
}

.detail-head {
  display: grid;
  gap: 5px;
  margin: 4px 0 16px;
}

.status-pill {
  color: var(--primary-dark);
  background: #dcebe6;
}

.status-pill.due {
  color: #6b3c04;
  background: #ffe9b8;
}

.status-pill.met {
  color: #164a33;
  background: #dbefe5;
}

.status-pill.needs-check {
  color: #6b3c04;
  background: #ffe9b8;
}

.status-pill.other {
  color: #4c425d;
  background: #ebe5f2;
}

.empty {
  border: 1px dashed #ccd6d1;
  border-radius: 8px;
  color: var(--muted);
  padding: 18px;
  text-align: center;
}

.sheet {
  position: fixed;
  inset: 0;
  z-index: 20;
}

.sheet-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(12, 22, 19, 0.42);
}

.sheet-panel {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  width: min(100%, 720px);
  max-height: 92vh;
  margin: 0 auto;
  overflow: auto;
  border-radius: 8px 8px 0 0;
  background: var(--surface);
  padding: 18px 16px 24px;
  box-shadow: 0 -12px 30px rgba(10, 20, 17, 0.22);
}

.sheet-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 14px;
}

.icon-button {
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: #eef2f0;
  color: var(--text);
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
}

fieldset {
  display: grid;
  gap: 9px;
  margin: 0;
  border: 0;
  padding: 0;
}

legend {
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.choice {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  cursor: pointer;
  font-weight: 800;
}

.choice input {
  width: 22px;
  height: 22px;
  accent-color: var(--primary);
}

@media (min-width: 640px) {
  .shell {
    padding-top: 28px;
  }

  .panel {
    padding: 22px;
  }

  .room-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
