/* Equitium - Lab Alpium */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
    --bg-deep: #050810;
    --bg-primary: #0a0f1c;
    --bg-secondary: #111827;
    --bg-card: rgba(17, 24, 39, 0.7);
    --bg-card-solid: #111827;
    --border: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.18);
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --accent: #00d4ff;
    --accent-dark: #0891b2;
    --accent-glow: rgba(0, 212, 255, 0.15);
    --gold: #fbbf24;
    --green: #10b981;
    --red: #ef4444;
    --purple: #a78bfa;
    --radius: 8px;
    --radius-lg: 14px;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg-deep);
    color: var(--text-primary);
    font-family: 'Outfit', system-ui, -apple-system, sans-serif;
    font-weight: 400;
    line-height: 1.55;
    min-height: 100vh;
}

body {
    background:
        radial-gradient(circle at 15% 10%, rgba(0, 212, 255, 0.08), transparent 40%),
        radial-gradient(circle at 85% 90%, rgba(167, 139, 250, 0.06), transparent 40%),
        var(--bg-deep);
    background-attachment: fixed;
}

a { color: var(--accent); text-decoration: none; transition: color .15s; }
a:hover { color: var(--accent-dark); }

code, .mono { font-family: 'JetBrains Mono', monospace; }

/* === Layout === */
.eq-shell { max-width: 1100px; margin: 0 auto; padding: 24px 20px 80px; }
.eq-narrow { max-width: 560px; margin: 0 auto; padding: 24px 20px 80px; }

.eq-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    background: rgba(5, 8, 16, 0.85);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 50;
}
.eq-nav .brand {
    font-weight: 800;
    letter-spacing: 1.5px;
    font-size: 18px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
}
.eq-nav .brand::before {
    content: '';
    width: 10px; height: 10px;
    background: var(--accent);
    border-radius: 50%;
    box-shadow: 0 0 16px var(--accent);
}
.eq-nav nav a { margin-left: 18px; color: var(--text-secondary); font-size: 14px; }
.eq-nav nav a:hover { color: var(--text-primary); }

/* === Headings === */
h1 { font-size: 32px; font-weight: 700; margin: 0 0 6px; letter-spacing: -0.5px; }
h2 { font-size: 22px; font-weight: 600; margin: 0 0 12px; }
h3 { font-size: 16px; font-weight: 600; margin: 18px 0 8px; color: var(--text-primary); }
.eq-subtitle { color: var(--text-secondary); margin: 0 0 28px; font-size: 15px; }

/* === Cards === */
.eq-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    backdrop-filter: blur(8px);
    margin-bottom: 18px;
}
.eq-card.compact { padding: 16px 18px; }
.eq-card-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

/* === Forms === */
.eq-form .field { margin-bottom: 16px; }
.eq-form label {
    display: block;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 6px;
    font-weight: 500;
}
.eq-form input[type="text"],
.eq-form input[type="email"],
.eq-form input[type="password"],
.eq-form input[type="number"],
.eq-form input[type="date"],
.eq-form input[type="url"],
.eq-form textarea,
.eq-form select {
    width: 100%;
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius);
    padding: 11px 13px;
    font-size: 15px;
    font-family: inherit;
    transition: border-color .15s, box-shadow .15s;
}
.eq-form input:focus, .eq-form textarea:focus, .eq-form select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}
.eq-form textarea { min-height: 80px; resize: vertical; }
.eq-form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.eq-form .row-3 { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 10px; }
@media (max-width: 600px) {
    .eq-form .row, .eq-form .row-3 { grid-template-columns: 1fr; }
}
.eq-form .help { font-size: 12px; color: var(--text-muted); margin-top: 4px; }

/* === Buttons === */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 22px;
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all .15s;
    text-decoration: none;
    line-height: 1;
}
.btn-primary {
    background: var(--accent);
    color: var(--bg-primary);
    border-color: var(--accent);
}
.btn-primary:hover { background: #5cdfff; color: var(--bg-primary); transform: translateY(-1px); }
.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--border-strong);
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }
.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border-color: transparent;
}
.btn-ghost:hover { color: var(--text-primary); background: var(--bg-secondary); }
.btn-danger {
    background: transparent;
    color: var(--red);
    border-color: rgba(239, 68, 68, 0.4);
}
.btn-danger:hover { background: rgba(239, 68, 68, 0.1); }
.btn-sm { padding: 6px 12px; font-size: 12px; }
.btn-block { width: 100%; }

/* === Alerts === */
.eq-alert {
    padding: 12px 14px;
    border-radius: var(--radius);
    margin-bottom: 16px;
    font-size: 14px;
    border-left: 3px solid var(--text-muted);
    background: var(--bg-secondary);
}
.eq-alert.error { border-color: var(--red); color: #fecaca; background: rgba(239, 68, 68, 0.08); }
.eq-alert.success { border-color: var(--green); color: #a7f3d0; background: rgba(16, 185, 129, 0.08); }
.eq-alert.info { border-color: var(--accent); color: var(--accent); background: var(--accent-glow); }

/* === Stats === */
.eq-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
    margin: 16px 0 24px;
}
.eq-stat {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 14px 16px;
}
.eq-stat .label { font-size: 12px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.eq-stat .value { font-size: 22px; font-weight: 700; margin-top: 4px; }
.eq-stat .value.accent { color: var(--accent); }
.eq-stat .value.green { color: var(--green); }
.eq-stat .value.red { color: var(--red); }

/* === Lists / Tables === */
.eq-list { list-style: none; padding: 0; margin: 0; }
.eq-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
}
.eq-list li:last-child { border-bottom: none; }
.eq-list .meta { color: var(--text-muted); font-size: 12px; }

.eq-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.eq-table th, .eq-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}
.eq-table th { color: var(--text-muted); font-weight: 500; font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; }
.eq-table tr:last-child td { border-bottom: none; }

/* === Badges === */
.badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}
.badge.open { background: rgba(0, 212, 255, 0.15); color: var(--accent); }
.badge.closed { background: rgba(148, 163, 184, 0.15); color: var(--text-secondary); }
.badge.joined { background: rgba(16, 185, 129, 0.15); color: var(--green); }
.badge.pending { background: rgba(251, 191, 36, 0.15); color: var(--gold); }

/* === Settlement table === */
.eq-transfer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    background: var(--bg-secondary);
    border-radius: var(--radius);
    margin-bottom: 8px;
    border-left: 3px solid var(--accent);
}
.eq-transfer .amt { font-weight: 700; color: var(--accent); font-size: 18px; }
.eq-transfer .pay-links { display: flex; gap: 6px; flex-wrap: wrap; }
.eq-transfer .pay-links a {
    background: var(--accent);
    color: var(--bg-primary);
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

/* === Hero auth === */
.eq-hero {
    text-align: center;
    padding: 60px 20px 40px;
}
.eq-hero h1 { font-size: 48px; letter-spacing: -1px; }
.eq-hero h1 .accent { color: var(--accent); text-shadow: 0 0 30px var(--accent-glow); }
.eq-hero .lead { color: var(--text-secondary); font-size: 17px; max-width: 540px; margin: 12px auto 30px; }
.eq-hero .cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

.eq-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin: 40px 0;
}
.eq-feature {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px;
}
.eq-feature .icon { font-size: 24px; margin-bottom: 8px; color: var(--accent); }

/* === Misc === */
.eq-empty {
    text-align: center;
    padding: 50px 20px;
    color: var(--text-muted);
}
.eq-empty .icon { font-size: 48px; margin-bottom: 12px; opacity: 0.3; }

.eq-link-row {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-secondary);
    padding: 10px 12px;
    border-radius: var(--radius);
    border: 1px solid var(--border-strong);
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
}
.eq-link-row input { flex: 1; background: transparent; border: none; color: var(--text-primary); font-family: inherit; outline: none; }

.muted { color: var(--text-muted); }
.text-right { text-align: right; }
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-0 { margin-bottom: 0; }
.mb-2 { margin-bottom: 16px; }
.flex { display: flex; }
.flex-gap { display: flex; gap: 12px; }
.flex-wrap { flex-wrap: wrap; }
.flex-grow { flex: 1; }
.between { justify-content: space-between; }
.center-y { align-items: center; }

/* === Footer === */
.eq-footer {
    margin-top: 60px;
    padding: 24px 20px;
    border-top: 1px solid var(--border);
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
}
.eq-footer a { color: var(--text-secondary); margin: 0 10px; }

/* === Print (récap) === */
@media print {
    body { background: white; color: black; }
    .eq-nav, .eq-footer, .no-print { display: none !important; }
    .eq-card { background: white; border: 1px solid #ddd; }
    a { color: black; text-decoration: underline; }
}
