/* =========================================
   THORNZ.LOL - ORIGINAL WARM/YELLOW THEME
   ========================================= */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Warm, Sunny, Light Yellow Theme */
  --bg: #fefce8;          /* Light cream background */
  --bg-2: #fffbeb;        /* Slightly darker cream for cards */
  --bg-3: #fef08a;        /* Vibrant yellow for inputs/hover */
  --bg-4: #fde047;        
  
  --accent: #ca8a04;      /* Deep golden yellow for accents */
  --accent-light: #eab308;
  --accent-glow: rgba(202, 138, 4, 0.2);
  
  --border: rgba(202, 138, 4, 0.25);
  --border-hover: rgba(202, 138, 4, 0.5);
  
  --text: #422006;        /* Very dark brown/black for contrast */
  --text-muted: #713f12;  /* Medium brown */
  --text-sub: #a16207;    /* Light brown */
  
  --card-bg: #ffffff;     /* Pure white for profile cards to pop */
  
  --shadow: 0 15px 35px rgba(202, 138, 4, 0.15);
  --radius: 16px;
  --radius-sm: 10px;
  --radius-xs: 6px;
  --font: 'Inter', system-ui, sans-serif;
  --transition: all 0.2s ease;
}

html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body { font-family: var(--font); background: var(--bg); color: var(--text); min-height: 100vh; overflow-x: hidden; }
a { color: inherit; text-decoration: none; }

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(202, 138, 4, 0.3); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: rgba(202, 138, 4, 0.5); }

/* Elements */
.logo-dot { width: 10px; height: 10px; background: var(--accent); border-radius: 50%; box-shadow: 0 0 10px var(--accent-glow); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 18px; border-radius: var(--radius-xs); font-family: var(--font); font-size: 0.85rem; font-weight: 600; cursor: pointer; transition: var(--transition); border: 1px solid transparent; white-space: nowrap; user-select: none; }
.btn-primary { background: var(--text); color: #fefce8; border-color: var(--text); } 
.btn-primary:hover { background: #271304; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
.btn-ghost { background: transparent; color: var(--text-muted); border-color: var(--border); }
.btn-ghost:hover { background: var(--card-bg); color: var(--text); border-color: var(--border-hover); }
.btn-outline { background: transparent; color: var(--text); border-color: var(--border); }
.btn-outline:hover { border-color: var(--accent); color: var(--accent); }
.btn-sm { padding: 6px 14px; font-size: 0.8rem; }
.btn-full { width: 100%; }

/* Nav */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 100; height: 60px; display: flex; align-items: center; padding: 0 24px; background: rgba(254, 252, 232, 0.85); border-bottom: 1px solid var(--border); backdrop-filter: blur(12px); }
.nav-inner { width: 100%; max-width: 1400px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; }
.nav-logo { display: flex; align-items: center; gap: 10px; font-size: 1.1rem; font-weight: 800; color: var(--text); letter-spacing: -0.5px; }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.mobile-menu-btn { display: none; background: none; border: none; font-size: 1.5rem; color: var(--text); cursor: pointer; margin-right: 12px; }
.sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 999; backdrop-filter: blur(2px); }
.sidebar-overlay.open { display: block; }

/* Profile View transparent nav adaptations */
.nav-transparent { background: transparent !important; border-bottom: none !important; backdrop-filter: none !important; }
.nav-transparent .nav-logo { color: inherit; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.15)); }

/* =========================================
   HOMEPAGE STYLES
   ========================================= */
.home-body { background: var(--bg); }

.hero { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 100px 24px 60px; }
.hero-title { font-size: clamp(2.5rem, 6vw, 4.5rem); font-weight: 800; line-height: 1.1; margin-bottom: 20px; letter-spacing: -1.5px; color: var(--text); }
.hero-sub { font-size: 1.1rem; max-width: 500px; margin-bottom: 40px; color: var(--text-muted); line-height: 1.6; }

.claim-bar { display: flex; align-items: center; background: var(--card-bg); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 6px; width: 100%; max-width: 480px; margin: 0 auto; transition: var(--transition); box-shadow: 0 4px 15px rgba(202, 138, 4, 0.05); }
.claim-bar:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow); }
.claim-prefix { padding-left: 14px; color: var(--text-muted); font-weight: 600; font-size: 0.95rem; }
.claim-bar input.claim-input[type="text"] { flex: 1; background: transparent !important; border: none !important; box-shadow: none !important; padding: 8px 10px !important; font-size: 1rem !important; color: var(--text) !important; outline: none !important; font-weight: 600 !important; border-radius: 0 !important; }

.footer { border-top: 1px solid var(--border); padding: 40px 24px; text-align: center; background: var(--bg-2); }
.footer-copy { color: var(--text-muted); font-size: 0.85rem; font-weight: 500; }

/* =========================================
   PROFILE VIEW STYLES
   ========================================= */
.profile-body { display: flex; flex-direction: column; min-height: 100vh; position: relative; }
.profile-main { flex: 1; display: flex; align-items: center; justify-content: center; padding: 80px 24px 40px; z-index: 2; }
.profile-loading { display: flex; flex-direction: column; align-items: center; gap: 16px; color: var(--text); }
.loading-spinner { width: 40px; height: 40px; border: 4px solid var(--border); border-top-color: var(--accent); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.profile-error { text-align: center; padding: 40px; background: var(--card-bg); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.profile-error h2 { font-size: 1.5rem; margin-bottom: 16px; }

.profile-wrapper { display: flex; justify-content: center; align-items: center; width: 100%; }

/* =========================================
   AUTH PAGES
   ========================================= */
.auth-body { display: flex; flex-direction: column; min-height: 100vh; background: var(--bg); }
.auth-container { flex: 1; display: flex; align-items: center; justify-content: center; padding: 80px 24px 40px; }
.auth-card { width: 100%; max-width: 420px; background: var(--card-bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 40px; box-shadow: var(--shadow); }
.auth-header { margin-bottom: 28px; text-align: center; }
.auth-header h1 { font-size: 1.6rem; font-weight: 800; letter-spacing: -0.5px; margin-bottom: 6px; }
.auth-header p { color: var(--text-muted); font-size: 0.9rem; }
.auth-footer { text-align: center; margin-top: 24px; font-size: 0.85rem; color: var(--text-muted); }
.auth-footer a { color: var(--accent); font-weight: 700; }

/* =========================================
   DASHBOARD STYLES
   ========================================= */
.dash-layout { display: flex; min-height: 100vh; padding-top: 60px; }
.dash-sidebar { width: 260px; background: var(--bg-2); border-right: 1px solid var(--border); position: fixed; top: 60px; bottom: 0; left: 0; display: flex; flex-direction: column; padding: 24px 16px; overflow-y: auto; z-index: 10; transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1); }
.sidebar-user { display: flex; align-items: center; gap: 12px; margin-bottom: 32px; padding: 0 8px; }
.sidebar-user-avatar { width: 42px; height: 42px; border-radius: 50%; background: var(--accent); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1.1rem; border: 2px solid var(--border); }
.sidebar-user-name { font-size: 0.95rem; font-weight: 700; color: var(--text); }
.sidebar-user-sub { font-size: 0.75rem; color: var(--text-muted); }
.sidebar-group { margin-bottom: 24px; }
.sidebar-group-label { font-size: 0.7rem; font-weight: 800; color: var(--text-sub); text-transform: uppercase; margin-bottom: 10px; padding: 0 8px; }
.sidebar-btn { width: 100%; display: flex; align-items: center; gap: 12px; padding: 10px 12px; background: transparent; border: 1px solid transparent; border-radius: var(--radius-xs); color: var(--text-muted); font-size: 0.9rem; font-weight: 600; cursor: pointer; transition: var(--transition); text-align: left; }
.sidebar-btn svg { width: 18px; height: 18px; opacity: 0.8; }
.sidebar-btn:hover { background: var(--card-bg); color: var(--text); }
.sidebar-btn.active { background: var(--accent-glow); color: var(--accent); border-color: rgba(202, 138, 4, 0.2); }
.sidebar-btn.active svg { opacity: 1; }
.premium-badge { margin-left: auto; font-size: 0.65rem; background: var(--text); color: var(--bg); padding: 2px 6px; border-radius: 4px; font-weight: 800; }
.sidebar-spacer { flex: 1; }
.sidebar-bottom { border-top: 1px solid var(--border); padding-top: 16px; display: flex; flex-direction: column; gap: 4px; }

.dash-main { margin-left: 260px; padding: 40px; width: calc(100% - 260px - 440px); }
.dash-content { display: none; animation: fadeIn 0.3s ease; }
.dash-content.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.dash-page-header { margin-bottom: 32px; }
.dash-page-header h1 { font-size: 1.8rem; font-weight: 800; letter-spacing: -0.5px; margin-bottom: 6px; }
.dash-page-header p { color: var(--text-muted); font-size: 0.95rem; }

.dc { background: var(--card-bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; margin-bottom: 24px; box-shadow: 0 4px 15px rgba(0,0,0,0.02); }
.dc-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 20px; }
.dc-title { font-size: 1.05rem; font-weight: 700; color: var(--text); }
.dc-sub { font-size: 0.85rem; color: var(--text-muted); margin-top: 4px; }

.ov-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; margin-bottom: 24px; }
.ov-stat { background: var(--card-bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: 0 4px 15px rgba(0,0,0,0.02); }
.ov-stat-label { font-size: 0.85rem; color: var(--text-muted); font-weight: 600; margin-bottom: 12px; }
.ov-stat-val { font-size: 2.2rem; font-weight: 800; color: var(--text); letter-spacing: -1px; }

/* Forms & Inputs */
.form-group { margin-bottom: 16px; }
.form-label { display: block; font-size: 0.85rem; font-weight: 600; color: var(--text-muted); margin-bottom: 8px; }
input[type="text"], input[type="url"], input[type="email"], input[type="password"], textarea, select { width: 100%; padding: 12px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-xs); color: var(--text); font-size: 0.9rem; outline: none; transition: var(--transition); font-weight: 500; }
input:focus, textarea:focus, select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow); background: var(--card-bg); }
.form-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.span2 { grid-column: span 2; }

.input-prefix-wrap { display: flex; align-items: center; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-xs); overflow: hidden; transition: var(--transition); }
.input-prefix-wrap:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow); background: var(--card-bg); }
.input-prefix { padding: 12px 10px 12px 14px; color: var(--text-sub); font-size: 0.9rem; font-weight: 600; border-right: 1px solid var(--border); background: var(--bg-2); }
.input-prefix-wrap input { border: none; background: transparent; padding: 12px; border-radius: 0; box-shadow: none; }
.input-prefix-wrap input:focus { box-shadow: none; background: transparent; }

.password-wrap { position: relative; }
.toggle-pw { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); background: none; border: none; color: var(--text-muted); cursor: pointer; display: flex; align-items: center; justify-content: center; }

.social-row { display: flex; align-items: center; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-xs); transition: var(--transition); }
.social-row:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow); background: var(--card-bg); }
.social-row-icon { width: 44px; display: flex; align-items: center; justify-content: center; border-right: 1px solid var(--border); color: var(--text-muted); }
.social-row input { border: none; flex: 1; background: transparent; padding: 12px; box-shadow: none; }

.upload-pair { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; }
.upload-zone { border: 2px dashed var(--border); border-radius: var(--radius-sm); display: flex; flex-direction: column; align-items: center; justify-content: center; position: relative; overflow: hidden; cursor: pointer; background: var(--bg); transition: var(--transition); padding: 20px; text-align: center; }
.upload-zone:hover { border-color: var(--accent); background: var(--accent-glow); }
.upload-zone input { position: absolute; inset: 0; opacity: 0; cursor: pointer; z-index: 3; }
.upload-zone-icon { font-size: 1.8rem; margin-bottom: 8px; }
.upload-avatar-zone { aspect-ratio: 1; width: 100%; max-width: 140px; border-radius: 50%; margin: 0 auto; }
.upload-preview { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 2; }

/* Custom Color Picker */
.custom-hue-picker { flex: 1; min-width: 150px; height: 24px; background: linear-gradient(to right, #f00 0%, #ff0 17%, #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%); border-radius: 12px; position: relative; cursor: pointer; border: 1px solid var(--border); box-shadow: inset 0 1px 3px rgba(0,0,0,0.1); }
.custom-hue-picker::after { content: ''; position: absolute; top: 50%; width: 20px; height: 20px; background: white; border: 2px solid #333; border-radius: 50%; transform: translate(-50%, -50%); box-shadow: 0 2px 5px rgba(0,0,0,0.3); pointer-events: none; left: var(--thumb-left, 0%); transition: left 0.05s linear; }

.particle-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 12px; }
.particle-opt { cursor: pointer; }
.particle-opt input { display: none; }
.particle-tile { padding: 12px; text-align: center; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg); font-size: 0.85rem; font-weight: 600; color: var(--text-muted); transition: var(--transition); }
.particle-opt input:checked + .particle-tile { border-color: var(--accent); background: var(--accent-glow); color: var(--text); }

.premium-box { background: linear-gradient(135deg, var(--bg-2), var(--card-bg)); border: 2px solid var(--accent); border-radius: var(--radius); padding: 40px; text-align: center; box-shadow: 0 10px 30px rgba(202, 138, 4, 0.1); }
.paypal-btn { background: #ffc439; color: #000; border-radius: 50px; padding: 14px 24px; font-weight: 800; font-size: 1.1rem; border: none; cursor: pointer; width: 100%; max-width: 320px; display: inline-flex; justify-content: center; align-items: center; gap: 8px; transition: transform 0.2s; box-shadow: 0 4px 12px rgba(255, 196, 57, 0.4); }
.paypal-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(255, 196, 57, 0.6); }

.save-bar { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(100px); background: var(--text); border: 1px solid var(--text); border-radius: 100px; padding: 10px 20px; display: flex; align-items: center; gap: 12px; box-shadow: 0 10px 40px rgba(0,0,0,0.2); transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1); z-index: 200; }
.save-bar.show { transform: translateX(-50%) translateY(0); }
.save-bar .btn-primary { background: var(--bg); color: var(--text); border-color: var(--bg); }
.save-bar .btn-ghost { color: var(--bg-3); }

/* =========================================
   LIVE PREVIEW PANEL & PROFILE CARD
   ========================================= */
.preview-panel { position: fixed; right: 0; top: 60px; bottom: 0; width: 440px; border-left: 1px solid var(--border); background: var(--bg-2); display: flex; flex-direction: column; align-items: center; justify-content: center; z-index: 5; }
.preview-label { position: absolute; top: 24px; left: 24px; font-size: 0.75rem; font-weight: 800; text-transform: uppercase; color: var(--text-muted); }
.card-3d-wrapper { perspective: 1000px; width: 100%; display: flex; justify-content: center; align-items: center; padding: 20px; }

.profile-card { position: relative; width: 440px; max-width: 90vw; background: var(--card-bg, #ffffff); color: var(--card-text-color, #422006); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); transform-style: preserve-3d; transition: box-shadow 0.3s; margin: 0 auto; }
.preview-panel .profile-card { transform: scale(0.75); transform-origin: center center; margin: 0; }

.card-banner { width: 100%; height: 120px; background: linear-gradient(135deg, var(--bg-3), var(--bg-4)); background-size: cover; background-position: center; }
.card-top { display: flex; align-items: flex-start; justify-content: space-between; padding: 0 24px; margin-top: -35px; position: relative; z-index: 2; }
.card-avatar-wrap { position: relative; }
.card-avatar { width: 80px; height: 80px; border-radius: 50%; border: 4px solid var(--card-bg, #ffffff); object-fit: cover; background: var(--accent); }
.avatar-ring { position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--accent); opacity: 0; transition: opacity 0.3s; }
.card-3d-wrapper:hover .avatar-ring { opacity: 0.8; }

.card-info { padding: 16px 24px 0; text-align: center; display: flex; flex-direction: column; align-items: center; }
.card-name-wrap { display: flex; flex-direction: column; align-items: center; width: 100%; }
.card-name { font-size: 1.4rem; font-weight: 800; }
.card-username { font-size: 0.9rem; color: var(--text-muted); font-weight: 600; margin-top: 4px; }
.card-bio { margin-top: 12px; font-size: 0.95rem; line-height: 1.6; color: inherit; opacity: 0.9; }

.card-stats { display: flex; margin: 24px; padding: 14px 0; background: rgba(0,0,0,0.03); border: 1px solid var(--border); border-radius: var(--radius-sm); width: calc(100% - 48px); flex-wrap: wrap; justify-content: center; }
.stat { flex: 1; text-align: center; min-width: 70px; }
.stat-val { display: block; font-size: 1.1rem; font-weight: 800; color: inherit; }
.stat-label { font-size: 0.7rem; font-weight: 700; opacity: 0.8; text-transform: uppercase; }
.stat-divider { width: 1px; background: var(--border); }

.card-socials { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; padding: 0 24px 24px; width: 100%; }
.social-icon { width: 100%; height: 50px; display: flex; align-items: center; justify-content: center; border-radius: var(--radius-sm); background: rgba(0,0,0,0.03); border: 1px solid var(--border); color: inherit; cursor: pointer; transition: var(--transition); }
.social-icon:hover { background: var(--accent); color: #fff; border-color: var(--accent); transform: translateY(-3px); box-shadow: 0 4px 12px rgba(202,138,4,0.3); }

.card-song { display: flex; align-items: center; gap: 12px; margin: 0 24px 24px; padding: 12px; background: rgba(0,0,0,0.03); border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer; width: calc(100% - 48px); }
.song-cover { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; box-shadow: 0 2px 8px rgba(0,0,0,0.1); }
.song-info { flex: 1; overflow: hidden; text-align: left; }
.song-now { font-size: 0.65rem; text-transform: uppercase; color: var(--accent); font-weight: 800; margin-bottom: 2px; }
.song-title { font-size: 0.95rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.song-artist { font-size: 0.8rem; font-weight: 500; opacity: 0.8; }
.song-bars { display: flex; align-items: flex-end; gap: 3px; height: 18px; }
.song-bars span { width: 3px; background: var(--accent); border-radius: 2px; animation: musicBar 0.8s ease-in-out infinite; }
.song-bars span:nth-child(1) { height: 60%; animation-delay: 0s; }
.song-bars span:nth-child(2) { height: 100%; animation-delay: 0.15s; }
.song-bars span:nth-child(3) { height: 80%; animation-delay: 0.3s; }
@keyframes musicBar { 0%, 100% { transform: scaleY(0.5); } 50% { transform: scaleY(1); } }

.profile-audio { margin: 0 24px 24px; text-align: center; background: rgba(0,0,0,0.03); border: 1px solid var(--border); padding: 16px; border-radius: var(--radius-sm); width: calc(100% - 48px); }
.audio-label { font-size: 0.85rem; font-weight: 700; margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.5px;}
.profile-audio audio { width: 100%; height: 40px; border-radius: 8px; outline: none; }
.unmute-btn { margin-top: 10px; padding: 8px 16px; background: var(--accent); color: #fff; border: none; border-radius: 20px; font-weight: 700; cursor: pointer; font-size: 0.85rem; display: inline-flex; align-items: center; gap: 6px; }

.card-shine { position: absolute; inset: 0; background: radial-gradient(circle at var(--shine-x, 50%) var(--shine-y, 50%), rgba(255,255,255,0.4), transparent 50%); pointer-events: none; border-radius: inherit; mix-blend-mode: overlay; }

/* Enhanced Particle System */
.particles-container { position: fixed; inset: 0; pointer-events: none; z-index: 1; overflow: hidden; }
.particle { position: absolute; border-radius: 50%; opacity: 0; }
.p-snow { background: #fff; box-shadow: 0 0 6px #fff; animation: pSnow linear infinite; }
.p-rain { background: rgba(0,0,0,0.2); width: 2px !important; height: 30px !important; border-radius: 0; animation: pRain linear infinite; }
.p-bubbles { border: 2px solid rgba(202, 138, 4, 0.4); background: transparent; animation: pBubble linear infinite; top: 110vh; }
.p-stars { background: var(--accent); box-shadow: 0 0 10px var(--accent); animation: pStar linear infinite; }
.p-fireflies { background: #ca8a04; box-shadow: 0 0 12px #ca8a04; animation: pFirefly linear infinite alternate; }

@keyframes pSnow { 0% { transform: translateY(-10vh) translateX(0); opacity: 0.9; } 50% { transform: translateY(50vh) translateX(30px); opacity: 0.9; } 100% { transform: translateY(110vh) translateX(-30px); opacity: 0; } }
@keyframes pRain { 0% { transform: translateY(-10vh) rotate(15deg); opacity: 0.5; } 100% { transform: translateY(110vh) rotate(15deg); opacity: 0; } }
@keyframes pBubble { 0% { transform: translateY(0) scale(0.5); opacity: 0; } 20% { opacity: 0.8; } 100% { transform: translateY(-110vh) scale(2); opacity: 0; } }
@keyframes pStar { 0%, 100% { opacity: 0.1; transform: scale(0.5); } 50% { opacity: 1; transform: scale(1.5); } }
@keyframes pFirefly { 0% { transform: translate(0, 0); opacity: 0.3; } 100% { transform: translate(40px, -40px); opacity: 1; } }

/* Improved Custom Cursor */
.custom-cursor { position: fixed; pointer-events: none; z-index: 99999; left: 0; top: 0; transition: transform 0.05s linear; }
.c-dot { width: 12px; height: 12px; background: var(--accent); border-radius: 50%; box-shadow: 0 0 12px var(--accent-glow); margin: -6px 0 0 -6px; }
.c-ring { width: 34px; height: 34px; border: 2px solid var(--accent); border-radius: 50%; margin: -17px 0 0 -17px; transition: transform 0.1s ease-out; }
.c-crosshair { width: 24px; height: 24px; margin: -12px 0 0 -12px; position: relative; }
.c-crosshair::before, .c-crosshair::after { content: ''; position: absolute; background: var(--accent); }
.c-crosshair::before { width: 2px; height: 100%; left: 11px; }
.c-crosshair::after { width: 100%; height: 2px; top: 11px; }

/* Scroll To Top */
.scroll-top-btn { position: fixed; bottom: 30px; right: 30px; width: 50px; height: 50px; border-radius: 50%; background: var(--text); border: none; color: var(--bg); font-size: 1.4rem; display: flex; align-items: center; justify-content: center; cursor: pointer; opacity: 0; transition: var(--transition); z-index: 100; box-shadow: 0 6px 16px rgba(0,0,0,0.2); }
.scroll-top-btn:hover { background: var(--accent); transform: translateY(-4px); }

/* Utilities */
.hidden { display: none !important; }
.form-error { padding: 12px; background: rgba(239, 68, 68, 0.1); color: #dc2626; border: 1px solid rgba(239, 68, 68, 0.2); border-radius: var(--radius-xs); font-size: 0.85rem; margin-bottom: 16px; font-weight: 600; }
.form-success { padding: 12px; background: rgba(34, 197, 94, 0.1); color: #16a34a; border: 1px solid rgba(34, 197, 94, 0.2); border-radius: var(--radius-xs); font-size: 0.85rem; margin-bottom: 16px; font-weight: 600; }

.bg-types { display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.bg-type-btn { padding: 8px 16px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-xs); cursor: pointer; font-weight: 600; color: var(--text-muted); transition: var(--transition); }
.bg-type-btn:hover { border-color: var(--accent); color: var(--accent); }
.bg-type-btn.active { background: var(--accent-glow); color: var(--accent); border-color: var(--accent); }
.bg-sub-section { display: none; margin-top: 16px; }
.bg-sub-section.active { display: block; }

/* =========================================
   COSMETIC STYLINGS
   ========================================= */
.card-badges { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 10px; }
.badge-tag { font-size: 0.65rem; font-weight: 900; text-transform: uppercase; padding: 4px 10px; border-radius: 100px; letter-spacing: 0.5px; display: inline-flex; align-items: center; border: 1px solid transparent; }
.badge-og { background: linear-gradient(135deg, #f59e0b, #d97706); color: #ffffff; box-shadow: 0 0 10px rgba(245, 158, 11, 0.4); }
.badge-pro { background: linear-gradient(135deg, #a855f7, #3b82f6); color: #ffffff; box-shadow: 0 0 10px rgba(168, 85, 247, 0.45); }
.badge-veteran { background: linear-gradient(135deg, #10b981, #047857); color: #ffffff; box-shadow: 0 0 10px rgba(16, 185, 129, 0.4); }
.badge-god { background: #000000; color: #ffffff; font-style: italic; border-color: #d97706; animation: godBadgeGlow 2s infinite alternate; }
.badge-manual { background: #e2e8f0; color: #334155; border-color: #cbd5e1; }

@keyframes godBadgeGlow { from { box-shadow: 0 0 4px #000; } to { box-shadow: 0 0 12px #f59e0b; } }

.effect-typewriter { display: inline-block !important; overflow: hidden; border-right: .15em solid var(--accent); white-space: nowrap; animation: typing 3.5s steps(30, end) infinite, blink-caret .75s step-end infinite; }
.effect-glow { text-shadow: 0 0 8px var(--accent), 0 0 20px var(--accent-light); animation: glowPulse 1.5s ease-in-out infinite alternate; }
.effect-rainbow { background: linear-gradient(to right, #ff0000, #ff7f00, #ffff00, #00ff00, #0000ff, #4b0082, #8b00ff); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-size: 400% 400%; animation: rainbowShift 8s ease infinite; }

@keyframes typing { 0%, 90%, 100% { width: 0 } 30%, 80% { width: 100% } }
@keyframes blink-caret { from, to { border-color: transparent } 50% { border-color: var(--accent); } }
@keyframes glowPulse { from { text-shadow: 0 0 5px var(--accent), 0 0 10px var(--accent-light); } to { text-shadow: 0 0 15px var(--accent), 0 0 30px var(--accent-light); } }
@keyframes rainbowShift { 0% { background-position: 0% 50% } 50% { background-position: 100% 50% } 100% { background-position: 0% 50% } }

/* =========================================
   INTERACTIVE PRO UPGRADE CHECKOUT DIALOG
   ========================================= */
.modal-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.6); z-index: 99999; display: flex; align-items: center; justify-content: center; backdrop-filter: blur(8px); }
.modal-card { background: var(--card-bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 32px; width: 100%; max-width: 440px; box-shadow: 0 20px 50px rgba(0,0,0,0.3); position: relative; animation: modalSlideUp 0.3s cubic-bezier(0.4, 0, 0.2, 1); color: var(--text); }
@keyframes modalSlideUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
.modal-close { position: absolute; top: 16px; right: 16px; background: transparent; border: none; font-size: 1.5rem; font-weight: 700; cursor: pointer; color: var(--text-muted); }
.modal-header { text-align: center; margin-bottom: 24px; }
.pro-crown { font-size: 2.5rem; margin-bottom: 8px; }
.modal-header h2 { font-size: 1.5rem; font-weight: 800; margin-bottom: 8px; }
.modal-header p { font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }
.pro-plans { display: flex; flex-direction: column; gap: 12px; margin-bottom: 20px; }
.pro-plan { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 16px; display: flex; align-items: center; gap: 12px; cursor: pointer; transition: var(--transition); }
.pro-plan:hover { border-color: var(--accent); background: rgba(202, 138, 4, 0.03); }
.pro-plan.active { border-color: var(--accent); background: var(--accent-glow); }
.plan-radio { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--border); position: relative; }
.pro-plan.active .plan-radio::after { content: ''; position: absolute; inset: 3px; border-radius: 50%; background: var(--accent); }
.plan-details { flex: 1; display: flex; flex-direction: column; text-align: left; }
.plan-name { font-size: 0.95rem; font-weight: 700; }
.plan-sub { font-size: 0.75rem; color: var(--text-muted); }
.plan-price { font-size: 1.3rem; font-weight: 900; }
.plan-dur { font-size: 0.75rem; font-weight: 600; }
.payment-methods-label { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; color: var(--text-sub); margin-bottom: 8px; text-align: left; }
.pro-checkout-btn { font-size: 0.95rem; padding: 12px; }

/* =========================================
   MOBILE RESPONSIVE FIXES
   ========================================= */
@media (max-width: 1024px) {
  .preview-panel { display: none; }
  .dash-main { width: calc(100% - 260px); }
}
@media (max-width: 768px) {
  .mobile-menu-btn { display: block; }
  .dash-sidebar { transform: translateX(-100%); z-index: 1000; box-shadow: 4px 0 20px rgba(0,0,0,0.1); }
  .dash-sidebar.open { transform: translateX(0); }
  .dash-main { margin-left: 0; width: 100%; padding: 24px 16px; }
  .form-2col, .upload-pair { grid-template-columns: 1fr; }
  .span2 { grid-column: span 1; }
  .card-socials { grid-template-columns: repeat(3, 1fr); }
  .auth-card { padding: 24px; margin: 0 16px; }
  .profile-card { width: 100%; max-width: 100%; }
  .card-stats { flex-direction: row; flex-wrap: wrap; justify-content: center; }
  .stat-divider { width: 1px; height: 20px; }
}
