/* SociTask Design System — Minimal Premium */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&display=swap');

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

:root {
  --black: #0a0a0a;
  --white: #ffffff;
  --gray-50: #fafafa;
  --gray-100: #f5f5f5;
  --gray-200: #e5e5e5;
  --gray-300: #d4d4d4;
  --gray-400: #a3a3a3;
  --gray-500: #737373;
  --gray-600: #525252;
  --gray-700: #404040;
  --gray-800: #262626;
  --gray-900: #171717;
  --accent: #6366f1;
  --accent-light: #818cf8;
  --accent-dark: #4f46e5;
  --accent-bg: #eef2ff;
  --success: #10b981;
  --success-bg: #ecfdf5;
  --warning: #f59e0b;
  --warning-bg: #fffbeb;
  --danger: #ef4444;
  --danger-bg: #fef2f2;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow-md: 0 4px 12px rgba(0,0,0,.08);
  --transition: 0.2s ease;
}

html { font-size: 16px; }
body { font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; background: var(--gray-100); color: var(--gray-800); line-height: 1.6; -webkit-font-smoothing: antialiased; }

/* Layout */
.app-layout { min-height: 100vh; display: flex; flex-direction: column; }
.main-content { flex: 1; padding: 2rem 1rem; max-width: 1200px; margin: 0 auto; width: 100%; }
@media (min-width: 768px) { .main-content { padding: 2.5rem 2rem; } }
@media (min-width: 1024px) { .main-content { padding: 3rem; } }

/* Nav */
.nav { background: var(--white); border-bottom: 1px solid var(--gray-200); position: sticky; top: 0; z-index: 100; }
.nav-inner { max-width: 1200px; margin: 0 auto; padding: 0 1rem; display: flex; align-items: center; justify-content: space-between; height: 60px; }
.nav-brand { font-weight: 600; font-size: 1.1rem; color: var(--black); text-decoration: none; letter-spacing: -0.02em; }
.nav-brand span { color: var(--accent); }
.nav-actions { display: flex; align-items: center; gap: 0.75rem; }
.nav-link { color: var(--gray-500); text-decoration: none; font-size: 0.875rem; font-weight: 500; transition: color var(--transition); }
.nav-link:hover { color: var(--black); }

/* Notification bell */
.notif-bell { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: var(--radius-sm); color: var(--gray-500); text-decoration: none; transition: all var(--transition); }
.notif-bell:hover { background: var(--gray-100); color: var(--black); }
.notif-bell svg { width: 20px; height: 20px; }
.notif-badge { position: absolute; top: 4px; right: 4px; background: var(--danger); color: white; font-size: 10px; font-weight: 700; width: 16px; height: 16px; border-radius: 50%; display: flex; align-items: center; justify-content: center; border: 2px solid var(--white); }
.notif-badge.hidden { display: none; }

/* Cards */
.card { background: var(--white); border-radius: var(--radius); border: 1px solid var(--gray-200); padding: 1.5rem; }
.card-lg { padding: 2rem; }
.card-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.25rem; }
.card-title { font-size: 1rem; font-weight: 600; color: var(--gray-900); letter-spacing: -0.01em; }
.card-subtitle { font-size: 0.875rem; color: var(--gray-500); margin-top: 0.25rem; }

/* Stats grid */
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 2rem; }
@media (min-width: 768px) { .stats-grid { grid-template-columns: repeat(4, 1fr); } }
.stat-card { background: var(--white); border-radius: var(--radius); border: 1px solid var(--gray-200); padding: 1.25rem; }
.stat-label { font-size: 0.75rem; font-weight: 500; color: var(--gray-500); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 0.5rem; }
.stat-value { font-size: 1.75rem; font-weight: 300; color: var(--gray-900); letter-spacing: -0.03em; }
.stat-value.accent { color: var(--accent); }
.stat-value.success { color: var(--success); }
.stat-sub { font-size: 0.75rem; color: var(--gray-400); margin-top: 0.25rem; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.625rem 1.25rem; border-radius: var(--radius-sm); font-size: 0.875rem; font-weight: 500; cursor: pointer; border: none; transition: all var(--transition); text-decoration: none; white-space: nowrap; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-primary { background: var(--black); color: var(--white); }
.btn-primary:hover:not(:disabled) { background: var(--gray-800); }
.btn-accent { background: var(--accent); color: var(--white); }
.btn-accent:hover:not(:disabled) { background: var(--accent-dark); }
.btn-outline { background: transparent; color: var(--gray-700); border: 1px solid var(--gray-200); }
.btn-outline:hover:not(:disabled) { border-color: var(--gray-400); color: var(--black); }
.btn-ghost { background: transparent; color: var(--gray-500); }
.btn-ghost:hover:not(:disabled) { background: var(--gray-100); color: var(--black); }
.btn-danger { background: var(--danger); color: var(--white); }
.btn-danger:hover:not(:disabled) { background: #dc2626; }
.btn-success { background: var(--success); color: var(--white); }
.btn-sm { padding: 0.375rem 0.75rem; font-size: 0.8125rem; }
.btn-lg { padding: 0.875rem 1.75rem; font-size: 1rem; }
.btn-full { width: 100%; }

/* Forms */
.form-group { margin-bottom: 1.25rem; }
.form-label { display: block; font-size: 0.875rem; font-weight: 500; color: var(--gray-700); margin-bottom: 0.5rem; }
.form-input { width: 100%; padding: 0.625rem 0.875rem; border: 1px solid var(--gray-200); border-radius: var(--radius-sm); font-size: 0.875rem; color: var(--gray-900); background: var(--white); transition: border-color var(--transition); outline: none; font-family: inherit; }
.form-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(99,102,241,.1); }
.form-input::placeholder { color: var(--gray-400); }
.form-select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 0.75rem center; background-size: 16px; padding-right: 2.5rem; }
.form-hint { font-size: 0.75rem; color: var(--gray-400); margin-top: 0.375rem; }
.form-error { font-size: 0.75rem; color: var(--danger); margin-top: 0.375rem; }
textarea.form-input { resize: vertical; min-height: 80px; }

/* Tables */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
thead { background: var(--gray-50); }
th { padding: 0.75rem 1rem; text-align: left; font-size: 0.75rem; font-weight: 600; color: var(--gray-500); text-transform: uppercase; letter-spacing: 0.04em; border-bottom: 1px solid var(--gray-200); white-space: nowrap; }
td { padding: 0.875rem 1rem; border-bottom: 1px solid var(--gray-100); color: var(--gray-700); vertical-align: middle; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: var(--gray-50); }

/* Badges */
.badge { display: inline-flex; align-items: center; padding: 0.2rem 0.6rem; border-radius: 999px; font-size: 0.75rem; font-weight: 500; }
.badge-active, .badge-approved, .badge-completed { background: var(--success-bg); color: #065f46; }
.badge-draft, .badge-pending, .badge-in_progress, .badge-submitted { background: var(--warning-bg); color: #92400e; }
.badge-paused, .badge-rejected, .badge-cancelled { background: var(--danger-bg); color: #991b1b; }
.badge-gray, .badge-admin { background: var(--gray-100); color: var(--gray-600); }
.badge-accent { background: var(--accent-bg); color: var(--accent-dark); }

/* Page header */
.page-header { margin-bottom: 2rem; }
.page-title { font-size: 1.75rem; font-weight: 300; color: var(--gray-900); letter-spacing: -0.03em; }
@media (min-width: 768px) { .page-title { font-size: 2.25rem; } }
.page-desc { font-size: 0.9375rem; color: var(--gray-500); margin-top: 0.5rem; }

/* Alerts */
.alert { padding: 0.875rem 1rem; border-radius: var(--radius-sm); font-size: 0.875rem; margin-bottom: 1rem; }
.alert-success { background: var(--success-bg); color: #065f46; border: 1px solid #6ee7b7; }
.alert-error { background: var(--danger-bg); color: #991b1b; border: 1px solid #fca5a5; }
.alert-warning { background: var(--warning-bg); color: #92400e; border: 1px solid #fcd34d; }
.alert-info { background: var(--accent-bg); color: var(--accent-dark); border: 1px solid #a5b4fc; }

/* Empty state */
.empty { text-align: center; padding: 3rem 1rem; color: var(--gray-400); }
.empty-icon { font-size: 2.5rem; margin-bottom: 1rem; }
.empty p { font-size: 0.9375rem; }

/* Auth pages */
.auth-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: var(--gray-100); padding: 2rem 1rem; }
.auth-card { background: var(--white); border-radius: var(--radius); border: 1px solid var(--gray-200); padding: 2.5rem; width: 100%; max-width: 420px; }
.auth-logo { text-align: center; margin-bottom: 2rem; }
.auth-logo h1 { font-size: 1.5rem; font-weight: 600; letter-spacing: -0.02em; }
.auth-logo span { color: var(--accent); }
.auth-title { font-size: 1.25rem; font-weight: 600; color: var(--gray-900); margin-bottom: 0.375rem; text-align: center; }
.auth-sub { font-size: 0.875rem; color: var(--gray-500); text-align: center; margin-bottom: 2rem; }
.auth-footer { text-align: center; margin-top: 1.5rem; font-size: 0.875rem; color: var(--gray-500); }
.auth-footer a { color: var(--accent); text-decoration: none; font-weight: 500; }

/* Modal */
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 200; display: flex; align-items: center; justify-content: center; padding: 1rem; opacity: 0; pointer-events: none; transition: opacity var(--transition); }
.modal-overlay.open { opacity: 1; pointer-events: all; }
.modal { background: var(--white); border-radius: var(--radius); padding: 2rem; width: 100%; max-width: 480px; transform: scale(.97); transition: transform var(--transition); }
.modal-overlay.open .modal { transform: scale(1); }
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.5rem; }
.modal-title { font-size: 1.125rem; font-weight: 600; color: var(--gray-900); }
.modal-close { background: none; border: none; cursor: pointer; color: var(--gray-400); padding: 0.25rem; border-radius: 4px; }
.modal-close:hover { color: var(--black); background: var(--gray-100); }
.modal-actions { display: flex; gap: 0.75rem; justify-content: flex-end; margin-top: 1.5rem; }

/* Tabs */
.tabs { display: flex; gap: 0; border-bottom: 1px solid var(--gray-200); margin-bottom: 1.5rem; overflow-x: auto; }
.tab { padding: 0.75rem 1.25rem; font-size: 0.875rem; font-weight: 500; color: var(--gray-500); cursor: pointer; border-bottom: 2px solid transparent; transition: all var(--transition); white-space: nowrap; background: none; border-top: none; border-left: none; border-right: none; }
.tab:hover { color: var(--gray-800); }
.tab.active { color: var(--accent); border-bottom-color: var(--accent); }

/* Divider */
.divider { border: none; border-top: 1px solid var(--gray-200); margin: 1.5rem 0; }

/* Loading spinner */
.spinner { display: inline-block; width: 20px; height: 20px; border: 2px solid var(--gray-200); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading { text-align: center; padding: 3rem; color: var(--gray-400); }

/* Responsive helpers */
.hidden-mobile { display: none; }
@media (min-width: 768px) { .hidden-mobile { display: initial; } .hidden-desktop { display: none; } }

/* Flex helpers */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.text-sm { font-size: 0.875rem; }
.text-xs { font-size: 0.75rem; }
.text-muted { color: var(--gray-500); }
.text-right { text-align: right; }
.text-center { text-align: center; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Grid */
.grid-2 { display: grid; grid-template-columns: 1fr; gap: 1.5rem; }
@media (min-width: 768px) { .grid-2 { grid-template-columns: 1fr 1fr; } }

/* Transitions on interactive elements */
a, button { transition: all var(--transition); }

/* Notification item */
.notif-item { padding: 1rem; border-radius: var(--radius-sm); border: 1px solid var(--gray-100); margin-bottom: 0.5rem; cursor: pointer; transition: all var(--transition); }
.notif-item:hover { border-color: var(--gray-200); background: var(--gray-50); }
.notif-item.unread { border-left: 3px solid var(--accent); background: var(--accent-bg); }
.notif-item .notif-title { font-weight: 600; font-size: 0.875rem; color: var(--gray-900); }
.notif-item .notif-msg { font-size: 0.8125rem; color: var(--gray-500); margin-top: 0.25rem; }
.notif-item .notif-time { font-size: 0.75rem; color: var(--gray-400); margin-top: 0.375rem; }

/* Wallet card */
.wallet-hero { background: linear-gradient(135deg, var(--black), var(--gray-800)); color: var(--white); border-radius: var(--radius); padding: 2rem; margin-bottom: 1.5rem; }
.wallet-balance-label { font-size: 0.75rem; letter-spacing: 0.1em; text-transform: uppercase; opacity: 0.6; margin-bottom: 0.5rem; }
.wallet-balance { font-size: 3rem; font-weight: 300; letter-spacing: -0.04em; }
.wallet-balance span { font-size: 1.25rem; opacity: 0.7; }
.wallet-sub { font-size: 0.8125rem; opacity: 0.5; margin-top: 0.75rem; }

/* Type badges */
.type-review { background: #e0e7ff; color: #3730a3; }
.type-social_post { background: #fce7f3; color: #9d174d; }
.type-download { background: #d1fae5; color: #065f46; }
.type-rating { background: #fff3cd; color: #92400e; }
.type-other { background: var(--gray-100); color: var(--gray-600); }

/* Mobile-first nav */
.nav-menu { display: none; }
@media (min-width: 768px) { .nav-menu { display: flex; align-items: center; gap: 1.5rem; } }

