/* SocketSense Unified Design System - Minimalist Pro */
:root {
    --primary: #000000;
    --primary-hover: #333333;
    --accent: #6366f1;
    --bg: #ffffff;
    --surface: #ffffff;
    --border: #e5e7eb;
    --text-main: #000000;
    --text-muted: #6b7280;
    --glass: rgba(255, 255, 255, 0.8);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --radius: 12px;
}

body {
    background-color: var(--bg);
    color: var(--text-main);
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* Base document layout & typography */
html {
    font-size: 14px;
    position: relative;
    min-height: 100%;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

body {
    margin-bottom: 60px;
}

/* Layout */
.navbar {
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 1rem 0;
}

.navbar-brand {
    font-weight: 800;
    letter-spacing: -0.025em;
    color: var(--text-main) !important;
    font-size: 1.25rem;
}

.nav-link {
    color: var(--text-muted) !important;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.5rem 1rem !important;
    transition: color 0.2s;
}

.nav-link:hover {
    color: var(--text-main) !important;
}

/* Components */
.glass-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2.5rem;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.3s ease;
}

.glass-card:hover {
    box-shadow: var(--shadow-md);
}

h1, h2, h3 {
    font-weight: 800;
    letter-spacing: -0.025em;
    color: var(--text-main);
}

p {
    color: var(--text-muted);
}

/* Tables */
.modern-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.modern-table th {
    padding: 1rem;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border);
}

.modern-table td {
    padding: 1.25rem 1rem;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}

.user-name {
    font-weight: 600;
    color: var(--text-main);
    text-decoration: none;
}

.user-name:hover {
    color: var(--accent);
}

/* Forms */
.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.input-wrapper {
    position: relative;
}

.input-wrapper i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.9rem;
}

.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    background: #f9fafb;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 0.95rem;
    transition: all 0.2s;
}

.input-wrapper .form-control {
    padding-left: 2.75rem;
}

.form-control:focus {
    background: #ffffff;
    border-color: var(--text-main);
    box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.05);
    outline: none;
}

/* Bootstrap baseline tweaks */
.btn:focus,
.btn:active:focus,
.btn-link.nav-link:focus,
.form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.form-floating > .form-control-plaintext::placeholder,
.form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder,
.form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* Buttons */
.btn-primary {
    background: var(--primary);
    color: #ffffff;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all 0.2s;
    text-decoration: none;
    cursor: pointer;
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
}

.btn-secondary {
    background: #f1f5f9;
    color: #475569;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
}

.btn-delete, .btn-edit, .btn-reset {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: transparent;
    transition: all 0.2s;
    color: var(--text-muted);
}

.btn-edit:hover { background: #f3f4f6; color: var(--text-main); }
.btn-delete:hover { background: #fee2e2; color: #dc2626; border-color: #fee2e2; }
.btn-reset:hover { background: #fef3c7; color: #d97706; border-color: #fef3c7; }

/* Utilities */
.header-icon {
    width: 48px;
    height: 48px;
    background: #f3f4f6;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-main);
    font-size: 1.25rem;
}

.header-icon.lg { width: 64px; height: 64px; font-size: 1.75rem; }

.badge {
    font-weight: 600;
    padding: 0.35em 0.8em;
}

.animate-fade-in {
    animation: fadeIn 0.4s ease-out forwards;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Standalone Page Theme (Login/Success) */
.standalone-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fafafa;
    padding: 2rem;
}

.standalone-card {
    max-width: 450px;
    width: 100%;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 3.5rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.05);
}

.brand-logo {
    font-size: 2rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 2rem;
    color: var(--text-main);
    letter-spacing: -0.05em;
}

.brand-logo span { color: var(--accent); }

/* Footer */
.footer-link {
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.footer-link:hover {
    color: var(--text-main);
}

.footer-link.text-danger:hover {
    color: #dc2626 !important;
}
