/* Modern UI Overhaul for rAthena Poll System */

:root {
  --primary: #6c5ce7;
  --primary-600: #5b4ad9;
  --secondary: #00c2a8;
  --bg: #0b1020;
  --panel: #111831;
  --panel-2: #0e1428;
  --muted: #9aa4c7;
  --text: #ecf0ff;
  --success: #22c55e;
  --danger: #ef4444;
  --warning: #f59e0b;
  --info: #0ea5e9;
  --border: #1e2a4a;
  --shadow: 0 10px 30px rgba(5, 10, 25, 0.5);
  --radius: 14px;
}

/* Normalize typography and spacing inside cards across Polls and Ideas */
.poll-card, .poll-card *:not(i) {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Ubuntu, sans-serif;
    letter-spacing: 0;
}

/* Preserve Font Awesome icons */
.poll-card i.fas,
.poll-card i.far,
.poll-card i.fab {
    font-family: 'Font Awesome 6 Free', 'Font Awesome 5 Free' !important;
}

/* Hard-normalize third‑party translation wrappers to avoid spacing/line-height differences */
.poll-card .poll-title *,
.poll-card .poll-description * {
  font-family: inherit !important;
  font-size: inherit !important;
  font-weight: inherit !important;
  letter-spacing: inherit !important;
  color: inherit !important;
  line-height: inherit !important;
  vertical-align: baseline !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  display: inline !important; /* keep inline so line-clamp math is identical */
}

/* Specifically neutralize <font> wrappers inserted by translators */
.poll-card .poll-title font,
.poll-card .poll-description font,
.poll-card .poll-title span[style*="vertical-align: inherit"],
.poll-card .poll-description span[style*="vertical-align: inherit"] {
  font: inherit !important;
  color: inherit !important;
  line-height: inherit !important;
  vertical-align: baseline !important;
  display: inline !important;
}

/* Ensure cards don't add extra outer spacing; grids handle gaps */
.polls-grid .poll-card, .ideas-grid .poll-card { margin: 0; }

* { box-sizing: border-box; }
html, body { height: 100%; }

body {
  margin: 0;
  font-family: "Inter", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, Helvetica Neue, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  color: var(--text);
  background: #0a0e1b;
  position: relative;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Prevent background scroll when a modal is open */
body.modal-open {
  overflow: hidden;
}

/* Beautiful Full Screen Background */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(ellipse at top left, rgba(59, 130, 246, 0.15), transparent 50%),
    radial-gradient(ellipse at bottom right, rgba(168, 85, 247, 0.15), transparent 50%),
    radial-gradient(ellipse at center, rgba(30, 64, 175, 0.1), transparent 70%),
    linear-gradient(180deg, #0a0e1b 0%, #0f1729 50%, #0a0e1b 100%);
  z-index: -2;
  pointer-events: none;
}

body::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(circle at 20% 80%, rgba(59, 130, 246, 0.05) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(168, 85, 247, 0.05) 0%, transparent 50%),
    radial-gradient(circle at 40% 40%, rgba(30, 64, 175, 0.03) 0%, transparent 50%),
    radial-gradient(circle at 60% 60%, rgba(59, 130, 246, 0.03) 0%, transparent 50%);
  opacity: 0.8;
  z-index: -1;
  pointer-events: none;
  animation: floatingGradient 20s ease-in-out infinite;
}

@keyframes floatingGradient {
  0%, 100% {
    transform: translate(0, 0) rotate(0deg);
  }
  33% {
    transform: translate(-20px, -20px) rotate(1deg);
  }
  66% {
    transform: translate(20px, -10px) rotate(-1deg);
  }
}

/* Loading Screen */
.loading-screen { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(6,10,24,0.85); z-index: 200; }
.loading-spinner { text-align: center; }
.spinner { width: 48px; height: 48px; border: 3px solid rgba(255,255,255,0.15); border-top-color: var(--primary); border-radius: 50%; animation: spin 1s linear infinite; margin: 0 auto 12px; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading-spinner p { margin: 0; color: var(--muted); }

/* Container */
.container { width: 100%; max-width: 1100px; margin: 0 auto; padding: 0 20px; }

/* Modal Styles */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  animation: fadeIn 0.3s ease-out;
  overflow: hidden;
}

.modal.active { 
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Redesigned Poll Modal */
.poll-modal-redesign {
    max-width: 900px !important;
}

.poll-detail-header {
    text-align: center;
    padding: 30px 20px 20px;
    border-bottom: 2px solid var(--border);
    margin-bottom: 25px;
}

.poll-author-avatar {
    width: 80px;
    height: 80px;
    margin: 15px auto;
    border: none;
    overflow: hidden;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
}

.poll-author-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.poll-author-avatar .avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #374151, #4b5563);
    position: relative;
}

.poll-author-avatar .avatar-placeholder i {
    font-size: 32px;
    color: #9ca3af;
}

.poll-type-badge {
    display: inline-block;
    padding: 6px 16px;
    background: linear-gradient(135deg, #6c5ce7, #a78bfa);
    color: white;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 15px;
    border-radius: 0;
}

.poll-modal-title {
    font-size: 28px;
    font-weight: 800;
    color: var(--text);
    margin: 10px 0;
    line-height: 1.3;
}

.poll-meta-info {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    font-size: 14px;
    color: var(--muted);
    margin-top: 10px;
}

.poll-separator {
    color: var(--border);
}

.description-card, .voting-card, .comments-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 0;
}

.comment-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 0;
    display: flex;
    gap: 15px;
}

.comment-avatar {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    border: none;
    overflow: hidden;
    border-radius: 0;
}

.comment-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.comment-avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #374151, #4b5563);
    position: relative;
}

.comment-avatar-placeholder i {
    font-size: 16px;
    color: #9ca3af;
}

.comment-body {
    flex: 1;
    min-width: 0;
}

.description-card h3, .voting-card h3, .comments-card h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.description-card .poll-description-text {
    font-size: 15px;
    line-height: 1.8;
    color: var(--text);
    white-space: pre-wrap;
    word-wrap: break-word;
}

.poll-description-text {
    font-size: 15px;
    line-height: 1.8;
    color: var(--text-secondary);
}

/* Share Section Styles */
.poll-share-section {
    margin: 20px 0;
}

.share-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    padding: 20px;
    border-radius: var(--radius);
}

.share-card h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
    margin: 0 0 15px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.share-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 15px;
}

.share-btn {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-600) 100%);
    border: none;
    color: white;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 100px;
    justify-content: center;
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(108, 92, 231, 0.3);
}

.share-btn:active {
    transform: translateY(0);
}

.share-btn.twitter {
    background: linear-gradient(135deg, #1da1f2 0%, #0d95e8 100%);
}

.share-btn.twitter:hover {
    box-shadow: 0 8px 25px rgba(29, 161, 242, 0.3);
}

.share-btn.facebook {
    background: linear-gradient(135deg, #4267b2 0%, #365899 100%);
}

.share-btn.facebook:hover {
    box-shadow: 0 8px 25px rgba(66, 103, 178, 0.3);
}

.share-btn.discord {
    background: linear-gradient(135deg, #7289da 0%, #5b6fb8 100%);
}

.share-btn.discord:hover {
    box-shadow: 0 8px 25px rgba(114, 137, 218, 0.3);
}

.share-btn.copy-link {
    background: linear-gradient(135deg, var(--secondary) 0%, #00a693 100%);
}

.share-btn.copy-link:hover {
    box-shadow: 0 8px 25px rgba(0, 194, 168, 0.3);
}

.share-url-display {
    display: none;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px;
    align-items: center;
    gap: 10px;
}

.share-url-display input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text);
    font-size: 14px;
    outline: none;
    font-family: 'Consolas', 'Monaco', monospace;
}

.copy-url-btn {
    background: var(--primary);
    border: none;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.copy-url-btn:hover {
    background: var(--primary-600);
    transform: scale(1.05);
}

/* Responsive design for share buttons */
@media (max-width: 768px) {
    .share-buttons {
        justify-content: center;
    }
    
    .share-btn {
        flex: 1;
        min-width: 80px;
    }
}

/* Poll Options Redesign */
.poll-options-redesign {
    display: grid;
    gap: 15px;
}

.poll-option-redesign {
    position: relative;
}

/* Compact Poll Options */
.poll-options-redesign {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    width: 100%;
}

.poll-option-redesign {
    width: 100%;
}

.option-content {
    background: rgba(255, 255, 255, 0.03);
    border: 2px solid var(--border);
    padding: 15px;
    transition: all 0.3s ease;
    border-radius: 0;
    text-align: center;
}

.option-content:hover {
    border-color: var(--primary);
    background: rgba(108, 92, 231, 0.05);
    transform: translateY(-2px);
}

.option-content.option-yes {
    border-top: 3px solid #22c55e;
}

.option-content.option-no {
    border-top: 3px solid #ef4444;
}

.option-content.option-maybe {
    border-top: 3px solid #f59e0b;
}

.option-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.option-header i {
    font-size: 28px;
}

.option-yes .option-header i {
    color: #22c55e;
}

.option-no .option-header i {
    color: #ef4444;
}

.option-maybe .option-header i {
    color: #f59e0b;
}

.option-text {
    font-size: 16px;
    font-weight: 700;
    color: var(--text);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.option-stats {
    margin-bottom: 12px;
    min-height: 20px;
}

.option-stats.hidden {
    visibility: hidden;
}

.option-votes {
    font-size: 14px;
    color: var(--primary);
    font-weight: 600;
}

.vote-btn-redesign {
    width: 100%;
    padding: 10px;
    background: linear-gradient(135deg, var(--primary), var(--primary-600));
    color: white;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 0;
    font-size: 14px;
}

.vote-btn-redesign:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(108, 92, 231, 0.3);
}

.vote-btn-redesign:disabled {
    background: rgba(255, 255, 255, 0.1);
    cursor: not-allowed;
    transform: none;
}

/* User voted state */
.option-content.user-voted {
    border-color: var(--primary);
    background: rgba(108, 92, 231, 0.1);
}

.option-content.user-voted .option-header i {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.total-votes-info {
    margin-top: 10px;
    font-size: 11px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

/* Responsive for mobile */
@media (max-width: 640px) {
    .poll-options-redesign {
        flex-direction: column;
    }
    
    .poll-option-redesign {
        max-width: 100%;
    }
}

/* Idea Voting Section */
.idea-voting-section {
    margin-bottom: 20px;
}

.idea-vote-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.idea-vote-btn {
    padding: 25px;
    background: rgba(255, 255, 255, 0.03);
    border: 2px solid var(--border);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    border-radius: 0;
    color: white;
    font-size: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.idea-vote-btn i {
    font-size: 36px;
}

.idea-vote-btn span {
    color: white;
}

.idea-vote-btn.like {
    border-top: 4px solid #22c55e;
}

.idea-vote-btn.like:hover {
    background: rgba(34, 197, 94, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(34, 197, 94, 0.3);
}

.idea-vote-btn.like i {
    color: #22c55e;
}

.idea-vote-btn.dislike {
    border-top: 4px solid #ef4444;
}

.idea-vote-btn.dislike:hover {
    background: rgba(239, 68, 68, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(239, 68, 68, 0.3);
}

.idea-vote-btn.dislike i {
    color: #ef4444;
}

.idea-vote-btn .vote-count {
    font-size: 24px;
    font-weight: 700;
    color: white;
}

.idea-vote-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

.idea-vote-btn.voted {
    background: rgba(108, 92, 231, 0.15);
    border-color: var(--primary);
}

/* Comments Section Redesign */
.comment-form-redesign {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 25px;
    padding-bottom: 25px;
    border-bottom: 1px solid var(--border);
}

.comment-form-redesign textarea {
    width: 100%;
    min-height: 120px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 15px;
    font-size: 14px;
    resize: vertical;
    border-radius: 0;
    transition: all 0.3s ease;
    font-family: inherit;
    line-height: 1.6;
}

.comment-form-redesign textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
}

.comment-form-redesign textarea.invalid {
    border-color: var(--danger);
}

.comment-form-redesign textarea.valid {
    border-color: var(--success);
}

.comment-form-redesign .char-counter {
    font-size: 13px;
    color: var(--muted);
    margin-top: 5px;
    margin-bottom: 5px;
}

.comment-form-redesign .char-requirement {
    margin-left: 10px;
}

.comment-form-redesign .char-requirement.valid {
    color: var(--success);
}

.comment-form-redesign button {
    align-self: flex-end;
}

.comment-form-redesign button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Navbar */
.navbar { position: sticky; top: 0; z-index: 50; background: rgba(11,16,32,0.6); backdrop-filter: blur(10px); border-bottom: 1px solid rgba(255,255,255,0.06); }
.nav-container { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.nav-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: 0.3px; }
.nav-brand i { color: var(--primary); }
.nav-brand span { font-size: 18px; }

.nav-menu { display: flex; align-items: center; gap: 8px; }
.nav-link { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); text-decoration: none; padding: 10px 14px; border-radius: 0; transition: .2s ease; }
.nav-link:hover, .nav-link.active { color: var(--text); background: rgba(255,255,255,0.06); }

.nav-actions { display: flex; align-items: center; gap: 12px; }
.login-btn, .btn { border: 0; border-radius: 0; padding: 10px 14px; background: var(--primary); color: white; cursor: pointer; transition: .2s ease; display: inline-flex; align-items: center; gap: 8px; box-shadow: var(--shadow); }
.login-btn:hover, .btn:hover { background: var(--primary-600); transform: translateY(-1px); }

/* User Menu / Nav Toggle */
.user-menu { position: relative; display: inline-flex; align-items: center; gap: 8px; cursor: pointer; }
.user-avatar { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: transparent; border: none; color: var(--text); overflow: hidden; }
.user-avatar img { width: 100%; height: 100%; object-fit: contain; }
.user-dropdown { position: absolute; right: 0; top: calc(100% + 10px); min-width: 180px; padding: 8px; background: var(--panel); border: 1px solid var(--border); border-radius: 0; box-shadow: var(--shadow); display: none; z-index: 1000; }
.user-menu.active .user-dropdown { display: block; }
.dropdown-item { display: flex; align-items: center; gap: 8px; color: var(--text); text-decoration: none; padding: 10px 12px; border-radius: 0; }
.dropdown-item:hover { background: rgba(255,255,255,0.06); }
#logout-btn { color: #ffb4b4; }

.nav-toggle { display: none; flex-direction: column; gap: 4px; cursor: pointer; }
.nav-toggle span { width: 22px; height: 2px; background: var(--text); display: block; }
@media (max-width: 900px) {
  .nav-menu { display: none; }
  .nav-toggle { display: flex; }
}

/* Hero - Ultra Compact Version */
.hero { 
  padding: 40px 0 30px 0;
  position: relative;
  background: transparent;
}

.hero .hero-content { 
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
}

.hero-title { 
  margin: 0 0 12px; 
  font-size: 42px; 
  font-weight: 800; 
  letter-spacing: -0.5px;
  background: linear-gradient(135deg, #ffffff, #93bbfc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-title i { 
  color: #3b82f6;
  margin-right: 12px;
}

.hero-subtitle { 
  margin: 0 auto 30px; 
  max-width: 600px; 
  color: #93bbfc;
  font-size: 16px;
  line-height: 1.5;
}

.hero-stats { 
  display: grid; 
  grid-template-columns: repeat(5, 1fr); 
  gap: 16px;
  max-width: 1100px;
  margin: 0 auto;
}

.stat { 
  background: rgba(20, 24, 44, 0.6);
  backdrop-filter: blur(10px);
  border: 2px solid rgba(59, 130, 246, 0.2);
  border-radius: 12px;
  padding: 18px 12px;
  transition: all 0.3s ease;
}

.stat:hover {
  transform: translateY(-5px);
  border-color: #3b82f6;
  box-shadow: 0 10px 30px rgba(59, 130, 246, 0.2);
}

.stat-clickable {
  cursor: pointer;
}

.stat-clickable:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 35px rgba(59, 130, 246, 0.3);
}

.stat-number { 
  font-size: 28px; 
  font-weight: 800;
  color: #3b82f6;
  margin-bottom: 4px;
}

.stat-number.stat-approved {
  color: #22c55e;
}

.stat-number.stat-denied {
  color: #ef4444;
}

.stat-label { 
  color: #93bbfc;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

.stat-label i {
  margin-right: 4px;
}

/* Section Head */
.section-title { display: flex; align-items: center; gap: 10px; font-size: 22px; font-weight: 800; margin: 28px 0 16px; }
.section-title i { color: var(--secondary); }

/* Cards grid - Unified */
.featured-polls, .polls-grid, .categories-grid, .ideas-grid { display: grid; }
.featured-polls { 
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr)); 
    gap: 24px;
}
.polls-grid, .ideas-grid { 
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); 
    gap: 24px; 
    align-items: stretch; 
    margin-bottom: 40px;
}
.categories-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }

/* Poll Card - Unified Definition */
.poll-card {
    background: linear-gradient(135deg, var(--panel) 0%, var(--panel-2) 100%);
    border: 1px solid var(--border);
    border-radius: 0;
    padding: 0;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    cursor: pointer;
    overflow: hidden;
    position: relative;
    margin: 0;
    /* Equal look using flex; let content define height */
    height: auto;
    display: flex;
    flex-direction: column;
}

.poll-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(5, 10, 25, 0.7);
    border-color: rgba(108, 92, 231, 0.3);
}

.card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.card-category { background: rgba(255,255,255,0.06); padding: 6px 10px; border-radius: 0; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); border: 1px solid var(--border); }
.card-type { color: var(--muted); font-size: 12px; }
.card-title { font-size: 18px; font-weight: 700; margin: 10px 0 8px; line-height: 1.35; }
.card-description { color: var(--muted); font-size: 14px; }
.card-meta { display: flex; justify-content: space-between; align-items: center; margin-top: 14px; color: var(--muted); font-size: 12px; }
.card-stats { display: flex; gap: 10px; margin-top: 12px; }
.stat-item { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 0; background: rgba(255,255,255,0.06); border: 1px solid var(--border); }
.stat-item.likes { color: var(--success); }
.stat-item.dislikes { color: var(--danger); }

/* Avatar images in poll/idea card listings - minimal border */
.poll-card .avatar-img,
.idea-card .avatar-img {
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
}

/* Approval Status Color Coding for Poll Cards */
.poll-card.approval-approved {
    border-left: 4px solid #22c55e;
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.1) 0%, var(--panel-2) 100%);
}

.poll-card.approval-denied {
    border-left: 4px solid #ef4444;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, var(--panel-2) 100%);
    opacity: 0.7;
}

.poll-card.approval-pending {
    border-left: 4px solid #a855f7;
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.1) 0%, var(--panel-2) 100%);
}

/* Approval Badge on Cards */
.approval-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.approval-badge.approved {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.approval-badge.denied {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.approval-badge.pending {
    background: rgba(168, 85, 247, 0.2);
    color: #a855f7;
    border: 1px solid rgba(168, 85, 247, 0.3);
}

/* Denied Poll Message */
.denied-message {
    margin: 20px 0;
}

.denied-message .status-indicator {
    font-size: 15px;
    padding: 15px;
}

/* GM Approval Section in Modal */
.gm-approval-section {
    margin: 20px 0;
}

.approval-card {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(108, 92, 231, 0.3);
    padding: 20px;
    border-radius: 0;
}

.approval-card h3 {
    color: var(--primary);
    margin-bottom: 15px;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.approval-status-display {
    margin-bottom: 15px;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    border-radius: 0;
    font-weight: 600;
    margin-bottom: 10px;
}

.status-indicator.approved {
    background: rgba(34, 197, 94, 0.2);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #22c55e;
}

.status-indicator.denied {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.status-indicator.pending {
    background: rgba(168, 85, 247, 0.2);
    border: 1px solid rgba(168, 85, 247, 0.3);
    color: #a855f7;
}

.approval-note-display {
    background: rgba(0, 0, 0, 0.3);
    padding: 10px;
    border-left: 3px solid var(--primary);
    margin-top: 10px;
    font-size: 14px;
    color: var(--muted);
}

.approval-actions textarea {
    width: 100%;
    min-height: 60px;
    padding: 10px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border);
    color: var(--text);
    font-family: inherit;
    font-size: 14px;
    resize: vertical;
    margin-bottom: 10px;
}

.approval-actions textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.approval-buttons {
    display: flex;
    gap: 10px;
}

.approve-btn,
.deny-btn {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 0;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.approve-btn {
    background: linear-gradient(135deg, #22c55e, #10b981);
    color: white;
}

.approve-btn:hover {
    background: linear-gradient(135deg, #16a34a, #059669);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.4);
}

.deny-btn {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
}

.deny-btn:hover {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

/* Image Upload Styles for Create Form */
.image-upload-container {
    margin-top: 10px;
}

.image-upload-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
    margin-bottom: 10px;
}

.image-upload-box {
    position: relative;
    aspect-ratio: 1;
    background: rgba(255, 255, 255, 0.02);
    border: 2px dashed rgba(255, 255, 255, 0.2);
    border-radius: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.image-upload-box:hover {
    border-color: var(--primary);
    background: rgba(108, 92, 231, 0.05);
}

.upload-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--muted);
    transition: all 0.3s ease;
}

.upload-placeholder:hover {
    color: var(--primary);
}

.upload-placeholder i {
    font-size: 32px;
    margin-bottom: 8px;
}

.upload-placeholder span {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.image-preview {
    position: relative;
    width: 100%;
    height: 100%;
}

.image-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.remove-image {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 30px;
    height: 30px;
    background: rgba(0, 0, 0, 0.8);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
    border-radius: 0;
}

.remove-image:hover {
    background: var(--danger);
}

.image-info {
    font-size: 12px;
    color: var(--muted);
    font-weight: normal;
    margin-left: 10px;
}

.image-upload-info {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px;
    background: rgba(108, 92, 231, 0.1);
    border: 1px solid rgba(108, 92, 231, 0.2);
    color: var(--muted);
    font-size: 12px;
    border-radius: 0;
}

/* Image Gallery in Poll/Idea View */
.image-gallery {
    margin: 20px 0;
    padding: 15px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    border-radius: 0;
}

.image-gallery-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.image-thumbnails {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
}

.image-thumbnail {
    aspect-ratio: 1;
    overflow: hidden;
    border: 1px solid var(--border);
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 0;
    position: relative;
}

.image-thumbnail:hover {
    border-color: var(--primary);
    transform: scale(1.05);
}

.image-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.image-thumbnail:hover::after {
    content: '\f002';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 24px;
    background: rgba(0, 0, 0, 0.5);
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Image Modal (Lightbox) */
.image-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.image-modal.active {
    display: flex;
}

.image-modal-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
}

.image-modal-content img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
}

.image-modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 32px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.image-modal-close:hover {
    color: var(--danger);
}

/* Section Headers - Unified */
.section-header { 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    gap: 20px; 
    margin-bottom: 24px; 
}
.page-title { 
    display: flex; 
    align-items: center; 
    gap: 12px; 
    font-size: 28px; 
    font-weight: 700; 
    margin: 0; 
    color: var(--text); 
}
.page-title i { 
    color: var(--primary); 
    font-size: 24px; 
}
.search-box { position: relative; }
.search-box input { width: 280px; background: var(--panel); border: 1px solid var(--border); border-radius: 0; padding: 12px 40px 12px 14px; color: var(--text); }
.search-box i { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.filter-select { background: var(--panel); border: 1px solid var(--border); color: var(--text); border-radius: 0; padding: 10px 12px; }

/* Modal - Enhanced Design */
.modal { 
  position: fixed; 
  inset: 0; 
  background: rgba(6,10,24,.85); 
  backdrop-filter: blur(10px); 
  display: none; 
  align-items: center; 
  justify-content: center; 
  padding: 40px 20px; 
  z-index: 1000;
  /* The modal container itself should not scroll to avoid double scrollbars */
  overflow: hidden;
}
.modal.active { display: flex; }
.modal-content { 
  width: 100%; 
  max-width: 560px; 
  background: linear-gradient(135deg, rgba(20,24,44,0.98), rgba(15,19,35,0.98)); 
  border: 2px solid var(--border);
  border-radius: 0; 
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  margin: auto;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
}

/* Large Modal for Poll Details */
.modal.large .modal-content {
  max-width: 900px;
  width: 95%;
}

.modal-header { 
  display: flex; 
  align-items: center; 
  justify-content: space-between; 
  padding: 24px;
  background: rgba(108,92,231,0.08);
  border-bottom: 2px solid var(--border);
  position: relative;
  flex-shrink: 0;
}
.modal-header h2 {
  font-size: 1.5em;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}
.modal-body { 
  padding: 0;
  overflow-y: auto;
  overflow-x: hidden;
  flex: 1;
  max-height: calc(90vh - 80px);
}

/* Themed Scrollbars (global) */
/* Firefox */
body, .modal-body {
  scrollbar-width: thin;
  scrollbar-color: rgba(108,92,231,0.4) rgba(255,255,255,0.06);
}

/* WebKit */
body::-webkit-scrollbar,
.modal-body::-webkit-scrollbar {
  width: 8px;
}

body::-webkit-scrollbar-track,
.modal-body::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.06);
}

body::-webkit-scrollbar-thumb,
.modal-body::-webkit-scrollbar-thumb {
  background: rgba(108,92,231,0.4);
  border-radius: 8px;
}

body::-webkit-scrollbar-thumb:hover,
.modal-body::-webkit-scrollbar-thumb:hover {
  background: rgba(108,92,231,0.6);
}
.modal-close { 
  background: rgba(255,255,255,0.08);
  border: 2px solid var(--border);
  color: var(--text-muted);
  font-size: 20px; 
  cursor: pointer;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0;
  transition: all 0.2s ease;
}
.modal-close:hover {
  background: rgba(239,68,68,0.15);
  border-color: rgba(239,68,68,0.4);
  color: #ef4444;
}

/* Buttons */
.btn-primary { background: var(--primary); }
.btn-primary:hover { background: var(--primary-600); }

/* Forms */
.form-group { position: relative; margin-bottom: 14px; }
.form-group label { display: block; margin: 0 0 8px; font-size: 13px; color: var(--muted); }
.form-group input, .form-select, .form-textarea { width: 100%; padding: 12px 14px; border-radius: 0; background: var(--panel); border: 1px solid var(--border); color: var(--text); }
.form-group .form-icon { position: absolute; right: 12px; bottom: 12px; color: var(--muted); }
.btn-full { width: 100%; }

/* Sections */
.main-content {
  min-height: calc(100vh - 60px);
  padding-top: 24px;
}

.section {
  display: none;
  padding: 24px 0;
  position: relative;
  z-index: 1;
}

.section.active {
  display: block !important;
}

/* Categories Section */
.categories-section {
    margin-bottom: 40px;
    padding-top: 10px;
}

.categories-section .section-title {
    font-size: 28px;
    margin-bottom: 24px;
    color: white;
}

.categories-section .section-title i {
    color: #22c55e;
}

/* Featured Carousel Section - Modern Redesign */
.featured-carousel-section {
    margin-bottom: 40px;
    position: relative;
}

.featured-carousel-container {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 0;
    background: linear-gradient(90deg, #1a1a2e 0%, #25253a 50%, #1a1a2e 100%);
    background-size: 200% 100%;
    animation: shimmer 15s ease infinite;
    padding: 3px;
    min-height: 100px;
    max-height: 100px;
    box-shadow: 0 0 30px rgba(108, 99, 255, 0.25);
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.featured-carousel-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, #6c63ff, transparent);
    animation: scan 3s linear infinite;
}

@keyframes scan {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.featured-carousel {
    display: flex;
    transition: transform 0.8s ease;
    will-change: transform;
    height: 100%;
    background: #16161f;
}

.carousel-slide {
    min-width: 100%;
    padding: 20px 40px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    cursor: pointer;
    position: relative;
    background: transparent;
    transition: all 0.3s ease;
}

.carousel-slide::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 50%;
    background: linear-gradient(180deg, transparent, #8b7fff, transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.carousel-slide:hover::before {
    opacity: 1;
}

.carousel-slide:hover {
    background: rgba(108, 99, 255, 0.05);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.carousel-slide-content {
    display: flex;
    gap: 20px;
    align-items: center;
}

.carousel-slide-avatar {
    width: 60px;
    height: 60px;
    flex-shrink: 0;
    border: none;
    overflow: hidden;
    border-radius: 0;
}

.carousel-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.carousel-avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #374151, #4b5563);
    position: relative;
}

.carousel-avatar-placeholder i {
    font-size: 26px;
    color: #9ca3af;
}

@keyframes pulse-badge {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.carousel-slide-number {
    flex: 0 0 auto;
    font-size: 36px;
    font-weight: 900;
    background: linear-gradient(135deg, #6c63ff, #ff006e);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0.3;
    font-family: 'Inter', sans-serif;
}

.carousel-slide-info {
    flex: 1;
    min-width: 0;
}

.carousel-slide-title {
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.3;
    margin: 0 0 4px 0;
    text-transform: capitalize;
    display: inline-block;
}

.carousel-slide-description {
    font-size: 13px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.4;
    margin: 0 0 8px 0;
    display: block;
}

.carousel-slide-title::after {
    content: '';
    display: inline-block;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 4px 0 4px 6px;
    border-color: transparent transparent transparent #6c63ff;
    margin-left: 8px;
    opacity: 0.5;
    animation: blink 1.5s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.carousel-slide-meta {
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
}

.carousel-slide-meta span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #888;
    font-size: 10px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.carousel-slide-meta span i {
    display: none; /* Hide icons for cleaner look */
}

.carousel-slide-stats {
    display: flex;
    gap: 20px;
    margin-left: auto;
    align-items: center;
}

.carousel-stat {
    position: relative;
    padding-left: 20px;
    font-size: 14px;
    color: #fff;
    font-weight: 600;
}

.carousel-stat::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.carousel-stat:nth-child(1)::before {
    background: linear-gradient(135deg, #00ff88, #00cc66);
    box-shadow: 0 0 10px rgba(0, 255, 136, 0.5);
}

.carousel-stat:nth-child(2)::before {
    background: linear-gradient(135deg, #6c63ff, #8b7fff);
    box-shadow: 0 0 10px rgba(108, 99, 255, 0.5);
}

.carousel-controls {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.carousel-control {
    display: none; /* Hide navigation arrows for cleaner ticker style */
}

.carousel-indicators {
    display: none; /* Hide indicators for ticker style */
}

.carousel-indicators {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.carousel-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    padding: 0;
}

.carousel-indicator.active {
    background: #6c63ff;
    transform: scale(1.2);
}

@media (max-width: 768px) {
    .featured-carousel-section {
        padding: 0;
    }
    
    .featured-carousel-container {
        min-height: 90px;
        max-height: 90px;
    }
    
    .carousel-slide {
        padding: 15px 20px;
    }
    
    .carousel-slide-icon {
        width: 35px;
        height: 35px;
        font-size: 16px;
    }
    
    .carousel-slide-title {
        font-size: 16px;
    }
    
    .carousel-slide-description {
        display: none; /* Hide on mobile for cleaner look */
    }
    
    .carousel-control {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }
    
    .carousel-control.prev {
        left: -40px;
    }
    
    .carousel-control.next {
        right: -40px;
    }
    
    .carousel-slide-meta span {
        font-size: 10px;
    }
    
    .carousel-stat {
        font-size: 10px;
    }
}

/* Featured Section - DEPRECATED */
.featured-section {
    margin-bottom: 48px;
    padding-top: 0;
}

.featured-section .section-title {
    font-size: 28px;
    margin-bottom: 24px;
    color: white;
}

.featured-section .section-title i {
    color: #f59e0b;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 24px;
    color: var(--text);
}

.section-title i {
    color: var(--primary);
    font-size: 20px;
}

.featured-polls {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 24px;
}

/* Duplicate poll card definition removed - using unified definition above */

.poll-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(5, 10, 25, 0.7);
    border-color: rgba(108, 92, 231, 0.3);
}

.poll-card.featured {
    border: 2px solid var(--primary);
    box-shadow: 0 15px 35px rgba(108, 92, 231, 0.2);
}

.poll-card.featured::before {
    content: "★ FEATURED";
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--primary);
    color: white;
    padding: 6px 10px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    border-radius: 4px;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(108, 92, 231, 0.4);
}

.poll-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.poll-category {
    padding: 6px 12px;
    border-radius: 0;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: white;
}

.poll-type {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 500;
    text-transform: capitalize;
}

.poll-type i {
    font-size: 14px;
}

.poll-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 12px 0;
    padding: 0 24px;
    color: var(--text);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.poll-description {
    color: var(--muted);
    font-size: 14px;
    line-height: 1.5;
    /* Create a subtle panel box around the description to match polls */
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 0;
    padding: 16px 20px;
    margin: 0 24px 20px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    /* Prevent long unbroken strings from overflowing the card */
    word-break: break-word;
    overflow-wrap: anywhere;
    /* Force a consistent visual box height for exactly 3 lines */
    min-height: calc(1.5em * 3 + 32px); /* 3 lines + 16px top/bottom padding */
}

.poll-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px 20px;
    background: rgba(255, 255, 255, 0.02);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    /* Stick meta to the bottom for equal-height cards */
    margin-top: auto;
}

.poll-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 500;
}

.poll-meta i {
    color: var(--primary);
    font-size: 11px;
}

/* Comments Section - Complete Modern Redesign */
.comments-section {
    margin-top: 48px;
    background: linear-gradient(135deg, rgba(20, 24, 44, 0.98), rgba(15, 19, 35, 0.98));
    border: 2px solid rgba(59, 130, 246, 0.2);
    border-radius: 12px;
    padding: 0;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

/* Categories Grid */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.comments-header {
    background: rgba(0, 0, 0, 0.3);
    border-bottom: 2px solid rgba(59, 130, 246, 0.2);
    padding: 20px 25px;
}

.comments-header h3 {
    margin: 0;
    font-size: 1.5em;
    color: white;
    display: flex;
    align-items: center;
    gap: 10px;
}

.comments-header h3 i {
    color: #3b82f6;
}

.comments-content {
    padding: 25px;
    max-height: 600px;
    overflow-y: auto;
    background: rgba(0, 0, 0, 0.2);
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

/* Category Cards */
.category-card { 
    background: rgba(20, 24, 44, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 0; 
    padding: 24px; 
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease; 
    cursor: pointer;
}

.category-card:hover { 
    transform: translateY(-6px); 
    box-shadow: 0 15px 30px rgba(5, 10, 25, 0.6);
    border-color: rgba(108, 92, 231, 0.2);
}

.category-icon { 
    width: 48px; 
    height: 48px; 
    display: grid; 
    place-items: center; 
    background: rgba(255,255,255,0.08); 
    border: 1px solid var(--border); 
    border-radius: 0; 
    margin-bottom: 16px; 
    transition: all 0.3s ease;
}

.category-card:hover .category-icon {
    background: rgba(108, 92, 231, 0.1);
    border-color: var(--primary);
}

.category-name { 
    font-weight: 700; 
    margin-bottom: 8px; 
    font-size: 16px;
    color: var(--text);
}

.category-description { 
    color: var(--muted); 
    font-size: 13px; 
    line-height: 1.4;
}

/* Duplicate section styles removed - using unified styles above */

.section-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

/* Search Box Styling */
.search-box {
    position: relative;
    min-width: 280px;
}

.search-box input {
    width: 100%;
    padding: 14px 48px 14px 16px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border);
    border-radius: 0;
    color: var(--text);
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.search-box input::placeholder {
    color: var(--muted);
}

.search-box i {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted);
    font-size: 14px;
    pointer-events: none;
}

/* Filter Dropdowns */
.filter-dropdown {
    position: relative;
}

.filter-dropdown select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    padding: 14px 40px 14px 16px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border);
    border-radius: 0;
    color: var(--text);
    font-size: 14px;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 160px;
}

.filter-dropdown select:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.filter-dropdown select option {
    background: var(--panel);
    color: var(--text);
    padding: 12px 16px;
    border: none;
}

.filter-dropdown::after {
    content: "▼";
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted);
    font-size: 10px;
    pointer-events: none;
    transition: all 0.3s ease;
}

.filter-dropdown:hover::after {
    color: var(--primary);
}

/* Grid card margins - handled above in unified grid styles */

/* Pagination Styling */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 40px;
}

.page-btn {
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border);
    border-radius: 0;
    color: var(--text);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 44px;
    text-align: center;
}

.page-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.page-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.page-btn.active:hover {
    background: var(--primary-600);
}

/* Empty State */
.polls-grid > p.empty-state,
.ideas-grid > p.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    color: var(--muted);
    font-size: 16px;
    padding: 60px 20px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    border-radius: 0;
}

/* Profile Section Styling - All Square Edges */
.profile-section *, 
#profile-section * {
    border-radius: 0 !important;
}

/* Profile Polls Header Styling */
.profile-polls-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 40px 0 30px 0;
    position: relative;
}

.polls-header-line {
    flex: 1;
    height: 2px;
    background: linear-gradient(90deg, transparent 0%, var(--primary) 50%, transparent 100%);
    opacity: 0.3;
}

.polls-header-title {
    padding: 12px 40px;
    margin: 0 20px;
    background: linear-gradient(135deg, var(--panel) 0%, rgba(108, 92, 231, 0.1) 100%);
    border: 2px solid var(--primary);
    color: var(--primary);
    font-size: 20px;
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
    box-shadow: 0 4px 20px rgba(108, 92, 231, 0.2);
}

.polls-header-title i {
    font-size: 24px;
    color: var(--primary);
}

.polls-header-title span {
    background: linear-gradient(90deg, var(--primary), var(--primary-600));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.profile-container {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 32px;
    align-items: start;
}

.profile-card {
    background: linear-gradient(135deg, var(--panel) 0%, var(--panel-2) 100%);
    border: 1px solid var(--border);
    border-radius: 0;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 32px 24px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

#profile-avatar, .profile-avatar {
    width: 140px;
    height: 140px;
    background: linear-gradient(135deg, var(--primary), var(--primary-600));
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin: 0 auto 20px;
    transition: transform 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
    cursor: pointer;
    border-radius: 0;
}

#profile-avatar:hover .avatar-upload-overlay,
.profile-avatar:hover .avatar-upload-overlay {
    opacity: 1;
}

#profile-avatar:hover {
    transform: scale(1.05);
    border-color: var(--primary);
}

.avatar-upload-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.avatar-upload-overlay i {
    font-size: 24px;
    margin-bottom: 8px;
}

.avatar-upload-overlay span {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

#profile-avatar .avatar-placeholder,
#profile-avatar #avatar-placeholder,
.profile-avatar .avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #374151, #4b5563);
    position: relative;
}

#profile-avatar .avatar-placeholder i,
#profile-avatar #avatar-placeholder i,
.profile-avatar .avatar-placeholder i {
    font-size: 48px;
    color: #9ca3af;
}

#profile-avatar #avatar-img,
.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.profile-info h2 {
    margin: 0 0 8px 0;
    font-size: 24px;
    font-weight: 700;
    color: var(--text);
}

.profile-role {
    display: inline-block;
    padding: 4px 12px;
    background: var(--primary);
    border-radius: 0;
    color: white;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.profile-joined {
    color: var(--muted);
    font-size: 14px;
}

.profile-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    padding: 24px;
}

.stat-item {
    text-align: center;
    padding: 16px 8px;
}

.stat-number {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 4px;
}

.stat-label {
    font-size: 12px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.profile-content {
    background: linear-gradient(135deg, var(--panel) 0%, var(--panel-2) 100%);
    border: 1px solid var(--border);
    border-radius: 0;
    box-shadow: var(--shadow);
    overflow: hidden;
}

.profile-tabs {
    display: flex;
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.02);
}

.tab-btn {
    flex: 1;
    padding: 16px 24px;
    background: transparent;
    border: none;
    color: var(--muted);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
}

.tab-btn.active,
.tab-btn:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.04);
}

.tab-btn.active {
    border-bottom-color: var(--primary);
}

.tab-panel {
    display: none;
    padding: 24px;
    min-height: 400px;
}

.tab-panel.active {
    display: block;
}

/* Settings Section Styling */
.settings-container {
    max-width: 800px;
    display: grid;
    gap: 24px;
}

.settings-card {
    background: linear-gradient(135deg, var(--panel) 0%, var(--panel-2) 100%);
    border: 1px solid var(--border);
    border-radius: 0;
    padding: 32px;
    box-shadow: var(--shadow);
}

.settings-card h3 {
    margin: 0 0 24px 0;
    font-size: 20px;
    font-weight: 700;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 12px;
}

.settings-card h3::before {
    content: "";
    width: 4px;
    height: 20px;
    background: var(--primary);
}

.settings-card .form-group {
    margin-bottom: 20px;
}

.settings-card .form-group:last-child {
    margin-bottom: 0;
}

.settings-card small {
    color: var(--muted);
    font-size: 12px;
    margin-top: 4px;
    display: block;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    font-size: 14px;
    color: var(--text);
}

.checkbox-label input[type="checkbox"] {
    appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid var(--border);
    border-radius: 0;
    background: rgba(255, 255, 255, 0.04);
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.checkbox-label input[type="checkbox"]:checked {
    background: var(--primary);
    border-color: var(--primary);
}

.checkbox-label input[type="checkbox"]:checked::after {
    content: "✓";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: 700;
}

.settings-actions {
    display: flex;
    gap: 16px;
    justify-content: flex-end;
    margin-top: 32px;
}

/* User Dropdown Styling */
.user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 0;
    box-shadow: var(--shadow);
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 100;
}

.user-menu.active .user-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--primary);
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item i {
    width: 16px;
    text-align: center;
}

.user-dropdown hr {
    margin: 8px 0;
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Responsive Design */
@media (max-width: 768px) {
    .featured-polls {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .categories-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 16px;
    }
    
    .poll-card-header {
        padding: 20px 24px 16px;
    }
    
    .poll-title {
        font-size: 18px;
        font-weight: 700;
        margin: 0 0 12px 0;
        padding: 0 24px;
        color: var(--text);
        line-height: 1.4;
    }
    
    .poll-description {
        /* Keep the description panel on mobile with same styling as desktop */
        background: rgba(255, 255, 255, 0.03);
        border: 1px solid rgba(255, 255, 255, 0.06);
        border-radius: 0;
        padding: 16px 20px;
        margin: 0 24px 20px;
        font-size: 14px;
        /* Force a consistent visual box height for exactly 3 lines - SAME as desktop */
        min-height: calc(1.5em * 3 + 32px); /* 3 lines + 16px top/bottom padding */
    }
    
    .poll-meta {
        padding: 16px 24px 20px;
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    
    .section-actions {
        width: 100%;
        flex-direction: column;
        gap: 12px;
    }
    
    .search-box {
        min-width: 100%;
    }
    
    .filter-dropdown select {
        width: 100%;
        min-width: 100%;
    }
    
    .polls-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .pagination {
        flex-wrap: wrap;
        gap: 6px;
    }
    
    .page-btn {
        padding: 10px 14px;
        font-size: 13px;
    }
}

/* Toasts */
.toast-container { 
  position: fixed; 
  top: 50%; 
  left: 50%; 
  transform: translate(-50%, -50%); 
  display: flex; 
  align-items: center;
  justify-content: center;
  z-index: 10000; 
}

.toast { 
  padding: 20px 30px; 
  border-radius: 12px; 
  background: rgba(20, 24, 44, 0.98);
  border: 2px solid var(--border);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8); 
  opacity: 0; 
  animation: fadeInScale 0.3s forwards;
  min-width: 400px;
  max-width: 600px;
  display: flex;
  align-items: center;
  gap: 15px;
}

.toast.show { 
  opacity: 1; 
}

.toast.success { 
  background: rgba(34, 197, 94, 0.15);
  border-color: #22c55e;
  color: #22c55e;
}

.toast.error { 
  background: rgba(20, 24, 44, 0.98);
  border-color: #ef4444;
  color: white;
}

.toast.error i {
  color: #ef4444;
  font-size: 1.5em;
}

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.toast.info { background: var(--info); }

/* Poll Detail */
.poll-detail { display: grid; gap: 14px; }

/* Create Form Styling */
.create-form-container {
    max-width: 800px;
    margin: 0 auto;
    background: linear-gradient(180deg, var(--panel), var(--panel-2));
    border: 1px solid var(--border);
    border-radius: 0;
    padding: 32px;
    box-shadow: var(--shadow);
}

.create-form {
    display: grid;
    gap: 24px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    display: grid;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    color: var(--text);
    font-size: 14px;
    letter-spacing: 0.3px;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    border-radius: 0;
    color: var(--text);
    font-family: inherit;
    font-size: 14px;
    transition: all 0.2s ease;
}

/* Create Form Dropdown Styling - Fixed */
.create-form .form-group select {
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    background: rgba(255, 255, 255, 0.04) url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a0aec0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e") no-repeat right 12px center;
    background-size: 16px;
    padding-right: 40px !important;
    cursor: pointer;
}

.create-form .form-group select:hover {
    border-color: rgba(108, 92, 231, 0.5);
    background-color: rgba(255, 255, 255, 0.06);
}

.create-form .form-group select:focus {
    background: rgba(255, 255, 255, 0.06) url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236c5ce7' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e") no-repeat right 12px center;
    background-size: 16px;
}

/* Fix dropdown option visibility */
.form-group select option {
    background: var(--panel);
    color: var(--text);
    padding: 12px 16px;
    border: none;
}

.form-group select:focus option {
    background: var(--panel);
    color: var(--text);
}

/* Enhanced dropdown styling for better visibility */
.create-form .form-row select {
    background: rgba(255, 255, 255, 0.06);
    border: 2px solid var(--border);
    color: var(--text);
    font-weight: 500;
}

.create-form .form-row select option {
    background: var(--panel-2);
    color: var(--text);
    padding: 12px 16px;
    font-weight: 500;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.create-form .form-row select option:hover {
    background: rgba(108, 92, 231, 0.1);
    color: var(--primary);
}

.create-form .form-row select option:checked,
.create-form .form-row select option:selected {
    background: var(--primary);
    color: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
    font-family: inherit;
}

/* Poll Options Section */
.poll-options {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    border-radius: 0;
    padding: 24px;
    margin-top: 8px;
}

.poll-options label {
    font-weight: 600;
    color: var(--text);
    font-size: 16px;
    margin-bottom: 12px;
    display: block;
}

.poll-options-info {
    background: rgba(108, 99, 255, 0.1);
    border: 1px solid rgba(108, 99, 255, 0.2);
    border-radius: 8px;
    padding: 10px;
    margin-top: 10px;
    color: #9ca3af;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.poll-options-info i {
    color: #6c63ff;
}

.poll-option[readonly] {
    background: rgba(255, 255, 255, 0.02);
    cursor: not-allowed;
    color: #9ca3af;
}

.options-container {
    display: grid;
    gap: 12px;
    margin-bottom: 16px;
}

.option-input {
    display: flex;
    gap: 12px;
    align-items: center;
}

.option-input input {
    flex: 1;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    border-radius: 0;
    color: var(--text);
    font-size: 14px;
    transition: all 0.2s ease;
}

.option-input input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.06);
}

.remove-option {
    padding: 8px;
    background: var(--danger);
    border: none;
    border-radius: 0;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    display: none;
}

.remove-option:hover {
    background: #dc2626;
    transform: scale(1.05);
}

.remove-option i {
    font-size: 12px;
}

/* Character Counter */
.char-counter {
    margin: 0;
    padding: 0;
    font-size: 9px;
    color: var(--muted);
    line-height: 1;
    height: 12px;
    display: block;
}

.char-counter span {
    margin: 0;
    padding: 0;
    white-space: nowrap;
    display: inline;
}

.char-requirement {
    color: var(--danger);
    font-weight: 500;
    font-size: 9px;
    margin-left: 6px;
}

.char-requirement.valid {
    color: var(--success);
}

/* Description validation states */
.form-group textarea.invalid {
    border-color: var(--danger);
    background: rgba(239, 68, 68, 0.1);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-group textarea.valid {
    border-color: var(--success);
    background: rgba(34, 197, 94, 0.05);
}

.form-group textarea.invalid:focus {
    border-color: var(--danger);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
}

.form-group textarea.valid:focus {
    border-color: var(--success);
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1);
}

/* Form Warning Message for Bug Reports */
.form-warning,
.form-warning-full {
    margin-top: 12px;
    padding: 12px 16px;
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 8px;
    color: var(--warning);
    font-size: 13px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    animation: slideInDown 0.3s ease;
}

.form-warning-full {
    margin: 20px 0;
    width: 100%;
    grid-column: 1 / -1;
}

.form-warning i,
.form-warning-full i {
    color: var(--warning);
    font-size: 16px;
    flex-shrink: 0;
    margin-top: 2px;
}

.form-warning p,
.form-warning-full p {
    margin: 0;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
}

.form-warning strong,
.form-warning-full strong {
    color: var(--warning);
    font-weight: 600;
}

.warning-flash {
    animation: warningPulse 2s ease-in-out infinite, slideInDown 0.3s ease;
}

@keyframes warningPulse {
    0%, 100% {
        border-color: rgba(245, 158, 11, 0.3);
        box-shadow: 0 0 0 rgba(245, 158, 11, 0);
    }
    50% {
        border-color: rgba(245, 158, 11, 0.8);
        box-shadow: 0 0 20px rgba(245, 158, 11, 0.4);
    }
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Character Selection Modal */
#character-modal .modal-body {
    padding: 20px 10px;  /* Add padding to modal body */
    overflow-x: visible;  /* Allow horizontal overflow for hover effects */
    overflow-y: auto;
}

.character-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));  /* Slightly smaller min-width */
    gap: 20px;
    padding: 15px 30px;  /* Good horizontal padding to prevent cutoff */
    margin: 20px 0;
    overflow: visible;  /* Ensure overflow is visible */
}

.character-card {
    background: linear-gradient(135deg, var(--card-bg) 0%, rgba(108, 92, 231, 0.05) 100%);
    border: 2px solid var(--border);
    border-radius: 16px;
    padding: 24px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.character-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.character-card:hover {
    border-color: var(--primary);
    transform: translateY(-2px);  /* Removed scale to prevent cutoff */
    box-shadow: 0 12px 40px rgba(108, 92, 231, 0.2);
    background: linear-gradient(135deg, var(--card-bg) 0%, rgba(108, 92, 231, 0.1) 100%);
    z-index: 10;  /* Bring to front on hover */
}

.character-card:hover::before {
    opacity: 1;
}

.character-card.selected {
    border-color: var(--primary);
    background: linear-gradient(135deg, rgba(108, 92, 231, 0.15), rgba(0, 194, 168, 0.1));
    box-shadow: 0 16px 50px rgba(108, 92, 231, 0.3);
    transform: translateY(-2px) scale(1.05);
}

.character-card.selected::before {
    opacity: 1;
}

.character-name {
    font-size: 1.4em;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
}

.character-name::before {
    content: '⚔️';
    margin-right: 8px;
    font-size: 0.8em;
}

.character-details {
    color: var(--text-secondary);
    font-size: 0.95em;
    line-height: 1.6;
}

.character-class {
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 8px;
    padding: 4px 12px;
    background: rgba(108, 92, 231, 0.1);
    border-radius: 20px;
    display: inline-block;
    font-size: 0.85em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.character-level {
    margin-bottom: 8px;
    display: flex;
    gap: 20px;
}

.character-level span {
    background: rgba(0, 194, 168, 0.1);
    padding: 4px 10px;
    border-radius: 12px;
    font-weight: 500;
    font-size: 0.85em;
    color: var(--secondary);
    border: 1px solid rgba(0, 194, 168, 0.2);
}

.character-map {
    font-size: 0.85em;
    opacity: 0.8;
    font-style: italic;
    color: var(--text-muted);
}

.character-status {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 0.8em;
    padding: 6px 12px;
    border-radius: 25px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(10px);
}

.character-status.online {
    background: rgba(34, 197, 94, 0.2);
    color: #16a34a;
    border: 1px solid rgba(34, 197, 94, 0.3);
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.4);
}

.character-status.offline {
    background: rgba(156, 163, 175, 0.2);
    color: #6b7280;
    border: 1px solid rgba(156, 163, 175, 0.3);
}

.character-status i {
    margin-right: 6px;
    font-size: 0.8em;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.character-info {
    background: linear-gradient(135deg, rgba(108, 92, 231, 0.1), rgba(0, 194, 168, 0.05));
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 12px;
    padding: 20px;
    margin-top: 25px;
    font-size: 0.9em;
    color: var(--text-secondary);
    backdrop-filter: blur(10px);
}

.character-info p {
    margin: 10px 0;
    display: flex;
    align-items: center;
    line-height: 1.5;
}

.character-info i {
    margin-right: 10px;
    color: var(--primary);
    width: 18px;
    text-align: center;
}

.no-characters {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.no-characters i {
    font-size: 4em;
    color: var(--text-muted);
    margin-bottom: 20px;
    opacity: 0.5;
}

.no-characters h3 {
    font-size: 1.5em;
    margin-bottom: 10px;
    color: var(--text-primary);
}

/* Admin Panel Styles */
.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, var(--card-bg), rgba(108, 92, 231, 0.05));
    border-radius: 12px;
    border: 1px solid var(--border);
}

.admin-search {
    display: flex;
    gap: 10px;
    align-items: center;
}

.search-input {
    padding: 10px 15px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--input-bg);
    color: var(--text-primary);
    font-size: 14px;
    min-width: 250px;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.admin-stats {
    display: flex;
    gap: 15px;
    align-items: center;
}

.stat-badge {
    background: var(--primary);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Admin Poll Cards */
.admin-polls-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.admin-poll-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    transition: all 0.3s ease;
}

.admin-poll-card:hover {
    border-color: var(--primary);
    box-shadow: 0 8px 25px rgba(108, 92, 231, 0.15);
    transform: translateY(-2px);
}

.poll-info {
    flex: 1;
}

/* Admin card specific title - renamed to avoid conflicts */
.admin-poll-card .poll-title {
    font-size: 1.3em;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
    line-height: 1.4;
}

.poll-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.poll-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    font-size: 0.9em;
}

.poll-meta i {
    color: var(--primary);
    width: 14px;
}

.poll-stats {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.poll-stats .stat {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    font-size: 0.85em;
    background: rgba(108, 92, 231, 0.1);
    padding: 4px 10px;
    border-radius: 12px;
}

.poll-stats i {
    color: var(--primary);
}

.featured-badge {
    background: linear-gradient(135deg, var(--warning), #f59e0b);
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.poll-actions {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
    margin-left: 20px;
}

.poll-actions .btn {
    padding: 8px 16px;
    font-size: 0.85em;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Approval Filter Tabs in Admin Panel */
.approval-filter-tabs {
    display: flex;
    gap: 10px;
    margin: 20px 0;
    padding: 10px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 0;
    flex-wrap: wrap;
}

.approval-filter-btn {
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 0;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.approval-filter-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
    color: var(--text-primary);
}

.approval-filter-btn.active {
    background: linear-gradient(135deg, var(--primary), #a78bfa);
    border-color: var(--primary);
    color: white;
}

.approval-filter-btn[data-status="pending"].active {
    background: linear-gradient(135deg, #a855f7, #c084fc);
}

.approval-filter-btn[data-status="approved"].active {
    background: linear-gradient(135deg, #22c55e, #10b981);
}

.approval-filter-btn[data-status="denied"].active {
    background: linear-gradient(135deg, #ef4444, #dc2626);
}

/* Status Badge in Admin Cards */
.poll-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.status-badge {
    padding: 6px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.status-badge.approved {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.status-badge.denied {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-badge.pending {
    background: rgba(168, 85, 247, 0.2);
    color: #a855f7;
    border: 1px solid rgba(168, 85, 247, 0.3);
}

/* Admin Poll Card Approval Status Colors */
.admin-poll-card.approval-approved {
    border-left: 4px solid #22c55e;
}

.admin-poll-card.approval-denied {
    border-left: 4px solid #ef4444;
    opacity: 0.8;
}

.admin-poll-card.approval-pending {
    border-left: 4px solid #a855f7;
}

/* Admin User Cards */
.admin-users-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.admin-user-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    transition: all 0.3s ease;
}

.admin-user-card:hover {
    border-color: var(--primary);
    box-shadow: 0 8px 25px rgba(108, 92, 231, 0.15);
    transform: translateY(-2px);
}

.user-info {
    flex: 1;
}

.user-name {
    font-size: 1.2em;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.role-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.role-badge.role-admin {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    color: white;
}

.role-badge.role-moderator {
    background: linear-gradient(135deg, var(--warning), #f59e0b);
    color: white;
}

.role-badge.role-player {
    background: linear-gradient(135deg, var(--success), #16a34a);
    color: white;
}

.banned-badge {
    background: linear-gradient(135deg, #dc2626, #991b1b);
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    animation: pulse 2s infinite;
}

.user-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.user-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    font-size: 0.9em;
}

.user-meta i {
    color: var(--primary);
    width: 14px;
}

.user-stats {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.user-stats .stat {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    font-size: 0.85em;
    background: rgba(0, 194, 168, 0.1);
    padding: 4px 10px;
    border-radius: 12px;
}

.user-stats i {
    color: var(--secondary);
}

.user-actions {
    display: flex;
    gap: 10px;
    flex-direction: column;
    align-items: flex-end;
    flex-shrink: 0;
    margin-left: 20px;
}

.role-select {
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--input-bg);
    color: var(--text-primary);
    font-size: 0.85em;
    min-width: 120px;
}

.role-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.admin-protected {
    color: var(--text-muted);
    font-size: 0.85em;
    font-style: italic;
    padding: 8px 12px;
}

/* Moderation Logs */
.moderation-logs-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.log-entry {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 20px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    transition: all 0.3s ease;
}

.log-entry:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 15px rgba(108, 92, 231, 0.1);
}

.log-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.1em;
}

.log-delete .log-icon {
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
}

.log-ban .log-icon {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
}

.log-unban .log-icon {
    background: rgba(34, 197, 94, 0.1);
    color: #22c55e;
}

.log-role .log-icon {
    background: rgba(108, 92, 231, 0.1);
    color: var(--primary);
}

.log-feature .log-icon {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
}

.log-info .log-icon {
    background: rgba(156, 163, 175, 0.1);
    color: #9ca3af;
}

.log-content {
    flex: 1;
}

.log-action {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    line-height: 1.4;
}

.log-meta {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.log-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    font-size: 0.85em;
}

.log-meta i {
    color: var(--primary);
    width: 14px;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
    padding: 20px 0;
}

.pagination .btn {
    padding: 10px 16px;
    font-size: 0.9em;
    border-radius: 8px;
    min-width: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pagination .btn.active {
    background: var(--primary);
    color: white;
    font-weight: 600;
}

.pagination .btn:not(.active) {
    background: var(--card-bg);
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.pagination .btn:not(.active):hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Responsive Design for Admin Panel */
@media (max-width: 768px) {
    .admin-header {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .admin-search {
        flex-direction: column;
        gap: 10px;
    }
    
    .search-input {
        min-width: auto;
        width: 100%;
    }
    
    .admin-poll-card,
    .admin-user-card {
        flex-direction: column;
        gap: 20px;
    }
    
    .poll-actions,
    .user-actions {
        margin-left: 0;
        flex-direction: row;
        justify-content: flex-start;
        flex-wrap: wrap;
    }
    
    .poll-meta,
    .user-meta {
        flex-direction: column;
        gap: 8px;
    }
    
    .pagination {
        flex-wrap: wrap;
        gap: 5px;
    }
    
    .pagination .btn {
        padding: 8px 12px;
        font-size: 0.85em;
        min-width: 40px;
    }
}

/* Profile Management Styles */
.profile-avatar {
    position: relative;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: 4px solid var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 8px 25px rgba(108, 92, 231, 0.15);
    cursor: pointer;
}

.profile-avatar:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(108, 92, 231, 0.25);
}

.profile-avatar .avatar-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 0;
}

.profile-avatar .avatar-placeholder {
    display: flex;
    flex-direction: column;
    padding: 20px;
}

.profile-avatar-outer {
    position: absolute;
    left: 50%;
    top: -60px;
    transform: translateX(-50%);
    width: 120px;
    height: 120px;
    border-radius: 0;
    background: linear-gradient(135deg, #6c5ce7 40%, #00c2a8 100%);
    box-shadow: 0 8px 32px 0 rgba(108, 92, 231, 0.3);
    border: 4px solid #191d2c;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.profile-header-info .character-badge {
    background: rgba(108,92,231,0.10);
    border: 1px solid rgba(108,92,231,0.18);
    color: var(--primary);
    border-radius: 0;
    padding: 6px 16px;
    font-size: 1em;
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.profile-header-info .stat-card {
    background: rgba(255,255,255,0.04);
    border: 2px solid var(--border);
    border-radius: 0;
    padding: 20px 26px;
    min-width: 120px;
    text-align: center;
    box-shadow: 0 2px 10px 0 rgba(108,92,231,0.08);
    transition: box-shadow 0.2s, border-color 0.2s;
  transition: box-shadow 0.2s, border-color 0.2s;
}
.profile-header-info .stat-card:hover {
  border-color: var(--primary);
  box-shadow: 0 6px 24px 0 rgba(108,92,231,0.18);
}
.profile-header-info .stat-number {
  font-size: 2em;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 2px;
}
.profile-header-info .stat-label {
  font-size: 0.8em;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 700;
}

/* Sidebar Navigation */
.profile-content-wrapper {
  display: flex;
  gap: 32px;
  margin: 40px auto 0 auto;
  max-width: 1100px;
  align-items: flex-start;
}
.profile-navigation {
  background: rgba(20, 24, 44, 0.8);
  backdrop-filter: blur(10px);
  border-radius: 0;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.4);
  border: 2px solid rgba(59, 130, 246, 0.2);
  padding: 20px;
  min-width: 280px;
  max-width: 300px;
  flex: 0 0 300px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  position: sticky;
  top: 120px;
  height: fit-content;
}
.profile-tabs {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.profile-tab {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 24px;
  background: rgba(255,255,255,0.02);
  border: 2px solid var(--border);
  border-radius: 0;
  color: var(--text-muted);
  transition: all 0.2s ease;
  font-weight: 600;
  cursor: pointer;
  font-size: 1.05em;
  text-align: left;
  width: 100%;
  margin-bottom: 4px;
}
.profile-tab:hover {
  background: rgba(108,92,231,0.08);
  color: var(--text);
  border-color: rgba(108,92,231,0.4);
}
.profile-tab.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 4px 12px 0 rgba(108,92,231,0.2);
}

.profile-tab i {
  font-size: 1.15em;
  width: 20px;
}

/* Main Profile Content */
.profile-content {
  background: rgba(20, 24, 44, 0.8);
  backdrop-filter: blur(10px);
  border-radius: 0;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.4);
  border: 2px solid rgba(59, 130, 246, 0.2);
  flex: 1;
  min-width: 0;
  padding: 0;
  min-height: 500px;
}

.tab-panel {
    display: none;
    padding: 32px;
}

.tab-panel.active {
    display: block;
}

.content-header {
    margin-bottom: 32px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border);
}

.content-header h2 {
    font-size: 1.8em;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.content-header h2 i {
    color: var(--primary);
}

.content-header p {
    color: var(--text-muted);
    margin: 0;
    font-size: 1.1em;
}

.settings-grid {
    display: grid;
    gap: 24px;
    margin-bottom: 32px;
}

.settings-card {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
}

.settings-header {
    background: rgba(var(--primary-rgb), 0.05);
    border-bottom: 1px solid var(--border);
    padding: 20px 24px;
}

.settings-header h3 {
    margin: 0;
    font-size: 1.2em;
    font-weight: 600;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 10px;
}

.settings-header h3 i {
    color: var(--primary);
}

.settings-body {
    padding: 24px;
}

.setting-item {
    margin-bottom: 24px;
}

.setting-item:last-child {
    margin-bottom: 0;
}

.setting-item label {
    display: block;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 8px;
}

.setting-value {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px 16px;
}

.setting-value span {
    font-weight: 600;
    color: var(--text);
}

.setting-value small {
    display: block;
    color: var(--text-muted);
    margin-top: 4px;
    font-size: 0.85em;
}

.character-setting {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.current-character {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 16px;
}

.character-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.character-info i {
    color: var(--primary);
    font-size: 1.2em;
}

.character-name {
    font-weight: 600;
    color: var(--text);
    display: block;
}

.no-character {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--warning);
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.2);
    border-radius: 8px;
    padding: 12px 16px;
}

.picture-manager {
    display: flex;
    align-items: center;
    gap: 20px;
}

.current-picture {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid var(--border);
    flex-shrink: 0;
}

.preview-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.no-picture {
    width: 100%;
    height: 100%;
    background: var(--bg-primary);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 0.8em;
}

.no-picture i {
    font-size: 1.5em;
    margin-bottom: 4px;
}

.picture-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toggle-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    padding: 16px;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 8px;
    transition: all 0.2s ease;
}

.toggle-label:hover {
    border-color: var(--primary);
    background: rgba(var(--primary-rgb), 0.05);
}

.toggle-slider {
    position: relative;
    width: 44px;
    height: 24px;
    background: var(--border);
    border-radius: 12px;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.toggle-slider::before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    transition: all 0.3s ease;
}

input[type="checkbox"]:checked + .toggle-slider {
    background: var(--primary);
}

input[type="checkbox"]:checked + .toggle-slider::before {
    transform: translateX(20px);
}

input[type="checkbox"] {
    display: none;
}

.toggle-text span {
    font-weight: 600;
    color: var(--text);
    display: block;
}

.toggle-text small {
    color: var(--text-muted);
    font-size: 0.85em;
    margin-top: 2px;
    display: block;
}

.settings-actions {
    display: flex;
    gap: 16px;
    justify-content: flex-end;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.btn-large {
    padding: 14px 28px;
    font-size: 1.05em;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .profile-content-wrapper {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .profile-navigation {
        position: static;
    }
    
    .profile-tabs {
        flex-direction: row;
        overflow-x: auto;
        padding: 4px;
    }
    
    .profile-tab {
        flex-shrink: 0;
        min-width: 120px;
        justify-content: center;
    }
}

/* Moderation Logs Styling */
.moderation-log-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    transition: all 0.3s ease;
}

.moderation-log-item:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--primary);
    transform: translateX(4px);
}

.log-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.log-action {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9em;
}

.log-action.delete_poll,
.log-action.delete_comment {
    background: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
}

.log-action.feature_poll,
.log-action.unfeature_poll {
    background: rgba(241, 196, 15, 0.1);
    color: #f1c40f;
}

.log-action.ban_user {
    background: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
}

.log-action.unban_user {
    background: rgba(46, 204, 113, 0.1);
    color: #2ecc71;
}

.log-action.change_role {
    background: rgba(108, 92, 231, 0.1);
    color: var(--primary);
}

.log-action.edit_poll {
    background: rgba(52, 152, 219, 0.1);
    color: #3498db;
}

.log-time {
    color: var(--text-secondary);
    font-size: 0.85em;
}

.log-details {
    display: flex;
    gap: 20px;
    font-size: 0.9em;
    color: var(--text-secondary);
}

.log-details span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.log-moderator i,
.log-target i {
    color: var(--primary);
}

.log-message {
    margin-top: 12px;
    padding: 10px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    font-size: 0.9em;
    color: var(--text-secondary);
    border-left: 3px solid var(--primary);
}

/* Categories Management Styling */
.admin-category-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
    transition: all 0.3s ease;
}

.admin-category-card:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.category-info {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.category-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    flex: 1;
}

.category-icon {
    font-size: 2em;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    flex-shrink: 0;
}

.category-details {
    flex: 1;
}

.category-name {
    font-size: 1.4em;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 8px 0;
}

.category-description {
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
}

.category-stats {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: flex-end;
}

.last-activity {
    font-size: 0.85em;
    color: var(--text-muted);
}

.category-actions {
    display: flex;
    gap: 8px;
}

/* Category Form Styling */
.category-form .form-group {
    margin-bottom: 20px;
}

.category-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text);
}

.category-form input,
.category-form textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: 8px;
    background: var(--card-bg);
    color: var(--text);
    font-size: 1em;
    transition: all 0.3s ease;
}

.category-form input:focus,
.category-form textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
}

.color-picker-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.color-picker-container input[type="color"] {
    width: 80px;
    height: 40px;
    padding: 4px;
    border-radius: 8px;
    cursor: pointer;
}

.color-presets {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.color-preset {
    width: 32px;
    height: 32px;
    border: 2px solid var(--border);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.color-preset:hover {
    transform: scale(1.1);
    border-color: var(--text);
}

.form-help {
    display: block;
    margin-top: 6px;
    font-size: 0.85em;
    color: var(--text-muted);
    font-style: italic;
}

.form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

/* Responsive Categories */
@media (max-width: 768px) {
    .category-info {
        flex-direction: column;
        gap: 16px;
    }
    
    .category-stats {
        align-items: flex-start;
    }
    
    .category-actions {
        justify-content: flex-start;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .form-actions .btn {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .create-form-container {
        padding: 24px 20px;
        margin: 0 16px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .btn {
        justify-content: center;
    }
    
    .profile-stats {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .profile-meta {
        flex-direction: column;
        gap: 8px;
    }
    
    .profile-name {
        font-size: 1.8em;
    }
    
    .settings-grid {
        gap: 16px;
    }
    
    .picture-manager {
        flex-direction: column;
        text-align: center;
    }
    
    .settings-actions {
        flex-direction: column;
    }
    
    .profile-info {
        padding: 24px 20px;
    }
}
.poll-options-voting { display: grid; gap: 10px; }
.poll-option-item { display: flex; align-items: center; justify-content: space-between; background: var(--panel); border: 1px solid var(--border); border-radius: 0; padding: 12px; cursor: pointer; }
.poll-option-item:hover { border-color: rgba(108,92,231,0.6); }
.vote-buttons { display: flex; gap: 10px; }
.btn.btn-danger { background: var(--danger); }
.btn.btn-success { background: var(--success); }

/* Poll Detail Modal Content */
.poll-detail {
  padding: 0;
  /* Ensure internals never exceed container width */
  box-sizing: border-box;
}

.poll-detail *,
#poll-modal-description {
  max-width: 100%;
  box-sizing: border-box;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.poll-detail .poll-meta {
  padding: 24px;
  background: rgba(255,255,255,0.02);
  border-bottom: 2px solid var(--border);
}

.poll-detail .poll-meta p {
  margin: 0 0 12px 0;
  color: var(--text-muted);
  line-height: 1.6;
}

.poll-detail .poll-meta p:last-child {
  margin-bottom: 0;
}

/* Poll Options in Modal */
.poll-options {
  padding: 24px;
  background: rgba(255,255,255,0.01);
  border-bottom: 2px solid var(--border);
}

.poll-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background: rgba(255,255,255,0.03);
  border: 2px solid var(--border);
  border-radius: 0;
  margin-bottom: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.poll-option:hover {
  background: rgba(108,92,231,0.08);
  border-color: rgba(108,92,231,0.3);
}

.poll-option.selected {
  background: rgba(108,92,231,0.15);
  border-color: var(--primary);
}

.poll-option-text {
  flex: 1;
  font-weight: 500;
  color: var(--text);
}

.poll-option-votes {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9em;
  color: var(--text-muted);
}

.poll-option-percentage {
  font-weight: 700;
  color: var(--primary);
  min-width: 50px;
  text-align: right;
}

/* Progress Bar for Poll Options */
.poll-option-progress {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  background: linear-gradient(90deg, rgba(108,92,231,0.15), rgba(108,92,231,0.05));
  border-right: 2px solid var(--primary);
  transition: width 0.3s ease;
  z-index: 1;
  pointer-events: none;
}

/* Comments Section - Redesigned */
.poll-comments { 
  padding: 24px;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
}

.poll-comments h4 {
  font-size: 1.3em;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 20px 0;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
}

.poll-comments h4::before {
  content: "\f075";
  font-family: "Font Awesome 5 Free";
  font-weight: 900;
  color: var(--primary);
}

/* Comments List */
#comments-list {
  max-height: 400px;
  overflow-y: auto;
  margin-bottom: 20px;
  padding-right: 8px;
}

#comments-list::-webkit-scrollbar {
  width: 6px;
}

#comments-list::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.02);
  border-radius: 3px;
}

#comments-list::-webkit-scrollbar-thumb {
  background: rgba(108,92,231,0.3);
  border-radius: 3px;
}

#comments-list::-webkit-scrollbar-thumb:hover {
  background: rgba(108,92,231,0.5);
}

/* Individual Comment Item */
.comment-item { 
  background: rgba(255,255,255,0.03);
  border: 2px solid var(--border);
  border-radius: 0;
  padding: 16px;
  margin-bottom: 12px;
  transition: all 0.2s ease;
  animation: slideInUp 0.3s ease;
}

.comment-item:hover {
  background: rgba(255,255,255,0.05);
  border-color: rgba(108,92,231,0.2);
  transform: translateX(4px);
}

.comment-header { 
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.comment-author {
  font-weight: 600;
  color: var(--primary);
  font-size: 1.1em;
  display: flex;
  align-items: center;
  gap: 8px;
}

.comment-author .role-badge {
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.75em;
  font-weight: 600;
  margin-left: 4px;
}

.comment-author .gm-badge {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.comment-author .mod-badge {
  background: rgba(34, 197, 94, 0.2);
  color: #22c55e;
  border: 1px solid rgba(34, 197, 94, 0.3);
}

.comment-date {
  margin-left: auto;
  color: var(--text-muted);
  font-size: 0.85em;
  opacity: 0.7;
}

.comment-content {
  color: var(--text);
  line-height: 1.6;
  font-size: 0.95em;
  white-space: pre-wrap;
  word-wrap: break-word;
}

/* Comment Links */
.comment-link {
  color: #60a5fa !important;
  text-decoration: none;
  border-bottom: 1px solid rgba(96, 165, 250, 0.3);
  transition: all 0.2s ease;
  padding: 2px 0;
  word-break: break-all;
}

.comment-link:hover {
  color: #93c5fd !important;
  border-bottom-color: #93c5fd;
  background: rgba(96, 165, 250, 0.1);
  padding: 2px 4px;
  border-radius: 3px;
}

.comment-link:visited {
  color: #a78bfa !important;
}

/* Comment Form - Enhanced */
.comment-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
  background: rgba(255,255,255,0.04);
  border: 2px solid var(--border);
  border-radius: 0;
}

.comment-form textarea { 
  width: 100%;
  min-height: 100px;
  background: rgba(255,255,255,0.03);
  border: 2px solid var(--border);
  border-radius: 0;
  color: var(--text);
  padding: 14px;
  font-size: 0.95em;
  resize: vertical;
  transition: all 0.2s ease;
  font-family: inherit;
}

.comment-form textarea:focus {
  outline: none;
  border-color: var(--primary);
  background: rgba(255,255,255,0.05);
  box-shadow: 0 0 0 3px rgba(108,92,231,0.1);
}

.comment-form textarea::placeholder {
  color: var(--text-muted);
  opacity: 0.6;
}

.comment-form .btn {
  align-self: flex-end;
  padding: 12px 24px;
  font-weight: 600;
  transition: all 0.2s ease;
}

/* Empty Comments State */
#comments-list p {
  text-align: center;
  color: var(--text-muted);
  padding: 40px 20px;
  font-style: italic;
  opacity: 0.7;
}

/* Animation */
@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Login Modal Info Message */
.login-info-message {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 24px;
  margin: 0 0 24px 0;
  background: rgba(108,92,231,0.1);
  border: 2px solid rgba(108,92,231,0.2);
  border-left: none;
  border-right: none;
  border-radius: 0;
  color: var(--text);
  font-size: 0.95em;
  animation: slideInUp 0.3s ease;
}

.login-info-message i {
  color: var(--primary);
  font-size: 1.2em;
  flex-shrink: 0;
}

.login-info-message span {
  line-height: 1.4;
  color: var(--text-muted);
}

/* Login Error Message */
.login-error-message {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px 20px;
  margin: 0 24px 20px 24px;
  background: rgba(239,68,68,0.1);
  border: 2px solid rgba(239,68,68,0.3);
  border-left: 4px solid #ef4444;
  border-radius: 0;
  animation: shake 0.3s ease;
}

.login-error-message i {
  color: #ef4444;
  font-size: 1.3em;
  flex-shrink: 0;
  margin-top: 2px;
}

.login-error-message .error-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.login-error-message .error-title {
  font-weight: 600;
  color: #ef4444;
  font-size: 1em;
}

.login-error-message .error-details {
  font-size: 0.9em;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Login Loading State */
.login-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 20px;
  margin: 0 0 20px 0;
  background: rgba(108,92,231,0.05);
  border-radius: 8px;
}

.login-loading i {
  font-size: 1.5em;
  color: var(--primary);
}

.login-loading span {
  color: var(--text);
  font-size: 0.95em;
}

/* Shake animation for errors */
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-4px); }
  20%, 40%, 60%, 80% { transform: translateX(4px); }
}

/* ============================================
   PROFILE SECTION - COMPLETE VERTICAL REDESIGN
   ============================================ */

#profile-section,
.profile-section-redesigned {
  display: none;
  padding: 60px 0;
  background: transparent;
  position: relative;
  z-index: 1;
}

.profile-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Profile Header - Clean Vertical Layout */
.profile-header {
  background: rgba(20, 24, 44, 0.8);
  backdrop-filter: blur(10px);
  border: 2px solid rgba(59, 130, 246, 0.2);
  border-radius: 16px;
  padding: 40px;
  margin-bottom: 30px;
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.profile-header::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--primary), transparent);
  opacity: 0.05;
  pointer-events: none;
}

/* Avatar Section */
.profile-avatar-section {
  margin-bottom: 24px;
}

.avatar-wrapper {
  width: 140px;
  height: 140px;
  position: relative;
  margin: 0 auto;
}

.avatar-image,
.avatar-placeholder {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(108,92,231,0.3);
  border: 3px solid var(--primary);
}

.avatar-image {
  object-fit: contain;
}

.avatar-placeholder {
  background: linear-gradient(135deg, var(--primary), var(--primary-600));
  display: flex;
  align-items: center;
  justify-content: center;
}

.avatar-placeholder i {
  font-size: 60px;
  color: white;
  opacity: 0.9;
}

/* Avatar Change Button */
.avatar-change-btn {
  position: absolute;
  bottom: 5px;
  right: 5px;
  width: 40px;
  height: 40px;
  background: var(--primary);
  border: 3px solid rgba(20,24,44,0.98);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.avatar-change-btn:hover {
  transform: scale(1.1);
  background: var(--primary-600);
}

.avatar-change-btn label {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

.avatar-change-btn i {
  font-size: 16px;
  color: white;
}

/* Profile Information */
.profile-info {
  width: 100%;
  max-width: 600px;
}

.profile-display-name {
  font-size: 2.2em;
  font-weight: 700;
  margin: 0 0 8px 0;
  color: var(--text);
  line-height: 1.2;
}

.profile-account-name {
  font-size: 1.1em;
  color: var(--text-muted);
  margin: 0 0 20px 0;
  opacity: 0.8;
}

/* Profile Badges */
.profile-badges {
  display: flex;
  gap: 10px;
  margin-bottom: 24px;
  flex-wrap: wrap;
  justify-content: center;
}

.badge {
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.85em;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge i {
  font-size: 0.9em;
}

.badge-role {
  background: rgba(108,92,231,0.15);
  color: var(--primary);
  border: 1px solid rgba(108,92,231,0.3);
}

.badge-role.badge-admin {
  background: rgba(239,68,68,0.15);
  color: #ef4444;
  border-color: rgba(239,68,68,0.3);
}

.badge-joined {
  background: rgba(255,255,255,0.05);
  color: var(--text-muted);
  border: 1px solid var(--border);
}

.badge-character {
  background: rgba(251,146,60,0.15);
  color: #fb923c;
  border: 1px solid rgba(251,146,60,0.3);
}

/* Profile Actions */
.profile-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.action-btn {
  padding: 10px 20px;
  border-radius: 8px;
  border: 2px solid var(--border);
  background: rgba(255,255,255,0.03);
  color: var(--text);
  font-size: 0.95em;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.action-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.action-btn.btn-primary {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.action-btn.btn-primary:hover {
  background: var(--primary-600);
}

.action-btn.btn-secondary {
  background: rgba(108,92,231,0.1);
  border: 2px solid rgba(108,92,231,0.3);
  color: var(--primary);
}

.action-btn.btn-secondary:hover {
  background: rgba(108,92,231,0.2);
  border-color: var(--primary);
}

/* Statistics Section */
.profile-stats-section {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  max-width: 900px;
  margin: 0 auto;
}

.stat-card {
  background: rgba(20, 24, 44, 0.6);
  backdrop-filter: blur(10px);
  border: 2px solid rgba(59, 130, 246, 0.2);
  border-radius: 12px;
  padding: 25px;
  text-align: center;
  transition: all 0.3s ease;
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
  border-color: var(--primary);
}

/* Profile Section Styling */
#profile-section {
  background: transparent; /* Use main body background */
  min-height: calc(100vh - 80px);
  padding: 40px 0;
  position: relative;
  z-index: 1;
}

#profile-section.active {
  display: block !important;
}

.profile-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

.profile-card {
  background: linear-gradient(135deg, rgba(20, 24, 44, 0.9) 0%, rgba(30, 35, 55, 0.8) 100%);
  backdrop-filter: blur(20px);
  border: 2px solid rgba(59, 130, 246, 0.3);
  border-radius: 20px;
  padding: 40px;
  margin-bottom: 30px;
  transition: all 0.3s ease;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  gap: 40px;
  position: relative;
  overflow: hidden;
}

.profile-card::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.1), transparent);
  pointer-events: none;
}

.profile-card::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 250px;
  height: 250px;
  background: radial-gradient(circle, rgba(168, 85, 247, 0.08), transparent);
  pointer-events: none;
}

.profile-avatar {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, #3b82f6, #a855f7);
  padding: 4px;
  box-shadow: 0 15px 35px rgba(59, 130, 246, 0.4);
  flex-shrink: 0;
  position: relative;
  animation: floatAvatar 6s ease-in-out infinite;
}

@keyframes floatAvatar {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

.profile-avatar .avatar-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(168, 85, 247, 0.2));
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.profile-avatar .avatar-placeholder i {
  font-size: 60px;
  color: rgba(255, 255, 255, 0.8);
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.3));
}

.profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.avatar-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--primary), var(--primary-600));
  display: flex;
  align-items: center;
  justify-content: center;
}

.avatar-placeholder i {
  font-size: 60px;
  color: white;
  opacity: 0.9;
}

.profile-info {
  flex: 1;
  position: relative;
  z-index: 2;
}

.profile-info .profile-name {
  font-size: 2.2em;
  font-weight: 800;
  margin: 0 0 8px 0;
  background: linear-gradient(135deg, #ffffff, #93bbfc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
}

.profile-info .profile-username {
  color: #64748b;
  font-size: 1.1em;
  margin: 0 0 20px 0;
  font-weight: 500;
}

.profile-info .profile-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 25px 0;
}

.profile-info .badge {
  padding: 8px 16px;
  border-radius: 25px;
  font-size: 0.85em;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;
  border: 1px solid transparent;
}

.profile-info .badge-role.badge-admin {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(239, 68, 68, 0.1));
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.3);
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.2);
}

.profile-info .badge-role.badge-admin i {
  color: #fbbf24;
  filter: drop-shadow(0 2px 4px rgba(251, 191, 36, 0.3));
}

.profile-info .badge-joined {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
  border-color: rgba(59, 130, 246, 0.3);
}

.profile-info .badge-character {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(168, 85, 247, 0.1));
  color: #a855f7;
  border-color: rgba(168, 85, 247, 0.3);
}

.profile-info .badge:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.profile-info .btn-primary {
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  color: white;
  border: none;
  padding: 14px 28px;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 20px;
  font-size: 0.95em;
  box-shadow: 0 8px 20px rgba(59, 130, 246, 0.3);
  position: relative;
  overflow: hidden;
}

.profile-info .btn-primary::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.profile-info .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(59, 130, 246, 0.4);
}

.profile-info .btn-primary:hover::before {
  width: 300px;
  height: 300px;
}

.profile-name {
  font-size: 2.5em;
  font-weight: 700;
  margin: 0 0 10px 0;
  color: white;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.profile-username {
  font-size: 1.2em;
  color: #93bbfc;
  margin: 0 0 20px 0;
}

.profile-badges {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 25px;
}

.profile-badges .badge {
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.85em;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-role {
  background: rgba(108,92,231,0.2);
  color: var(--primary);
  border: 1px solid rgba(108,92,231,0.4);
}

.badge-role.badge-admin {
  background: rgba(239,68,68,0.2);
  color: #ef4444;
  border-color: rgba(239,68,68,0.4);
}

.badge-joined {
  background: rgba(59,130,246,0.2);
  color: #93bbfc;
  border: 1px solid rgba(59,130,246,0.4);
}

.badge-character {
  background: rgba(251,146,60,0.2);
  color: #fb923c;
  border: 1px solid rgba(251,146,60,0.4);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.stats-grid .stat-card {
  background: rgba(20, 24, 44, 0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(108, 92, 231, 0.2);
  text-align: center;
  padding: 30px 20px;
}

.stats-grid .stat-card:hover {
  border-color: var(--primary);
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(108,92,231,0.2);
}

.stats-grid .stat-icon {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, rgba(108,92,231,0.2), rgba(59,130,246,0.2));
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 15px;
}

.stats-grid .stat-icon i {
  font-size: 24px;
  color: #93bbfc;
}

.stats-grid .stat-content {
  text-align: center;
}

.stats-grid .stat-value {
  font-size: 2.5em;
  font-weight: 700;
  color: white;
  margin-bottom: 5px;
}

.stats-grid .stat-label {
  font-size: 0.9em;
  color: #93bbfc;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Activity Section */
.activity-section {
  background: rgba(20, 24, 44, 0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(108, 92, 231, 0.2);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}

.activity-section .tabs {
  display: flex;
  background: rgba(0,0,0,0.3);
  border-bottom: 2px solid rgba(59,130,246,0.3);
}

.activity-section .tab-btn {
  flex: 1;
  padding: 20px;
  background: transparent;
  border: none;
  color: #64748b;
  font-size: 1em;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: relative;
}

.activity-section .tab-btn:hover {
  background: rgba(108,92,231,0.1);
  color: #93bbfc;
}

.activity-section .tab-btn.active {
  color: white;
  background: rgba(108,92,231,0.2);
}

.activity-section .tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--primary);
}

.activity-section .tab-content {
  padding: 30px;
  min-height: 400px;
}

.activity-section .tab-pane {
  display: none;
}

.activity-section .tab-pane.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.loading-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  color: #64748b;
  gap: 12px;
}

.loading-placeholder i {
  font-size: 2em;
  color: var(--primary);
  animation: spin 1s linear infinite;
}

/* Responsive Design for Profile */
@media (max-width: 768px) {
  .profile-card {
    flex-direction: column;
    text-align: center;
    padding: 30px 20px;
  }
  
  .profile-avatar {
    margin: 0 auto 20px;
  }
  
  .profile-info {
    text-align: center;
  }
  
  .profile-badges {
    justify-content: center;
  }
  
  .profile-name {
    font-size: 2em;
  }
  
  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }
  
  .activity-section .tabs {
    flex-direction: column;
  }
  
  .activity-section .tab-btn {
    width: 100%;
    border-bottom: 1px solid rgba(59,130,246,0.2);
  }
  
  .activity-section .tab-btn.active::after {
    display: none;
  }
  
  .activity-section .tab-btn.active {
    border-left: 3px solid var(--primary);
  }
}

@media (max-width: 480px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
  
  .profile-name {
    font-size: 1.5em;
  }
  
  .profile-badges .badge {
    font-size: 0.75em;
    padding: 6px 12px;
  }
}

.no-content {
  text-align: center;
  padding: 40px;
  color: #64748b;
  font-size: 1.1em;
}

/* Profile specific poll grid */
.activity-section .polls-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}

.activity-section .poll-card {
  background: rgba(0,0,0,0.3);
  border: 1px solid rgba(59,130,246,0.3);
  padding: 20px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.activity-section .poll-card:hover {
  transform: translateY(-3px);
  border-color: var(--primary);
  box-shadow: 0 5px 20px rgba(108,92,231,0.2);
}

.activity-section .poll-card h3 {
  color: white;
  margin-bottom: 10px;
}

.activity-section .poll-card p {
  color: #93bbfc;
  margin-bottom: 15px;
  font-size: 0.9em;
}

.activity-section .poll-meta {
  display: flex;
  gap: 15px;
  color: #64748b;
  font-size: 0.85em;
}

.activity-section .poll-meta span {
  display: flex;
  align-items: center;
  gap: 5px;
}

/* Votes and Comments List Styling */
.votes-list, .comments-list {
  display: grid;
  gap: 15px;
}

.vote-item, .comment-item {
  background: rgba(20, 24, 44, 0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 16px;
  transition: all 0.3s ease;
  position: relative;
}

.vote-item:hover, .comment-item:hover {
  border-color: #3b82f6;
  transform: translateX(5px);
  box-shadow: 0 5px 20px rgba(59, 130, 246, 0.1);
  background: rgba(30, 64, 175, 0.2);
}

.vote-item h4, .comment-item p {
  color: white;
  margin-bottom: 10px;
}

.vote-item p {
  color: #93bbfc;
  margin-bottom: 10px;
}

.vote-item small, .comment-meta {
  color: #64748b;
  font-size: 0.85em;
}

.comment-meta {
  display: flex;
  gap: 15px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(59,130,246,0.2);
}

.comment-meta span {
  display: flex;
  align-items: center;
  gap: 5px;
}

/* Error state styling */
.error {
  text-align: center;
  padding: 40px;
  color: #ef4444;
  font-size: 1.1em;
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.3);
  border-radius: 12px;
}

/* Duplicate poll card definition removed - using main definition */

.poll-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  border-color: var(--primary);
}

/* Featured Poll Cards - Premium Design */
.featured-polls {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 24px;
  margin-top: 24px;
}

.poll-card.featured {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f172a 100%);
  border: 2px solid #1e40af;
  padding: 32px;
  position: relative;
  overflow: hidden;
  color: white;
  box-shadow: 0 10px 40px rgba(30, 64, 175, 0.2);
}

.poll-card.featured::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.1) 0%, transparent 60%);
  pointer-events: none;
}

.poll-card.featured::after {
  content: '⭐ FEATURED';
  position: absolute;
  top: 20px;
  right: -30px;
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: white;
  padding: 4px 40px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  transform: rotate(45deg);
  box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.poll-card.featured:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 15px 60px rgba(30, 64, 175, 0.3);
  border-color: #3b82f6;
}

.poll-card.featured .poll-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  position: relative;
  z-index: 1;
}

.poll-card.featured .poll-category {
  background: rgba(59, 130, 246, 0.2) !important;
  backdrop-filter: blur(10px);
  color: white !important;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid rgba(59, 130, 246, 0.4);
}

.poll-card.featured .poll-type {
  background: rgba(30, 64, 175, 0.3);
  padding: 6px 12px;
  border-radius: 16px;
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: white;
}

.poll-card.featured .poll-title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 16px;
  color: white;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
  position: relative;
  z-index: 1;
}

.poll-card.featured .poll-description {
  color: rgba(255, 255, 255, 0.95);
  line-height: 1.6;
  margin-bottom: 24px;
  font-size: 15px;
  position: relative;
  z-index: 1;
}

.poll-card.featured .poll-meta {
  display: flex;
  gap: 24px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  position: relative;
  z-index: 1;
}

.poll-card.featured .poll-meta span {
  display: flex;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 14px;
  font-weight: 500;
}

.poll-card.featured .poll-meta i {
  color: rgba(255, 255, 255, 0.8);
  font-size: 16px;
}

/* Animation for featured cards */
@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

.poll-card.featured:hover::before {
  animation: shimmer 2s infinite;
  background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.15), transparent);
  background-size: 1000px 100%;
}

.stat-icon {
  width: 60px;
  height: 60px;
  background: rgba(108,92,231,0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.stat-icon i {
  font-size: 24px;
  color: var(--primary);
}

.stat-content {
  flex: 1;
}

.stat-value {
  font-size: 2em;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}

.stat-title {
  font-size: 0.9em;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Profile Navigation */
.profile-navigation {
  background: rgba(20,24,44,0.98);
  border: 2px solid var(--border);
  border-radius: 8px;
  padding: 8px;
  margin-bottom: 24px;
  display: flex;
  gap: 8px;
}

.nav-tab {
  flex: 1;
  padding: 14px 20px;
  background: transparent;
  border: 2px solid transparent;
  border-radius: 6px;
  color: var(--text-muted);
  font-size: 0.95em;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  position: relative;
}

.nav-tab:hover {
  background: rgba(108,92,231,0.05);
  color: var(--text);
}

.nav-tab.active {
  background: rgba(108,92,231,0.15);
  border-color: var(--primary);
  color: var(--primary);
}

.nav-tab i {
  font-size: 1.1em;
}

/* Content Panels */
.profile-content {
  background: rgba(20,24,44,0.98);
  border: 2px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  min-height: 500px;
}

.tab-panel {
  display: none;
  animation: fadeIn 0.3s ease;
}

.tab-panel.active {
  display: block;
}

.panel-header {
  padding: 24px;
  background: rgba(108,92,231,0.05);
  border-bottom: 2px solid var(--border);
}

.panel-title {
  font-size: 1.5em;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 8px 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.panel-title i {
  color: var(--primary);
}

.panel-description {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95em;
}

.panel-content {
  padding: 24px;
}

.loading-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  color: var(--text-muted);
  gap: 12px;
}

.loading-placeholder i {
  font-size: 2em;
  color: var(--primary);
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.profile-meta {
  display: flex;
  gap: 20px;
  margin-bottom: 12px;
}

.profile-meta span {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  font-size: 0.95em;
}

.profile-handle {
  color: var(--primary);
  font-weight: 600;
}

.profile-role {
  padding: 4px 12px;
  background: rgba(108,92,231,0.1);
  border: 1px solid rgba(108,92,231,0.3);
  border-radius: 20px;
  color: var(--primary);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.8em;
  letter-spacing: 0.5px;
}

.profile-role.admin {
  background: rgba(239,68,68,0.15);
  border-color: rgba(239,68,68,0.4);
  color: #ef4444;
}

.profile-role.moderator {
  background: rgba(34,197,94,0.15);
  border-color: rgba(34,197,94,0.4);
  color: #22c55e;
}

.profile-role.player {
  background: rgba(108,92,231,0.1);
  border-color: rgba(108,92,231,0.3);
  color: var(--primary);
}

.profile-character {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background: rgba(108,92,231,0.08);
  border: 2px solid rgba(108,92,231,0.2);
  border-radius: 0;
  margin-top: 16px;
  color: var(--text);
  width: fit-content;
}

.profile-character i {
  color: var(--primary);
  font-size: 1.2em;
}

.profile-character strong {
  color: var(--primary);
}

.profile-character .btn {
  margin-left: auto;
}

/* Small Button Style */
.btn.btn-sm {
  padding: 6px 12px;
  font-size: 0.85em;
  font-weight: 600;
}

/* Profile Stats Grid */
.profile-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  position: relative;
  z-index: 1;
}

.profile-stat {
  background: rgba(255,255,255,0.03);
  border: 2px solid var(--border);
  padding: 20px;
  text-align: center;
  transition: all 0.3s ease;
}

.profile-stat:hover {
  background: rgba(108,92,231,0.08);
  border-color: rgba(108,92,231,0.3);
  transform: translateY(-4px);
}

.stat-number {
  font-size: 2.5em;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 4px;
}

.stat-label {
  color: var(--text-muted);
  font-size: 0.9em;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

/* Profile Navigation Card */
.profile-nav-card {
  background: rgba(20,24,44,0.98);
  border: 2px solid var(--border);
  border-radius: 0;
  padding: 0;
  margin-bottom: 24px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

.profile-tabs {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--border);
}

.profile-tab {
  flex: 1;
  padding: 20px;
  background: transparent;
  border: none;
  border-right: 2px solid var(--border);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  position: relative;
}

.profile-tab:last-child {
  border-right: none;
}

.profile-tab:hover {
  background: rgba(108,92,231,0.05);
  color: var(--text);
}

.profile-tab.active {
  background: rgba(108,92,231,0.1);
  color: var(--primary);
}

.profile-tab.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--primary);
}

.profile-tab i {
  font-size: 1.5em;
}

.profile-tab span {
  font-size: 0.9em;
}

/* Profile Content Card */
.profile-content-card {
  background: rgba(20,24,44,0.98);
  border: 2px solid var(--border);
  border-radius: 0;
  padding: 0;
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  min-height: 500px;
}

.profile-tab-content {
  display: none;
  animation: fadeIn 0.3s ease;
}

.profile-tab-content.active {
  display: block;
}

.content-header {
  padding: 24px;
  background: rgba(108,92,231,0.05);
  border-bottom: 2px solid var(--border);
}

.content-header h2 {
  margin: 0 0 8px 0;
  color: var(--text);
  font-size: 1.5em;
  display: flex;
  align-items: center;
  gap: 12px;
}

.content-header h2 i {
  color: var(--primary);
}

.content-header p {
  margin: 0;
  color: var(--text-muted);
}

.content-body {
  padding: 24px;
}

/* Activity Grid */
.activity-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.activity-card {
  background: rgba(255,255,255,0.03);
  border: 2px solid var(--border);
  padding: 20px;
  transition: all 0.3s ease;
}

.activity-card:hover {
  background: rgba(108,92,231,0.08);
  border-color: rgba(108,92,231,0.3);
}

.activity-icon {
  width: 48px;
  height: 48px;
  background: rgba(108,92,231,0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.activity-icon i {
  font-size: 20px;
  color: var(--primary);
}

.activity-info h3 {
  margin: 0 0 8px 0;
  color: var(--text);
}

.activity-info p {
  margin: 0 0 12px 0;
  color: var(--text-muted);
  font-size: 0.9em;
}

.activity-stat {
  display: flex;
  align-items: center;
  gap: 8px;
}

.stat-value {
  font-size: 1.5em;
  font-weight: 700;
  color: var(--primary);
}

/* Activity Overview Styles */
.activity-overview {
  display: grid;
  gap: 24px;
}

.activity-summary {
  background: rgba(255,255,255,0.03);
  border: 2px solid var(--border);
  border-radius: 8px;
  padding: 24px;
}

.activity-summary h3 {
  font-size: 1.2em;
  margin: 0 0 16px 0;
  color: var(--text);
}

.contribution-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
}

.contribution-item {
  text-align: center;
  padding: 12px;
  background: rgba(108,92,231,0.05);
  border-radius: 6px;
}

.contribution-count {
  display: block;
  font-size: 1.8em;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 4px;
}

.contribution-label {
  font-size: 0.85em;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Responsive */
@media (max-width: 1100px) {
  .hero-stats { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
  .hero-stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .hero-stats { grid-template-columns: 1fr; }
  .featured-polls, .polls-grid, .ideas-grid { grid-template-columns: 1fr; }
  .nav-container { padding-left: 6px; padding-right: 6px; }
  .search-box input { width: 200px; }
  
  /* Profile Responsive Design */
  .profile-container {
    padding: 0 10px;
  }
  
  .profile-header {
    padding: 30px 20px;
  }
  
  .avatar-wrapper {
    width: 120px;
    height: 120px;
  }
  
  .profile-display-name {
    font-size: 1.8em;
  }
  
  .profile-actions {
    flex-direction: column;
    width: 100%;
  }
  
  .action-btn {
    width: 100%;
  }
  
  .profile-stats-section {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .profile-navigation {
    flex-direction: column;
  }
  
  .nav-tab {
    width: 100%;
  }
  
  .nav-tab span {
    display: none;
  }
  
  .nav-tab i {
    font-size: 1.3em;
  }
}

/* Archive Section Styles */
.section-subtitle {
  color: var(--text-secondary);
  font-size: 1em;
  margin-top: -10px;
  margin-bottom: 20px;
}

.archive-tabs {
  display: flex;
  gap: 10px;
  margin: 20px 0;
  padding: 10px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 0;
  flex-wrap: wrap;
}

.archive-tab-btn {
  padding: 10px 20px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 0;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
}

.archive-tab-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--primary);
  color: var(--text-primary);
}

.archive-tab-btn.active {
  background: linear-gradient(135deg, var(--primary), #a78bfa);
  border-color: var(--primary);
  color: white;
}

.archive-status-filter {
  display: flex;
  gap: 10px;
  margin: 20px 0;
  flex-wrap: wrap;
}

.status-filter-btn {
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 0;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-filter-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--primary);
  color: var(--text-primary);
}

.status-filter-btn.active {
  background: linear-gradient(135deg, var(--primary), #a78bfa);
  border-color: var(--primary);
  color: white;
}

.status-filter-btn[data-status="approved"].active {
  background: linear-gradient(135deg, #22c55e, #10b981);
}

.status-filter-btn[data-status="denied"].active {
  background: linear-gradient(135deg, #ef4444, #dc2626);
}

.archive-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
  margin: 20px 0;
}

.archive-grid .loading,
.archive-grid .empty-state,
.archive-grid .error-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
  color: var(--text-secondary);
  font-size: 1.1em;
}

.archive-grid .empty-state {
  background: rgba(255, 255, 255, 0.03);
  border: 2px dashed var(--border);
  border-radius: 0;
}

@media (max-width: 768px) {
  .archive-grid {
    grid-template-columns: 1fr;
  }
  
  .archive-tabs,
  .archive-status-filter {
    flex-direction: column;
  }
  
  .archive-tab-btn,
  .status-filter-btn {
    width: 100%;
    justify-content: center;
  }
}
