@font-face { font-family: 'Inter'; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url('/fonts/inter-latin-wght-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, 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('/fonts/inter-latin-ext-wght-normal.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 {
  --bg: #f3f5f9; --bg-grad: radial-gradient(1200px 600px at 80% -10%, #dfe9ff 0%, transparent 60%), radial-gradient(900px 500px at -10% 10%, #ffe9d6 0%, transparent 55%);
  --surface: #ffffff; --surface-2: #f6f8fc; --glass: rgba(255,255,255,.72);
  --text: #0f1a2b; --muted: #5b6b82; --line: rgba(15,26,43,.10);
  --accent: #ff7a1a; --accent-2: #ffb15c; --accent-ink: #ffffff;
  --ok: #12a37f; --warn: #e8a100; --bad: #e5484d; --info: #3b82f6;
  --shadow: 0 1px 2px rgba(15,26,43,.05), 0 8px 30px rgba(15,26,43,.08);
  --radius: 18px; --radius-sm: 12px; --nav-h: 68px;
}
:root[data-theme="dark"] {
  --bg: #080d17; --bg-grad: radial-gradient(1100px 600px at 85% -15%, #16294d 0%, transparent 60%), radial-gradient(800px 500px at -10% 5%, #2b1a0c 0%, transparent 55%);
  --surface: #101827; --surface-2: #0c1320; --glass: rgba(16,24,39,.72);
  --text: #e8eef9; --muted: #8fa0ba; --line: rgba(232,238,249,.09);
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 12px 40px rgba(0,0,0,.35);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #080d17; --bg-grad: radial-gradient(1100px 600px at 85% -15%, #16294d 0%, transparent 60%), radial-gradient(800px 500px at -10% 5%, #2b1a0c 0%, transparent 55%);
    --surface: #101827; --surface-2: #0c1320; --glass: rgba(16,24,39,.72);
    --text: #e8eef9; --muted: #8fa0ba; --line: rgba(232,238,249,.09);
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 12px 40px rgba(0,0,0,.35);
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; font: 15px/1.5 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color: var(--text); background: var(--bg) var(--bg-grad) fixed; -webkit-font-smoothing: antialiased; font-feature-settings: 'cv11', 'ss01'; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
h1, h2, h3 { margin: 0; letter-spacing: -.02em; line-height: 1.15; }
h1 { font-size: clamp(26px, 4vw, 38px); font-weight: 750; }
h2 { font-size: 18px; font-weight: 650; }
h3 { font-size: 15px; font-weight: 650; }
.muted { color: var(--muted); }
.num { font-variant-numeric: tabular-nums; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 8px; }

/* ---------- elrendezés ---------- */
.topbar { position: sticky; top: 0; z-index: 30; height: var(--nav-h); display: flex; align-items: center; gap: 18px;
  padding: 0 clamp(16px, 4vw, 40px); background: var(--glass); backdrop-filter: saturate(160%) blur(18px); -webkit-backdrop-filter: saturate(160%) blur(18px);
  border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand img { height: 36px; width: auto; display: block; background: #0d1a33; padding: 6px 12px; border-radius: 10px; box-sizing: border-box; }
.brand .sub { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); border-left: 1px solid var(--line); padding-left: 12px; white-space: nowrap; }
.nav { display: flex; gap: 4px; margin-left: 12px; }
.nav a { padding: 8px 14px; border-radius: 999px; color: var(--muted); font-weight: 550; transition: color .2s, background .2s; }
.nav a:hover { color: var(--text); background: var(--surface-2); }
.nav a.active { color: var(--text); background: var(--surface); box-shadow: var(--shadow); }
.spacer { flex: 1; }
.tabbar { display: none; }
.tools { display: flex; align-items: center; gap: 8px; }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.seg button { border: 0; background: none; padding: 5px 10px; border-radius: 999px; font-size: 12px; font-weight: 650; color: var(--muted); letter-spacing: .04em; }
.seg button.on { background: var(--accent); color: var(--accent-ink); }
.icon-btn { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); display: grid; place-items: center; transition: transform .2s; }
.icon-btn:hover { transform: translateY(-1px); }
.badge-demo { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--warn); border: 1px solid currentColor; border-radius: 999px; padding: 3px 9px; }
main { max-width: 1240px; margin: 0 auto; padding: 32px clamp(16px, 4vw, 40px) 80px; }
footer { text-align: center; color: var(--muted); font-size: 12px; padding: 0 16px 36px; }

/* ---------- kártyák ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px; }
.card.flat { box-shadow: none; }
.card h2 + .muted { margin-top: 4px; font-size: 13px; }
.grid { display: grid; gap: 18px; }
.g-kpi { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.g-2 { grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); }
.g-fleet { grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 26px; }
.page-head p { margin: 8px 0 0; color: var(--muted); }

.kpi { position: relative; overflow: hidden; }
.kpi .label { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.kpi .value { font-size: 34px; font-weight: 750; letter-spacing: -.03em; margin-top: 8px; font-variant-numeric: tabular-nums; }
.kpi .value small { font-size: 14px; font-weight: 600; color: var(--muted); margin-left: 4px; letter-spacing: 0; }
.kpi::after { content: ''; position: absolute; right: -30px; top: -30px; width: 110px; height: 110px; border-radius: 50%; background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 22%, transparent), transparent); }

/* ---------- pillék, állapotok ---------- */
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 650; padding: 4px 10px; border-radius: 999px;
  background: color-mix(in srgb, var(--c, var(--muted)) 14%, transparent); color: var(--c, var(--muted)); white-space: nowrap; }
.pill::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.st-OK, .st-ACTIVE, .st-SERVICEABLE, .st-RECTIFIED, .st-CLOSED, .st-COMPLETED, .st-IN_WARRANTY { --c: var(--ok); }
.st-DUE_SOON, .st-IN_MAINTENANCE, .st-MONITORED, .st-SERVICEABLE_WITH_LIMITATIONS, .st-MAJOR, .st-HIGH, .st-EXTENDED, .st-UNDER_INVESTIGATION { --c: var(--warn); }
.st-OVERDUE, .st-GROUNDED, .st-CRITICAL, .st-NOT_SERVICEABLE, .st-FAILED, .st-GROUND_AIRCRAFT, .st-OPEN { --c: var(--bad); }
.st-NO_RECORD, .st-NO_BASIS, .st-STORED, .st-MINOR, .st-LOW, .st-NORMAL, .st-NOT_REQUIRED, .st-OUT_OF_WARRANTY, .st-REQUIRED { --c: var(--muted); }
.st-FURTHER_ACTION_REQUIRED { --c: var(--warn); }

/* ---------- flottakártya ---------- */
.ac-card { display: grid; grid-template-columns: 1fr auto; gap: 18px; padding: 24px; position: relative; overflow: hidden; transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .35s; cursor: pointer; }
.ac-card:hover { transform: translateY(-4px); box-shadow: 0 2px 4px rgba(0,0,0,.06), 0 20px 50px rgba(15,26,43,.16); }
.ac-card .reg { font-size: 28px; font-weight: 800; letter-spacing: -.03em; }
.ac-card .meta { color: var(--muted); font-size: 13px; margin-top: 4px; }
.ac-card .row { display: flex; gap: 22px; margin-top: 20px; flex-wrap: wrap; }
.ac-card .stat b { display: block; font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; }
.ac-card .stat span { font-size: 12px; color: var(--muted); }
.ac-card .go { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); padding-top: 14px; color: var(--muted); font-size: 13px; }
.ac-card .go svg { transition: transform .25s; }
.ac-card:hover .go svg { transform: translateX(5px); }
.ring { position: relative; width: 128px; height: 128px; align-self: center; }
.ring svg { transform: rotate(-90deg); width: 100%; height: 100%; }
.ring .track { stroke: var(--surface-2); }
.ring .bar { stroke: var(--c, var(--ok)); stroke-linecap: round; transition: stroke-dashoffset 1.2s cubic-bezier(.2,.8,.2,1); filter: drop-shadow(0 0 6px color-mix(in srgb, var(--c, var(--ok)) 55%, transparent)); }
.ring .mid { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.ring .mid b { font-size: 24px; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.ring .mid span { font-size: 11px; color: var(--muted); max-width: 84px; line-height: 1.2; }

/* ---------- gép oldal ---------- */
.hero { position: relative; border-radius: 24px; padding: clamp(22px, 4vw, 38px); color: #fff; overflow: hidden;
  background: linear-gradient(135deg, #0d1a33 0%, #17315f 55%, #5b3014 130%); box-shadow: var(--shadow); }
.hero::before { content: ''; position: absolute; inset: 0; background:
  radial-gradient(500px 240px at 90% 0%, rgba(255,122,26,.35), transparent 70%),
  repeating-linear-gradient(115deg, rgba(255,255,255,.03) 0 2px, transparent 2px 22px); }
.hero > * { position: relative; }
.hero .top { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.hero .reg { font-size: clamp(34px, 6vw, 56px); font-weight: 850; letter-spacing: -.04em; line-height: 1; }
.hero .sub { color: rgba(255,255,255,.7); margin-top: 8px; }
.hero .pill { background: rgba(255,255,255,.14); color: #fff; backdrop-filter: blur(6px); }
.hero .pill::before { background: var(--c, #fff); }
.hero .stats { display: flex; gap: clamp(18px, 4vw, 46px); margin-top: 30px; flex-wrap: wrap; }
.hero .stats b { display: block; font-size: clamp(24px, 3.4vw, 34px); font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.hero .stats span { font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: rgba(255,255,255,.6); }
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-weight: 550; margin-bottom: 16px; }
.back:hover { color: var(--text); }
.tabs { display: flex; gap: 6px; margin: 26px 0 22px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { padding: 9px 16px; border-radius: 999px; font-weight: 600; color: var(--muted); white-space: nowrap; border: 1px solid transparent; transition: all .2s; }
.tabs a:hover { color: var(--text); }
.tabs a.active { background: var(--surface); color: var(--text); border-color: var(--line); box-shadow: var(--shadow); }

/* ---------- grafikon ---------- */
.chart { position: relative; margin-top: 14px; }
.chart svg { width: 100%; height: auto; display: block; overflow: visible; }
.chart .grid-line { stroke: var(--line); stroke-dasharray: 3 5; }
.chart .axis { fill: var(--muted); font-size: 11px; }
.chart .line { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.chart .dot { fill: var(--surface); stroke: var(--accent); stroke-width: 2.5; }
.chart .tip { position: absolute; pointer-events: none; transform: translate(-50%, -120%); background: var(--text); color: var(--bg); padding: 6px 10px; border-radius: 10px; font-size: 12px; font-weight: 650; white-space: nowrap; opacity: 0; transition: opacity .15s; }

/* ---------- karbantartás ---------- */
.due-list { display: grid; gap: 12px; margin-top: 16px; }
.due { display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); }
.due .t { font-weight: 650; }
.due .d { font-size: 13px; color: var(--muted); }
.due .code { font-size: 11px; font-weight: 750; letter-spacing: .08em; color: var(--accent); margin-right: 8px; }
.meter { grid-column: 1 / -1; height: 8px; border-radius: 99px; background: var(--line); overflow: hidden; }
.meter i { display: block; height: 100%; width: 0; border-radius: 99px; background: var(--c, var(--ok)); transition: width 1.1s cubic-bezier(.2,.8,.2,1); }

/* ---------- táblázat, lista ---------- */
.table-wrap { overflow-x: auto; margin: 12px -8px 0; }
table { width: 100%; border-collapse: collapse; min-width: 560px; }
th { text-align: left; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 650; padding: 10px 8px; border-bottom: 1px solid var(--line); }
td { padding: 13px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
tbody tr.link { cursor: pointer; transition: background .15s; }
tbody tr.link:hover { background: var(--surface-2); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 10px 22px; margin-top: 14px; }
.kv dt { color: var(--muted); font-size: 13px; }
.kv dd { margin: 0; font-weight: 600; text-align: right; word-break: break-word; }
.timeline { position: relative; margin-top: 16px; padding-left: 22px; }
.timeline::before { content: ''; position: absolute; left: 5px; top: 6px; bottom: 6px; width: 2px; background: var(--line); border-radius: 2px; }
.timeline .item { position: relative; padding: 0 0 18px; }
.timeline .item::before { content: ''; position: absolute; left: -22px; top: 6px; width: 12px; height: 12px; border-radius: 50%; background: var(--surface); border: 3px solid var(--accent); }
.empty { text-align: center; color: var(--muted); padding: 34px 10px; }
.input { width: 100%; padding: 12px 14px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--surface-2); color: var(--text); font: inherit; transition: border-color .2s, box-shadow .2s; }
.input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 18%, transparent); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; padding: 12px 20px; border-radius: 999px; font-weight: 700;
  background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: #1a0d00; box-shadow: 0 8px 22px color-mix(in srgb, var(--accent) 35%, transparent); transition: transform .2s, box-shadow .2s; }
.btn:hover { transform: translateY(-1px); }
.btn:disabled { opacity: .6; cursor: progress; }
.btn.ghost { background: var(--surface-2); color: var(--text); box-shadow: none; border: 1px solid var(--line); }
.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field label { font-size: 13px; font-weight: 600; color: var(--muted); }
.msg { padding: 10px 14px; border-radius: var(--radius-sm); font-size: 14px; margin-bottom: 14px; }
.msg.err { background: color-mix(in srgb, var(--bad) 12%, transparent); color: var(--bad); }
.msg.ok { background: color-mix(in srgb, var(--ok) 12%, transparent); color: var(--ok); }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.toolbar .input { max-width: 340px; }

/* ---------- dokumentum nézet ---------- */
.doc { max-width: 880px; margin: 0 auto; padding: clamp(22px, 4vw, 48px); }
.doc-head { display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap; border-bottom: 2px solid var(--text); padding-bottom: 18px; margin-bottom: 22px; }
.doc-head .no { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.doc section { margin-top: 24px; }
.doc section h3 { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.doc section p { margin: 0; white-space: pre-wrap; }
.doc .facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px 24px; }
.doc .facts div b { display: block; font-size: 12px; color: var(--muted); font-weight: 600; }
.doc .notice { margin-top: 30px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface-2); color: var(--muted); font-size: 13px; }
.hash { font: 12px ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--muted); word-break: break-all; }

/* ---------- belépés ---------- */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.auth-art { position: relative; color: #fff; padding: clamp(28px, 5vw, 64px); display: flex; flex-direction: column; justify-content: space-between; overflow: hidden;
  background: linear-gradient(145deg, #0a1428 0%, #14295a 60%, #6a3511 140%); }
.auth-art .blade { position: absolute; right: -160px; top: 50%; width: 760px; height: 760px; margin-top: -380px; opacity: .22; animation: spin 14s linear infinite; }
.auth-art h2 { font-size: clamp(30px, 4vw, 50px); font-weight: 800; letter-spacing: -.035em; line-height: 1.05; max-width: 12ch; position: relative; }
.auth-art p { color: rgba(255,255,255,.7); max-width: 38ch; position: relative; }
.auth-art img { height: 34px; width: auto; position: relative; align-self: flex-start; }
.auth-form { display: grid; place-items: center; padding: 32px 20px; }
.auth-box { width: min(400px, 100%); }
.auth-box h1 { margin-bottom: 8px; }
.auth-box > p { color: var(--muted); margin: 0 0 26px; }
.auth-box .btn { width: 100%; }
.auth-box .tools { justify-content: flex-end; margin-bottom: 40px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- animációk ---------- */
.reveal { opacity: 0; transform: translateY(14px); animation: reveal .6s cubic-bezier(.2,.8,.2,1) forwards; animation-delay: calc(var(--i, 0) * 70ms); }
@keyframes reveal { to { opacity: 1; transform: none; } }
.skeleton { background: linear-gradient(100deg, var(--surface-2) 30%, var(--line) 50%, var(--surface-2) 70%); background-size: 300% 100%; animation: shimmer 1.4s infinite; border-radius: var(--radius); min-height: 130px; }
@keyframes shimmer { to { background-position: -150% 0; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } .reveal { opacity: 1; transform: none; } }

@media (max-width: 880px) {
  .auth { grid-template-columns: 1fr; } .auth-art { display: none; }
  .brand .sub { display: none; }
  .nav { display: none; }
  .tabbar { display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 40; padding: 8px 8px calc(8px + env(safe-area-inset-bottom)); justify-content: space-around; background: var(--glass); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); border-top: 1px solid var(--line); }
  .tabbar a { padding: 8px 14px; border-radius: 999px; color: var(--muted); font-weight: 600; } .tabbar a.active { color: var(--text); background: var(--surface); box-shadow: var(--shadow); }
  main { padding-bottom: 100px; }
  .ac-card { grid-template-columns: 1fr; } .ring { justify-self: start; }
  .g-fleet, .g-2 { grid-template-columns: 1fr; }
  .g-kpi { grid-template-columns: repeat(2, 1fr); gap: 12px; } .kpi { padding: 16px; } .kpi .value { font-size: 26px; }
  .topbar { gap: 8px; padding: 0 12px; } .tools { gap: 6px; } .badge-demo { display: none; } .seg button { padding: 5px 7px; }
  .icon-btn { width: 34px; height: 34px; } .brand img { height: 32px; }
  .hero .stats { gap: 22px; } .card { padding: 18px; }
}
@media print {
  .topbar, .nav, .tabbar, footer, .no-print { display: none !important; }
  body { background: #fff; color: #000; } .card { box-shadow: none; border: 0; } main { padding: 0; }
}
