:root {
    --bg-color: #0f172a;
    --card-bg: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --accent: #3b82f6;
    --accent-hover: #2563eb;
    --danger: #ef4444;
    --success: #22c55e;
    --nav-height: 64px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
}

/* Navigation */
.fixed-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--nav-height);
    background: rgba(30, 41, 59, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1000;
}

.nav-content {
    max-width: 95%;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
}

.logo {
    font-weight: 600;
    font-size: 1.25rem;
    color: var(--text-primary);
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--text-primary);
}


.mapper-link.active {
    background: rgba(59, 130, 246, 0.25);
    border-color: var(--accent);
}

.logout-btn {
    color: var(--danger) !important;
}

/* Layout */
.content-wrapper {
    margin-top: var(--nav-height);
    padding: 2rem;
    max-width: 95%;
    margin-left: auto;
    margin-right: auto;
    min-height: calc(100vh - var(--nav-height));
}

/* Form Elements */
select {
    background: rgba(0, 0, 0, 0.4) !important;
    color: var(--text-primary) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    padding: 0.5rem;
    border-radius: 0.5rem;
    width: 100%;
}

select option {
    background: rgba(20, 30, 48, 0.95);
    color: var(--text-primary);
    padding: 0.5rem;
}

select option:hover,
select option:checked {
    background: rgba(59, 130, 246, 0.3);
}

/* Choices.js overrides */
.choices {
    width: 100%;
    margin-bottom: 0;
}

.choices__inner {
    background: rgba(0, 0, 0, 0.4) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 0.5rem !important;
    padding: 0.25rem 0.5rem !important;
    min-height: auto !important;
    color: var(--text-primary) !important;
}

.choices__input {
    background: transparent !important;
    color: var(--text-primary) !important;
}

.choices__list--dropdown {
    background: #1e293b !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: var(--text-primary) !important;
}

.choices__item--choice {
    color: var(--text-primary) !important;
}

.choices__item--choice.is-highlighted {
    background: rgba(59, 130, 246, 0.3) !important;
}

/* Login */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 80vh;
}
.login-card {
    background: var(--card-bg);
    padding: 2.5rem;
    border-radius: 1rem;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.login-card h1 {
    margin-bottom: 2rem;
    text-align: center;
    font-weight: 600;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-family: inherit;
    transition: border-color 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent);
}

.btn {
    width: 100%;
    padding: 0.75rem;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.btn:hover {
    background: var(--accent-hover);
}

/* Flash Messages */
.flash-messages {
    margin-bottom: 2rem;
}

.flash-message {
    padding: 1rem;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: #fca5a5;
    border-radius: 0.5rem;
    text-align: center;
}
/* Table Column Widths */
.col-checkbox { width: 3%; }
.col-symbol { width: 7%; }
.col-original-name { width: 15%; }
.col-original-group { width: 20%; }
.col-new-group { width: 20%; }
.col-new-code { width: 15%; }
.col-new-name { width: 21%; }

/* Select Wrapper */
.select-wrapper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
}

.choices {
    flex-grow: 1;
    width: auto !important;
}
