/* Haushalter – components (iOS 27). Load after theme.css. */
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: var(--color-bg); color: var(--color-text); font-family: var(--font-body); font-size: 17px; line-height: 1.35; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }
.btn { display: inline-flex; align-items: center; justify-content: center; cursor: pointer; text-decoration: none; color: var(--color-text); background: transparent; white-space: nowrap; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.field > label { display: block; }
.input { width: 100%; min-height: 44px; font: inherit; }
.seg { display: inline-flex; overflow: hidden; }
.seg-opt { display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.seg-opt input { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; }
.tag { display: inline-flex; align-items: center; }
.tag-accent { background: var(--color-accent-800); color: var(--color-accent-100); }
.tag-accent-2 { background: var(--color-accent-2-800); color: var(--color-accent-2-100); }
.tag-neutral { background: var(--fill); color: var(--color-text); }
.tag-outline { box-shadow: inset 0 0 0 1px var(--color-accent); color: var(--color-accent-text); }
.btn { border-radius: 999px; font-family: inherit; font-weight: 600; font-size: 15px; border: 0; padding: 0 16px; min-height: 36px; gap: 6px; transition: transform .12s, background .15s; }
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--color-accent); color: var(--on-solid); border: 0; }
.btn-primary:hover { background: color-mix(in srgb, var(--color-accent) 88%, #000); }
.btn-primary:active { background: color-mix(in srgb, var(--color-accent) 76%, #000); }
.btn-secondary { background: var(--fill); color: var(--color-accent-text); border: 0; }
.btn-secondary:hover, .btn-secondary:active { background: var(--fill-2); }
.btn-ghost { color: var(--color-accent-text); padding-inline: 8px; }
.btn-ghost:hover { background: var(--fill); }
.btn-icon { width: 36px; height: 36px; padding: 0; border-radius: 50%; }
.input { border: 0; border-radius: 12px; background: var(--fill); font-size: 17px; padding: 10px 14px; color: var(--color-text); }
.input:hover { border: 0; }
.input:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 0; }
.seg { border: 0; border-radius: 999px; background: var(--fill); padding: 2px; gap: 2px; }
.seg-opt { border-radius: 999px; font-size: 14px; font-weight: 500; padding: 6px 12px; }
.seg-opt + .seg-opt { border-left: 0; }
.seg-opt:has(input:checked) { background: var(--seg-sel); color: var(--color-text); box-shadow: 0 3px 8px rgba(0,0,0,.12), 0 0 0 .5px rgba(0,0,0,.04); }
.seg-opt:not(:has(input:checked)):hover { background: transparent; }
.tag { border-radius: 999px; font-weight: 600; font-size: 12px; padding: 3px 9px; }
.field > label { font-size: 13px; color: var(--color-neutral-400); margin: 0 0 6px 4px; }
a { color: var(--color-accent-300); } a:hover { color: var(--color-accent-200); }
button { font-family: inherit; }

/* --- Layout blocks --- */
.card { background: var(--color-surface); border-radius: 26px; padding: 18px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.card-title { font-size: 20px; font-weight: 700; letter-spacing: -0.02em; margin: 0; }
.row { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 4px 0; }
.row + .row.sep, .sep { border-top: .5px solid var(--color-divider); }
.secondary { color: var(--color-neutral-400); }
.footnote { font-size: 13px; } .subhead { font-size: 15px; }
.large-title { font-size: 34px; font-weight: 700; letter-spacing: -0.03em; line-height: 1.15; margin: 0; }
.glass { background: var(--glass); -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%); box-shadow: var(--glass-edge); }
.glass-btn { width: 44px; height: 44px; border-radius: 50%; border: 0; display: inline-flex; align-items: center; justify-content: center; color: var(--color-text); cursor: pointer; }
.avatar { border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-weight: 600; flex: none; }
.check { width: 44px; height: 44px; margin: -6px -8px -6px -10px; border: 0; background: transparent; display: flex; align-items: center; justify-content: center; color: var(--color-neutral-500); cursor: pointer; }
.check > span { width: 22px; height: 22px; border-radius: 50%; border: 1.75px solid currentColor; }
.check:hover { color: var(--color-accent-text); }
.bar { height: 6px; border-radius: 6px; background: var(--fill); overflow: hidden; } .bar > i { display: block; height: 100%; border-radius: inherit; background: var(--color-accent); }
.tabs { display: flex; gap: 2px; padding: 3px; border-radius: 999px; background: var(--fill); overflow-x: auto; scrollbar-width: none; }
.tabs > a, .tabs > button { flex: 1 0 auto; min-height: 32px; padding: 0 14px; border: 0; border-radius: 999px; background: transparent; color: var(--color-text); font-size: 14px; font-weight: 500; }
.tabs > .active { background: var(--seg-sel); font-weight: 600; box-shadow: 0 3px 8px rgba(0,0,0,.12); }
.tabbar { position: fixed; left: 14px; right: 14px; bottom: calc(8px + env(safe-area-inset-bottom)); z-index: 30; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 2px; padding: 5px; border-radius: 999px; }
.tabbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; min-height: 54px; border-radius: 999px; color: var(--color-text); font-size: 10px; font-weight: 600; text-decoration: none; position: relative; }
.tabbar a.active { background: var(--fill); color: var(--color-accent-text); }
.sheet-backdrop { position: fixed; inset: 0; z-index: 60; display: flex; align-items: flex-end; justify-content: center; background: rgba(0,0,0,.45); }
.sheet { width: 100%; max-height: 90vh; overflow-y: auto; border-radius: 34px 34px 0 0; background: var(--color-surface); padding: 12px 20px calc(20px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 16px; }
.sheet .grabber { width: 36px; height: 5px; border-radius: 3px; background: var(--color-neutral-600); align-self: center; }
@media (min-width: 700px) { .sheet-backdrop { align-items: center; padding: 16px; } .sheet { width: 520px; border-radius: 26px; padding-bottom: 22px; } .sheet .grabber { display: none; } }
.toast { position: fixed; z-index: 70; left: 16px; bottom: calc(84px + env(safe-area-inset-bottom)); padding: 12px 16px; border-radius: 999px; font-size: 15px; display: flex; gap: 10px; align-items: center; }
