:root {
	--gfs-gold: #cfaf3e;
	--gfs-gold-dark: #b89b37;
	--gold-text: #8a6e1f;
	--gfs-brown: #716551;
	--gfs-brown-dark: #5d513f;
	--ink: #0d2231;
	--ink-2: #1a3a52;
	--bg: #f6f4ef;
	--surface: #ffffff;
	--surface-2: #faf8f4;
	--text: #20262e;
	--muted: #6f6857;
	--border: #e7e1d6;
	--border-soft: #efeae1;
	--ok: #2f7a48;
	--bad: #b4452f;
	--radius-sm: 6px;
	--radius: 10px;
	--radius-lg: 16px;
	--shadow-sm: 0 1px 2px rgba(32,38,46,.05), 0 1px 3px rgba(32,38,46,.06);
	--shadow: 0 14px 36px -16px rgba(8,33,49,.22);
	--shadow-soft: 0 18px 50px -28px rgba(8,33,49,.30);
	--ease: cubic-bezier(.2,.7,.2,1);
	--font: 'Montserrat', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
	font-family: var(--font);
	background: var(--bg);
	color: var(--text);
	font-size: 15px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	min-height: 100vh;
}
.hidden { display: none !important; }
a { color: inherit; text-decoration: none; }

h1, h2, h3 { font-family: var(--font); font-weight: 700; letter-spacing: -.02em; color: var(--ink); margin: 0; }

.goldbar {
	height: 2px;
	background: linear-gradient(90deg, transparent 0%, var(--gfs-gold) 22%, var(--gfs-gold-dark) 50%, var(--gfs-gold) 78%, transparent 100%);
	opacity: .9;
}

/* Brand */
.brand { display: inline-flex; align-items: center; gap: 14px; }
.brand-logo { height: 34px; width: auto; display: block; }
.brand-logo-lg { height: 54px; display: block; margin-bottom: 22px; }
.brand-app {
	font-size: 11px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase;
	color: var(--gfs-brown); padding-left: 14px; border-left: 1px solid var(--border);
}

/* ---------- Login ---------- */
.login { min-height: calc(100vh - 2px); display: grid; place-items: center; padding: 32px; }
.panel {
	width: 100%; max-width: 430px; background: var(--surface);
	border: 1px solid var(--border); border-radius: var(--radius-lg);
	padding: 40px 38px; box-shadow: var(--shadow-soft);
	animation: rise .5s var(--ease) both;
}
.panel { text-align: left; }
.eyebrow { display: block; font-size: 11px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: var(--gold-text); margin-bottom: 8px; }
.panel h1 { font-size: 28px; letter-spacing: -.025em; }
.panel .sub { margin: 7px 0 26px; color: var(--muted); font-size: 14px; }
label { display: block; font-size: 12.5px; font-weight: 600; color: var(--text); margin: 0 0 7px; letter-spacing: .01em; }
input {
	width: 100%; padding: 12px 14px; font-family: inherit; font-size: 15px; color: var(--text);
	background: #fff; border: 1px solid var(--border); border-radius: var(--radius-sm);
	margin-bottom: 18px; transition: border-color .18s, box-shadow .18s;
}
input::placeholder { color: #b3ab98; }
input:focus { outline: none; border-color: var(--gfs-brown); box-shadow: 0 0 0 3px rgba(113,101,81,.14); }
.msg { min-height: 18px; margin: 14px 0 0; font-size: 13px; color: var(--muted); }

/* ---------- Buttons ---------- */
.cta {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	background: var(--ink); color: #fff; border: none; border-radius: 7px;
	font-family: inherit; font-weight: 600; font-size: 14.5px; letter-spacing: .015em;
	padding: 12px 22px; cursor: pointer; box-shadow: 0 1px 2px rgba(13,34,49,.2);
	transition: transform .18s, background .18s, box-shadow .18s;
}
.cta:hover { background: var(--ink-2); transform: translateY(-1px); box-shadow: 0 12px 26px -12px rgba(13,34,49,.55); }
.cta:active { transform: translateY(0); }
.cta-block { width: 100%; }
.ghost {
	display: inline-flex; align-items: center; gap: 7px; background: transparent; color: var(--ink);
	border: 1px solid var(--border); border-radius: 999px; font-family: inherit; font-weight: 600;
	font-size: 13px; padding: 8px 16px; cursor: pointer; transition: all .2s;
}
.ghost:hover { border-color: var(--gfs-gold); background: rgba(207,175,62,.08); }

/* ---------- Header ---------- */
.site-header {
	position: sticky; top: 0; z-index: 50;
	background: rgba(255,255,255,.92); backdrop-filter: blur(10px);
	border-bottom: 1px solid var(--border-soft);
}
.header-inner {
	max-width: 1180px; margin: 0 auto; padding: 16px 28px;
	display: flex; align-items: center; gap: 22px;
}
.header-inner .brand { margin-right: auto; }
.tabs { display: flex; align-items: center; gap: 4px; }
.tab {
	position: relative; background: none; border: none; cursor: pointer; font-family: inherit;
	font-size: 13.5px; font-weight: 600; color: var(--muted); letter-spacing: .01em;
	padding: 8px 14px; border-radius: var(--radius-sm); transition: color .18s, background .18s;
}
.tab:hover { color: var(--ink); background: rgba(113,101,81,.06); }
.tab.active { color: var(--ink); }
.tab.active::after {
	content: ''; position: absolute; left: 14px; right: 14px; bottom: -1px; height: 2px;
	background: linear-gradient(90deg, var(--gfs-gold), var(--gfs-gold-dark)); border-radius: 2px;
}

/* ---------- Layout ---------- */
.site-main { max-width: 1180px; margin: 0 auto; padding: 34px 28px 56px; }
.site-footer { padding: 24px 28px; border-top: 1px solid var(--border-soft); color: var(--muted); font-size: 12.5px; text-align: center; letter-spacing: .04em; }
.view { animation: rise .45s var(--ease) both; }

.page-head { margin: 0 0 26px; }
.page-head .eyebrow { color: var(--gfs-brown); }
.page-head h1 { font-size: clamp(28px, 3.4vw, 38px); line-height: 1.06; letter-spacing: -.028em; }
.page-head p { margin: 9px 0 0; color: var(--muted); font-size: 15px; max-width: 60ch; }

/* ---------- Freshness ---------- */
.freshness { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 24px; }
.fresh {
	display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600;
	padding: 7px 13px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border);
	color: var(--muted); letter-spacing: .01em;
}
.fresh::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.fresh .src { color: var(--ink); text-transform: uppercase; letter-spacing: .08em; font-size: 11px; }
.fresh.ok { color: var(--ok); border-color: rgba(47,122,72,.3); background: rgba(47,122,72,.06); }
.fresh.stale { color: var(--bad); border-color: rgba(180,69,47,.32); background: rgba(180,69,47,.06); }

/* ---------- KPI grid ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.kpi {
	position: relative; overflow: hidden; background: var(--surface); border: 1px solid var(--border);
	border-radius: var(--radius); padding: 20px 22px; box-shadow: var(--shadow-sm);
	transition: transform .2s, box-shadow .2s, border-color .2s;
	animation: rise .5s var(--ease) both;
}
.kpi:hover { transform: translateY(-3px); box-shadow: var(--shadow-soft); border-color: rgba(207,175,62,.5); }
.kpi::after {
	content: ''; position: absolute; top: 0; right: 0; width: 64px; height: 64px;
	background: radial-gradient(120% 120% at 100% 0%, rgba(207,175,62,.16), transparent 70%);
}
.kpi .label { font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--gfs-brown); }
.kpi .value { font-size: 34px; font-weight: 700; letter-spacing: -.02em; color: var(--ink); margin: 8px 0 6px; line-height: 1; }
.kpi .label:last-child { font-size: 11.5px; font-weight: 500; letter-spacing: .01em; text-transform: none; color: var(--muted); }

/* ---------- Filters ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 12px; margin: 0 0 22px; align-items: center; }
select {
	font-family: inherit; font-size: 13.5px; font-weight: 600; color: var(--ink);
	padding: 9px 32px 9px 14px; border: 1px solid var(--border); border-radius: var(--radius-sm);
	background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' stroke='%23716551' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 12px center;
	-webkit-appearance: none; appearance: none; cursor: pointer; transition: border-color .18s, box-shadow .18s;
}
select:focus { outline: none; border-color: var(--gfs-brown); box-shadow: 0 0 0 3px rgba(113,101,81,.14); }
.filters .cta, .filters .ghost { padding-top: 9px; padding-bottom: 9px; }

/* ---------- Chart ---------- */
.chartWrap {
	background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
	padding: 18px 20px; box-shadow: var(--shadow-sm); margin: 0 0 24px;
}

/* ---------- Tables ---------- */
table {
	width: 100%; border-collapse: collapse; background: var(--surface);
	border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden;
	box-shadow: var(--shadow-sm); margin: 0 0 26px;
}
thead th {
	background: var(--surface-2); color: var(--gfs-brown); font-weight: 700;
	font-size: 11px; text-transform: uppercase; letter-spacing: .08em; text-align: left;
	padding: 13px 16px; border-bottom: 1px solid var(--border);
}
tbody td { padding: 12px 16px; font-size: 13.5px; border-bottom: 1px solid var(--border-soft); color: var(--text); }
tbody td:nth-child(n+4) { font-variant-numeric: tabular-nums; font-weight: 600; }
tbody tr:last-child td { border-bottom: none; }
tbody tr { transition: background .14s; }
tbody tr:hover { background: rgba(207,175,62,.05); }
tbody td a { color: var(--ink); font-weight: 600; border-bottom: 1px solid transparent; transition: border-color .15s; }
tbody td a:hover { border-color: var(--gfs-gold); }

h2 { font-size: 18px; letter-spacing: -.02em; margin: 6px 0 14px; }
h2 + table { margin-top: 0; }
.gap { font-size: 13px; color: var(--muted); margin: -10px 0 28px; padding: 12px 16px; background: var(--surface-2); border: 1px dashed var(--border); border-radius: var(--radius-sm); }

@keyframes rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.kpi:nth-child(2) { animation-delay: .05s; }
.kpi:nth-child(3) { animation-delay: .1s; }
.kpi:nth-child(4) { animation-delay: .15s; }
.kpi:nth-child(5) { animation-delay: .2s; }

@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

@media (max-width: 760px) {
	.header-inner { flex-wrap: wrap; gap: 14px; padding: 14px 18px; }
	.header-inner .lockup { margin-right: 0; }
	.tabs { order: 3; width: 100%; overflow-x: auto; }
	.site-main { padding: 24px 18px 44px; }
	table { display: block; overflow-x: auto; white-space: nowrap; }
	.brand-app { display: none; }
}

/* ---------- Cockpit (Übersicht) ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 0 0 30px; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow-sm); animation: rise .5s var(--ease) both; }
.stat:nth-child(2) { animation-delay: .05s; } .stat:nth-child(3) { animation-delay: .1s; } .stat:nth-child(4) { animation-delay: .15s; }
.stat-label { font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--gfs-brown); }
.stat-value { font-size: 30px; font-weight: 700; letter-spacing: -.025em; color: var(--ink); margin: 7px 0 4px; line-height: 1; }
.stat-sub { font-size: 12px; color: var(--muted); }

.cols { display: grid; grid-template-columns: 1.9fr 1fr; gap: 26px; align-items: start; }
.sec-title { font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--gfs-brown); margin: 0 0 14px; }
.col-main .sec-title:not(:first-child) { margin-top: 30px; }

.trend-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.trend-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px 6px; box-shadow: var(--shadow-sm); transition: box-shadow .2s, border-color .2s; }
.trend-card:hover { box-shadow: var(--shadow-soft); border-color: rgba(207,175,62,.5); }
.trend-head { display: flex; align-items: center; justify-content: space-between; }
.trend-name { font-size: 12px; font-weight: 700; letter-spacing: .04em; color: var(--text); }
.trend-delta { font-size: 11.5px; font-weight: 700; }
.trend-delta.up { color: var(--ok); } .trend-delta.down { color: var(--bad); }
.trend-value { font-size: 26px; font-weight: 700; letter-spacing: -.02em; color: var(--ink); margin: 6px 0 8px; line-height: 1; }
.spark { width: 100%; height: 52px; display: block; overflow: visible; }
.spark-line { fill: none; stroke: var(--gfs-gold); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.spark-area { fill: rgba(207,175,62,.12); stroke: none; }
.spark-dot { fill: var(--gfs-gold-dark); }
.spark-empty { font-size: 11.5px; color: var(--muted); padding: 14px 0 16px; }

.top-list { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; }
.top-row { display: flex; align-items: center; gap: 16px; padding: 14px 18px; border-bottom: 1px solid var(--border-soft); transition: background .14s; }
.top-row:last-child { border-bottom: none; }
.top-row:hover { background: rgba(207,175,62,.05); }
.top-rank { flex: 0 0 26px; width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; font-size: 12px; font-weight: 800; color: var(--gfs-brown); background: rgba(207,175,62,.16); }
.top-row:first-child .top-rank { color: #fff; background: linear-gradient(135deg, var(--gfs-gold), var(--gfs-gold-dark)); }
.top-main { flex: 1; min-width: 0; }
.top-title { display: block; font-size: 13.5px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-meta { display: block; font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.top-stat { flex: 0 0 auto; text-align: right; font-size: 10.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; min-width: 56px; }
.top-stat b { display: block; font-size: 15px; font-weight: 700; color: var(--ink); letter-spacing: -.01em; font-variant-numeric: tabular-nums; }

.plan-list { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; }
.plan-row { display: grid; grid-template-columns: 1fr; gap: 2px; padding: 12px 16px; border-bottom: 1px solid var(--border-soft); }
.plan-row:last-child { border-bottom: none; }
.plan-date { font-size: 11px; font-weight: 700; letter-spacing: .04em; color: var(--gold-text); }
.plan-title { font-size: 13px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plan-ch { font-size: 11.5px; color: var(--muted); }
.empty-state { background: var(--surface-2); border: 1px dashed var(--border); border-radius: var(--radius); padding: 28px 22px; text-align: center; color: var(--muted); }
.empty-icon { font-size: 30px; color: var(--gfs-brown); opacity: .6; margin-bottom: 8px; }
.empty-state p { margin: 0; font-size: 13.5px; line-height: 1.55; }
.empty-state b { color: var(--ink); }

@media (max-width: 920px) {
	.stats { grid-template-columns: repeat(2, 1fr); }
	.cols { grid-template-columns: 1fr; gap: 30px; }
	.top-stat:nth-child(5) { display: none; }
}
