/* ============================================================
   STYLE.CSS v2.1 — Complete, Universeel, Mobile-First
   Voor: index, dashboard, vote, profile, about, login, nav.js
   ============================================================ */

/* ============================================================
   1. GLOBAL VARIABLES + THEMES
   ============================================================ */
:root {
  --bg: #071827;
  --panel: #0f2a3a;
  --panel-alt: #112b3c;
  --card-bg: #112b3c;
  --text: #e6f2f8;
  --muted: #9fb0bf;
  --accent: #ff7a00;
  --accent-soft: #ff9d47;
  --radius: 10px;
  --shadow: 0 8px 30px rgba(0,0,0,0.45);
}
html, body {
  overflow-x: hidden;
}
body.theme-light {
  --bg: #ffffff;
  --text: #0a0a0a;
  --panel: #f2f2f2;
  --panel-alt: #ffffff;
  --muted: #444;
}

body {
  margin: 0;
  font-family: Inter, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

/* ============================================================
   2. LAYOUT BASICS
   ============================================================ */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 16px;
}
*, *:before, *::after {
 box-sizing: border-box;
}

section {
  margin-bottom: 40px;
}

a {
  text-decoration: none;
  color: var(--accent);
}

/* ============================================================
   3. HEADER + NAVIGATION (nav.js)
   ============================================================ */
.site-header {
  background: #0f0f0f;
  border-bottom: 1px solid #222;
  position: sticky;
  top: 0;
  z-index: 200;
}

/* Top navigation bar */
.top-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
}

/* Logo */
.header-logo {
  height: 110px;
  width: auto;
}
@media (max-width: 600px) {
  .header-logo {
    height: 90px;
  }
}

/* Right-side nav items */
.nav-right {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.icon-btn {
  background: none;
  border: none;
  color: #ccc;
  cursor: pointer;
  font-size: 16px;
  padding: 6px;
}
.icon-btn:hover {
  color: var(--accent);
}

/* Hamburger */
.menu-toggle {
  background: none;
  border: none;
  color: #ccc;
  cursor: pointer;
  font-size: 24px;
  padding: 4px;
}
.menu-toggle:hover {
  color: var(--accent);
}

/* Second row links */
.link-bar {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 18px;
  padding: 12px 0;
  background: #181818;
  border-top: 1px solid #222;
}
.link-bar.hidden {
  display: none;
}
.link-bar a {
  color: #ccc;
  display: flex;
  align-items: center;
  gap: 6px;
}
.link-bar a:hover {
  color: var(--accent);
}

.nav-link.active {
  color: var(--accent);
  font-weight: 700;
}

.nav-link.active svg {
  fill: var(--accent);
}

.user-avatar img {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--accent);
  cursor: pointer;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.user-avatar img:hover {
  transform: scale(1.06);
  opacity: 0.85;
}

/* ------------------------------
   PROFIELFOTO + RINGS
------------------------------ */
.profile-photo-wrapper {
  position: relative;
  width: 92px;
  height: 92px;
}

.profile-photo-wrapper img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #111;
  box-shadow: 0 0 6px var(--ring-color), 0 0 16px var(--ring-color);
  transition: 0.25s ease;
}

/* Ring Levels */
.ring-basic { --ring-color: #3AF2E8; }
.ring-active { --ring-color: #B762FF; }
.ring-veteran { --ring-color: #FFD700; }

.ring-premium {
  --ring-color: #4DAEFF;
  animation: premiumPulse 2.4s infinite ease-in-out;
}

@keyframes premiumPulse {
  0% { box-shadow: 0 0 6px var(--ring-color), 0 0 16px var(--ring-color); }
  50% { box-shadow: 0 0 10px var(--ring-color), 0 0 26px var(--ring-color); }
  100% { box-shadow: 0 0 6px var(--ring-color), 0 0 16px var(--ring-color); }
}

.nav-profile {
  display: flex;
  margin-right: 12px; /* ruimte rechts */
  margin-left: 12px;  /* ruimte links */
  align-items: center;
  cursor: pointer;
}

.nav-profile .profile-photo-wrapper {
  width: 36px;
  height: 36px;
}

.active-link {
  color: var(--accent);
  font-weight: 600;
}

.top-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px var(--container-padding);
}


/* ============================================================
   4. BUTTONS
   ============================================================ */
.btn {
  padding: 8px 12px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  font-weight: 600;
}

.btn-primary {
  background: var(--accent);
  color: #071827;
}
.btn-primary:hover {
  background: var(--accent-soft);
}

.btn-ghost {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.15);
  color: var(--text);
}
.btn-ghost:hover {
  border-color: var(--accent);
}
.input,
.btn-primary,
.btn-ghost {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

/* ============================================================
   5. CARDS + GRID
   ============================================================ */
.card {
  background: var(--panel);
  padding: 18px;
  box-sizing: border-box; 
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-top: 16px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.tile {
  background: var(--panel-alt);
  padding: 14px;
  border-radius: 8px;
  transition: transform .2s ease, opacity .2s ease;
}
.tile:hover {
  transform: translateY(-4px);
}
.tile.voted {
  opacity: .45;
}

/* ============================================================
   6. FORMS
   ============================================================ */
.input {
  width: 100%;
  padding: 10px;
  margin-top: 10px;
  border-radius: 6px;
  background: transparent;
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.15);
}
.input:focus {
  border-color: var(--accent);
  outline: none;
}

/* ============================================================
   7. HERO SECTIONS
   ============================================================ */
.hero-banner {
  position: relative;
  min-height: 420px;
  display: flex;
  justify-content: center;
  align-items: center;
  background-size: cover;
  background-position: center;
  text-align: center;
}

.hero-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.55);
}
.hero-overlay {
  position: relative;
  color: #fff;
  padding: 40px 20px;
  max-width: 800px;
}

/* ============================================================
   8. TICKER (index.html)
   ============================================================ */
.ticker-line {
  width: 100%;
  padding: 10px 0;
  margin: 30px auto;
  background: linear-gradient(90deg, #ff8c00, #ff6600);
  white-space: nowrap;
  overflow: hidden;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  font-weight: 500;
}
.ticker-item {
  display: inline-block;
  margin-right: 24px;
  font-size: 14px;
  color: #fff;
}

.ticker-price {
  margin-left: 4px;
  color: #ccc;
}

.ticker-change {
  margin-left: 4px;
  font-weight: bold;
}

.ticker-item.pos .ticker-change {
  color: #4caf50;
}

.ticker-item.neg .ticker-change {
  color: #f44336;
}

#ticker-content {
  display: inline-block;
  animation: ticker-scroll 25s linear infinite;
  font-weight: 500;
  font-size: 0.95rem;
}

@keyframes ticker-scroll {
  from { transform: translateX(100%); }
  to   { transform: translateX(-100%); }
}

.ticker-pos { color: #2ce67b; }
.ticker-neg { color: #ff4d4d; }

/* ============================================================
   9. SUBNAV (profile, dashboard, vote)
   ============================================================ */
.subnav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  background: #141414;
  border-top: 1px solid rgba(255,255,255,0.08);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.subnav a {
  padding: 12px 18px;
  color: #ccc;
}
.subnav a.active,
.subnav a:hover {
  color: #fff;
  background: rgba(255,255,255,0.08);
}

/* ============================================================
   10. MODALS
   ============================================================ */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: flex;
  justify-content: center;
  align-items: center;
  visibility: hidden;
  opacity: 0;
  transition: .3s ease;
  backdrop-filter: blur(8px);
}
.modal.show {
  visibility: visible;
  opacity: 1;
}

.modal-content {
  background: var(--panel-alt);
  padding: 32px;
  max-width: 420px;
  width: 90%;
  border-radius: 12px;
}


/* ============================================================
   11. FOOTER
   ============================================================ */

.site-footer {
  padding: 40px 0 60px;
  background: var(--panel);
  border-top: 1px solid rgba(255,255,255,0.07);
  margin-top: 40px;
}

.footer-inner {
  text-align: center;
}

.footer-logo img {
  width: 120px;
  max-width: 60%;
  opacity: 0.85;
  display: block;
  margin: 0 auto 12px;
}

.footer-partners {
  margin: 18px 0 25px;
  display: none;
}

.footer-partners img {
  width: 110px;
  margin: 0 12px;
  opacity: 0.6;
  filter: grayscale(100%);
  transition: opacity 0.25s ease, filter 0.25s ease, transform 0.25s ease;
}

.footer-partners img:hover {
  opacity: 1;
  filter: grayscale(0%);
  transform: scale(1.05);
}

.footer-social {
  margin-bottom: 20px;
}

.footer-social .social-icon img {
  width: 26px;
  margin: 0 8px;
  opacity: 0.8;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.footer-social .social-icon img:hover {
  opacity: 1;
  transform: scale(1.12);
}

.footer-copy {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-top: 10px;
  line-height: 1.5;
}

/* ============================================================
   12. RESPONSIVE
   ============================================================ */
@media (max-width: 900px) {
  .grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  }
}

@media (max-width: 600px) {
  .hero-overlay h1 {
    font-size: 1.6rem;
  }
}

@media (max-width: 480px) {
  .grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .top-nav {
    padding: 8px 8px;
  }
  .nav-right {
    gap: 6px;
    min-width: 0;
  }
  .icon-btn {
    font-size: 14px;
    padding: 4px;
  }
  .menu-toggle {
    max-width: 100%;
    font-size: 30px;
    margin-right: 0;
  }
  .header-logo {
    height: 54px; /* voorkomt dat logo te breed wordt in combinatie */
  }
}
@media (max-width: 480px) {
  main.container {
    padding: 10px;
    display: block;  /* voorkomt horizontale druk */
  }
}

/* --- Vote Card Styling --- */

.stock-card {
  background: #111;
  padding: 16px;
  border-radius: 14px;
  border: 1px solid #222;
  transition: 0.25s;
  position: relative;
}

.stock-card.voted {
  opacity: 0.6;
  border-color: #ff7b00;
}

.stock-card header {
  display: flex;
  justify-content: center;
  margin-bottom: 8px;
}

.stock-card .logo {
  width: 42px;
  height: 42px;
  object-fit: contain;
  opacity: 0.9;
}

/* Name */
.stock-name {
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 12px;
}

/* Price box */
.stock-price-box {
  text-align: center;
  margin-bottom: 12px;
}

.stock-price-label {
  font-size: 11px;
  opacity: 0.65;
  margin-bottom: 2px;
}

.stock-price {
  font-size: 20px;
  font-weight: 700;
}

/* Change indicator */
.change-up { color: #2ecc71; }
.change-down { color: #e74c3c; }
.change-neutral { color: #bbb; }

/* Vote Options */
.vote-options {
  display: flex;
  justify-content: space-between;
  margin-top: 14px;
}

.vote-options.disabled {
  pointer-events: none;
  opacity: 0.2;
}

.vote-btn {
  flex: 1;
  margin: 0 4px;
  padding: 10px 0;
  border-radius: 10px;
  background: #1a1a1a;
  color: #fff;
  font-weight: 600;
  border: 1px solid #333;
  transition: 0.2s;
  cursor: pointer;
}

.vote-btn:hover {
  transform: translateY(-2px);
  border-color: #ff7b00;
}

/* --- Voted Info Box --- */

.vote-info {
  margin-top: 14px;
  padding: 12px;
  border-radius: 12px;
  border: 2px solid rgba(255, 123, 0, 0.7);
  background: rgba(255, 123, 0, 0.10);
  animation: fadeSlideIn 0.3s ease-out;
}

.vote-info-title {
  font-weight: 700;
  margin-bottom: 6px;
  font-size: 14px;
}

.vote-info-row {
  display: flex;
  justify-content: space-between;
  margin: 3px 0;
  font-size: 14px;
}

.vote-symbol {
  font-size: 20px;
  font-weight: 700;
}

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.notif-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-bottom: 1px solid #222;
  cursor: pointer;
  transition: background 0.2s ease;
}

.notif-row:hover {
  background: #1b1b1b;
}

.notif-row.unread {
  background: #202020;
  border-left: 3px solid var(--accent-color, #f97316);
}

.notif-icon {
  font-size: 1.3rem;
}

.notif-text {
  flex: 1;
}

.notif-time {
  font-size: 0.75rem;
}

.small {
  font-size: 0.85rem;
}

.score-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
  font-size: 0.95rem;
}
.score-row strong {
  font-weight: 600;
}
.score-total {
  border-top: 1px solid rgba(255,255,255,0.08);
  margin-top: 8px;
  padding-top: 8px;
  font-size: 1.05rem;
}
.info-tip {
  cursor: help;
  font-size: 0.85em;
  opacity: 0.7;
}
.score-progress { margin-top: 10px; }
.score-progress-bar {
  width: 100%;
  height: 8px;
  background: rgba(255,255,255,0.1);
  border-radius: 4px;
  overflow: hidden;
}
.score-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #22c55e, #60a5fa);
}


/* --- Animated score tooltip --- */
.animated-tip {
  position: relative;
  display: inline-block;
  margin-left: 6px;
  cursor: pointer;
  font-size: 0.85em;
  opacity: 0.75;
}

.animated-tip:focus {
  outline: none;
}

/* Tooltip box */
.score-tooltip {
  position: absolute;
  bottom: 140%;
  left: 50%;
  transform: translateX(-50%) scale(0.96);
  background: #0f172a;
  color: #e5e7eb;
  border-radius: 10px;
  padding: 12px 14px;
  width: 220px;
  box-shadow: 0 15px 40px rgba(0,0,0,0.45);
  opacity: 0;
  pointer-events: none;
  z-index: 1000;

  /* animation */
  transition:
    opacity 0.25s ease,
    transform 0.25s cubic-bezier(.16,1,.3,1);
}

/* Arrow */
.score-tooltip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border-width: 8px;
  border-style: solid;
  border-color: #0f172a transparent transparent transparent;
}

/* Active state */
.animated-tip.active .score-tooltip {
  opacity: 1;
  transform: translateX(-50%) scale(1);
  pointer-events: auto;
}

/* Rows */
.tooltip-row {
  display: grid;
  grid-template-columns: 20px 1fr auto;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 0.85rem;
}

.tooltip-row strong {
  color: #60a5fa;
}

.tooltip-row .icon {
  text-align: center;
}

/* Footer */
.tooltip-footer {
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid rgba(255,255,255,0.08);
  font-size: 0.7rem;
  color: #9ca3af;
}

/* Subtle hover */
.animated-tip:hover {
  opacity: 1;
}
