/* share.niklas-bambor.de – Komponenten. Nutzt ausschließlich Tokens aus global.css. */

/* ---------- Header / Footer (aus DESIGN.md Anhang B, reduziert: ein Menüpunkt, kein Drawer) ---------- */
.topbar { position: sticky; top: 0; z-index: 50; height: var(--header-h); backdrop-filter: blur(12px); background: rgba(11,14,20,.82); border-bottom: 1px solid var(--line); }
.nav { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { font-size: .92rem; color: var(--text-bright); display: inline-flex; align-items: baseline; gap: 1px; }
.brand:hover { text-decoration: none; }
.brand__prompt { color: var(--green); }
.brand__sep, .brand__dollar { color: var(--muted); }
.brand__path { color: var(--cyan); }
.brand__cursor { width: 8px; height: 1.05em; margin-left: 5px; background: var(--amber); align-self: center; animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.menu { display: flex; align-items: center; gap: 26px; }
.lang { background: none; border: 0; padding: 0; cursor: pointer; font: inherit; color: var(--amber); font-size: .85rem; }
.lang__bracket { color: var(--muted); }
.lang:hover .lang__bracket { color: var(--amber); }

.footer { border-top: 1px solid var(--line); padding: 28px 0; margin-top: 40px; }
.footer__inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; font-size: .82rem; }
.footer__copy { color: var(--muted); }
.footer__links { display: flex; gap: 22px; }
.footer__links a { color: var(--muted); }
.footer__links a:hover { color: var(--amber); text-decoration: none; }

@media (prefers-reduced-motion: reduce) { .brand__cursor { animation: none; } }

/* ---------- Seite ---------- */
main.section { padding-top: 64px; min-height: calc(100vh - var(--header-h) - 120px); }
.wrap { max-width: 760px; margin-inline: auto; padding-inline: 24px; position: relative; z-index: 1; }
.lead { color: var(--muted); font-size: 1.1rem; max-width: 52ch; margin-bottom: 30px; }
.stack > * + * { margin-top: 18px; }
.section-head { margin-bottom: 26px; }
.section-head h1 { margin-bottom: 0; }

/* ---------- Tabs (Mono-Buttons, aktiv = Amber) ---------- */
.tabs { display: flex; gap: 10px; margin-bottom: 18px; }
.tab { background: none; font: inherit; font-family: var(--font-mono); font-size: .9rem; color: var(--text); border: 1px solid var(--line-bright); border-radius: 8px; padding: 9px 18px; cursor: pointer; transition: border-color .2s, color .2s; }
.tab:hover { border-color: var(--amber); color: var(--amber); }
.tab[aria-selected="true"] { border-color: var(--amber); color: var(--amber); background: var(--amber-dim); }

/* ---------- Felder ---------- */
.label { display: block; font-family: var(--font-mono); font-size: .72rem; color: var(--muted); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 8px; }
.input { width: 100%; font-family: var(--font-mono); font-size: 16px; line-height: 1.6; color: var(--text-bright); background: #0d1117; border: 1px solid var(--line-bright); border-radius: 8px; padding: 12px 14px; transition: border-color .2s; }
.input:focus { outline: none; border-color: rgba(255,180,84,.55); }
.input:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }
textarea.input { min-height: 200px; resize: vertical; }
.input::placeholder { color: var(--muted); }

.drop { cursor: pointer; text-align: center; padding: 34px 24px; }
.drop:hover { transform: none; }
.drop input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; }
.drop:focus-within { border-color: var(--amber); }
.drop__name { color: var(--text-bright); font-family: var(--font-mono); font-size: .95rem; word-break: break-all; }
.drop .meta { margin-top: 6px; display: block; }

.card--static:hover { transform: none; box-shadow: none; border-color: var(--line); }
.card--static:hover::before { opacity: 0; animation: none; }

.opts { display: grid; gap: 22px; }
.seg { display: flex; flex-wrap: wrap; gap: 8px; }
.seg input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.seg label { font-family: var(--font-mono); font-size: .85rem; color: var(--text); border: 1px solid var(--line-bright); border-radius: 8px; padding: 7px 14px; cursor: pointer; transition: border-color .2s, color .2s; }
.seg label:hover { border-color: var(--amber); color: var(--amber); }
.seg input:checked + label { border-color: var(--amber); color: var(--amber); background: var(--amber-dim); }
.seg input:focus-visible + label { outline: 2px solid var(--amber); outline-offset: 3px; }

.check { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; }
.check input { width: 18px; height: 18px; margin: 3px 0 0; accent-color: var(--amber); flex-shrink: 0; }
.check span { color: var(--text-bright); }
.check small { display: block; color: var(--muted); font-size: .85rem; }

.actions { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.btn[disabled] { opacity: .5; cursor: not-allowed; transform: none; box-shadow: none; }

/* ---------- Status / Fortschritt ---------- */
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px rgba(127,217,98,.7); animation: pulse 2.6s ease-in-out infinite; display: inline-block; }
.bar { height: 6px; background: var(--line); border-radius: 999px; overflow: hidden; }
.bar__fill { height: 100%; width: 0; background: var(--amber); transition: width .2s linear; }

.msg { font-family: var(--font-mono); font-size: .85rem; margin: 0; }
.msg--err { color: var(--red); }
.msg--ok { color: var(--green); }

/* ---------- Terminal-Fenster (aus Anhang C, reduziert; Höhe flexibel statt fix) ---------- */
.nbt { position: relative; display: flex; flex-direction: column; width: 100%; min-width: 0; background: #0d1117; border: 1px solid var(--line-bright); border-radius: 12px; box-shadow: 0 18px 50px rgba(0,0,0,.5); font-family: var(--font-mono); font-size: .82rem; line-height: 1.7; color: var(--text); overflow: hidden; }
.nbt__bar { display: flex; align-items: center; gap: 7px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.nbt__dot { width: 11px; height: 11px; border-radius: 50%; }
.nbt__dot--r { background: #f26d78; } .nbt__dot--y { background: var(--amber); } .nbt__dot--g { background: var(--green); }
.nbt__title { margin-left: 10px; font-size: .72rem; color: var(--muted); flex: 1; }
.nbt__screen { padding: 14px 18px; min-height: 140px; }
.nbt__row { white-space: pre-wrap; word-break: break-word; }
.nbt__row--out { color: var(--muted); } .nbt__row--cmd { color: var(--text-bright); }
.nbt__row--ok { color: var(--green); } .nbt__row--err { color: var(--red); }
.nbt-g { color: var(--green); } .nbt-m { color: var(--muted); } .nbt-c { color: var(--cyan); }

.secret { white-space: pre-wrap; word-break: break-word; color: var(--text-bright); font-family: var(--font-mono); font-size: .9rem; line-height: 1.6; max-height: 60vh; overflow: auto; margin: 0; }

.linkbox { display: flex; gap: 10px; }
.linkbox .input { flex: 1; min-width: 0; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; font-family: var(--font-mono); font-size: .8rem; margin: 0; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; color: var(--text-bright); }
.kv .g { color: var(--green); }

@media (max-width: 560px) { .linkbox { flex-direction: column; } main.section { padding-top: 40px; } }
