/* Modern CSS for Cube - Dark Theme */

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #ff8c00;
    --primary-hover: #ff7700;
    --secondary-color: #ffa500;
    --dark-bg: #1e1e1e;
    --darker-bg: #141414;
    --card-bg: #2a2a2a;
    --card-hover: #323232;
    --light-bg: #363636;
    --text-primary: #e8e8e8;
    --text-secondary: #999999;
    --border-color: #3a3a3a;
    --success: #4caf50;
    --error: #f44336;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.4);
    --shadow-md: 0 2px 4px 0 rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 4px 8px 0 rgba(0, 0, 0, 0.6);
    --shadow-xl: 0 8px 16px 0 rgba(0, 0, 0, 0.7);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.5;
    color: var(--text-primary);
    background: var(--dark-bg);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0;
    font-size: 14px;
    overflow-x: hidden;
}

html {
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Navbar - Horde Square Style */
.navbar {
    background: var(--card-bg);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    padding: 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--primary-color);
    height: 50px;
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    padding: 0 1rem;
}

.nav-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--primary-color);
    font-weight: 700;
    font-size: 1.1rem;
}

.logo-icon {
    font-size: 1.3rem;
}

.logo-text {
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.nav-center {
    flex: 1;
    display: flex;
    justify-content: center;
}

.nav-icons {
    display: flex;
    gap: 0.25rem;
}

.nav-icon {
    padding: 0.4rem 0.8rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 1.1rem;
    transition: all 0.2s;
    border-radius: 3px;
}

.nav-icon:hover {
    background: var(--light-bg);
    color: var(--primary-color);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Icon Buttons */
.icon-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 3px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
}

.icon-btn:hover {
    background: var(--light-bg);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.icon {
    display: block;
}

.notification-btn {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 0.75rem;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 3px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
    height: 40px;
}

.notification-btn:hover {
    background: var(--light-bg);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.notification-btn:hover .icon {
    color: var(--primary-color);
}

.notification-text {
    font-size: 12px;
    font-weight: 500;
}

.notification-badge {
    background: var(--primary-color);
    color: var(--darker-bg);
    border-radius: 10px;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: 700;
    min-width: 18px;
    text-align: center;
    line-height: 1.2;
}

.notification-badge.zero {
    background: #444;
    color: #999;
}

.user-info {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 3px;
    transition: all 0.2s;
    cursor: pointer;
    height: 40px;
}

.user-info:hover {
    background: var(--light-bg);
    border-color: var(--primary-color);
}

.user-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
}

.user-name {
    color: var(--text-primary);
    font-weight: 500;
    font-size: 12px;
    white-space: nowrap;
}

.dropdown-arrow {
    color: var(--text-secondary);
    font-size: 10px;
    margin-left: 0.25rem;
}

/* User Dropdown Menu */
.user-dropdown {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    min-width: 180px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 3px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s;
    z-index: 1000;
}

.user-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: block;
    padding: 0.65rem 1rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.15s;
    font-size: 13px;
    border-left: 3px solid transparent;
}

.dropdown-item:hover {
    background: var(--light-bg);
    color: var(--text-primary);
    border-left-color: var(--primary-color);
}

.dropdown-divider {
    height: 1px;
    background: var(--border-color);
    margin: 0.4rem 0;
}

.btn-login {
    padding: 0.4rem 0.9rem;
    background: var(--primary-color);
    color: var(--darker-bg);
    text-decoration: none;
    border-radius: 3px;
    font-weight: 600;
    transition: all 0.2s;
    font-size: 13px;
}

.btn-login:hover {
    background: var(--primary-hover);
    box-shadow: 0 2px 6px rgba(255, 140, 0, 0.3);
}

/* Layout with Sidebar */
.layout {
    display: flex;
    flex: 1;
    min-height: calc(100vh - 50px);
    width: 100%;
    max-width: 100vw;
    padding-top: 50px;
}

/* Sidebar - Horde Square Style */
.sidebar {
    width: 180px;
    background: var(--card-bg);
    border-right: 1px solid var(--border-color);
    padding: 0.5rem 0;
    position: fixed;
    top: 50px;
    left: 0;
    height: calc(100vh - 50px);
    overflow-y: auto;
    z-index: 500;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
}

.sidebar-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.65rem 1rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.15s;
    border-left: 3px solid transparent;
    font-size: 13px;
}

.sidebar-item:hover {
    background: var(--light-bg);
    color: var(--text-primary);
}

.sidebar-item.active {
    background: var(--light-bg);
    color: var(--primary-color);
    border-left-color: var(--primary-color);
    font-weight: 500;
}

.sidebar-icon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.sidebar-label {
    font-size: 13px;
}

.sidebar-divider {
    height: 1px;
    background: var(--border-color);
    margin: 0.4rem 0.8rem;
}

/* Main Content Area */
.main-content {
    flex: 1;
    background: var(--darker-bg);
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    padding: 2rem;
    max-width: calc(100vw - 180px);
    margin-left: 180px;
    height: calc(100vh - 50px);
}

/* Old nav styles - remove these */
.nav-brand,
.nav-links {
    display: none;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 3px;
    transition: all 0.2s;
    border: none;
    cursor: pointer;
    text-align: center;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--darker-bg);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

/* OAuth Social Login Buttons */
.btn-eve {
    background: transparent;
    border: none;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s, transform 0.2s;
}

.btn-eve:hover {
    opacity: 0.85;
    transform: translateY(-1px);
    background: transparent;
    box-shadow: none;
}

.btn-eve img {
    width: 100%;
    height: auto;
}

.btn-discord {
    background: #5865F2;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 15px;
}

.btn-discord:hover {
    background: #4752C4;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(88, 101, 242, 0.4);
}

.btn-outline {
    background: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: var(--darker-bg);
}

.btn-lg {
    padding: 0.7rem 1.5rem;
    font-size: 14px;
}

.btn-block {
    display: block;
    width: 100%;
}

.btn-sm {
    padding: 0.4rem 0.8rem;
    font-size: 12px;
}

/* Auth Pages - Login/Register */
.auth-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: var(--darker-bg);
    min-height: calc(100vh - 50px);
}

.auth-card {
    background: var(--card-bg);
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    width: 100%;
    max-width: 420px;
    padding: 2rem;
    border: 1px solid var(--border-color);
}

.auth-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary-color);
    margin: 0 0 0.5rem 0;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.auth-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
    text-align: center;
    margin: 0 0 2rem 0;
}

.oauth-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 1.5rem 0;
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 600;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid var(--border-color);
}

.auth-divider span {
    padding: 0 1rem;
}

.auth-form {
    margin-bottom: 1.5rem;
}

.auth-footer {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
    font-size: 13px;
    color: var(--text-secondary);
}

.auth-footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Messages */
.messages-container {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 1000;
    max-width: 400px;
}

.alert {
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
    border-radius: 0.25rem;
    box-shadow: var(--shadow-lg);
    animation: slideIn 0.3s ease;
    background: var(--card-bg);
    border-left: 4px solid;
    font-weight: 500;
}

.alert-success {
    border-left-color: var(--success);
    color: var(--success);
}

.alert-error {
    border-left-color: var(--error);
    color: var(--error);
}

.alert-info {
    border-left-color: var(--primary-color);
    color: var(--primary-color);
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }2.5rem 0;
    text-align: center;
    background: linear-gradient(180deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 3px;
}

.hero-subtitle {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}

.hero-content {
    margin-top: 1.5rem;
}

.hero-content h2 {
    font-size: 1.75rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.button-group {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    margin-top: 1.5rem;
}

/* Features Section */
.features {
    background: var(--darker-bg);
    padding: 2.5rem 0;
}

.section-title {
    text-align: center;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2rem;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 1px;
}

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

.feature-card {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
    transition: all 0.2s;
    border: 1px solid var(--border-color);
}

.feature-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
    border-color: var(--primary-color);
    background: var(--card-hover);
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

.feature-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.5
    color: var(--primary-color);
}

.feature-card p {
    color: var(--text-secondary);
}

/* Auth Container */
.auth-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: var(--darker-bg);
}

.auth-card {
    background: var(--card-bg);
    padding: 3rem;
    border-radius: 0.25rem;
    box-shadow: var(--shadow-xl);
    width: 100%;
    max-width: 450px;
    border: 1px solid var(--border-color);
}

.auth-title {
    font-size: 2rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
    text-transform: uppercase;
}

.auth-subtitle {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

/* Forms */
.auth-form {
    margin-top: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-primary);
}

.form-input,
input[type="text"],
input[type="email"],
input[type="password"] {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: 0.25rem;
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
    background: var(--light-bg);
    color: var(--text-primary);
}

.form-input:focus,
input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(255, 140, 0, 0.2);
}

.form-help {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.form-errors,
.field-errors {
    color: var(--error);
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

.field-errors ul {
    list-style: none;
}

.auth-footer {
    text-align: center;
    margin-top: 2rem;
    color: var(--text-secondary);
}

.auth-footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Profile */
.profile-container {
    flex: 1;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 1.5rem;
    background: var(--darker-bg);
}

.profile-card {
    background: var(--card-bg);
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    width: 100%;
    max-width: 1000px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.profile-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--darker-bg);
    padding: 2rem 1.5rem;
    text-align: center;
}

.profile-avatar {
    width: 80px;
    height: 80px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 auto 0.75rem;
    border: 3px solid var(--darker-bg);
}

.profile-name {
    font-size: 1.75rem;
    margin-bottom: 0.4rem;
    text-transform: uppercase;
    font-weight: 700;
}

.profile-email {
    opacity: 0.9;
    font-size: 14px;
}

.profile-info {
    padding: 1.5rem;
    background: var(--card-bg);
}

.profile-info h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.info-grid {
    display: grid;
    gap: 0.75rem;
}

.info-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem;
    background: var(--light-bg);
    border-radius: 3px;
    border: 1px solid var(--border-color);
}

.info-label {
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 13px;
}

.info-value {
    color: var(--text-primary);
    font-size: 13px;
}

.profile-actions {
    padding: 1.5rem;
    display: flex;
    gap: 0.75ctions {
    padding: 2rem;
    display: flex;
    gap: 1rem;
    border-top: 1px solid var(--border-color);
}

/* EVE Online Characters Section */
.eve-characters-section {
    padding: 2rem;
    border-top: 1px solid var(--border-color);
    background: var(--darker-bg);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.section-header h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin: 0;
    text-transform: uppercase;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.eve-icon {
    margin-right: 0.25rem;
}

.characters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.character-card {
    background: var(--card-bg);
    border-radius: 0.25rem;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 2px solid var(--border-color);
}

.character-card.main-character {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 1px var(--primary-color), var(--shadow-md);
}

.character-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.character-header {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    background: var(--light-bg);
    gap: 1rem;
}

.character-portrait {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    border: 3px solid var(--primary-color);
    box-shadow: var(--shadow-md);
}

.character-info {
    flex: 1;
}

.character-name {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0 0 0.25rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.main-badge {
    background: var(--primary-color);
    color: var(--darker-bg);
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    display: inline-block;
    line-height: 1.2;
}

.character-id {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin: 0;
}

.character-details {
    padding: 1rem 1.5rem;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.detail-item:last-child {
    border-bottom: none;
}

.detail-icon {
    gap: 0.5rem;
    font-size: 1.125rem;
}

.detail-text {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.character-actions {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    background: var(--light-bg);
}

.btn-danger {
    background: var(--error);
    color: white;
}

.btn-danger:hover {
    background: #d32f2f;
    transform: translateY(-2px);
}

.no-characters {
    text-align: center;
    padding: 3rem 2rem;
    background: var(--card-bg);
    border-radius: 0.25rem;
    border: 2px dashed var(--border-color);
}

.no-characters-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.no-characters h4 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.no-characters p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

/* Footer */
.footer {
    background: var(--card-bg);
    padding: 1.5rem 0;
    text-align: center;
    color: var(--text-secondary);
    border-top: 2px solid var(--primary-color);
    font-size: 0.875rem;
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Responsive Design */
@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        left: -200px;
        transition: left 0.3s;
        z-index: 99;
    }
    
    .sidebar.open {
        left: 0;
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .search-input {
        width: 150px;
    }
    
    .search-input:focus {
        width: 180px;
    }
    
    .nav-center {
        display: none;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .auth-card {
        padding: 2rem;
    }
    
    .profile-actions {
        flex-direction: column;
    }
    
    .messages-container {
        right: 10px;
        left: 10px;
        max-width: none;
    }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Navbar */
.navbar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand a {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.nav-links a {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--primary-color);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.625rem 1.25rem;
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
    border-radius: 0.5rem;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-outline {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: white;
}

.btn-lg {
    padding: 0.875rem 2rem;
    font-size: 1.125rem;
}

.btn-block {
    display: block;
    width: 100%;
}

/* Messages */
.messages-container {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 1000;
    max-width: 400px;
}

.alert {
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow-lg);
    animation: slideIn 0.3s ease;
    background: white;
    border-left: 4px solid;
}

.alert-success {
    border-left-color: var(--success);
    color: var(--success);
}

.alert-error {
    border-left-color: var(--error);
    color: var(--error);
}

.alert-info {
    border-left-color: var(--primary-color);
    color: var(--primary-color);
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Hero Section */
.hero {
    padding: 4rem 0;
    text-align: center;
    color: white;
}

.hero-title {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-content {
    margin-top: 2rem;
}

.hero-content h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.button-group {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

/* Features Section */
.features {
    background: white;
    padding: 4rem 0;
    margin-top: 2rem;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: var(--shadow-md);
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid var(--border-color);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
}

/* Auth Container */
.auth-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.auth-card {
    background: white;
    padding: 3rem;
    border-radius: 1rem;
    box-shadow: var(--shadow-xl);
    width: 100%;
    max-width: 450px;
}

.auth-title {
    font-size: 2rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.auth-subtitle {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

/* Forms */
.auth-form {
    margin-top: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-primary);
}

.form-input,
input[type="text"],
input[type="email"],
input[type="password"] {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
    background: white;
}

.form-input:focus,
input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.form-help {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.form-errors,
.field-errors {
    color: var(--error);
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

.field-errors ul {
    list-style: none;
}

.auth-footer {
    text-align: center;
    margin-top: 2rem;
    color: var(--text-secondary);
}

.auth-footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Profile Page */
.profile-page {
    flex: 1;
    padding: 2rem;
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
}

.profile-header-bar {
    margin-bottom: 2rem;
}

.page-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Settings Layout */
.settings-layout {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.settings-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    align-items: start;
}

.settings-row .settings-card {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.settings-row .card-body {
    flex: 1;
}

.settings-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.settings-card.full-width {
    grid-column: 1 / -1;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    background: linear-gradient(180deg, var(--card-bg) 0%, var(--light-bg) 100%);
}

.card-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card-body {
    padding: 1.5rem;
}

.card-body.no-padding {
    padding: 0;
}

.card-footer {
    padding: 1.5rem;
    border-top: 1px solid var(--border-color);
    background: var(--darker-bg);
    display: flex;
    justify-content: flex-end;
}

/* Settings Form */
.settings-form {
    /* Form styling */
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.field-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.field-input {
    padding: 0.65rem 0.85rem;
    background: var(--dark-bg);
    border: 1px solid var(--border-color);
    border-radius: 3px;
    color: var(--text-primary);
    font-size: 13px;
    transition: all 0.2s;
}

.field-input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: var(--light-bg);
}

.field-value {
    padding: 0.65rem 0.85rem;
    background: var(--darker-bg);
    border: 1px solid var(--border-color);
    border-radius: 3px;
    color: var(--text-primary);
    font-size: 13px;
}

.field-value.readonly {
    opacity: 0.7;
}

.field-hint {
    font-size: 11px;
    color: var(--text-secondary);
    font-style: italic;
}

/* Account Section - Legacy (remove if not needed) */
.account-section {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.section-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0 0 1rem 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.account-form .form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-group label {
    font-size: 11px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.form-input {
    padding: 0.5rem 0.75rem;
    background: var(--dark-bg);
    border: 1px solid var(--border-color);
    border-radius: 3px;
    color: var(--text-primary);
    font-size: 13px;
    transition: all 0.2s;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.form-input[readonly] {
    opacity: 0.6;
    cursor: not-allowed;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
}

/* Characters Section */
.characters-section {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 1.5rem;
}

.section-header-inline {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

/* Characters Table */
.characters-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 13px;
    background: var(--card-bg);
}

.characters-table thead {
    background: var(--light-bg);
}

.characters-table th {
    padding: 1rem;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid var(--border-color);
    background: var(--darker-bg);
}

.characters-table tbody tr {
    border-bottom: 1px solid var(--border-color);
    transition: all 0.2s;
    background: var(--card-bg);
}

.characters-table tbody tr:hover {
    background: var(--light-bg);
}

.characters-table tbody tr.main-row {
    background: rgba(255, 140, 0, 0.08);
    border-left: 3px solid var(--primary-color);
}

.characters-table tbody tr.main-row:hover {
    background: rgba(255, 140, 0, 0.12);
}

.characters-table td {
    padding: 1rem;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.characters-table tbody tr:last-child td {
    border-bottom: none;
}

.token-status-icon {
    display: inline-block;
    vertical-align: middle;
}

.token-status-icon.valid {
    color: var(--success);
}

.token-status-icon.invalid {
    color: var(--error);
}

.sortable-table th.sortable {
    user-select: none;
    transition: background 0.2s;
    cursor: pointer;
}

.sortable-table th.sortable:hover {
    background: var(--card-hover);
    color: var(--text-primary);
}

.sort-arrow {
    margin-left: 0.25rem;
    font-size: 11px;
    color: var(--text-secondary);
    opacity: 0.6;
}

/* ========================================
   POPUP STYLES (Themed, Not Modal)
   ======================================== */

.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.popup-overlay[style*="display: none"] {
    display: none !important;
}

.popup-overlay[style*="display: flex"] {
    display: flex !important;
}

.popup-box {
    position: relative;
    background: var(--card-bg);
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    width: 90%;
    max-width: 480px;
    box-shadow: 0 0 40px rgba(255, 140, 0, 0.3), 0 8px 32px rgba(0, 0, 0, 0.8);
    animation: popupSlide 0.2s ease-out;
    margin: auto;
}

@keyframes popupSlide {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    background: linear-gradient(135deg, var(--darker-bg) 0%, var(--card-bg) 100%);
    border-bottom: 2px solid var(--primary-color);
}

.popup-header h3 {
    margin: 0;
    color: var(--primary-color);
    font-size: 1.15rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.popup-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    border-radius: 3px;
}

.popup-close:hover {
    color: var(--primary-color);
    background: var(--light-bg);
}

.popup-body {
    padding: 1.5rem;
}

.popup-footer {
    padding: 1.25rem 1.5rem;
    border-top: 1px solid var(--border-color);
    background: var(--darker-bg);
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
}

/* ========================================
   CHARACTER CARDS GRID
   ======================================== */

.characters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.5rem;
    padding: 1.5rem;
}

.character-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    transition: all 0.3s;
}

.character-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(255, 140, 0, 0.1);
    transform: translateY(-2px);
}

.character-card.main-character {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, var(--card-bg) 0%, rgba(255, 140, 0, 0.05) 100%);
}

.character-portrait-section {
    position: relative;
    display: flex;
    justify-content: center;
}

.character-portrait {
    width: 96px;
    height: 96px;
    border-radius: 8px;
    border: 2px solid var(--border-color);
    transition: border-color 0.2s;
}

.character-card:hover .character-portrait {
    border-color: var(--primary-color);
}

.main-badge-overlay {
    position: absolute;
    bottom: -8px;
    background: var(--primary-color);
    color: var(--darker-bg);
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.character-info-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.character-name {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    text-align: center;
}

.character-details {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.detail-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 12px;
    color: var(--text-secondary);
}

.detail-icon {
    color: var(--text-secondary);
    flex-shrink: 0;
}

.detail-icon.status-success {
    color: var(--success);
}

.detail-icon.status-error {
    color: var(--error);
}

.detail-row .status-success {
    color: var(--success);
    font-weight: 500;
}

.detail-row .status-error {
    color: var(--error);
    font-weight: 500;
}

.character-actions {
    display: flex;
    justify-content: center;
    padding-top: 0.5rem;
}

.character-actions .btn {
    flex: 1;
    max-width: 200px;
}

.char-portrait {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    border: 1px solid var(--border-color);
    object-fit: cover;
    display: block;
}

.char-name {
    font-weight: 500;
    font-size: 14px;
    color: var(--text-primary);
}

.text-secondary {
    color: var(--text-secondary);
}

.text-mono {
    font-family: 'Courier New', monospace;
    font-size: 12px;
    color: var(--text-secondary);
}

.action-buttons {
    justify-content: center;
}

.btn-xs {
    padding: 0.4rem 0.8rem;
    font-size: 11px;
    font-weight: 600
    padding: 0.3rem 0.6rem;
    font-size: 11px;
}

/* Empty State */
.empty-state {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 4rem 2rem;
    text-align: center;
}

.empty-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

/* Responsive */
@media (max-width: 768px) {
    .character-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .character-stats {
        justify-content: space-between;
    }
    
    .character-actions-row {
        justify-content: flex-end;
    }
}

/* Old Profile Styles - Remove if not needed */
.profile-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.profile-card {
    background: white;
    border-radius: 1rem;
    box-shadow: var(--shadow-xl);
    width: 100%;
    max-width: 600px;
    overflow: hidden;
}

.profile-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 3rem 2rem;
    text-align: center;
}

.profile-avatar {
    width: 100px;
    height: 100px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    font-weight: 700;
    margin: 0 auto 1rem;
    border: 4px solid white;
}

.profile-name {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.profile-email {
    opacity: 0.9;
}

.profile-info {
    padding: 2rem;
}

.profile-info h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.info-grid {
    display: grid;
    gap: 1rem;
}

.info-item {
    display: flex;
    justify-content: space-between;
    padding: 1rem;
    background: var(--light-bg);
    border-radius: 0.5rem;
}

.info-label {
    font-weight: 600;
    color: var(--text-secondary);
}

.info-value {
    color: var(--text-primary);
}

.profile-actions {
    padding: 2rem;
    display: flex;
    gap: 1rem;
    border-top: 1px solid var(--border-color);
}

/* EVE Online Characters Section */
.eve-characters-section {
    padding: 2rem;
    border-top: 1px solid var(--border-color);
    background: var(--light-bg);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.section-header h3 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin: 0;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.eve-icon {
    margin-right: 0.25rem;
}

.characters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.character-card {
    background: white;
    border-radius: 0.75rem;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 2px solid var(--border-color);
}

.character-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.character-header {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
    gap: 1rem;
}

.character-portrait {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: var(--shadow-md);
}

.character-info {
    flex: 1;
}

.character-name {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 0.25rem 0;
}

.character-id {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin: 0;
}

.character-details {
    padding: 1rem 1.5rem;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.detail-item:last-child {
    border-bottom: none;
}

.detail-icon {
    font-size: 1.125rem;
}

.detail-text {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.character-actions {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
}

.btn-danger {
    background: var(--error);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
    transform: translateY(-2px);
}

.no-characters {
    text-align: center;
    padding: 3rem 2rem;
    background: white;
    border-radius: 0.75rem;
    border: 2px dashed var(--border-color);
}

.no-characters-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.no-characters h4 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.no-characters p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

/* Footer */
.footer {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 2rem 0;
    margin-top: auto;
    text-align: center;
    color: var(--text-secondary);
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .auth-card {
        padding: 2rem;
    }
    
    .nav-links {
        gap: 1rem;
    }
    
    .profile-actions {
        flex-direction: column;
    }
    
    .messages-container {
        right: 10px;
        left: 10px;
        max-width: none;
    }
}

/* ========================================
   GROUP STYLES
   ======================================== */

/* Groups Grid */
.groups-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 25px;
}

.group-card {
    background: #2a2a2a;
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid #3a3a3a;
    transition: all 0.3s;
}

.group-card:hover {
    border-color: #ff8c00;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.group-header {
    background: linear-gradient(135deg, #333 0%, #2a2a2a 100%);
    padding: 20px 25px;
    border-bottom: 2px solid #3a3a3a;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.group-header h3 {
    margin: 0;
    color: #fff;
    font-size: 20px;
    font-weight: 600;
}

.group-body {
    padding: 25px;
}

.group-description {
    margin: 0 0 20px 0;
    color: #ddd;
    font-size: 14px;
    line-height: 1.6;
}

.group-description.empty {
    color: #666;
    font-style: italic;
}

.group-stats {
    display: flex;
    gap: 30px;
    padding-top: 15px;
    border-top: 1px solid #3a3a3a;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-value {
    color: #ff8c00;
    font-size: 24px;
    font-weight: 700;
}

.stat-label {
    color: #888;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.group-footer {
    padding: 20px 25px;
    background: #252525;
    border-top: 1px solid #3a3a3a;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Group Badges */
.auto-accept-badge {
    display: inline-block;
    background: #4caf50;
    color: #fff;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.admin-badge {
    display: inline-block;
    background: #ff8c00;
    color: #000;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.member-badge {
    display: inline-block;
    background: #555;
    color: #fff;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pending-badge {
    display: inline-block;
    background: #f0ad4e;
    color: #000;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Alert Box */
.alert {
    padding: 15px 20px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.alert-info {
    background: rgba(33, 150, 243, 0.1);
    border: 1px solid #2196f3;
    color: #64b5f6;
}

/* ========================================
   NOTIFICATIONS PAGE
   ======================================== */

.notifications-list {
    display: flex;
    flex-direction: column;
}

.notification-item {
    display: flex;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    transition: background 0.2s;
}

.notification-item:hover {
    background: var(--light-bg);
}

.notification-item:last-child {
    border-bottom: none;
}

.notification-item.unread {
    background: rgba(255, 140, 0, 0.05);
    border-left: 3px solid var(--primary-color);
}

.notification-item.unread:hover {
    background: rgba(255, 140, 0, 0.08);
}

.notification-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--darker-bg);
}

.notification-icon .icon-success {
    color: #4caf50;
}

.notification-icon .icon-error {
    color: #f44336;
}

.notification-icon .icon-warning {
    color: #ff9800;
}

.notification-icon .icon-info {
    color: #2196f3;
}

.notification-content {
    flex: 1;
    min-width: 0;
}

.notification-title {
    margin: 0 0 0.5rem 0;
    color: var(--text-primary);
    font-size: 15px;
    font-weight: 600;
}

.notification-message {
    margin: 0 0 0.5rem 0;
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.5;
}

.notification-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 12px;
    color: var(--text-secondary);
}

.notification-time {
    color: var(--text-secondary);
}

.notification-separator {
    color: var(--border-color);
}

.notification-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.notification-link:hover {
    text-decoration: underline;
}

.notification-actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

/* ========================================
   ACCOUNT INFO GRID
   ======================================== */

/* Account Info Grid */
.account-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
}

.info-item:nth-child(odd) {
    border-right: 1px solid var(--border-color);
}

.info-item:nth-last-child(-n+2) {
    border-bottom: none;
}

.info-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-value {
    font-size: 14px;
    color: var(--text-primary);
    font-weight: 500;
}

/* Email Edit Button */
.info-value-with-edit {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
}

.edit-icon-btn {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    cursor: pointer;
    padding: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s;
    opacity: 0;
    position: relative;
}

.info-item.email-item:hover .edit-icon-btn {
    opacity: 1;
}

.edit-icon-btn:hover {
    background: var(--light-bg);
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-1px);
}

.edit-icon-btn svg {
    width: 14px;
    height: 14px;
}

.edit-icon-btn::before {
    content: 'Edit Email';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--darker-bg);
    border: 1px solid var(--primary-color);
    color: var(--text-primary);
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 11px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
    margin-bottom: 8px;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.edit-icon-btn::after {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--primary-color);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
    margin-bottom: 2px;
    z-index: 1000;
}

.edit-icon-btn:hover::before,
.edit-icon-btn:hover::after {
    opacity: 1;
}

/* Groups Scroll Container */
.groups-scroll-container {
    max-height: 400px;
    overflow-y: auto;
}

.groups-scroll-container::-webkit-scrollbar {
    width: 8px;
}

.groups-scroll-container::-webkit-scrollbar-track {
    background: var(--darker-bg);
}

.groups-scroll-container::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

.groups-scroll-container::-webkit-scrollbar-thumb:hover {
    background: var(--light-bg);
}

/* Info Table (for Groups) */
.info-table {
    display: flex;
    flex-direction: column;
}

.info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    transition: background 0.2s;
}

.info-row:hover {
    background: var(--light-bg);
}

.info-row:last-child {
    border-bottom: none;
}

.info-cell {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.info-cell .info-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    text-transform: none;
    letter-spacing: normal;
}

.info-badges {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.member-count {
    font-size: 11px;
    color: var(--text-secondary);
}

.info-actions {
    display: flex;
    gap: 0.5rem;
}

/* ========================================
   MODAL STYLES
   ======================================== */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.85);
    z-index: 9999;
}

.modal[style*="display: flex"] {
    display: flex !important;
    align-items: center;
    justify-content: center;
}2px solid var(--primary-color);
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
    position: relative;
    margin: auto
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    margin: 0;
    color: var(--text-primary);
    font-size: 1.25rem;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 28px;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    padding: 1.5rem;
    border-top: 1px solid var(--border-color);
    background: var(--darker-bg);
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
}

/* ========================================
   ENHANCED TABLE STYLES
   ======================================== */

.characters-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 13px;
}

.characters-table thead {
    background: var(--light-bg);
}

.characters-table th {
    padding: 1rem;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid var(--border-color);
}

.characters-table tbody tr {
    border-bottom: 1px solid var(--border-color);
    transition: all 0.2s;
}

.characters-table tbody tr:hover {
    background: var(--light-bg);
}

.characters-table tbody tr.main-row {
    background: rgba(255, 140, 0, 0.05);
    border-left: 3px solid var(--primary-color);
}

.characters-table tbody tr.main-row:hover {
    background: rgba(255, 140, 0, 0.08);
}

.characters-table td {
    padding: 1rem;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-color);
}

.characters-table tbody tr:last-child td {
    border-bottom: none;
}

/* Notification unread highlight */
.unread-notification {
    background: rgba(255, 140, 0, 0.05);
}

.unread-notification:hover {
    background: rgba(255, 140, 0, 0.08);
}

/* ========================================
   EXPANDABLE SIDEBAR MENU
   ======================================== */

.sidebar-nav .sidebar-expandable {
    display: flex;
    flex-direction: column;
}

.sidebar-nav .sidebar-expandable .sidebar-parent {
    cursor: pointer;
}

.sidebar-nav .sidebar-expandable .sidebar-arrow {
    margin-left: auto;
    transition: transform 0.2s;
}

.sidebar-nav .sidebar-expandable.expanded .sidebar-arrow {
    transform: rotate(180deg);
}

.sidebar-nav .sidebar-submenu {
    display: none;
    flex-direction: column;
    background: var(--darker-bg);
}

.sidebar-nav .sidebar-expandable.expanded .sidebar-submenu {
    display: flex;
}

.sidebar-nav .sidebar-submenu .sidebar-subitem {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 1rem 0.55rem 2.5rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 13px;
    transition: all 0.15s;
    border-left: 3px solid transparent;
}

.sidebar-nav .sidebar-submenu .sidebar-subitem:hover {
    background: var(--light-bg);
    color: var(--text-primary);
}

.sidebar-nav .sidebar-submenu .sidebar-subitem.active {
    background: var(--light-bg);
    color: var(--primary-color);
    border-left-color: var(--primary-color);
    font-weight: 500;
}
