/* Weilbacher Automobile – internes System. Mobile-first. */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 100 900; font-display: swap; src: url('/static/fonts/inter-latin-wght.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 100 900; font-display: swap; src: url('/static/fonts/inter-latin-ext-wght.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --brand: #702A31; --brand-2: #B75361; --brand-soft: #F6ECEE; --brand-ink: #4a1b20;
  --bg: #f4f4f6; --surface: #ffffff; --surface-2: #f8f8fa; --border: #e3e4e8; --border-strong: #c9cbd3;
  --text: #1c1c21; --text-2: #5b5e6a; --text-3: #8a8d99;
  --ok: #1f7a3f; --ok-soft: #e6f4ea; --warn: #9a6200; --warn-soft: #fff4de; --err: #b3261e; --err-soft: #fde9e7; --info: #1f4f8a; --info-soft: #e8f0fb;
  --radius: 12px; --radius-sm: 8px; --shadow: 0 1px 2px rgba(20,20,30,.06), 0 4px 14px rgba(20,20,30,.05);
  --topbar-h: 56px; --tabbar-h: 60px; --sidenav-w: 236px;
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 15px; line-height: 1.45; color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { margin: 0 0 .5rem; line-height: 1.2; font-weight: 650; letter-spacing: -.01em; }
h1 { font-size: 1.5rem; } h2 { font-size: 1.1rem; } h3 { font-size: 1rem; }
p { margin: 0 0 .75rem; }
.muted { color: var(--text-2); } .small { font-size: .86rem; } .mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .92em; }
.inline { display: inline; } .nowrap { white-space: nowrap; } .right { text-align: right; } .center { text-align: center; }
.mt { margin-top: 1rem; } .mb { margin-bottom: 1rem; } .mb-0 { margin-bottom: 0; }
.hide { display: none !important; }
.link { font-weight: 500; }

/* App shell */
.app { min-height: 100vh; min-height: 100dvh; }
.topbar { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: .5rem; height: var(--topbar-h); padding: 0 .75rem; padding-left: max(.75rem, env(safe-area-inset-left)); padding-right: max(.75rem, env(safe-area-inset-right)); background: var(--surface); border-bottom: 1px solid var(--border); }
.brand { display: flex; align-items: center; height: 100%; }
.brand-logo { height: 30px; width: auto; display: block; }
.topbar-spacer { flex: 1; }
.topbar-search { display: none; flex: 1; max-width: 460px; }
.topbar-search input { width: 100%; }
.user-menu { display: none; align-items: center; gap: .5rem; }
.user-name { font-size: .9rem; color: var(--text-2); }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border: 0; background: transparent; border-radius: 10px; color: var(--text); cursor: pointer; }
.icon-btn:hover { background: var(--surface-2); }
.nav-toggle { margin-left: -.35rem; }

.sidenav { position: fixed; top: 0; left: 0; bottom: 0; z-index: 40; width: min(84vw, 300px); background: var(--surface); border-right: 1px solid var(--border); transform: translateX(-102%); transition: transform .22s ease; display: flex; flex-direction: column; padding-top: var(--topbar-h); }
.sidenav.open { transform: none; box-shadow: 0 0 40px rgba(0,0,0,.25); }
.nav-backdrop { position: fixed; inset: 0; z-index: 35; background: rgba(20,20,30,.4); opacity: 0; pointer-events: none; transition: opacity .2s; }
.nav-backdrop.open { opacity: 1; pointer-events: auto; }
.sidenav ul { list-style: none; margin: 0; padding: .75rem .6rem; flex: 1; overflow-y: auto; }
.sidenav li a { display: flex; align-items: center; gap: .7rem; padding: .7rem .8rem; border-radius: 10px; color: var(--text); font-weight: 500; }
.sidenav li a:hover { background: var(--surface-2); text-decoration: none; }
.sidenav li a.active { background: var(--brand-soft); color: var(--brand); }
.sidenav li a svg { flex: none; opacity: .85; }
.sidenav-foot { padding: .75rem .9rem; padding-bottom: max(.9rem, env(safe-area-inset-bottom)); border-top: 1px solid var(--border); }

.content { padding: 1rem; padding-bottom: calc(var(--tabbar-h) + 1.25rem + env(safe-area-inset-bottom)); max-width: 1200px; margin: 0 auto; }

.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; justify-content: space-around; align-items: stretch; height: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: var(--surface); border-top: 1px solid var(--border); }
.tabbar a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: .68rem; color: var(--text-2); font-weight: 500; }
.tabbar a:hover { text-decoration: none; }
.tabbar a.active { color: var(--brand); }
.tab-add-circle { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 50%; background: var(--brand); color: #fff; font-size: 1.6rem; line-height: 1; box-shadow: 0 4px 12px rgba(112,42,49,.35); margin-top: -14px; }

@media (min-width: 1024px) {
  .nav-toggle, .tabbar, [data-search-toggle] { display: none; }
  .topbar-search, .user-menu { display: flex; }
  .sidenav { transform: none; width: var(--sidenav-w); box-shadow: none; }
  .nav-backdrop { display: none; }
  .content { margin-left: var(--sidenav-w); padding: 1.5rem 2rem 3rem; max-width: calc(var(--sidenav-w) + 1240px); }
  .brand-logo { height: 34px; }
}
@media (max-width: 1023px) {
  body.search-open .topbar-search { display: flex; position: absolute; left: .75rem; right: .75rem; top: calc(var(--topbar-h) + 6px); max-width: none; z-index: 31; }
}

/* Page */
.page-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: .75rem 1rem; margin-bottom: 1rem; }
.page-head h1 { margin-bottom: .15rem; }
.page-actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.breadcrumb { font-size: .86rem; color: var(--text-2); margin-bottom: .35rem; }
.breadcrumb a { color: var(--text-2); }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem; margin-bottom: 1rem; box-shadow: var(--shadow); }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: .75rem; margin-bottom: .75rem; }
.card-head h2 { margin: 0; }
.grid-2 { display: grid; grid-template-columns: 1fr; gap: 1rem; }
.grid-3 { display: grid; grid-template-columns: 1fr; gap: 1rem; }
@media (min-width: 800px) { .grid-2 { grid-template-columns: 1fr 1fr; } .grid-3 { grid-template-columns: repeat(3, 1fr); } }
.empty { padding: 1.25rem; text-align: center; color: var(--text-2); background: var(--surface-2); border-radius: var(--radius-sm); }

/* Stats */
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; margin-bottom: 1rem; }
@media (min-width: 800px) { .stat-grid { grid-template-columns: repeat(4, 1fr); gap: 1rem; } }
.stat { display: flex; flex-direction: column; gap: .15rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: .9rem 1rem; color: inherit; box-shadow: var(--shadow); }
.stat:hover { text-decoration: none; border-color: var(--border-strong); }
.stat-label { font-size: .78rem; color: var(--text-2); font-weight: 500; text-transform: uppercase; letter-spacing: .04em; }
.stat-value { font-size: 1.75rem; font-weight: 700; letter-spacing: -.02em; }
.stat-value-sm { font-size: 1.2rem; }
.stat-sub { font-size: .8rem; color: var(--text-3); }

/* Lists */
.list { list-style: none; margin: 0; padding: 0; }
.list li + li { border-top: 1px solid var(--border); }
.list-row { display: flex; align-items: center; gap: .75rem; padding: .6rem .25rem; color: inherit; }
.list-row:hover { text-decoration: none; background: var(--surface-2); }
.list-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.list-main strong { font-weight: 600; }
.list-main .muted { font-size: .84rem; }
.list-main span, .list-main strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.thumb { flex: none; width: 56px; height: 42px; border-radius: 6px; overflow: hidden; background: var(--surface-2); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb-placeholder { display: block; width: 100%; height: 100%; background: repeating-linear-gradient(45deg, #eee, #eee 6px, #f6f6f6 6px, #f6f6f6 12px); }
.amount { font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { display: grid; grid-template-columns: 1fr; gap: .1rem .75rem; padding: .5rem 0; border-top: 1px solid var(--border); font-size: .92rem; }
.timeline li:first-child { border-top: 0; }
.timeline .time { color: var(--text-3); font-size: .8rem; white-space: nowrap; }
@media (min-width: 640px) { .timeline li { grid-template-columns: 130px 1fr; } }

/* Badges */
.badge { display: inline-flex; align-items: center; padding: .15rem .55rem; border-radius: 999px; font-size: .75rem; font-weight: 600; white-space: nowrap; background: var(--surface-2); color: var(--text-2); border: 1px solid var(--border); }
.badge-eingang { background: var(--info-soft); color: var(--info); border-color: transparent; }
.badge-bestand { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.badge-reserviert { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.badge-verkauft { background: #ececf1; color: #444; border-color: transparent; }
.badge-ok, .badge-final, .badge-freigegeben, .badge-veroeffentlicht { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.badge-warn, .badge-entwurf, .badge-offen, .badge-aufgenommen, .badge-neu { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.badge-err, .badge-storniert { background: var(--err-soft); color: var(--err); border-color: transparent; }
.badge-info, .badge-bearbeitet { background: var(--info-soft); color: var(--info); border-color: transparent; }
.badge-brand { background: var(--brand-soft); color: var(--brand); border-color: transparent; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; min-height: 40px; padding: .5rem .95rem; border-radius: 10px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); font: inherit; font-weight: 550; cursor: pointer; white-space: nowrap; transition: background .12s, border-color .12s; text-decoration: none; }
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn:disabled { opacity: .55; cursor: default; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-ink); border-color: var(--brand-ink); }
.btn-secondary { background: var(--brand-soft); border-color: transparent; color: var(--brand); }
.btn-secondary:hover { background: #eddde0; }
.btn-ghost { border-color: transparent; background: transparent; }
.btn-danger { color: var(--err); border-color: #f0c7c3; }
.btn-danger:hover { background: var(--err-soft); }
.btn-sm { min-height: 32px; padding: .25rem .65rem; font-size: .86rem; border-radius: 8px; }
.btn-lg { min-height: 48px; font-size: 1.02rem; }
.btn-block { width: 100%; }
.btn-group { display: flex; flex-wrap: wrap; gap: .5rem; }

/* Forms */
.form { display: flex; flex-direction: column; gap: .85rem; }
.form-grid { display: grid; grid-template-columns: 1fr; gap: .85rem 1rem; }
@media (min-width: 640px) { .form-grid { grid-template-columns: 1fr 1fr; } .form-grid .span-2 { grid-column: span 2; } }
@media (min-width: 1024px) { .form-grid.cols-3 { grid-template-columns: repeat(3, 1fr); } .form-grid.cols-3 .span-2 { grid-column: span 2; } .form-grid.cols-3 .span-3 { grid-column: span 3; } }
.field { display: flex; flex-direction: column; gap: .3rem; }
.field > span, .field-label { font-size: .84rem; font-weight: 550; color: var(--text-2); }
.field .hint { font-size: .78rem; color: var(--text-3); }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=search], input[type=date], input[type=tel], input[type=url], select, textarea {
  width: 100%; min-height: 44px; padding: .55rem .75rem; border: 1px solid var(--border-strong); border-radius: 10px; background: var(--surface); color: var(--text); font: inherit; font-size: 16px; }
@media (min-width: 640px) { input[type=text], input[type=email], input[type=password], input[type=number], input[type=search], input[type=date], input[type=tel], input[type=url], select, textarea { font-size: 15px; min-height: 40px; } }
textarea { min-height: 90px; resize: vertical; line-height: 1.4; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--brand-2); outline-offset: 1px; border-color: var(--brand-2); }
input[readonly] { background: var(--surface-2); color: var(--text-2); }
.check { display: flex; align-items: center; gap: .55rem; min-height: 40px; font-weight: 500; }
.check input { width: 20px; height: 20px; accent-color: var(--brand); }
.input-group { display: flex; align-items: stretch; }
.input-group input { border-radius: 10px 0 0 10px; }
.input-group .addon { display: flex; align-items: center; padding: 0 .7rem; border: 1px solid var(--border-strong); border-left: 0; border-radius: 0 10px 10px 0; background: var(--surface-2); color: var(--text-2); white-space: nowrap; }
.form-actions { display: flex; flex-wrap: wrap; gap: .5rem; justify-content: flex-end; padding-top: .5rem; border-top: 1px solid var(--border); margin-top: .25rem; }
.form-actions.sticky { position: sticky; bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); background: var(--surface); padding: .75rem 0; z-index: 5; }
@media (min-width: 1024px) { .form-actions.sticky { bottom: 0; } }
fieldset { border: 0; padding: 0; margin: 0 0 1rem; min-width: 0; }
legend, .section-title { font-size: .8rem; font-weight: 650; text-transform: uppercase; letter-spacing: .06em; color: var(--brand); margin-bottom: .65rem; padding: 0; }
.filters { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin-bottom: 1rem; }
.filters input[type=search] { flex: 1 1 220px; }
.filters select { width: auto; min-width: 140px; }
.chips { display: flex; gap: .4rem; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; min-height: 34px; padding: .3rem .8rem; border-radius: 999px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text-2); font-size: .86rem; font-weight: 500; }
.chip:hover { text-decoration: none; background: var(--surface-2); }
.chip.active { background: var(--brand); border-color: var(--brand); color: #fff; }

/* Flash */
.flash-stack { margin-bottom: 1rem; }
.flash { display: flex; align-items: flex-start; gap: .5rem; padding: .7rem .9rem; border-radius: var(--radius-sm); margin-bottom: .5rem; font-size: .93rem; border: 1px solid transparent; }
.flash-success { background: var(--ok-soft); color: var(--ok); }
.flash-error { background: var(--err-soft); color: var(--err); }
.flash-info { background: var(--info-soft); color: var(--info); }
.flash-warning { background: var(--warn-soft); color: var(--warn); }
.flash-close { margin-left: auto; border: 0; background: transparent; color: inherit; font-size: 1.2rem; line-height: 1; cursor: pointer; padding: 0 .2rem; }

/* Tables */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 -1rem; padding: 0 1rem; }
table.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th, .table td { padding: .6rem .6rem; text-align: left; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table th { font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--text-2); font-weight: 600; white-space: nowrap; }
.table tr:hover td { background: var(--surface-2); }
.table td.num, .table th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table a.row-link { color: inherit; font-weight: 600; }
.table .actions { white-space: nowrap; text-align: right; }

/* Key/value definition lists */
.kv { display: grid; grid-template-columns: minmax(120px, 40%) 1fr; gap: .35rem .75rem; margin: 0; font-size: .93rem; }
.kv dt { color: var(--text-2); }
.kv dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }

/* Tabs */
.tabs { display: flex; gap: .25rem; overflow-x: auto; border-bottom: 1px solid var(--border); margin-bottom: 1rem; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { flex: none; padding: .6rem .85rem; border-bottom: 2px solid transparent; color: var(--text-2); font-weight: 550; white-space: nowrap; }
.tabs a:hover { text-decoration: none; color: var(--text); }
.tabs a.active { color: var(--brand); border-bottom-color: var(--brand); }
.tabs .count { display: inline-block; margin-left: .3rem; padding: 0 .4rem; border-radius: 999px; background: var(--surface-2); font-size: .75rem; color: var(--text-2); }

/* Vehicle cards */
.vehicle-grid { display: grid; grid-template-columns: 1fr; gap: .75rem; }
@media (min-width: 560px) { .vehicle-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .vehicle-grid { grid-template-columns: repeat(3, 1fr); } }
.vcard { display: flex; gap: .85rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: .75rem; color: inherit; box-shadow: var(--shadow); }
.vcard:hover { text-decoration: none; border-color: var(--border-strong); }
.vcard .thumb { width: 104px; height: 78px; border-radius: 8px; }
.vcard-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .15rem; }
.vcard-title { font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vcard-meta { font-size: .82rem; color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vcard-foot { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-top: auto; }

/* Photo grid */
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: .5rem; }
.photo { position: relative; aspect-ratio: 4/3; border-radius: 8px; overflow: hidden; background: var(--surface-2); border: 1px solid var(--border); }
.photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo .photo-badge { position: absolute; left: 6px; top: 6px; }
.photo .photo-cover { position: absolute; right: 6px; top: 6px; background: var(--brand); color: #fff; font-size: .68rem; padding: .1rem .4rem; border-radius: 999px; font-weight: 600; }
.photo .photo-actions { position: absolute; left: 0; right: 0; bottom: 0; display: flex; gap: .25rem; padding: .3rem; background: linear-gradient(transparent, rgba(0,0,0,.55)); opacity: 0; transition: opacity .15s; }
.photo:hover .photo-actions, .photo:focus-within .photo-actions { opacity: 1; }
@media (hover: none) { .photo .photo-actions { opacity: 1; } }
.photo-actions .btn { min-height: 28px; padding: .1rem .45rem; font-size: .75rem; }
.dropzone { border: 2px dashed var(--border-strong); border-radius: var(--radius); padding: 1.25rem; text-align: center; color: var(--text-2); background: var(--surface-2); }
.dropzone.drag { border-color: var(--brand); background: var(--brand-soft); }
.dropzone input[type=file] { display: none; }

/* Auth */
.auth-body { background: linear-gradient(160deg, #f7f3f4, #ececf0); }
.auth-wrap { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 1.25rem; }
.auth-card { width: 100%; max-width: 400px; background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 1.75rem 1.5rem; box-shadow: var(--shadow); }
.auth-logo { display: block; width: 220px; max-width: 100%; margin: 0 auto 1.25rem; }
.auth-card h1 { text-align: center; font-size: 1.25rem; margin-bottom: 1rem; }
.auth-foot { margin-top: 1rem; font-size: .8rem; color: var(--text-3); text-align: center; }

/* Misc */
.progress { height: 6px; border-radius: 3px; background: var(--border); overflow: hidden; }
.progress > span { display: block; height: 100%; background: var(--brand); }
.status-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--text-3); margin-right: .35rem; vertical-align: middle; }
.status-dot.ok { background: var(--ok); } .status-dot.err { background: var(--err); } .status-dot.warn { background: var(--warn); }
.pdf-frame { width: 100%; height: 75vh; border: 1px solid var(--border); border-radius: var(--radius-sm); background: #fff; }
details.panel { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .5rem .75rem; margin-bottom: .75rem; background: var(--surface); }
details.panel summary { cursor: pointer; font-weight: 600; }
.pagination { display: flex; gap: .35rem; flex-wrap: wrap; justify-content: center; margin-top: 1rem; }
.pagination a, .pagination span { min-width: 36px; padding: .35rem .6rem; border-radius: 8px; border: 1px solid var(--border); background: var(--surface); text-align: center; }
.pagination .current { background: var(--brand); color: #fff; border-color: var(--brand); }
kbd { font-family: inherit; font-size: .8em; padding: .05rem .35rem; border: 1px solid var(--border-strong); border-bottom-width: 2px; border-radius: 5px; background: var(--surface-2); }
@media print { .topbar, .sidenav, .tabbar, .page-actions, .form-actions, .nav-backdrop { display: none !important; } .content { margin: 0; padding: 0; } .card { box-shadow: none; } }

/* --- Module: Fahrzeuge / Kunden / Dateien --- */
.vcard-badges { display: flex; flex-wrap: wrap; gap: .25rem; justify-content: flex-end; }
.photo-grid-lg { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: .75rem; }
.photo-item { display: flex; flex-direction: column; gap: .35rem; scroll-margin-top: calc(var(--topbar-h) + 10px); }
.photo-item select { min-height: 36px; font-size: 14px; }
.photo-tools { display: flex; flex-wrap: wrap; gap: .3rem; }
.photo-tools form { display: inline; margin: 0; }
.fileicon { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--border); font-size: .66rem; font-weight: 700; color: var(--text-2); letter-spacing: .03em; }
.fileicon-pdf { background: var(--err-soft); color: var(--err); border-color: transparent; }
.fileicon-doc, .fileicon-docx { background: var(--info-soft); color: var(--info); border-color: transparent; }
.fileicon-xls, .fileicon-xlsx { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.fileicon-jpg, .fileicon-png, .fileicon-webp { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.note-row { display: flex; align-items: flex-start; justify-content: space-between; gap: .75rem; padding: .75rem 0; }
.note-main { flex: 1; min-width: 0; }
.list-row .list-main a { color: inherit; }
.customer-form:has(select[data-customer-type] option[value="privat"]:checked) .company-only { display: none; }
.customer-form:has(select[data-customer-type] option[value="gewerblich"]:checked) .company-only { display: flex; }
.customer-form:has(select[data-customer-type] option[value="gewerblich"]:checked) .private-only { display: none; }
[data-customer-picker] { gap: .4rem; }

/* --- mobile.de + Einstellungen (mobile/settings module) --- */
.checklist { margin: .25rem 0 .75rem; padding-left: 1.2rem; }
.checklist li { margin: .2rem 0; }
.mobile-caps { display: grid; grid-template-columns: 1fr; gap: 1rem; }
@media (min-width: 800px) { .mobile-caps { grid-template-columns: 1fr 1fr; } }
.mobile-cap h3 { display: flex; align-items: center; }
.mobile-ad { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .75rem; padding: .6rem .25rem; }
.mobile-ad .thumb { width: 72px; height: 54px; }
.mobile-ad .list-main { min-width: 180px; }
.mobile-ad-actions { display: flex; flex-wrap: wrap; gap: .4rem; align-items: flex-start; }
@media (max-width: 559px) { .mobile-ad-actions { width: 100%; } }
.mobile-assign summary { list-style: none; }
.mobile-assign summary::-webkit-details-marker { display: none; }
.mobile-assign-form { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .4rem; }
.mobile-assign-form select { width: auto; max-width: 100%; min-width: 200px; flex: 1; }
.seq-form { display: flex; gap: .4rem; align-items: center; }
.seq-form input[type=number] { width: 7.5rem; min-height: 36px; }
.seq-table td { white-space: nowrap; }
.user-item > summary { list-style: none; cursor: pointer; }
.user-item > summary::-webkit-details-marker { display: none; }
.user-item[open] > summary { background: var(--surface-2); }
.user-form { padding: .75rem .25rem 1rem; }
.settings-narrow { max-width: 560px; }
ul.errors { margin: .25rem 0 0; padding-left: 1.1rem; }

/* Documents: "new vehicle" option on the vehicle picker */
.pick-new { display: flex; align-items: center; gap: .9rem; color: inherit; border: 2px dashed var(--brand-2); background: var(--brand-soft); }
.pick-new:hover { text-decoration: none; border-style: solid; }
.pick-new > span:last-child { display: flex; flex-direction: column; gap: .15rem; }
.pick-new-icon { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 50%; background: var(--brand); color: #fff; font-size: 1.6rem; line-height: 1; }

/* One-click mobile.de upload button: allow wrapping on narrow screens */
.mobile-upload .btn { white-space: normal; text-align: center; line-height: 1.25; }

/* Dateien tab: grouped documents with inline edit */
.doc-group { margin-top: .5rem; }
.doc-group .count { display: inline-block; margin-left: .3rem; padding: 0 .45rem; border-radius: 999px; background: var(--surface-2); color: var(--text-2); font-size: .72rem; letter-spacing: 0; }
.doc-row + .doc-row { border-top: 1px solid var(--border); }
.doc-row .list-main .badge { margin-top: .2rem; }
.doc-edit { padding: 0 .25rem .6rem 3.4rem; }
.doc-edit summary { cursor: pointer; font-size: .85rem; color: var(--text-2); }
.doc-edit[open] summary { margin-bottom: .5rem; }
@media (max-width: 640px) { .doc-edit { padding-left: .25rem; } }
.doc-row .list-main strong, .doc-row .list-main > span { white-space: normal; overflow: visible; }
.doc-row .list-row { align-items: flex-start; }
.doc-row .list-row .btn { margin-top: .1rem; }
