.insights-page,.schedules-page,.bills-page{display:grid;gap:1.25rem;padding-bottom:1rem}
.insights-page [data-insight-error]:empty{display:none}
.insights-page .sr-only,.bills-page .sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.insight-heading{display:flex;align-items:center;justify-content:space-between;gap:1rem;flex-wrap:wrap}
.insight-heading h2{margin:.3rem 0 0;font-size:1.5rem;letter-spacing:-.04em;font-weight:650}
.insight-heading .eyebrow{margin:0;color:#72857b;font-size:.875rem}
.insight-controls,.insight-filter{display:flex;gap:.65rem;align-items:center;flex-wrap:wrap}
.insight-filter{justify-content:space-between}
.insight-controls input,.insight-filter select,.bill-month-switch input{border:1px solid #dce6df;background:white;border-radius:.65rem;padding:.6rem .7rem;font:inherit;min-height:2.75rem;max-width:100%;color:#27483a}
.insight-date input[type=number]{width:6.5rem}
.insight-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.8rem}
.insight-summary article{display:flex;flex-direction:column;gap:.6rem;padding:1.15rem}
.insight-summary .muted{font-size:.875rem}
.insight-summary strong{font-size:clamp(1.15rem,2.7vw,1.75rem);font-weight:650;letter-spacing:-.03em;overflow-wrap:anywhere;font-variant-numeric:tabular-nums}
.insight-panels{display:grid;grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);gap:1.25rem}
.insights-page .card,.bills-page .card{padding:1.4rem}
.insights-page .section-title,.bills-page .section-title{display:flex;align-items:center;justify-content:space-between;gap:.75rem;flex-wrap:wrap;margin-bottom:1rem}
.insights-page .section-title h3,.bills-page .section-title h3{font-size:1rem;margin:0;font-weight:650}
.insights-page .section-title>.muted,.bills-page .section-title>.muted{font-size:.8125rem}
.insight-composition-body{display:flex;align-items:center;gap:1rem;min-height:12rem}
.insight-donut{width:clamp(9rem,17vw,12rem);flex-shrink:0}
.insight-donut text{fill:#244b3c;font-family:inherit}
.insight-donut .donut-number{font-size:30px;font-weight:600}
.insight-donut .donut-caption{font-size:14px;fill:#829289}
.insight-legend{flex:1;min-width:5rem;display:grid;gap:.85rem;font-size:.875rem}
.insight-legend>div{display:flex;align-items:center;gap:.5rem}
.insight-legend>div{min-width:0}
.insight-legend>div>span{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.insight-legend i,.trend-legend i{width:.5rem;height:.5rem;border-radius:50%;flex-shrink:0}
.insight-legend b{margin-left:auto;font-size:.8125rem;font-weight:500;color:#75847b;flex-shrink:0;white-space:nowrap}
.trend-legend{display:flex;flex-wrap:wrap;gap:.8rem;justify-content:flex-end;font-size:.8125rem;margin-bottom:.4rem}
.trend-legend span{display:inline-flex;align-items:center;gap:.4rem}
.insight-trend{display:block;width:100%;height:auto}
.insight-trend text{fill:#85938b;font-size:20px;font-family:inherit}
.insight-chart-empty{font-size:.875rem;text-align:center;margin:.5rem 0}
.insight-ranking{overflow:hidden}
.insight-rank{display:flex;width:100%;align-items:center;text-align:left;gap:.75rem;padding:.85rem 0;background:none;color:inherit;border:0;border-bottom:1px solid #edf1ee;cursor:pointer;font:inherit;min-height:3.5rem}
.insight-rank:last-child{border-bottom:0}
.insight-rank:hover .rank-heading>b{color:#317b65}
.rank-order{width:1.1rem;flex-shrink:0;font-size:.8125rem;color:#9aaa9f;font-variant-numeric:tabular-nums}
.rank-name{display:grid;gap:.4rem;flex:1;min-width:0}
.rank-heading,.rank-footer{display:flex;align-items:center;justify-content:space-between;gap:.75rem;min-width:0}
.rank-heading>b{font-size:.9375rem;font-weight:550;min-width:0;overflow-wrap:anywhere}
.rank-footer>small{color:#85948b;font-size:.75rem;white-space:nowrap;font-variant-numeric:tabular-nums}
.rank-track{flex:1;min-width:0;height:.25rem;background:#f0f4f1;border-radius:1rem;overflow:hidden}
.rank-track i{display:block;height:100%;border-radius:1rem;min-width:.2rem}
.rank-value{text-align:right;font-size:.9375rem;font-weight:550;font-variant-numeric:tabular-nums;white-space:nowrap;flex-shrink:0}
.rank-detail-summary{display:flex;flex-direction:column;gap:.4rem;margin-bottom:1.25rem}
.rank-detail-summary>strong{font-size:1.9rem;letter-spacing:-.04em}
.rank-detail-summary>.muted{font-size:.875rem}
.rank-detail-list{max-height:55dvh;overflow-y:auto;overscroll-behavior:contain}
.rank-detail-row{display:flex;align-items:center;justify-content:space-between;gap:1rem;width:100%;text-align:left;border:0;border-bottom:1px solid #edf1ee;background:none;color:inherit;padding:1rem 0;font:inherit;cursor:pointer}
.rank-detail-row>span{min-width:0;display:grid;gap:.4rem}
.rank-detail-row b{font-size:.9375rem;overflow-wrap:anywhere;font-weight:550}
.rank-detail-row small{font-size:.8125rem;color:#829288}
.rank-detail-row strong{font-weight:550;white-space:nowrap;font-size:.9375rem}
.insight-loading{padding:2.5rem!important;text-align:center;color:#7b9184;animation:insight-pulse 1.6s ease-in-out infinite}
.insight-error{text-align:center;padding:1.5rem;color:#8f6558}
.insight-error p{margin:0 0 1rem;overflow-wrap:anywhere}
.schedule-intro{margin:0;font-size:.875rem;line-height:1.8}
.schedules-page>[data-rules]{overflow:hidden}
.schedule-row{padding:1rem 0;border-bottom:1px solid #edf1ee}
.schedule-row:last-child{border-bottom:0}
.schedule-row-content{display:flex;align-items:center;gap:.6rem}
.schedule-main{display:flex;gap:.85rem;align-items:flex-start;text-align:left;border:0;background:transparent;font:inherit;color:inherit;padding:.25rem 0;flex:1;min-width:0;cursor:pointer;touch-action:pan-y}
.schedule-main:disabled{cursor:default;opacity:1}
.schedule-mark{display:flex;align-items:center;justify-content:center;width:2.5rem;height:2.5rem;border-radius:.8rem;background:#eef4ef;color:#32614d;flex-shrink:0;font-size:.9375rem}
.schedule-copy{display:grid;gap:.35rem;min-width:0;flex:1}
.schedule-title{display:flex;align-items:flex-start;justify-content:space-between;gap:.5rem;min-width:0}
.schedule-title>b{font-size:1rem;line-height:1.5;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;overflow-wrap:anywhere;font-weight:550;min-width:0}
.schedule-copy>small{font-size:.875rem;line-height:1.5;color:#788a7e}
.schedule-date{display:flex;align-items:baseline;flex-wrap:wrap;gap:.1rem .65rem;font-size:.8125rem;line-height:1.5;color:#8c9a91}
.schedule-date>span{white-space:nowrap}
.schedule-record-date{font-size:.8125rem;line-height:1.5;color:#8c9a91}
.schedule-status{font-size:.75rem;white-space:nowrap;border-radius:.4rem;padding:.2rem .4rem;background:#edf5ef;color:#527761;flex-shrink:0}
.schedule-row.paused .schedule-status{background:#f2f1ee;color:#9b9382}
.schedule-more{border:0;background:none;font:inherit;font-size:.8125rem;color:#8b9b90;padding:.5rem .15rem;cursor:pointer;min-height:2.75rem}
.schedule-actions{display:none;justify-content:flex-end;gap:.65rem;margin-top:.8rem}
.schedule-row.actions-open .schedule-actions{display:flex}
.schedule-actions .button{min-height:2.5rem;padding:.5rem 1rem;font-size:.875rem}
.schedule-delete{background:#b85c4f!important;color:white!important}
.schedule-empty{padding:2rem 1rem!important;text-align:center}
.schedule-empty>.icon{width:2.8rem;height:2.8rem;color:#94ac9b;margin-bottom:.75rem}
.schedule-empty h3{font-size:1rem;font-weight:550;color:#3a5b48;margin:.25rem 0 .7rem}
.schedule-empty p{font-size:.875rem;line-height:1.8;margin-bottom:1.5rem}
.schedule-form{display:grid;gap:1.05rem}
.schedule-form .form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.9rem}
.schedule-form .field{display:grid;gap:.45rem;font-size:.875rem;min-width:0}
.schedule-form input,.schedule-form select,.schedule-form textarea{width:100%;box-sizing:border-box;min-width:0}
.schedule-form textarea{resize:vertical;min-height:4.5rem}
.schedule-follow{display:flex;gap:.6rem;align-items:center;font-size:.875rem;color:#486c57;cursor:pointer;line-height:1.6}
.schedule-follow input{width:1.1rem;height:1.1rem;accent-color:#174d40;flex-shrink:0}
.schedule-help{font-size:.8125rem;line-height:1.8;color:#849589;background:#f4f7f3;padding:.75rem .85rem;border-radius:.6rem;margin:0}
.schedule-preview{display:grid;gap:.25rem;margin:0;padding:.8rem .9rem;border-radius:.65rem;background:#eef4ef;color:#52705e;font-size:.8125rem;line-height:1.7;overflow-wrap:anywhere}
.schedule-preview>span{color:#849589;font-size:.75rem}.schedule-preview>strong{font-weight:500}
.schedule-form-error{color:#b85c4f;line-height:1.65;font-size:.875rem;margin:0;overflow-wrap:anywhere}
.schedule-form-error:empty{display:none}
.schedule-form-actions{display:flex;justify-content:flex-end;gap:.65rem;padding-top:.3rem}
.schedule-confirm{font-weight:550;overflow-wrap:anywhere}
.bill-month-switch{display:flex;gap:.35rem;align-items:center;max-width:100%}
.bill-month-switch .button{padding:.5rem;min-width:2.5rem}
.bill-month-switch input{min-width:0;width:10rem}
.bill-hero{border-radius:1.3rem;padding:1.75rem;background:linear-gradient(125deg,#174d40,#286552);color:#fff;position:relative;overflow:hidden}
.bill-hero:after{content:'';width:17rem;height:17rem;position:absolute;right:-7rem;top:-10rem;border:3rem solid #ffffff06;border-radius:50%;pointer-events:none}
.bill-hero-heading{display:flex;justify-content:space-between;gap:1rem;font-size:.875rem;color:#d6e7dc;margin-bottom:2rem}
.bill-hero-heading span:last-child{text-align:right;overflow-wrap:anywhere}
.bill-hero>p{font-size:.875rem;letter-spacing:.03em;margin:0 0 .6rem;color:#c0d8c8}
.bill-hero>strong{display:block;font-size:clamp(2rem,6vw,2.8rem);font-weight:550;letter-spacing:-.04em;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
.bill-hero-totals{display:grid;grid-template-columns:1fr 1fr;gap:1rem;margin-top:1.75rem;padding-top:1.15rem;border-top:1px solid #ffffff20}
.bill-hero-totals>div{display:grid;gap:.4rem;min-width:0}
.bill-hero-totals span{font-size:.8125rem;color:#c0d8c8}
.bill-hero-totals b{font-size:1.25rem;font-weight:500;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
.bill-facts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.8rem}
.bill-facts .card{display:grid;gap:.5rem;padding:1.15rem;text-align:center;min-width:0}
.bill-facts strong{font-size:1.35rem;font-weight:550;overflow-wrap:anywhere;font-variant-numeric:tabular-nums}
.bill-facts .muted{font-size:.8125rem}
.bill-total-line{display:flex;align-items:center;gap:.8rem;margin:1.25rem 0;font-size:.875rem}
.bill-total-line>div{flex:1;min-width:0;background:#f0f4f0;border-radius:1rem;height:.5rem}
.bill-total-line i,.bill-mini-track i{display:block;height:100%;border-radius:1rem}
.bill-total-line>b{font-size:.9375rem;text-align:right;min-width:5.5rem;font-weight:550;font-variant-numeric:tabular-nums}
.income-bar{background:#4d9476}.expense-bar{background:#d88974}
.bill-member{padding:1rem 0 1.25rem;border-bottom:1px solid #edf1ee}
.bill-member:last-child{border-bottom:0;padding-bottom:0}
.bill-member-heading{display:flex;align-items:center;gap:.65rem}
.bill-avatar{display:flex;align-items:center;justify-content:center;width:2rem;height:2rem;border-radius:.7rem;color:white;font-size:.875rem}
.bill-member-heading>b{font-size:.9375rem;font-weight:550;overflow-wrap:anywhere;min-width:0}
.bill-member-heading>.muted{font-size:.8125rem;margin-left:auto;white-space:nowrap}
.bill-member-amounts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1.5rem;margin-top:1rem}
.bill-member-amounts>div{display:grid;gap:.5rem;min-width:0}
.bill-member-amounts strong{font-weight:550;font-size:1.1rem;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
.bill-member-amounts .muted{font-size:.8125rem}
.bill-mini-track{height:.25rem;background:#f0f4f0;border-radius:1rem}
.bill-category-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1.25rem}
.bill-category{display:flex;align-items:center;justify-content:space-between;gap:.75rem;padding:.8rem 0;border-bottom:1px solid #edf1ee;font-size:.9375rem}
.bill-category:last-child{border-bottom:0}
.bill-category b{font-weight:500;font-variant-numeric:tabular-nums}
.bill-footnote{font-size:.8125rem;line-height:1.8;text-align:center;margin:0}
@keyframes insight-pulse{50%{opacity:.55}}
@media(max-width:1100px){.insight-panels{grid-template-columns:minmax(0,1fr)}.insight-composition-body{justify-content:center}.insight-legend{max-width:15rem}.insight-donut{width:10.5rem}}
@media(max-width:760px){
  .insights-page,.schedules-page,.bills-page{gap:.75rem}
  .insight-panels{grid-template-columns:1fr;gap:.75rem}
  .insight-heading{align-items:center;gap:.75rem}
  .insight-heading h2{margin-top:.15rem;font-size:1.125rem}
  .insight-heading .eyebrow{font-size:.75rem;letter-spacing:1px}
  .insight-controls{width:100%;justify-content:space-between;gap:.5rem}
  .insight-controls input,.insight-filter select,.bill-month-switch input{font-size:16px;min-height:44px;padding:.45rem .6rem}
  .insights-page .card,.bills-page .card{padding:1rem}
  .insights-page .section-title,.bills-page .section-title{margin-bottom:.65rem}
  .insights-page .section-title h3,.bills-page .section-title h3{font-size:.9375rem}
  .insights-page .section-title>.muted,.bills-page .section-title>.muted{font-size:.75rem}
  .insight-summary{gap:.5rem}
  .insight-summary article{padding:.75rem!important;gap:.4rem}
  .insight-summary .muted{font-size:.75rem}
  .insight-summary strong{font-size:clamp(.9375rem,4vw,1.0625rem)}
  .insight-donut{width:8rem}
  .insight-composition-body{justify-content:center;min-height:0;gap:1rem}
  .insight-legend{max-width:none;gap:.55rem;font-size:.8125rem}
  .insight-legend>div{gap:.4rem}
  .insight-legend b{font-size:.75rem}
  .insight-rank{gap:.6rem;padding:.7rem 0;min-height:56px}
  .rank-name{gap:.35rem}
  .rank-heading>b,.rank-value{font-size:.875rem}
  .rank-footer{gap:.65rem}
  .rank-detail-summary{gap:.3rem;margin-bottom:.75rem}
  .rank-detail-summary>strong{font-size:1.5rem}
  .rank-detail-summary>.muted{font-size:.8125rem}
  .rank-detail-row{gap:.65rem;padding:.75rem 0;min-height:44px}
  .rank-detail-row>span{gap:.25rem}
  .rank-detail-row b,.rank-detail-row strong{font-size:.875rem}
  .rank-detail-row small{font-size:.75rem}
  .schedules-page .insight-heading>.button{min-height:44px;padding:.6rem .85rem;font-size:.8125rem}
  .schedule-intro{font-size:.8125rem;line-height:1.6}
  .schedules-page>[data-rules]{padding:.15rem .85rem}
  .schedule-row{padding:.75rem 0}
  .schedule-row-content{gap:.25rem;align-items:flex-start}
  .schedule-main{gap:.6rem;padding:.1rem 0;min-height:44px}
  .schedule-mark{width:2rem;height:2rem;border-radius:.6rem;font-size:.875rem}
  .schedule-copy{gap:.25rem}
  .schedule-title>b{font-size:.875rem;line-height:1.45}
  .schedule-copy>small{font-size:.8125rem;line-height:1.45}
  .schedule-date,.schedule-record-date{font-size:.75rem;line-height:1.5}
  .schedule-status{font-size:.75rem;line-height:1.5;padding:.15rem .35rem}
  .schedule-more{min-width:44px;min-height:44px;padding:.35rem .15rem;font-size:.75rem}
  .schedule-actions{margin-top:.4rem;gap:.5rem}
  .schedule-actions .button{min-height:44px}
  .schedule-form{gap:.85rem}
  .schedule-form .form-grid{gap:.7rem}
  .schedule-form input,.schedule-form select,.schedule-form textarea{font-size:16px}
  .schedule-help{padding:.6rem .7rem;line-height:1.6;font-size:.75rem}
  .bill-category-grid{grid-template-columns:1fr;gap:.75rem}
  .bill-facts{gap:.5rem}
  .bill-facts .card{padding:.75rem}
  .bill-facts strong{font-size:1rem}
  .bill-facts .muted{font-size:.75rem}
  .bill-month-switch{width:100%;justify-content:space-between}
  .bill-month-switch input{width:auto;min-width:10rem}
  .bill-month-switch .button{min-width:44px;min-height:44px}
  .bill-hero{padding:1.15rem;border-radius:1rem}
  .bill-hero-heading{margin-bottom:1rem;font-size:.8125rem}
  .bill-hero>strong{font-size:1.9rem}
  .bill-hero-totals{margin-top:1rem;padding-top:.85rem}
  .bill-hero-totals b{font-size:1.125rem}
  .bill-member{padding:.8rem 0}
  .bill-member-amounts{gap:1rem;margin-top:.75rem}
  .bill-member-amounts>div{gap:.35rem}
  .bill-member-amounts strong{font-size:1rem}
  .bill-total-line{gap:.6rem;margin:1rem 0}
  .bill-category{padding:.65rem 0;font-size:.875rem}
}
@media(max-width:360px){.insight-donut{width:7rem}.insight-composition-body{gap:.65rem}}
@media(prefers-reduced-motion:reduce){.insight-loading{animation:none}}
