/* ==========================================================================
   EMS PANEL – MINIMALIST DARK THEME
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --bg:          #0c0c0d;
    --bg-card:     #111113;
    --bg-hover:    #18181b;
    --border:      rgba(255,255,255,0.07);
    --border-red:  rgba(220, 38, 38, 0.35);

    --red:         #dc2626;
    --red-dim:     rgba(220, 38, 38, 0.12);

    --text:        #f4f4f5;
    --text-muted:  #71717a;
    --text-dim:    #3f3f46;

    --radius:      10px;
    --radius-sm:   6px;
    --radius-full: 9999px;
    --transition:  all 0.18s ease;
}

*, *::before, *::after {
    margin: 0; padding: 0; box-sizing: border-box;
}

body {
    font-family: 'Inter', system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.65;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

a { color: inherit; text-decoration: none; transition: var(--transition); }

/* ==========================================================================
   NAVBAR
   ========================================================================== */
.navbar {
    position: sticky;
    top: 0;
    width: 100%;
    background: rgba(12, 12, 13, 0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    z-index: 100;
    padding: 0;
}

.nav-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: -0.2px;
    color: var(--text);
}

.nav-logo {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    object-fit: cover;
}

.nav-badge {
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--red);
    background: var(--red-dim);
    border: 1px solid var(--border-red);
    padding: 2px 7px;
    border-radius: var(--radius-full);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 4px;
    list-style: none;
}

.nav-link {
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 500;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.nav-link:hover { color: var(--text); background: rgba(255,255,255,0.05); }
.nav-link.active { color: var(--text); }

/* User profile in nav */
.user-profile-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 10px 4px 4px;
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    background: var(--bg-card);
    transition: var(--transition);
    cursor: pointer;
}

.user-profile-badge:hover { border-color: var(--border-red); }

.user-avatar {
    width: 28px; height: 28px;
    border-radius: var(--radius-full);
    object-fit: cover;
}

.user-name { font-size: 0.85rem; font-weight: 600; color: var(--text); }

.btn-logout {
    background: none; border: none; cursor: pointer;
    color: var(--text-muted); font-size: 0.78rem;
    transition: var(--transition);
}
.btn-logout:hover { color: var(--red); }

/* ==========================================================================
   BUTTONS
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-family: inherit;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: var(--radius);
    border: 1px solid transparent;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.btn-primary {
    background: var(--red);
    color: #fff;
    border-color: var(--red);
}
.btn-primary:hover { background: #b91c1c; border-color: #b91c1c; transform: translateY(-1px); }

.btn-secondary {
    background: transparent;
    color: var(--text-muted);
    border-color: var(--border);
}
.btn-secondary:hover { color: var(--text); border-color: rgba(255,255,255,0.18); background: rgba(255,255,255,0.04); transform: translateY(-1px); }

.btn-discord {
    background: #5865F2;
    color: #fff;
    border-color: #5865F2;
}
.btn-discord:hover { background: #4752c4; border-color: #4752c4; transform: translateY(-1px); }

.btn-large { padding: 13px 28px; font-size: 0.95rem; }
.btn-block { width: 100%; }

/* ==========================================================================
   LAYOUT
   ========================================================================== */
.main-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 56px 24px;
    flex: 1;
    width: 100%;
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero-section {
    padding: 32px 0 48px;
    text-align: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border: 1px solid var(--border-red);
    background: var(--red-dim);
    border-radius: var(--radius-full);
    color: var(--red);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 28px;
}

.hero-title {
    font-size: 2.6rem;
    font-weight: 700;
    letter-spacing: -1px;
    line-height: 1.15;
    margin-bottom: 18px;
    color: var(--text);
}

.hero-title span { color: var(--red); }

.hero-subtitle {
    font-size: 1rem;
    color: var(--text-muted);
    max-width: 560px;
    margin: 0 auto 36px;
    font-weight: 400;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* ==========================================================================
   CARDS GRID
   ========================================================================== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    margin-top: 56px;
    background: var(--border);
}

.stat-card {
    background: var(--bg-card);
    padding: 28px 24px;
    transition: var(--transition);
}

.stat-card:hover { background: var(--bg-hover); }

.stat-icon { font-size: 1.4rem; margin-bottom: 12px; }

.stat-value {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 6px;
}

.stat-label {
    font-size: 0.82rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* ==========================================================================
   GLASS CARD (used for requirements etc)
   ========================================================================== */
.glass-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 36px;
}

.form-header {
    padding-bottom: 24px;
    margin-bottom: 28px;
    border-bottom: 1px solid var(--border);
}

.form-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 6px;
}

.form-header p { color: var(--text-muted); font-size: 0.875rem; }

/* ==========================================================================
   FORM
   ========================================================================== */
.form-section { margin-bottom: 32px; }

.section-legend {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 18px;
}

.legend-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px; height: 22px;
    background: var(--red-dim);
    color: var(--red);
    border: 1px solid var(--border-red);
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 700;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
}

.form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.form-group.full-width { grid-column: 1 / -1; }

.form-label {
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.form-label span.req { color: var(--red); }

.form-hint { font-size: 0.74rem; color: var(--text-dim); }

.form-input, .form-textarea, .form-select {
    width: 100%;
    padding: 10px 14px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-family: inherit;
    font-size: 0.875rem;
    transition: var(--transition);
}

.form-textarea { resize: vertical; min-height: 100px; }

.form-input:focus, .form-textarea:focus, .form-select:focus {
    outline: none;
    border-color: var(--red);
    background: var(--bg-card);
}

.form-select option { background: var(--bg-card); }

.form-checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-size: 0.875rem;
    color: var(--text-muted);
    user-select: none;
}
.form-checkbox-label input[type="checkbox"] {
    width: 16px; height: 16px;
    accent-color: var(--red);
    margin-top: 3px;
    flex-shrink: 0;
}

/* ==========================================================================
   STATUS PAGE
   ========================================================================== */
.status-card { text-align: center; padding: 40px 20px; }

.status-badge-lg {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 20px;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 24px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    border: 1px solid;
}

.status-pending  { background: rgba(234,179,8,0.1);  border-color: rgba(234,179,8,0.35);  color: #eab308; }
.status-accepted { background: rgba(34,197,94,0.1);  border-color: rgba(34,197,94,0.35);  color: #22c55e; }
.status-rejected { background: rgba(220,38,38,0.1);  border-color: rgba(220,38,38,0.35);  color: var(--red); }

.status-details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    margin: 24px 0;
    text-align: left;
}

.status-detail-item {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 14px 16px;
}

.status-detail-label {
    font-size: 0.72rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.status-detail-val { font-size: 0.95rem; font-weight: 600; color: var(--text); }

/* ==========================================================================
   ALERTS
   ========================================================================== */
.alert {
    padding: 14px 18px;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    margin-bottom: 20px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    border: 1px solid;
}

.alert-warning { background: rgba(234,179,8,0.08); border-color: rgba(234,179,8,0.3); color: #fbbf24; }
.alert-info    { background: rgba(59,130,246,0.08); border-color: rgba(59,130,246,0.3); color: #93c5fd; }
.alert-danger  { background: rgba(220,38,38,0.08);  border-color: rgba(220,38,38,0.3);  color: #fca5a5; }

/* ==========================================================================
   DIVIDER
   ========================================================================== */
.divider {
    height: 1px;
    background: var(--border);
    margin: 32px 0;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.footer {
    border-top: 1px solid var(--border);
    padding: 20px 24px;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-top: auto;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 768px) {
    .hero-title { font-size: 2rem; letter-spacing: -0.5px; }
    .glass-card { padding: 24px 18px; }
    .form-grid { grid-template-columns: 1fr; }
    .nav-links { display: none; }
    .main-container { padding: 36px 16px; }
}
