/* ==========================================================================
   Premium Profile Page Stylesheet for Venturalink
   ========================================================================== */

/* --- :root Variables --- */
:root {
    /* Primary Gradient System */
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #373a9c 100%);
    --gradient-secondary: linear-gradient(135deg, #93c9fb 0%, #5767f5 100%);
    --gradient-accent: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --gradient-success: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    --gradient-warm: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    
    /* Glassmorphism Colors */
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    --glass-strong: rgba(255, 255, 255, 0.08);
    
    /* Dark Mode Colors */
    --bg-primary: #0a0a0f;
    --bg-secondary: #111118;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a8;
    --text-tertiary: #6b6b76;
    --text-accent: #667eea;
    
    /* Interactive Colors */
    --hover-bg: rgba(255, 255, 255, 0.1);
    --active-bg: rgba(255, 255, 255, 0.15);
    --focus-ring: rgba(102, 126, 234, 0.4);
    
    /* Shadows & Effects */
    --shadow-subtle: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 8px 25px rgba(0, 0, 0, 0.15);
    --shadow-strong: 0 20px 40px rgba(0, 0, 0, 0.25);
    --shadow-glow: 0 0 20px rgba(102, 126, 234, 0.3);
    
    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
    
    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    
    /* Typography */
    --font-primary: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-secondary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    
    /* Transitions */
    --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Global & Base Styles --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-secondary);
    background: var(--bg-primary);
    color: var(--text-primary);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* --- Animated Background --- */
.animated-bg {
    position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; z-index: -1; overflow: hidden;
}
.floating-orb {
    position: absolute; border-radius: 50%; filter: blur(100px); opacity: 0.4; animation: float 20s ease-in-out infinite;
}
.orb-1 { width: 400px; height: 400px; background: var(--gradient-primary); top: -200px; left: -200px; }
.orb-2 { width: 300px; height: 300px; background: var(--gradient-accent); top: 50%; right: -150px; animation-delay: 7s; }
.gradient-mesh { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%); animation: meshMove 30s ease-in-out infinite; }
@keyframes float { 0%, 100% { transform: translateY(0px); } 50% { transform: translateY(-30px); } }
@keyframes meshMove { 0%, 100% { opacity: 0.3; } 50% { opacity: 0.5; } }

/* --- Glass Navigation --- */
.glass-nav { position: sticky; top: 0; z-index: 1000; backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-bottom: 1px solid var(--glass-border); background: var(--glass-bg); }
.navbar { display: flex; align-items: center; justify-content: space-between; padding: var(--space-lg) var(--space-2xl); max-width: 1400px; margin: 0 auto; }
.logo-link { display: flex; align-items: center; gap: var(--space-md); text-decoration: none; color: var(--text-primary); }
.logo-icon { width: 48px; height: 48px; background: var(--gradient-primary); border-radius: var(--radius-lg); display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-glow); }
.logo-text { font-family: var(--font-primary); font-size: 1.5rem; font-weight: 700; background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.nav-links { display: flex; gap: var(--space-xl); list-style: none; align-items: center; }
.nav-link { display: flex; align-items: center; gap: var(--space-sm); padding: var(--space-md) var(--space-lg); background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: var(--radius-full); color: var(--text-secondary); text-decoration: none; font-weight: 500; transition: var(--transition-normal); position: relative; overflow: hidden; }
.nav-link::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: var(--gradient-primary); transition: var(--transition-normal); z-index: -1; }
.nav-link:hover::before, .nav-link.active::before { left: 0; }
.nav-link:hover, .nav-link.active { color: white; border-color: transparent; box-shadow: var(--shadow-glow); transform: translateY(-2px); }
.logout-btn { background: none; border: 1px solid var(--glass-border); cursor: pointer; font-family: inherit; font-size: inherit; }

/* --- Main Profile Container --- */
.profile-container { max-width: 1200px; margin: 0 auto; padding: var(--space-2xl); display: flex; flex-direction: column; gap: var(--space-2xl); }

/* --- General Card Styles --- */
.glass-card { background: var(--glass-strong); backdrop-filter: blur(20px); border: 1px solid var(--glass-border); border-radius: var(--radius-xl); padding: var(--space-2xl); transition: var(--transition-normal); box-shadow: var(--shadow-subtle); }
.glass-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-medium); border-color: rgba(102, 126, 234, 0.2); }

/* --- Profile Header --- */
.profile-header { display: flex; align-items: center; gap: var(--space-2xl); }
.profile-avatar { position: relative; flex-shrink: 0; }
.avatar-image { width: 120px; height: 120px; border-radius: 50%; border: 4px solid var(--text-accent); object-fit: cover; box-shadow: var(--shadow-strong); }
.avatar-edit-btn { position: absolute; bottom: 5px; right: 5px; width: 36px; height: 36px; background: var(--gradient-primary); border: 2px solid var(--bg-primary); border-radius: 50%; color: white; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: var(--transition-normal); }
.avatar-edit-btn:hover { transform: scale(1.1); box-shadow: var(--shadow-glow); }
.profile-info { flex: 1; }
.profile-name { font-family: var(--font-primary); font-size: 2.5rem; font-weight: 700; margin: 0; background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.profile-role { font-size: 1.2rem; color: var(--text-secondary); margin-top: var(--space-sm); text-transform: capitalize; }
.profile-completion { margin-top: var(--space-lg); max-width: 400px; }
.completion-text { font-size: 0.9rem; color: var(--text-secondary); margin-bottom: var(--space-sm); display: block; }
.completion-bar { width: 100%; height: 8px; background: var(--glass-bg); border-radius: var(--radius-full); overflow: hidden; }
.completion-fill { height: 100%; background: var(--gradient-success); border-radius: var(--radius-full); transition: width 0.5s ease-in-out; }
.social-links { display: flex; gap: var(--space-md); margin-top: var(--space-lg); }
.social-icon { color: var(--text-secondary); transition: var(--transition-normal); }
.social-icon:hover { color: var(--text-primary); transform: scale(1.1) translateY(-2px); }

/* --- Statistics Grid --- */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: var(--space-xl); }
.stat-card { display: flex; align-items: center; gap: var(--space-lg); padding: var(--space-lg); }
.stat-icon { width: 56px; height: 56px; background: var(--gradient-accent); border-radius: var(--radius-lg); display: flex; align-items: center; justify-content: center; color: white; flex-shrink: 0; box-shadow: var(--shadow-subtle); }
.stat-content { display: flex; flex-direction: column; }
.stat-number { font-family: var(--font-primary); font-size: 2rem; font-weight: 700; color: var(--text-primary); line-height: 1; }
.stat-label { color: var(--text-secondary); }

/* --- Profile Content Grid --- */
.profile-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(350px, 1fr)); gap: var(--space-xl); }
.card-header { display: flex; align-items: center; gap: var(--space-md); margin-bottom: var(--space-xl); }
.card-icon { width: 48px; height: 48px; background: var(--gradient-secondary); border-radius: var(--radius-lg); display: flex; align-items: center; justify-content: center; color: white; }
.card-header h3 { font-family: var(--font-primary); font-size: 1.4rem; font-weight: 600; }

/* --- Edit Profile Form --- */
.premium-form { display: flex; flex-direction: column; gap: var(--space-lg); }
.premium-form .form-group { display: flex; flex-direction: column; gap: var(--space-sm); }
.premium-form label { font-weight: 500; color: var(--text-secondary); }
.input-wrapper { position: relative; display: flex; align-items: center; }
.input-wrapper i { position: absolute; left: var(--space-md); color: var(--text-tertiary); z-index: 1; pointer-events: none; }
.input-wrapper input, .input-wrapper textarea { width: 100%; padding: var(--space-md) var(--space-md) var(--space-md) 45px; background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: var(--radius-lg); color: var(--text-primary); font-family: inherit; transition: var(--transition-normal); }
.input-wrapper textarea { resize: vertical; padding-top: var(--space-md); }
.input-wrapper input:focus, .input-wrapper textarea:focus { border-color: var(--text-accent); background: var(--glass-strong); box-shadow: 0 0 0 3px var(--focus-ring); outline: none; }

/* --- Premium Button --- */
.premium-btn { display: flex; align-items: center; justify-content: center; gap: var(--space-sm); padding: var(--space-md) var(--space-xl); background: transparent; border: none; border-radius: var(--radius-full); color: white; font-weight: 600; cursor: pointer; position: relative; overflow: hidden; z-index: 1; transition: var(--transition-normal); }
.btn-gradient { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: var(--gradient-primary); z-index: -1; transition: var(--transition-normal); }
.premium-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-glow); }
.premium-btn:hover .btn-gradient { background: var(--gradient-accent); }

/* --- Recent Activity Card --- */
.activity-feed { display: flex; flex-direction: column; gap: var(--space-md); max-height: 250px; overflow-y: auto; }
.activity-item { display: flex; align-items: center; gap: var(--space-md); padding: var(--space-md); border-radius: var(--radius-lg); background: var(--glass-bg); transition: var(--transition-normal); }
.activity-item:hover { background: var(--hover-bg); }
.activity-icon { color: var(--text-accent); flex-shrink: 0; }
.activity-content p { margin: 0; flex: 1; }
.activity-content small { color: var(--text-tertiary); font-size: 0.8rem; }

/* --- My Proposals/Investments Card --- */
.full-width-card { grid-column: 1 / -1; }
.proposals-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: var(--space-md); }
.proposal-item { background: var(--glass-bg); padding: var(--space-lg); border-radius: var(--radius-lg); border-left: 3px solid var(--text-accent); display: flex; justify-content: space-between; align-items: center; transition: var(--transition-normal); }
.proposal-item:hover { background: var(--hover-bg); transform: translateX(5px); }
.proposal-item h4 { font-family: var(--font-primary); margin: 0 0 var(--space-sm) 0; }
.proposal-item p { margin: 0; color: var(--text-secondary); }
.status { display: inline-block; padding: 0.25rem 0.75rem; border-radius: var(--radius-full); font-size: 0.8rem; font-weight: 600; text-transform: uppercase; }
.status.pending { background: rgba(251, 146, 60, 0.2); color: #fb923c; }
.status.approved { background: rgba(34, 197, 94, 0.2); color: #22c55e; }

/* --- Custom Scrollbar --- */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--glass-bg); }
::-webkit-scrollbar-thumb { background: var(--gradient-primary); border-radius: var(--radius-full); }

/* --- Responsive Design --- */
@media (max-width: 992px) {
    .profile-header { flex-direction: column; text-align: center; }
    .social-links { justify-content: center; }
}

@media (max-width: 768px) {
    .profile-container { padding: var(--space-xl); }
    .stats-grid, .profile-grid { grid-template-columns: 1fr; }
    .navbar { padding: var(--space-lg); }
}

@media (max-width: 480px) {
    .profile-container { padding: var(--space-lg); }
    .profile-name { font-size: 2rem; }
    .navbar { flex-direction: column; gap: var(--space-lg); }
    .nav-links { width: 100%; justify-content: center; }
}
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-overlay.hidden {
    display: none;
}

.modal-content {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(15px);
    padding: 2rem;
    border-radius: 1rem;
    text-align: center;
    width: 320px;
    max-width: 90%;
}

.modal-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;
}

.modal-actions button {
    flex: 1;
    margin: 0 0.5rem;
}
/* ==========================
   Light Theme Styles
========================== */
[data-theme="light"] {
  --gradient-primary: linear-gradient(135deg, #373a9c 0%, #667eea 100%);
  --gradient-secondary: linear-gradient(135deg, #5767f5 0%, #93c9fb 100%);
  --gradient-accent: linear-gradient(135deg, #00f2fe 0%, #4facfe 100%);
  --gradient-success: linear-gradient(135deg, #38f9d7 0%, #43e97b 100%);

  --glass-bg: rgba(244, 239, 239, 0.992);
  --glass-border: rgba(0, 0, 0, 0.1);
  --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.05);

  --bg-primary: #ffffff;
  --bg-secondary: #f5f5f5;
  --bg-tertiary: #eaeaea;
  --bg-card: rgba(255, 255, 255, 0.8);

  --text-primary: #000000;
  --text-secondary: #333333;
  --text-tertiary: #555555;
  --text-accent: #373a9c;

  --hover-bg: rgba(0, 0, 0, 0.05);
  --active-bg: rgba(0, 0, 0, 0.1);

  --shadow-subtle: 0 2px 10px rgba(0, 0, 0, 0.05);
  --shadow-medium: 0 8px 25px rgba(0, 0, 0, 0.1);
  --shadow-strong: 0 20px 40px rgba(0, 0, 0, 0.15);
  --shadow-glow: 0 0 20px rgba(55, 58, 156, 0.2);
}

/* Light theme background overrides */
[data-theme="light"] header,
[data-theme="light"] .navbar,
[data-theme="light"] .top-header,
[data-theme="light"] .site-header {
  background: #ffffff !important;
}

[data-theme="light"] .nav-link:hover,
[data-theme="light"] .nav-link:active {
  background-color: rgba(0, 0, 0, 0.05);
  color: #000000 !important;
}

[data-theme="light"] body {
  background: var(--bg-primary);
  color: var(--text-primary);
}
