/* Pilea: neutral grouped surfaces, system typography and semantic green accents. */
:root {
  --pilea-canvas: #f2f2f7;
  --pilea-ink: #1c1c1e;
  --pilea-pine: #1c1c1e;
  --pilea-green: #13bf63;
  --pilea-muted: #f2f2f7;
  --pilea-border: #e5e5ea;
  --pilea-shadow: 0 6px 24px #00000006;
  --pilea-radius: 22px;
}
body {
  background: var(--pilea-canvas);
  color: var(--pilea-ink);
  font-family:
    -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
}
h1 {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -1.2px;
  line-height: 1.18;
}
h2,
h3 {
  font-weight: 700;
  letter-spacing: -0.35px;
}
p,
small {
  color: #6c6c70;
}
.topbar {
  background: transparent;
  border: 0;
  height: 72px;
}
.topbar .icon-button,
.topbar .avatar {
  background: #ffffffd9;
  border-color: transparent;
}
.device-tag {
  color: #6c6c70;
}
.page-heading {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 12px 2px 18px;
  margin-bottom: 20px;
  box-shadow: none;
  flex-wrap: wrap;
  gap: 20px;
}
.page-heading h1 {
  margin-bottom: 8px;
}
.eyebrow {
  color: #6c6c70;
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 1.2px;
  margin-bottom: 10px;
}
.page-heading p {
  font-size: 13px;
  color: #6c6c70;
}
.heading-actions {
  gap: 8px;
}
.primary,
.secondary,
.danger {
  border-radius: 14px;
  min-height: 44px;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 700;
  box-shadow: none;
}
.primary {
  background: var(--pilea-green);
  color: #103b24;
  border-color: transparent;
}
.primary:hover {
  background: #0eaf58;
  box-shadow: 0 4px 12px #0f8b3b20;
}
.secondary {
  background: #f2f2f7;
  color: #187846;
  border-color: transparent;
}
.secondary:hover {
  background: #e5e5ea;
  border-color: transparent;
}
.primary:active,
.secondary:active {
  transform: translateY(1px);
  box-shadow: none;
}
.icon-button {
  background: #f2f2f7;
  border-color: transparent;
  border-radius: 13px;
}
.month-picker {
  height: 44px;
  min-height: 44px;
  border: 0;
  background: #f2f2f7;
  border-radius: 13px;
  box-shadow: none;
}
.month-picker button {
  width: 36px;
  height: 36px;
  min-height: 36px;
  background: transparent;
  border-radius: 10px;
}
.month-picker input {
  font-size: 13px;
  background: transparent;
}
.panel,
.card-showcase,
.account-card,
.auth-card,
.metric,
.balance-card {
  border-color: transparent;
  border-radius: var(--pilea-radius);
  box-shadow: var(--pilea-shadow);
}
.personal-metrics {
  gap: 18px;
  margin-bottom: 20px;
}
.personal-metrics article {
  background: #fff;
  border-color: transparent;
  border-radius: var(--pilea-radius);
  padding: 24px;
  box-shadow: var(--pilea-shadow);
}
.personal-metrics article > span {
  color: #636366;
  font-size: 13px;
  font-weight: 650;
}
.personal-metrics article > strong {
  font-size: 34px;
  line-height: 1.2;
  margin: 14px 0;
  font-weight: 700;
  letter-spacing: -1px;
}
.personal-metrics article > small {
  color: #6c6c70;
}
.personal-metrics .surplus-card {
  background: #fff;
}
.personal-metrics .surplus-card > span,
.personal-metrics .surplus-card > small {
  color: #636366;
}
.personal-metrics .surplus-card > strong {
  color: #187846;
}
.personal-metrics .surplus-card .negative {
  color: #6e231e;
}
.surplus-card .info-button {
  background: #ffffff52;
  border-color: transparent;
  color: #636366;
}
.fortnight-grid,
.check-analytics,
.budget-simple-grid,
.investment-grid {
  gap: 20px;
}
.fortnight-grid > .check-section,
.check-analytics > .panel {
  padding: 24px;
}
.fortnight-grid .section-title h2 {
  font-size: 19px;
}
.fortnight-grid .section-title > strong {
  font-size: 19px;
}
.check-section .section-title p {
  font-size: 12px;
  color: #6c6c70;
}
.list-caption {
  color: #6c6c70;
  font-size: 11px;
  letter-spacing: 0.075em;
  margin-top: 18px;
}
.check-row {
  border-top-color: #ececf0;
  min-height: 104px;
  padding: 14px 0;
}
.check-description strong {
  font-size: 14px;
  font-weight: 700;
  color: #1c1c1e;
}
.check-description small {
  font-size: 12px;
  color: #6c6c70;
  margin-top: 4px;
}
.check-value strong {
  font-size: 17px;
  font-weight: 700;
}
.check-value .text-link {
  font-size: 12px;
  color: #2a7950;
}
.bill-check {
  border-color: #a7beb0;
  border-width: 1.5px;
  border-radius: 10px;
  background: #f9fcfa;
}
.bill-check[aria-checked="true"] {
  background: #13bf63;
  border-color: #13bf63;
  color: #103b24;
}
.receipt-confirm,
.receipt-badge {
  background: #e5f5eb;
  border-color: transparent;
  color: #24613e;
}
.check-history > details {
  border-top-color: #e5e5ea;
}
.check-history summary {
  color: #636366;
  font-size: 13px;
}
.info-button {
  background: #f2f2f7;
  border-color: transparent;
  color: #386449;
  width: 28px;
  height: 28px;
  min-width: 28px;
  min-height: 28px;
}
.check-analytics {
  margin-top: 20px;
}
.check-analytics .section-title h2 {
  font-size: 18px;
}
.debt-progress {
  border-bottom-color: #ececf0;
}
.debt-progress > div {
  font-size: 13px;
}
.debt-progress progress {
  height: 12px;
  border-radius: 10px;
}
.debt-progress progress::-webkit-progress-bar {
  background: #eaf3ed;
}
.debt-progress progress::-webkit-progress-value {
  background: #13bf63;
  border-radius: 10px;
}
.pie-legend li {
  border-bottom-color: #ececf0;
}
.pie-legend i {
  border-radius: 50%;
  width: 10px;
  height: 10px;
  flex-basis: 10px;
}
.check-credit-card {
  border-radius: 22px;
  box-shadow: 0 12px 24px #1c1c1e18;
}
.card-split > div {
  background: #f2f2f7;
  border-radius: 16px;
}
.card-split strong {
  font-size: 24px;
}
.check-person {
  border-top-color: #e5e5ea;
}
.check-unassigned {
  border-radius: 14px;
}
form input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
form select,
form textarea,
.filterbar input,
.filterbar select {
  background: #f2f2f7;
  border-color: #e5e5ea;
  border-radius: 13px;
  color: #1c1c1e;
}
form input:focus,
form select:focus,
form textarea:focus {
  border-color: #20a05b;
  outline-color: #13bf6326;
}
form label {
  font-size: 13px;
  color: #3a3a3c;
}
dialog {
  border: 0;
  border-radius: 28px;
  box-shadow: 0 24px 80px #123d2c26;
}
dialog::backdrop {
  background: #1c1c1e52;
  backdrop-filter: blur(4px);
}
.dialog-actions {
  gap: 10px;
}
.pill,
.count {
  background: #e9f4ed;
  border-color: transparent;
  color: #2a6743;
}
.progress {
  height: 12px;
  background: #eaf3ed;
}
.progress i {
  background: #13bf63;
}
.investment-total {
  font-size: 32px;
}
footer {
  border-top: 0;
  color: #8e8e93;
}
.auth-card {
  border-radius: 28px;
}
@media (min-width: 701px) {
  .sidebar {
    inset: 16px auto 16px 16px;
    width: 210px;
    border: 0;
    border-radius: 26px;
    padding: 26px 14px;
    box-shadow: var(--pilea-shadow);
  }
  .main {
    margin-left: 242px;
  }
  main {
    padding: 8px 28px 24px;
  }
  .topbar {
    padding: 0 28px;
  }
  .sidebar .brand {
    font-size: 32px;
  }
  .sidebar nav a {
    border-radius: 15px;
    min-height: 46px;
    font-weight: 650;
  }
  .sidebar nav a.active {
    background: #edf7f0;
    color: #187846;
    box-shadow: none;
  }
  .sidebar nav a.active i {
    background: #155b32;
  }
  .sidebar nav a:not(.active):hover {
    background: #f2f2f7;
  }
  .sidebar-foot {
    border-color: #ececf0;
  }
}
@media (max-width: 1100px) and (min-width: 701px) {
  .sidebar {
    width: 184px;
  }
  .main {
    margin-left: 216px;
  }
  main {
    padding: 8px 20px 24px;
  }
  .topbar {
    padding: 0 20px;
  }
}
@media (max-width: 700px) {
  body {
    background: #f2f2f7;
  }
  main {
    padding: 12px 12px 24px;
  }
  .topbar {
    height: 60px;
    padding: 0 16px;
  }
  .page-heading {
    padding: 8px 4px 12px;
    border-radius: 0;
    gap: 18px;
    margin-bottom: 16px;
  }
  h1 {
    font-size: 28px;
    letter-spacing: -0.8px;
  }
  .page-heading p {
    font-size: 12px;
  }
  .heading-actions {
    gap: 8px;
  }
  .heading-actions .primary,
  .heading-actions .secondary {
    min-height: 44px;
    font-size: 13px;
  }
  .personal-metrics {
    gap: 12px;
    margin-bottom: 16px;
  }
  .personal-metrics article {
    padding: 18px;
    border-radius: 22px;
  }
  .personal-metrics article > strong {
    font-size: 27px;
  }
  .personal-metrics article > span {
    font-size: 12px;
  }
  .personal-metrics article > small {
    font-size: 11px;
  }
  .fortnight-grid,
  .check-analytics,
  .budget-simple-grid,
  .investment-grid {
    gap: 16px;
  }
  .fortnight-grid > .check-section,
  .check-analytics > .panel {
    padding: 20px 18px;
  }
  .fortnight-grid .section-title h2,
  .fortnight-grid .section-title > strong {
    font-size: 18px;
  }
  .check-analytics .section-title h2 {
    font-size: 18px;
  }
  .info-button {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
  }
  .sidebar {
    background: #ffffffed;
    border-color: #e5e5ea;
    box-shadow: 0 -4px 24px #234c350c;
  }
  .sidebar nav a.active {
    background: #edf7f0;
    color: #187846;
    border-radius: 16px;
    box-shadow: none;
  }
  .sidebar nav a.active i {
    background: #155b32;
  }
  .card-split strong {
    font-size: 22px;
  }
  dialog {
    border-radius: 24px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}

/* iPhone-like hierarchy: color communicates actions and state, not the canvas. */
.page-heading h1 {
  color: #1c1c1e;
}
.page-heading p {
  color: #6c6c70;
}
.eyebrow {
  letter-spacing: 0.06em;
  font-size: 10px;
  font-weight: 600;
}
.primary,
.secondary,
.danger {
  font-weight: 650;
  border-radius: 12px;
}
.primary:hover {
  box-shadow: none;
}
.primary:active,
.secondary:active {
  transform: scale(0.98);
}
.personal-metrics article > span {
  color: #636366;
}
.personal-metrics .surplus-card > span,
.personal-metrics .surplus-card > small {
  color: #636366;
}
.surplus-card .info-button,
.info-button {
  background: #f2f2f7;
  color: #6c6c70;
}
.personal-metrics article > strong {
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.8px;
}
.fortnight-grid .section-title > strong {
  color: #1c1c1e;
}
.check-description strong {
  font-size: 15px;
}
.check-description small {
  line-height: 1.5;
}
.check-value .text-link {
  color: #187846;
  font-weight: 600;
}
.bill-check {
  background: #fff;
  border-color: #c7c7cc;
  border-radius: 50%;
}
.bill-check[aria-checked="true"] {
  background: #13bf63;
  border-color: #13bf63;
}
.receipt-confirm {
  color: #187846;
  background: #edf7f0;
  border-radius: 12px;
}
.check-history summary {
  font-weight: 600;
}
.debt-progress > div > span {
  color: #636366;
}
.debt-progress progress::-webkit-progress-bar {
  background: #ececf0;
}
.card-split span {
  color: #6c6c70;
}
.card-split strong {
  color: #1c1c1e;
}
.investment-total {
  color: #1c1c1e;
}
.icon-button {
  color: #636366;
}
.icon-button:hover {
  color: #187846;
  background: #e9f4ed;
}
.topbar .icon-button,
.topbar .avatar {
  background: #ffffffb3;
}
.pill,
.count {
  background: #edf7f0;
  color: #187846;
}
.status.pending {
  background: #fff4df;
  color: #865b10;
}
.status.paid {
  background: #edf7f0;
  color: #187846;
}
dialog::backdrop {
  background: #00000038;
  backdrop-filter: blur(6px);
}
.auth-card {
  background: #fff;
}
@media (min-width: 701px) {
  .sidebar {
    background: #ffffffd9;
    border: 1px solid #ffffff;
    box-shadow: none;
  }
  .sidebar nav a.active {
    background: #edf7f0;
    color: #187846;
  }
  .sidebar nav a.active i {
    background: #13bf63;
  }
  .sidebar nav a:not(.active) {
    color: #636366;
  }
  .sidebar nav a:not(.active):hover {
    background: #f2f2f7;
    color: #1c1c1e;
  }
}
@media (max-width: 700px) {
  .topbar {
    background: #f2f2f7e8;
    backdrop-filter: blur(16px);
  }
  .sidebar {
    background: #ffffffed;
    border-top: 1px solid #d1d1d680;
    backdrop-filter: blur(18px);
    box-shadow: none;
  }
  .sidebar nav a {
    color: #8e8e93;
  }
  .sidebar nav a.active {
    background: transparent;
    color: #187846;
  }
  .sidebar nav a.active i {
    background: #13bf63;
  }
  .personal-metrics article {
    border-radius: 20px;
  }
  .check-row {
    gap: 10px 12px;
  }
}
