/**
 * Hive Dark Theme - "Obsidian"
 * Version: 1.0.0
 *
 * 모던하고 세련된 다크 테마
 * 어두운 네이비 기반의 전문적인 디자인
 */

/* ========================================
   CSS Variables (Design Tokens)
   ======================================== */
:root {
    /* Base Colors */
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    --bg-elevated: #475569;

    /* Border Colors */
    --border-default: #334155;
    --border-light: #475569;
    --border-subtle: #1e293b;

    /* Text Colors */
    --text-primary: #e2e8f0;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --text-disabled: #475569;

    /* Accent Colors */
    --accent-gold: #fbbf24;
    --accent-gold-border: #c9a227;
    --accent-blue: #3b82f6;
    --accent-blue-light: #93c5fd;
    --accent-blue-dark: #2563eb;
    --accent-emerald: #10b981;
    --accent-emerald-light: #6ee7b7;
    --accent-indigo: #6366f1;
    --accent-indigo-light: #a5b4fc;
    --accent-amber: #f59e0b;
    --accent-red: #ef4444;
    --accent-red-light: #fca5a5;
    --accent-purple: #8b5cf6;
    --accent-purple-light: #c4b5fd;

    /* Status Colors */
    --status-online: #10b981;
    --status-away: #f59e0b;
    --status-busy: #ef4444;
    --status-offline: #6b7280;

    /* Typography */
    --font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', Consolas, monospace;

    /* Font Sizes */
    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;
    --text-3xl: 1.875rem;
    --text-4xl: 2.25rem;

    /* Spacing */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;

    /* Border Radius */
    --radius-none: 0;
    --radius-sm: 2px;
    --radius-default: 4px;
    --radius-md: 6px;
    --radius-lg: 8px;
    --radius-xl: 12px;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-default: 0 2px 4px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.4);
    --shadow-xl: 0 16px 32px rgba(0, 0, 0, 0.5);

    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-default: 0.2s ease;
    --transition-slow: 0.3s ease;

    /* Z-Index */
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-fixed: 300;
    --z-modal-backdrop: 400;
    --z-modal: 500;
    --z-popover: 600;
    --z-tooltip: 700;
    --z-toast: 800;
}

/* ========================================
   Reset & Base
   ======================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-family);
    font-size: var(--text-base);
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-primary);
    min-height: 100vh;
}

/* ========================================
   Typography
   ======================================== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 300;
    letter-spacing: 0.02em;
    color: var(--text-primary);
    margin-bottom: var(--space-4);
}

h1 { font-size: var(--text-3xl); }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-lg); }
h5 { font-size: var(--text-base); font-weight: 500; }
h6 { font-size: var(--text-sm); font-weight: 500; }

p {
    margin-bottom: var(--space-4);
    color: var(--text-secondary);
}

a {
    color: var(--accent-blue-light);
    text-decoration: none;
    transition: color var(--transition-default);
}

a:hover {
    color: var(--accent-blue);
}

small {
    font-size: var(--text-sm);
    color: var(--text-muted);
}

code {
    font-family: var(--font-mono);
    font-size: 0.9em;
    background: var(--bg-tertiary);
    padding: 0.125rem 0.375rem;
    border-radius: var(--radius-sm);
    color: var(--accent-purple-light);
}

pre {
    font-family: var(--font-mono);
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    padding: var(--space-4);
    overflow-x: auto;
}

/* ========================================
   Buttons
   ======================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: 0.625rem 1.25rem;
    font-family: var(--font-family);
    font-size: var(--text-sm);
    font-weight: 500;
    line-height: 1;
    border-radius: var(--radius-default);
    cursor: pointer;
    transition: all var(--transition-default);
    text-decoration: none;
    border: 1px solid transparent;
    white-space: nowrap;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Primary Button */
.btn-primary {
    background: var(--accent-blue);
    color: white;
    border-color: var(--accent-blue);
}

.btn-primary:hover:not(:disabled) {
    background: var(--accent-blue-dark);
    border-color: var(--accent-blue-dark);
    transform: translateY(-1px);
}

/* Secondary Button */
.btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border-color: var(--border-default);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--bg-tertiary);
    border-color: var(--border-light);
    color: var(--text-primary);
}

/* Ghost Button */
.btn-ghost {
    background: transparent;
    color: var(--text-muted);
    border: none;
    padding: 0.5rem 0.75rem;
}

.btn-ghost:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

/* Danger Button */
.btn-danger {
    background: var(--accent-red);
    color: white;
    border-color: var(--accent-red);
}

.btn-danger:hover:not(:disabled) {
    background: #dc2626;
    border-color: #dc2626;
}

/* Success Button */
.btn-success {
    background: var(--accent-emerald);
    color: white;
    border-color: var(--accent-emerald);
}

.btn-success:hover:not(:disabled) {
    background: #059669;
    border-color: #059669;
}

/* Button Sizes */
.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: var(--text-xs);
}

.btn-lg {
    padding: 0.875rem 1.75rem;
    font-size: var(--text-base);
}

.btn-icon {
    width: 36px;
    height: 36px;
    padding: 0;
}

.btn-icon.btn-sm {
    width: 28px;
    height: 28px;
}

.btn-icon.btn-lg {
    width: 44px;
    height: 44px;
}

/* ========================================
   Form Elements
   ======================================== */
.form-group {
    margin-bottom: var(--space-4);
}

.form-label {
    display: block;
    margin-bottom: var(--space-2);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--text-secondary);
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 0.625rem 0.875rem;
    font-family: var(--font-family);
    font-size: var(--text-base);
    color: var(--text-primary);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-default);
    transition: all var(--transition-default);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: var(--text-disabled);
}

.form-input:disabled,
.form-select:disabled,
.form-textarea:disabled {
    background: var(--bg-secondary);
    color: var(--text-muted);
    cursor: not-allowed;
}

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

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    padding-right: 2.5rem;
}

/* Checkbox & Radio */
.form-check {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    cursor: pointer;
}

.form-check-input {
    width: 18px;
    height: 18px;
    accent-color: var(--accent-blue);
    cursor: pointer;
}

.form-check-label {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    cursor: pointer;
}

/* Form Error */
.form-error {
    margin-top: var(--space-1);
    font-size: var(--text-sm);
    color: var(--accent-red);
}

.form-input.error,
.form-select.error,
.form-textarea.error {
    border-color: var(--accent-red);
}

/* ========================================
   Cards
   ======================================== */
.card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    transition: border-color var(--transition-default);
}

.card:hover {
    border-color: var(--border-light);
}

.card-header {
    padding: var(--space-4) var(--space-5);
    border-bottom: 1px solid var(--border-subtle);
}

.card-title {
    font-size: var(--text-lg);
    font-weight: 500;
    margin-bottom: 0;
}

.card-body {
    padding: var(--space-5);
}

.card-footer {
    padding: var(--space-4) var(--space-5);
    border-top: 1px solid var(--border-subtle);
    background: rgba(0, 0, 0, 0.1);
}

/* ========================================
   Tables
   ======================================== */
.table-container {
    overflow-x: auto;
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    font-weight: 500;
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: var(--space-3) var(--space-4);
    text-align: left;
    border-bottom: 1px solid var(--border-default);
    white-space: nowrap;
}

.table td {
    padding: var(--space-3) var(--space-4);
    border-bottom: 1px solid var(--border-subtle);
    color: var(--text-primary);
    vertical-align: middle;
}

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

.table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.table-striped tr:nth-child(even) td {
    background: rgba(0, 0, 0, 0.1);
}

/* ========================================
   Badges & Tags
   ======================================== */
.badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    padding: 0.25rem 0.625rem;
    font-size: var(--text-xs);
    font-weight: 500;
    border-radius: var(--radius-full);
    white-space: nowrap;
}

.badge-primary {
    background: rgba(59, 130, 246, 0.2);
    color: var(--accent-blue-light);
}

.badge-success {
    background: rgba(16, 185, 129, 0.2);
    color: var(--accent-emerald-light);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.2);
    color: var(--accent-amber);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.2);
    color: var(--accent-red-light);
}

.badge-info {
    background: rgba(99, 102, 241, 0.2);
    color: var(--accent-indigo-light);
}

.badge-neutral {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
}

/* ========================================
   Modals
   ======================================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: var(--z-modal-backdrop);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-default);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--bg-primary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    max-width: 90vw;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transform: scale(0.95);
    transition: transform var(--transition-default);
}

.modal-overlay.active .modal {
    transform: scale(1);
}

.modal-sm { width: 400px; }
.modal-md { width: 560px; }
.modal-lg { width: 720px; }
.modal-xl { width: 900px; }

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

.modal-title {
    font-size: var(--text-lg);
    font-weight: 400;
    letter-spacing: 0.03em;
    margin: 0;
}

.modal-close {
    background: transparent;
    border: 1px solid var(--border-default);
    color: var(--text-muted);
    width: 32px;
    height: 32px;
    border-radius: var(--radius-default);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-default);
}

.modal-close:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border-light);
}

.modal-body {
    padding: var(--space-6);
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: var(--space-3);
    padding: var(--space-4) var(--space-6);
    border-top: 1px solid var(--border-subtle);
    background: rgba(0, 0, 0, 0.1);
}

/* ========================================
   Navigation
   ======================================== */
.nav {
    display: flex;
    gap: var(--space-1);
}

.nav-vertical {
    flex-direction: column;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-4);
    color: var(--text-muted);
    border-radius: var(--radius-default);
    transition: all var(--transition-default);
    text-decoration: none;
    font-size: var(--text-sm);
}

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

.nav-item.active {
    background: var(--bg-tertiary);
    color: var(--accent-blue-light);
}

.nav-item i {
    width: 20px;
    text-align: center;
}

/* ========================================
   Tabs
   ======================================== */
.tabs {
    display: flex;
    border-bottom: 1px solid var(--border-default);
}

.tab {
    padding: var(--space-3) var(--space-4);
    color: var(--text-muted);
    font-size: var(--text-sm);
    font-weight: 500;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    transition: all var(--transition-default);
}

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

.tab.active {
    color: var(--accent-blue-light);
    border-bottom-color: var(--accent-blue);
}

/* ========================================
   Dropdowns
   ======================================== */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 180px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: var(--space-2);
    z-index: var(--z-dropdown);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all var(--transition-default);
}

.dropdown-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(4px);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-3);
    color: var(--text-secondary);
    font-size: var(--text-sm);
    border-radius: var(--radius-default);
    cursor: pointer;
    transition: all var(--transition-fast);
}

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

.dropdown-divider {
    height: 1px;
    background: var(--border-subtle);
    margin: var(--space-2) 0;
}

/* ========================================
   Alerts / Notifications
   ======================================== */
.alert {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    padding: var(--space-4);
    border-radius: var(--radius-md);
    border: 1px solid;
}

.alert-info {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
    color: var(--accent-blue-light);
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.3);
    color: var(--accent-emerald-light);
}

.alert-warning {
    background: rgba(245, 158, 11, 0.1);
    border-color: rgba(245, 158, 11, 0.3);
    color: var(--accent-amber);
}

.alert-danger {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: var(--accent-red-light);
}

/* ========================================
   Avatar
   ======================================== */
.avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-default);
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    font-weight: 500;
    overflow: hidden;
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-xs { width: 24px; height: 24px; font-size: var(--text-xs); }
.avatar-sm { width: 32px; height: 32px; font-size: var(--text-sm); }
.avatar-md { width: 40px; height: 40px; font-size: var(--text-base); }
.avatar-lg { width: 48px; height: 48px; font-size: var(--text-lg); }
.avatar-xl { width: 64px; height: 64px; font-size: var(--text-xl); }

.avatar-circle {
    border-radius: var(--radius-full);
}

/* Avatar with status indicator */
.avatar-wrapper {
    position: relative;
    display: inline-block;
}

.avatar-status {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 12px;
    height: 12px;
    border-radius: var(--radius-full);
    border: 2px solid var(--bg-secondary);
}

.avatar-status.online { background: var(--status-online); }
.avatar-status.away { background: var(--status-away); }
.avatar-status.busy { background: var(--status-busy); }
.avatar-status.offline { background: var(--status-offline); }

/* ========================================
   Progress
   ======================================== */
.progress {
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--accent-blue);
    border-radius: var(--radius-full);
    transition: width var(--transition-slow);
}

.progress-bar.success { background: var(--accent-emerald); }
.progress-bar.warning { background: var(--accent-amber); }
.progress-bar.danger { background: var(--accent-red); }

/* ========================================
   Tooltips
   ======================================== */
[data-tooltip] {
    position: relative;
}

[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-4px);
    padding: var(--space-2) var(--space-3);
    background: var(--bg-elevated);
    color: var(--text-primary);
    font-size: var(--text-xs);
    white-space: nowrap;
    border-radius: var(--radius-default);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-fast);
    z-index: var(--z-tooltip);
}

[data-tooltip]:hover::after {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-8px);
}

/* ========================================
   Loading / Spinner
   ======================================== */
.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--bg-tertiary);
    border-top-color: var(--accent-blue);
    border-radius: var(--radius-full);
    animation: spin 0.8s linear infinite;
}

.spinner-sm { width: 14px; height: 14px; border-width: 2px; }
.spinner-lg { width: 32px; height: 32px; border-width: 3px; }

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.skeleton {
    background: linear-gradient(
        90deg,
        var(--bg-tertiary) 25%,
        var(--bg-elevated) 50%,
        var(--bg-tertiary) 75%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: var(--radius-default);
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ========================================
   Empty State
   ======================================== */
.empty-state {
    text-align: center;
    padding: var(--space-12) var(--space-6);
    color: var(--text-muted);
}

.empty-state i {
    font-size: var(--text-4xl);
    margin-bottom: var(--space-4);
    opacity: 0.3;
}

.empty-state p {
    margin-bottom: var(--space-4);
}

/* ========================================
   Dividers
   ======================================== */
.divider {
    height: 1px;
    background: var(--border-subtle);
    margin: var(--space-4) 0;
}

.divider-vertical {
    width: 1px;
    height: 100%;
    background: var(--border-subtle);
    margin: 0 var(--space-4);
}

.divider-text {
    display: flex;
    align-items: center;
    color: var(--text-muted);
    font-size: var(--text-sm);
}

.divider-text::before,
.divider-text::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-subtle);
}

.divider-text::before {
    margin-right: var(--space-3);
}

.divider-text::after {
    margin-left: var(--space-3);
}

/* ========================================
   Utility Classes
   ======================================== */

/* Display */
.d-none { display: none !important; }
.d-block { display: block !important; }
.d-flex { display: flex !important; }
.d-inline-flex { display: inline-flex !important; }
.d-grid { display: grid !important; }

/* Flex */
.flex-column { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.justify-start { justify-content: flex-start; }
.justify-center { justify-content: center; }
.justify-end { justify-content: flex-end; }
.justify-between { justify-content: space-between; }
.align-start { align-items: flex-start; }
.align-center { align-items: center; }
.align-end { align-items: flex-end; }
.flex-1 { flex: 1; }
.flex-shrink-0 { flex-shrink: 0; }

/* Gap */
.gap-1 { gap: var(--space-1); }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-5 { gap: var(--space-5); }
.gap-6 { gap: var(--space-6); }

/* Text */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.text-primary { color: var(--text-primary) !important; }
.text-secondary { color: var(--text-secondary) !important; }
.text-muted { color: var(--text-muted) !important; }
.text-success { color: var(--accent-emerald-light) !important; }
.text-warning { color: var(--accent-amber) !important; }
.text-danger { color: var(--accent-red-light) !important; }
.text-info { color: var(--accent-blue-light) !important; }
.text-gold { color: var(--accent-gold) !important; }

.font-light { font-weight: 300; }
.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.text-xs { font-size: var(--text-xs); }
.text-sm { font-size: var(--text-sm); }
.text-base { font-size: var(--text-base); }
.text-lg { font-size: var(--text-lg); }
.text-xl { font-size: var(--text-xl); }
.text-2xl { font-size: var(--text-2xl); }

.uppercase { text-transform: uppercase; }
.capitalize { text-transform: capitalize; }
.truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Spacing */
.m-0 { margin: 0 !important; }
.m-1 { margin: var(--space-1) !important; }
.m-2 { margin: var(--space-2) !important; }
.m-3 { margin: var(--space-3) !important; }
.m-4 { margin: var(--space-4) !important; }
.m-auto { margin: auto !important; }

.mt-0 { margin-top: 0 !important; }
.mt-1 { margin-top: var(--space-1) !important; }
.mt-2 { margin-top: var(--space-2) !important; }
.mt-3 { margin-top: var(--space-3) !important; }
.mt-4 { margin-top: var(--space-4) !important; }

.mb-0 { margin-bottom: 0 !important; }
.mb-1 { margin-bottom: var(--space-1) !important; }
.mb-2 { margin-bottom: var(--space-2) !important; }
.mb-3 { margin-bottom: var(--space-3) !important; }
.mb-4 { margin-bottom: var(--space-4) !important; }

.p-0 { padding: 0 !important; }
.p-1 { padding: var(--space-1) !important; }
.p-2 { padding: var(--space-2) !important; }
.p-3 { padding: var(--space-3) !important; }
.p-4 { padding: var(--space-4) !important; }
.p-5 { padding: var(--space-5) !important; }
.p-6 { padding: var(--space-6) !important; }

/* Width/Height */
.w-full { width: 100%; }
.h-full { height: 100%; }
.min-h-screen { min-height: 100vh; }

/* Border */
.border { border: 1px solid var(--border-default); }
.border-0 { border: none !important; }
.rounded { border-radius: var(--radius-default); }
.rounded-md { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-full { border-radius: var(--radius-full); }

/* Background */
.bg-primary { background: var(--bg-primary); }
.bg-secondary { background: var(--bg-secondary); }
.bg-tertiary { background: var(--bg-tertiary); }

/* Cursor */
.cursor-pointer { cursor: pointer; }
.cursor-not-allowed { cursor: not-allowed; }

/* Overflow */
.overflow-auto { overflow: auto; }
.overflow-hidden { overflow: hidden; }
.overflow-x-auto { overflow-x: auto; }
.overflow-y-auto { overflow-y: auto; }

/* Position */
.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.sticky { position: sticky; }

/* Visibility */
.invisible { visibility: hidden; }
.visible { visibility: visible; }
.opacity-0 { opacity: 0; }
.opacity-50 { opacity: 0.5; }
.opacity-100 { opacity: 1; }

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 768px) {
    :root {
        --text-base: 0.9375rem;
        --space-4: 0.875rem;
        --space-6: 1.25rem;
    }

    .hide-mobile {
        display: none !important;
    }

    .btn {
        padding: 0.5rem 1rem;
    }
}

@media (min-width: 769px) {
    .hide-desktop {
        display: none !important;
    }
}

/* ========================================
   Scrollbar
   ======================================== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--bg-elevated);
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--bg-tertiary) var(--bg-primary);
}

/* ========================================
   Selection
   ======================================== */
::selection {
    background: rgba(59, 130, 246, 0.3);
    color: var(--text-primary);
}

/* ========================================
   Focus Visible
   ======================================== */
:focus-visible {
    outline: 2px solid var(--accent-blue);
    outline-offset: 2px;
}
