/* Schnappschuss – Variante „Garten“ (hell) */

/* Schriften liegen selbst gehostet in assets/fonts (kein Google-Server, DSGVO). Fehlen sie, greifen die Systemschriften. */
@font-face {
  font-family: 'Bricolage Grotesque';
  src: url('fonts/bricolage-grotesque-latin-wght-normal.woff2') format('woff2');
  font-weight: 200 800;
  font-display: swap;
}
@font-face {
  font-family: 'DM Sans';
  src: url('fonts/dm-sans-latin-wght-normal.woff2') format('woff2');
  font-weight: 100 1000;
  font-display: swap;
}
@font-face {
  font-family: 'DM Mono';
  src: url('fonts/dm-mono-latin-400-normal.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'DM Mono';
  src: url('fonts/dm-mono-latin-500-normal.woff2') format('woff2');
  font-weight: 500;
  font-display: swap;
}

:root {
  --ground: #F5F3EE;
  --surface: #FFFFFF;
  --line: #DCD8D0;
  --line-soft: #E4E0D8;
  --field-border: #8F887E;
  --text: #171615;
  --muted: #5E5952;
  --placeholder: #6E6862;
  --accent: #1E6B4F;
  --accent-strong: #134A36;
  --accent-tint: #E6F0EB;
  --on-accent: #FFFFFF;
  --error: #B42318;

  --font-display: 'Bricolage Grotesque', 'Avenir Next', 'Segoe UI', system-ui, sans-serif;
  --font-body: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: 'DM Mono', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--ground);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.5;
}

a { color: var(--accent); }
a:hover { color: var(--accent-strong); }

svg { display: block; flex: none; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* Gerüst */

.page {
  min-height: 100vh;
  min-height: 100dvh;
  max-width: 480px;
  margin: 0 auto;
  padding: 16px 24px calc(32px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
}

.topbar {
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -0.01em;
}
.brand svg { color: var(--accent); }

.topbar-event {
  min-width: 0;
  font-size: 14px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.page[data-view="start"] .topbar-event { display: none; }

main {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.screen {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding-top: 36px;
}

/* Typografie */

.eyebrow {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}
.eyebrow-error { color: var(--error); }

.title {
  margin: 10px 0 0;
  font-family: var(--font-display);
  font-size: 46px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.035em;
  overflow-wrap: break-word;
  hyphens: auto;
}
.title:focus { outline: none; }
.title-m { font-size: 40px; }

.meta {
  margin: 10px 0 0;
  font-size: 16px;
  color: var(--muted);
}

.lead {
  margin: 28px 0 0;
  font-size: 17px;
  line-height: 1.5;
}
.muted { color: var(--muted); }

.hint {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
}
.center { text-align: center; }

/* Start */

.facts {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
}
.facts li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 16px;
}
.facts li + li { border-top: 1px solid var(--line); }
.facts svg { margin-top: 1px; color: var(--accent); }
.facts strong { display: block; font-size: 16px; font-weight: 600; }
.facts span { display: block; margin-top: 2px; font-size: 14px; line-height: 1.4; color: var(--muted); }

.start-action {
  margin-top: auto;
  padding-top: 28px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.field label { font-size: 15px; font-weight: 600; }
.field label span { font-weight: 400; color: var(--muted); }
.field input {
  height: 52px;
  padding: 0 16px;
  border-radius: 12px;
  border: 1px solid var(--field-border);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 17px;
}
.field input::placeholder { color: var(--placeholder); opacity: 1; }
.field input:focus-visible { outline: 2px solid var(--text); outline-offset: 2px; }

.dropzone {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.dropzone-desktop,
.dropzone-formats { display: none; }

.form-error {
  margin: 0;
  font-size: 15px;
  color: var(--error);
  text-align: center;
}

/* Buttons */

.button {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 58px;
  padding: 0 24px;
  border: 0;
  border-radius: 14px;
  font: inherit;
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.button:focus-visible,
.button:has(input:focus-visible) {
  outline: 3px solid var(--text);
  outline-offset: 3px;
}
.button-primary { background: var(--accent); color: var(--on-accent); }
.button-primary:hover { background: var(--accent-strong); }
.button-secondary {
  height: 54px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--field-border);
  font-size: 17px;
  font-weight: 600;
}
.button-secondary:hover { border-color: var(--text); }

/* Hochladen */

.progress {
  margin-top: 20px;
  height: 10px;
  border-radius: 5px;
  background: var(--line-soft);
  overflow: hidden;
}
.progress-bar {
  width: 0;
  height: 100%;
  border-radius: 5px;
  background: var(--accent);
  transition: width 0.3s ease;
}

.notice {
  margin-top: 20px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  font-size: 15px;
  line-height: 1.45;
}
.notice svg { margin-top: 1px; color: var(--accent); }
.notice p { margin: 0; }
.notice-warn svg { color: var(--error); }

.files { margin-top: 28px; }
.files h2 {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 600;
  color: var(--muted);
}
.files ul { list-style: none; margin: 0; padding: 0; }

.files-more {
  margin: 0;
  padding: 10px 0;
  font-size: 14px;
  color: var(--muted);
}
.files-more-top { border-bottom: 1px solid var(--line-soft); }

.file {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line-soft);
}
.file-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.file-name {
  font-family: var(--font-mono);
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.file-size { font-size: 13px; color: var(--muted); }
.file-bar {
  height: 4px;
  border-radius: 2px;
  background: var(--line-soft);
  overflow: hidden;
}
.file-bar > div {
  width: 0;
  height: 100%;
  border-radius: 2px;
  background: var(--accent);
}
.file-status {
  flex: none;
  min-width: 116px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  font-size: 14px;
  color: var(--muted);
}
.file-status.is-done svg { color: var(--accent); }
.file-status.is-missing { color: var(--error); }
.file-status .pct {
  font-family: var(--font-mono);
  font-weight: 500;
  color: var(--text);
}

.screen-actions {
  margin-top: auto;
  padding-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Fertig und Fehler */

.done-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-bottom: 24px;
}
.done-body .eyebrow { margin-top: 26px; }
.done-body .title { margin-top: 18px; font-size: 40px; }
.done-body .lead { margin-top: 18px; }

.badge {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--on-accent);
  display: flex;
  align-items: center;
  justify-content: center;
}
.badge-error {
  width: 56px;
  height: 56px;
  margin-bottom: 18px;
  background: none;
  border: 2px solid var(--error);
  color: var(--error);
}

.footer {
  margin-top: 28px;
  display: flex;
  justify-content: center;
  gap: 20px;
  font-size: 13px;
}
.footer a { color: var(--muted); }

/* Laptop: zwei Spalten mit Ablagefläche */

@media (min-width: 960px) {
  .page {
    max-width: 1168px;
    padding: 24px 24px 56px;
  }

  .screen:not(.screen-start) {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
  }

  .screen-start {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr);
    gap: 56px;
    padding-top: 56px;
  }
  .screen-start .title {
    margin-top: 12px;
    font-size: 68px;
    line-height: 0.98;
    letter-spacing: -0.04em;
  }
  .screen-start .meta { margin-top: 14px; font-size: 18px; }
  .screen-start .lead { margin-top: 32px; font-size: 19px; line-height: 1.55; max-width: 30em; }

  .facts {
    margin-top: 32px;
    background: none;
    border: 0;
    border-radius: 0;
    display: flex;
    flex-direction: column;
    gap: 18px;
  }
  .facts li { padding: 0; }
  .facts li + li { border-top: 0; }
  .facts span { font-size: 15px; }

  .start-action {
    margin-top: 0;
    padding-top: 0;
    gap: 20px;
  }

  .dropzone {
    flex: 1;
    min-height: 420px;
    padding: 40px 24px;
    border: 2px dashed #B5AEA3;
    border-radius: 22px;
    background: var(--surface);
    align-items: center;
    justify-content: center;
    gap: 18px;
    text-align: center;
    transition: border-color 0.15s ease, background-color 0.15s ease;
  }
  body.dragging .dropzone {
    border-color: var(--accent);
    background: var(--accent-tint);
  }
  .dropzone-desktop {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
  }
  .dropzone-icon {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: var(--accent-tint);
    color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .dropzone-title {
    margin: 0;
    font-family: var(--font-display);
    font-size: 30px;
    font-weight: 700;
    letter-spacing: -0.02em;
  }
  .dropzone .button {
    height: 56px;
    padding: 0 28px;
    font-size: 17px;
  }
  .dropzone .mobile-only { display: none; }
  .dropzone-formats {
    display: block;
    margin: 6px 0 0;
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--muted);
  }
}
