/* =============================================
   AMFreelance - Modern Freelancer Platform CSS
   ============================================= */

/* CSS Custom Properties (Design Tokens) */
:root {
    /* Colors */
    --primary: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --primary-50: #eef2ff;
    --primary-100: #e0e7ff;
    --primary-200: #c7d2fe;
    
    --secondary: #0ea5e9;
    --secondary-light: #38bdf8;
    --secondary-dark: #0284c7;
    
    --accent: #f59e0b;
    --accent-light: #fbbf24;
    
    --success: #10b981;
    --success-light: #d1fae5;
    --warning: #f59e0b;
    --warning-light: #fef3c7;
    --danger: #ef4444;
    --danger-light: #fee2e2;
    --info: #3b82f6;
    --info-light: #dbeafe;
    
    /* Neutrals */
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    
    /* Text */
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --text-inverse: #ffffff;
    
    /* Backgrounds */
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --bg-dark: #0f172a;
    
    /* Borders */
    --border-color: #e2e8f0;
    --border-light: #f1f5f9;
    
    /* Shadows */
    --shadow-xs: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px -1px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -2px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.1);
    --shadow-2xl: 0 25px 50px -12px rgba(0,0,0,0.25);
    --shadow-glow: 0 0 20px rgba(99, 102, 241, 0.3);
    
    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
    
    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    
    /* Spacing */
    --container-max: 1280px;
    --header-height: 72px;
    --topbar-height: 40px;
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-primary);
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: var(--primary);
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    cursor: pointer;
    border: none;
    outline: none;
    font-family: inherit;
    font-size: inherit;
}

input, textarea, select {
    font-family: inherit;
    font-size: inherit;
    outline: none;
}

ul, ol {
    list-style: none;
}

/* Container */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

.container-sm {
    max-width: 800px;
}

.container-lg {
    max-width: 1440px;
}

/* =============================================
   TOP BAR
   ============================================= */
.top-bar {
    background: var(--bg-dark);
    color: var(--gray-400);
    font-size: 13px;
    height: var(--topbar-height);
    display: flex;
    align-items: center;
    position: relative;
    z-index: 1001;
}

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

.top-bar-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.top-bar-text i {
    margin-right: 6px;
    color: var(--primary-light);
}

.top-bar-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.top-bar-link {
    color: var(--gray-400);
    font-size: 13px;
    transition: color var(--transition-fast);
}

.top-bar-link:hover {
    color: white;
}

.top-bar-divider {
    color: var(--gray-600);
}

.language-selector {
    position: relative;
}

.lang-btn {
    background: none;
    color: var(--gray-400);
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.lang-btn:hover {
    color: white;
    background: rgba(255,255,255,0.1);
}

.lang-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--bg-primary);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-xl);
    min-width: 160px;
    padding: 8px;
    z-index: 1100;
    max-height: 300px;
    overflow-y: auto;
}

.language-selector:hover .lang-dropdown {
    display: block;
}

.lang-option {
    display: block;
    padding: 8px 12px;
    color: var(--text-primary);
    border-radius: var(--radius-sm);
    font-size: 13px;
    transition: background var(--transition-fast);
}

.lang-option:hover {
    background: var(--primary-50);
    color: var(--primary);
}

/* =============================================
   MAIN HEADER / NAVBAR
   ============================================= */
.main-header {
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all var(--transition-base);
}

.main-header.header-transparent {
    background: transparent;
    border-bottom: none;
}

.main-header.header-transparent.scrolled {
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}

.navbar {
    display: flex;
    align-items: center;
    height: var(--header-height);
    gap: 24px;
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 22px;
    font-weight: 800;
    color: var(--text-primary);
    flex-shrink: 0;
}

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

.logo-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
}

.logo-accent {
    color: var(--primary);
}

/* Nav Search */
.nav-search {
    flex: 1;
    max-width: 520px;
    position: relative;
}

.search-form {
    position: relative;
}

.search-input-wrapper {
    display: flex;
    align-items: center;
    background: var(--bg-tertiary);
    border: 2px solid transparent;
    border-radius: var(--radius-full);
    overflow: hidden;
    transition: all var(--transition-base);
}

.search-input-wrapper:focus-within {
    border-color: var(--primary);
    background: var(--bg-primary);
    box-shadow: var(--shadow-glow);
}

.search-input-wrapper i {
    padding-left: 16px;
    color: var(--gray-400);
    font-size: 14px;
}

.search-input {
    flex: 1;
    border: none;
    background: none;
    padding: 10px 12px;
    font-size: 14px;
    color: var(--text-primary);
}

.search-input::placeholder {
    color: var(--gray-400);
}

.search-btn {
    background: var(--primary);
    color: white;
    padding: 10px 20px;
    font-weight: 600;
    font-size: 14px;
    border-radius: var(--radius-full);
    margin: 3px;
    transition: background var(--transition-fast);
}

.search-btn:hover {
    background: var(--primary-dark);
}

.search-suggestions {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    padding: 12px;
    z-index: 1000;
}

.search-suggestions.active {
    display: block;
}

/* Nav Links */
.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.nav-link {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 14px;
    padding: 8px 14px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all var(--transition-fast);
    white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary);
    background: var(--primary-50);
}

.nav-link i {
    font-size: 14px;
}

.icon-link {
    position: relative;
    padding: 8px 10px;
}

.badge {
    position: absolute;
    top: 2px;
    right: 2px;
    background: var(--danger);
    color: white;
    font-size: 10px;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
}

.nav-cta {
    margin-left: 4px;
}

/* Dropdowns */
.nav-dropdown {
    position: relative;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border-color);
    min-width: 280px;
    z-index: 1100;
    animation: dropdownFade 0.2s ease;
}

.nav-dropdown.active .dropdown-menu {
    display: block;
}

@keyframes dropdownFade {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

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

.dropdown-header h4 {
    font-size: 15px;
    font-weight: 600;
}

.mark-all-read {
    font-size: 12px;
    color: var(--primary);
}

.dropdown-footer {
    display: block;
    text-align: center;
    padding: 12px;
    font-size: 13px;
    font-weight: 500;
    color: var(--primary);
    border-top: 1px solid var(--border-color);
}

.user-menu-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: none;
    color: var(--text-primary);
    padding: 6px 10px;
    border-radius: var(--radius-md);
    transition: background var(--transition-fast);
}

.user-menu-btn:hover {
    background: var(--bg-tertiary);
}

.user-name {
    font-weight: 500;
    font-size: 14px;
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.avatar-xs {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    object-fit: cover;
}

.avatar-sm {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    object-fit: cover;
}

.avatar-md {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-full);
    object-fit: cover;
}

.avatar-lg {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-full);
    object-fit: cover;
}

.avatar-xl {
    width: 120px;
    height: 120px;
    border-radius: var(--radius-full);
    object-fit: cover;
}

.dropdown-user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
}

.dropdown-user-info strong {
    display: block;
    font-size: 14px;
}

.dropdown-user-info .text-muted {
    font-size: 12px;
    color: var(--gray-400);
}

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

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    color: var(--text-secondary);
    font-size: 14px;
    transition: all var(--transition-fast);
}

.dropdown-item:hover {
    background: var(--primary-50);
    color: var(--primary);
}

.dropdown-item i {
    width: 18px;
    text-align: center;
    font-size: 14px;
}

.user-menu {
    min-width: 260px;
}

/* Categories Bar */
.categories-bar {
    background: var(--bg-primary);
    border-top: 1px solid var(--border-color);
    overflow: hidden;
}

.categories-scroll {
    display: flex;
    gap: 4px;
    overflow-x: auto;
    padding: 10px 0;
    scrollbar-width: none;
}

.categories-scroll::-webkit-scrollbar {
    display: none;
}

.category-link {
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    padding: 6px 14px;
    border-radius: var(--radius-full);
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all var(--transition-fast);
}

.category-link:hover {
    background: var(--primary-50);
    color: var(--primary);
}

.category-link i {
    font-size: 12px;
}

/* Mobile Toggle */
.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    padding: 8px;
}

.mobile-toggle span {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all var(--transition-fast);
}

/* =============================================
   BUTTONS
   ============================================= */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--radius-md);
    border: 2px solid transparent;
    transition: all var(--transition-base);
    cursor: pointer;
    text-decoration: none;
    line-height: 1.4;
    white-space: nowrap;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
}

.btn-lg {
    padding: 16px 32px;
    font-size: 16px;
    border-radius: var(--radius-lg);
}

.btn-xl {
    padding: 18px 40px;
    font-size: 17px;
    border-radius: var(--radius-lg);
}

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

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: white;
    box-shadow: var(--shadow-glow);
    transform: translateY(-1px);
}

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

.btn-secondary:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-50);
}

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

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

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

.btn-white:hover {
    background: var(--primary-50);
    transform: translateY(-1px);
}

.btn-success {
    background: var(--success);
    color: white;
    border-color: var(--success);
}

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

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: none;
    padding: 8px 12px;
}

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

.btn-icon {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: var(--radius-md);
}

.btn-block {
    width: 100%;
}

.btn:disabled, .btn.disabled {
    opacity: 0.55;
    cursor: not-allowed;
    transform: none !important;
}

/* =============================================
   ALERTS
   ============================================= */
.alert {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    position: fixed;
    top: calc(var(--header-height) + var(--topbar-height) + 16px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    min-width: 300px;
    max-width: 600px;
    box-shadow: var(--shadow-xl);
    animation: slideDown 0.4s ease;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateX(-50%) translateY(-20px); }
    to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

.alert-success {
    background: var(--success);
    color: white;
}

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

.alert-warning {
    background: var(--warning);
    color: var(--gray-900);
}

.alert-info {
    background: var(--info);
    color: white;
}

.alert-close {
    background: none;
    color: inherit;
    font-size: 20px;
    margin-left: auto;
    opacity: 0.7;
    line-height: 1;
}

.alert-close:hover {
    opacity: 1;
}

/* =============================================
   FORMS
   ============================================= */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.form-label .required {
    color: var(--danger);
}

.form-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 14px;
    color: var(--text-primary);
    background: var(--bg-primary);
    transition: all var(--transition-fast);
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-200);
}

.form-control::placeholder {
    color: var(--gray-400);
}

.form-control.error {
    border-color: var(--danger);
}

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

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23475569' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px 12px;
    padding-right: 40px;
}

.form-check {
    display: flex;
    align-items: center;
    gap: 8px;
}

.form-check input[type="checkbox"],
.form-check input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}

.form-error {
    color: var(--danger);
    font-size: 12px;
    margin-top: 4px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.input-icon {
    position: relative;
}

.input-icon i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray-400);
    font-size: 14px;
}

.input-icon .form-control {
    padding-left: 40px;
}

.password-toggle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    color: var(--gray-400);
    font-size: 14px;
}

/* =============================================
   CARDS
   ============================================= */
.card {
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: all var(--transition-base);
}

.card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.card-body {
    padding: 20px;
}

.card-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border-color);
    background: var(--bg-secondary);
}

/* Gig Card */
.gig-card {
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: all var(--transition-base);
    position: relative;
}

.gig-card:hover {
    box-shadow: var(--shadow-xl);
    transform: translateY(-6px);
    border-color: var(--primary-200);
}

.gig-card-image {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
}

.gig-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.gig-card:hover .gig-card-image img {
    transform: scale(1.05);
}

.gig-card-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--primary);
    color: white;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.gig-card-save {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(4px);
    border: none;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-500);
    font-size: 14px;
    transition: all var(--transition-fast);
    cursor: pointer;
}

.gig-card-save:hover, .gig-card-save.saved {
    color: var(--danger);
    background: white;
}

.gig-card-body {
    padding: 16px;
}

.gig-card-seller {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.gig-card-seller img {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-full);
    object-fit: cover;
}

.gig-card-seller-info {
    flex: 1;
}

.gig-card-seller-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
}

.gig-card-seller-level {
    font-size: 11px;
    color: var(--text-muted);
}

.gig-card-title {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
    color: var(--text-primary);
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gig-card-title a {
    color: inherit;
}

.gig-card-title a:hover {
    color: var(--primary);
}

.gig-card-rating {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
}

.stars {
    display: inline-flex;
    gap: 1px;
    color: var(--accent);
    font-size: 13px;
}

.gig-card-rating span {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
}

.gig-card-rating .review-count {
    color: var(--text-muted);
    font-weight: 400;
}

.gig-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-top: 1px solid var(--border-color);
}

.gig-card-price {
    font-size: 13px;
    color: var(--text-muted);
}

.gig-card-price strong {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
}

/* =============================================
   HERO SECTION
   ============================================= */
.hero {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f172a 100%);
    padding: 100px 0 80px;
    position: relative;
    overflow: hidden;
    min-height: 600px;
    display: flex;
    align-items: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(ellipse at 20% 50%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(14, 165, 233, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at 60% 80%, rgba(236, 72, 153, 0.08) 0%, transparent 40%);
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-content h1 {
    font-size: 52px;
    font-weight: 800;
    line-height: 1.15;
    color: white;
    margin-bottom: 24px;
    letter-spacing: -0.02em;
}

.hero-content h1 .gradient-text {
    background: linear-gradient(135deg, var(--primary-light), var(--secondary-light), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-content p {
    font-size: 18px;
    color: var(--gray-400);
    line-height: 1.7;
    margin-bottom: 40px;
    max-width: 520px;
}

.hero-search {
    max-width: 560px;
}

.hero-search .search-input-wrapper {
    background: rgba(255,255,255,0.1);
    border: 2px solid rgba(255,255,255,0.15);
    border-radius: var(--radius-lg);
}

.hero-search .search-input-wrapper:focus-within {
    background: rgba(255,255,255,0.15);
    border-color: var(--primary);
}

.hero-search .search-input {
    color: white;
    padding: 16px;
    font-size: 16px;
}

.hero-search .search-input::placeholder {
    color: var(--gray-400);
}

.hero-search .search-btn {
    padding: 14px 28px;
    font-size: 15px;
    margin: 5px;
}

.hero-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 24px;
}

.hero-tags span {
    color: var(--gray-400);
    font-size: 14px;
}

.hero-tag {
    color: var(--gray-300);
    font-size: 13px;
    padding: 4px 12px;
    border: 1px solid var(--gray-700);
    border-radius: var(--radius-full);
    transition: all var(--transition-fast);
}

.hero-tag:hover {
    border-color: var(--primary);
    color: var(--primary-light);
    background: rgba(99, 102, 241, 0.1);
}

/* Hero Right - Stats / Illustration */
.hero-visual {
    position: relative;
}

.hero-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.hero-stat-card {
    background: rgba(255,255,255,0.06);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
    transition: all var(--transition-base);
}

.hero-stat-card:hover {
    background: rgba(255,255,255,0.1);
    transform: translateY(-4px);
}

.hero-stat-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin: 0 auto 12px;
}

.hero-stat-card h3 {
    font-size: 32px;
    font-weight: 800;
    color: white;
    margin-bottom: 4px;
}

.hero-stat-card p {
    font-size: 13px;
    color: var(--gray-400);
    margin: 0;
}

.floating-card {
    position: absolute;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-lg);
    padding: 16px;
    box-shadow: var(--shadow-2xl);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.floating-card-1 {
    bottom: -20px;
    left: -20px;
    animation-delay: 0s;
}

.floating-card-2 {
    top: -10px;
    right: -10px;
    animation-delay: 2s;
}

/* =============================================
   SECTIONS
   ============================================= */
.section {
    padding: 80px 0;
}

.section-dark {
    background: var(--bg-dark);
    color: white;
}

.section-gray {
    background: var(--bg-secondary);
}

.section-header {
    text-align: center;
    margin-bottom: 48px;
}

.section-header .section-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--primary-50);
    color: var(--primary);
    font-size: 13px;
    font-weight: 600;
    padding: 6px 16px;
    border-radius: var(--radius-full);
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.section-header h2 {
    font-size: 36px;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.section-dark .section-header h2 {
    color: white;
}

.section-header p {
    font-size: 17px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

.section-dark .section-header p {
    color: var(--gray-400);
}

/* Categories Grid */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
}

.category-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px 20px;
    text-align: center;
    transition: all var(--transition-base);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.category-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--category-color, var(--primary));
    transform: scaleX(0);
    transition: transform var(--transition-base);
}

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

.category-card:hover::after {
    transform: scaleX(1);
}

.category-icon {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin: 0 auto 16px;
    transition: transform var(--transition-base);
}

.category-card:hover .category-icon {
    transform: scale(1.1) rotate(-5deg);
}

.category-card h3 {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.category-card span {
    font-size: 12px;
    color: var(--text-muted);
}

/* Gig Grid */
.gig-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

/* Freelancer Grid */
.freelancer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

/* Freelancer Card */
.freelancer-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px;
    text-align: center;
    transition: all var(--transition-base);
    position: relative;
}

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

.freelancer-card .online-dot {
    width: 14px;
    height: 14px;
    background: var(--success);
    border: 3px solid var(--bg-primary);
    border-radius: var(--radius-full);
    position: absolute;
    bottom: 2px;
    right: 2px;
}

.freelancer-card-avatar {
    position: relative;
    width: 80px;
    height: 80px;
    margin: 0 auto 16px;
}

.freelancer-card-avatar img {
    width: 100%;
    height: 100%;
    border-radius: var(--radius-full);
    object-fit: cover;
}

.freelancer-card h3 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 4px;
}

.freelancer-card h3 a {
    color: var(--text-primary);
}

.freelancer-card h3 a:hover {
    color: var(--primary);
}

.freelancer-card .tagline {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.freelancer-card .location {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.freelancer-card .location i {
    margin-right: 4px;
}

.freelancer-card .skills-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: center;
    margin-bottom: 16px;
}

.skill-tag {
    font-size: 11px;
    font-weight: 500;
    padding: 3px 10px;
    background: var(--primary-50);
    color: var(--primary);
    border-radius: var(--radius-full);
}

.freelancer-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.freelancer-card-footer .rate {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
}

.freelancer-card-footer .rate span {
    font-size: 13px;
    font-weight: 400;
    color: var(--text-muted);
}

/* How It Works */
.how-it-works-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    position: relative;
}

.how-it-works-grid::before {
    content: '';
    position: absolute;
    top: 40px;
    left: 12.5%;
    right: 12.5%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--secondary), var(--accent), var(--success));
    z-index: 0;
}

.how-step {
    text-align: center;
    position: relative;
    z-index: 1;
}

.how-step-number {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: 800;
    margin: 0 auto 20px;
    color: white;
    position: relative;
}

.how-step h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 10px;
}

.how-step p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Stats Section */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.stat-card {
    text-align: center;
    padding: 30px;
}

.stat-card h3 {
    font-size: 42px;
    font-weight: 800;
    margin-bottom: 8px;
    background: linear-gradient(135deg, var(--primary-light), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-card p {
    font-size: 15px;
    color: var(--gray-400);
}

/* CTA Section */
.cta-section {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 80px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.cta-section h2 {
    font-size: 40px;
    font-weight: 800;
    color: white;
    margin-bottom: 16px;
    position: relative;
}

.cta-section p {
    font-size: 18px;
    color: rgba(255,255,255,0.8);
    margin-bottom: 32px;
    position: relative;
}

.cta-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    position: relative;
}

/* =============================================
   PAGINATION
   ============================================= */
.pagination-wrapper {
    display: flex;
    justify-content: center;
    margin-top: 40px;
}

.pagination {
    display: flex;
    gap: 4px;
}

.page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    transition: all var(--transition-fast);
}

.page-link:hover, .page-link.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* =============================================
   UTILITY CLASSES
   ============================================= */
.text-primary { color: var(--primary) !important; }
.text-success { color: var(--success) !important; }
.text-danger { color: var(--danger) !important; }
.text-warning { color: var(--warning) !important; }
.text-muted { color: var(--text-muted) !important; }
.text-center { text-align: center; }
.text-right { text-align: right; }

.bg-primary { background-color: var(--primary) !important; }
.bg-success { background-color: var(--success) !important; }
.bg-light { background-color: var(--bg-secondary) !important; }

.d-flex { display: flex; }
.d-grid { display: grid; }
.d-none { display: none; }
.d-block { display: block; }
.d-inline-flex { display: inline-flex; }

.align-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.gap-1 { gap: 4px; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 16px; }
.gap-4 { gap: 24px; }
.gap-5 { gap: 32px; }

.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }
.mt-5 { margin-top: 48px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 32px; }

.p-3 { padding: 16px; }
.p-4 { padding: 24px; }
.p-5 { padding: 32px; }

.w-full { width: 100%; }

.rounded { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-full { border-radius: var(--radius-full); }

.overflow-hidden { overflow: hidden; }
.relative { position: relative; }

.gradient-text {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.verified-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    background: var(--primary);
    color: white;
    border-radius: var(--radius-full);
    font-size: 10px;
    margin-left: 4px;
}

.online-indicator {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--success);
}

.online-indicator::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: var(--radius-full);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 16px;
    display: block;
    opacity: 0.3;
}

.tab-nav {
    display: flex;
    border-bottom: 2px solid var(--border-color);
    gap: 4px;
    margin-bottom: 24px;
    overflow-x: auto;
}

.tab-link {
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all var(--transition-fast);
    white-space: nowrap;
}

.tab-link:hover, .tab-link.active {
    color: var(--primary);
    border-color: var(--primary);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1200px) {
    .gig-grid, .freelancer-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .categories-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 992px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .hero-content h1 {
        font-size: 40px;
    }
    .hero-content p {
        margin: 0 auto 40px;
    }
    .hero-search {
        margin: 0 auto;
    }
    .hero-tags {
        justify-content: center;
    }
    .hero-visual {
        display: none;
    }
    .gig-grid, .freelancer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .how-it-works-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .how-it-works-grid::before {
        display: none;
    }
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .section-header h2 {
        font-size: 30px;
    }
    .nav-search {
        display: none;
    }
}

@media (max-width: 768px) {
    .top-bar {
        display: none;
    }
    
    .nav-links {
        display: none;
        position: fixed;
        top: var(--header-height);
        left: 0;
        right: 0;
        bottom: 0;
        background: var(--bg-primary);
        flex-direction: column;
        padding: 24px;
        gap: 8px;
        overflow-y: auto;
        z-index: 999;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .mobile-toggle {
        display: flex;
    }
    
    .gig-grid, .freelancer-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .how-it-works-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .hero {
        padding: 60px 0 40px;
        min-height: auto;
    }
    
    .hero-content h1 {
        font-size: 32px;
    }
    
    .section {
        padding: 48px 0;
    }
    
    .section-header h2 {
        font-size: 26px;
    }
    
    .cta-section h2 {
        font-size: 28px;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }
    .hero-content h1 {
        font-size: 28px;
    }
    .categories-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* =============================================
   FOOTER
   ============================================= */
.main-footer {
    background: var(--bg-dark);
    color: var(--gray-400);
}

.footer-top {
    padding: 60px 0 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr 1.2fr;
    gap: 40px;
}

.footer-brand {
    max-width: 320px;
}

.footer-brand .logo {
    color: white;
    margin-bottom: 16px;
}

.footer-desc {
    font-size: 14px;
    line-height: 1.7;
    margin-bottom: 20px;
}

.social-links {
    display: flex;
    gap: 8px;
}

.social-link {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    background: rgba(255,255,255,0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-400);
    font-size: 14px;
    transition: all var(--transition-fast);
}

.social-link:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
}

.footer-col h4 {
    color: white;
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 20px;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col ul li a {
    color: var(--gray-400);
    font-size: 14px;
    transition: all var(--transition-fast);
}

.footer-col ul li a:hover {
    color: white;
    padding-left: 4px;
}

.footer-text {
    font-size: 13px;
    margin-bottom: 12px;
}

.newsletter-input {
    display: flex;
    background: rgba(255,255,255,0.08);
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.1);
}

.newsletter-input input {
    flex: 1;
    border: none;
    background: none;
    padding: 10px 14px;
    color: white;
    font-size: 13px;
}

.newsletter-input input::placeholder {
    color: var(--gray-500);
}

.newsletter-input button {
    background: var(--primary);
    color: white;
    padding: 10px 14px;
    transition: background var(--transition-fast);
}

.newsletter-input button:hover {
    background: var(--primary-dark);
}

.trust-badges {
    display: flex;
    gap: 12px;
    margin-top: 12px;
}

.trust-badge {
    font-size: 11px;
    color: var(--gray-500);
    display: flex;
    align-items: center;
    gap: 4px;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 20px 0;
}

.footer-bottom-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.footer-bottom p {
    font-size: 13px;
}

.footer-bottom-links {
    display: flex;
    gap: 20px;
}

.footer-bottom-links a {
    color: var(--gray-400);
    font-size: 13px;
}

.footer-bottom-links a:hover {
    color: white;
}

.payment-icons {
    display: flex;
    gap: 10px;
    font-size: 24px;
    color: var(--gray-500);
}

/* Back to Top */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 44px;
    height: 44px;
    background: var(--primary);
    color: white;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    transition: all var(--transition-base);
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: all;
    transform: translateY(0);
}

.back-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-3px);
}

/* Loading Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-color);
    border-top-color: var(--primary);
    border-radius: var(--radius-full);
    animation: spin 0.8s linear infinite;
}

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

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255,255,255,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}
