.d-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: clamp(24px, 4vw, 48px); align-items: start; }
.d-stack { display: grid; gap: 16px; }
.d-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.d-card h2 { font-size: 1.25rem; margin-bottom: 12px; }
.d-card h3 { font-size: 1rem; margin-bottom: 8px; }
.d-tint { background: var(--teal-tint); border-color: transparent; }
.d-warn { background: #FFF4CF; border-color: transparent; }
.d-error { background: #FDEDE9; border-color: transparent; color: #9A3A28; }
.d-form { display: grid; gap: 14px; max-width: 480px; }
.d-form label { display: grid; gap: 6px; font-weight: 600; font-size: .9375rem; }
.d-form input, .d-form select { font: inherit; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--white); color: var(--ink); }
.d-form input:focus, .d-form select:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 3px rgba(23,163,143,.15); }
.d-form .btn { justify-self: start; }
.d-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.d-row.between { justify-content: space-between; }
.d-note { color: var(--ink-3); font-size: .9375rem; }
.d-qr { display: grid; place-items: center; gap: 10px; }
.d-qr svg { width: 200px; height: 200px; }
.d-qr code { font-size: .9375rem; background: var(--teal-tint); padding: 4px 10px; border-radius: 8px; }
.d-items { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.d-item { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; align-items: center; background: var(--white); border: 1.5px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.d-item.on { border-color: var(--teal); background: var(--teal-tint); }
.d-item.open { border-style: dashed; }
.d-item .name { font-weight: 600; }
.d-item .price { font-variant-numeric: tabular-nums; font-weight: 600; }
.d-item .meta { grid-column: 1 / -1; font-size: .875rem; color: var(--ink-3); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.d-item form { grid-column: 1 / -1; }
.d-item button { width: 100%; font: inherit; font-weight: 700; padding: 10px; border-radius: 10px; border: 1.5px solid var(--navy); background: var(--white); color: var(--navy); cursor: pointer; }
.d-item.on button { background: var(--navy); color: var(--white); }
.d-chip { display: inline-flex; align-items: center; gap: 6px; background: var(--white); border: 1px solid var(--line); border-radius: 999px; padding: 2px 10px 2px 3px; font-size: .8125rem; font-weight: 600; color: var(--ink); }
.d-av { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--teal); color: var(--white); font-size: .7rem; font-weight: 700; }
.d-av.host { background: var(--navy); }
.d-unclaimed { color: #9A3A28; font-weight: 600; }
.d-totals { display: grid; gap: 6px; font-variant-numeric: tabular-nums; }
.d-totals div { display: flex; justify-content: space-between; gap: 12px; }
.d-totals .grand { font-weight: 800; font-size: 1.25rem; border-top: 1px solid var(--line); padding-top: 8px; margin-top: 4px; }
.d-people { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.d-people li { display: flex; justify-content: space-between; gap: 12px; align-items: center; font-variant-numeric: tabular-nums; }
.d-people li strong { font-size: 1.05rem; }
.d-people .paid { font-size: .8125rem; color: var(--teal-ink); font-weight: 600; }
.d-log { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; font-size: .875rem; color: var(--ink-3); }
.d-transfer { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center; background: var(--white); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.d-transfer strong { font-variant-numeric: tabular-nums; font-size: 1.1rem; }
.d-transfer form button { font: inherit; font-size: .875rem; font-weight: 700; color: var(--teal-ink); background: none; border: 0; cursor: pointer; padding: 0; }
.d-balance { display: flex; justify-content: space-between; gap: 12px; font-variant-numeric: tabular-nums; padding: 8px 0; border-bottom: 1px solid var(--line); }
.d-balance:last-child { border-bottom: 0; }
.d-balance .plus { color: var(--teal-ink); font-weight: 700; }
.d-balance .minus { color: #9A3A28; font-weight: 700; }
.d-big { font-size: 2.2rem; font-weight: 800; letter-spacing: -.03em; line-height: 1; }
.d-inline-form { display: flex; gap: 8px; flex-wrap: wrap; }
.d-inline-form input { flex: 1 1 160px; font: inherit; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 10px; }
.d-inline-form select { font: inherit; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 10px; background: var(--white); }
.d-inline-form button { font: inherit; font-weight: 700; padding: 10px 16px; border-radius: 999px; border: 0; background: var(--teal); color: var(--white); cursor: pointer; }
.d-badge { display: inline-block; font-size: .8125rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: var(--teal-tint); color: var(--teal-ink); }
.d-badge.open { background: #FFF4CF; color: #6B4E00; }
@media (max-width: 860px) { .d-grid { grid-template-columns: 1fr; } }
.d-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 14px; }
.d-stat { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; }
.d-stat strong { display: block; font-size: 1.9rem; font-weight: 800; letter-spacing: -.03em; line-height: 1.1; }
.d-stat span { color: var(--ink-3); font-size: .875rem; }
.d-table { width: 100%; border-collapse: collapse; font-size: .9375rem; }
.d-table th, .d-table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.d-table th { color: var(--ink-3); font-weight: 600; font-size: .8125rem; }
.d-table td.num, .d-table th.num { text-align: right; font-variant-numeric: tabular-nums; }
.d-table a { font-weight: 600; }
.d-subnav { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.d-subnav a { padding: 8px 14px; border-radius: 999px; border: 1.5px solid var(--line); text-decoration: none; color: var(--ink); font-weight: 600; font-size: .9375rem; }
.d-subnav a[aria-current="page"] { background: var(--navy); color: var(--white); border-color: var(--navy); }
.d-message { background: var(--teal-tint); border-radius: 12px; padding: 12px 16px; font-weight: 600; color: var(--teal-ink); }
.d-danger-zone { border-color: #F3C9C0; }
.d-danger-zone button { background: #9A3A28; }
.d-empty { color: var(--ink-3); }
.d-linkbtn { font: inherit; font-size: .875rem; font-weight: 700; color: var(--teal-ink); background: none; border: 0; cursor: pointer; padding: 0; }
.d-linkbtn.quiet { color: var(--ink-3); font-weight: 500; }
