/* ===== KOMUNITA – Dark Theme ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #0D0D2B;
  --bg-light: #13133a;
  --card: rgba(255,255,255,0.05);
  --card-border: rgba(255,255,255,0.1);
  --cyan: #00C8E0;
  --purple: #6366F1;
  --green: #22c55e;
  --red: #ef4444;
  --yellow: #f59e0b;
  --white: #ffffff;
  --gray: #94a3b8;
  --text: #e2e8f0;
  --radius: 12px;
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
}

a { color: var(--cyan); text-decoration: none; }
a:hover { opacity: 0.85; }

.container { max-width: 1100px; margin: 0 auto; padding: 0 20px; }

/* ===== NAVBAR ===== */
.navbar {
  background: rgba(13,13,43,0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--card-border);
  padding: 14px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--white);
}
.nav-logo span { color: var(--cyan); }
.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
  list-style: none;
}
.nav-links a {
  color: var(--gray);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--white); }
.nav-user {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--white);
  font-weight: 600;
  font-size: 14px;
}
.nav-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--purple);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--white);
}

/* ===== BUTTONS ===== */
.btn-primary {
  display: inline-block;
  background: var(--cyan);
  color: var(--bg);
  font-weight: 700;
  padding: 12px 28px;
  border-radius: var(--radius);
  border: none;
  font-size: 15px;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}
.btn-primary:hover { background: #00b8cf; opacity: 1; }
.btn-outline {
  display: inline-block;
  border: 1px solid var(--card-border);
  color: var(--white);
  font-weight: 600;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-size: 15px;
  cursor: pointer;
  transition: all 0.2s;
  background: transparent;
  text-align: center;
}
.btn-outline:hover { border-color: var(--cyan); color: var(--cyan); }
.btn-full { width: 100%; }
.btn-sm { padding: 8px 18px; font-size: 13px; }
.btn-danger { background: var(--red); }
.btn-danger:hover { background: #dc2626; }

/* ===== CARDS ===== */
.card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 24px;
}

/* ===== AUTH PAGES ===== */
.auth-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: calc(100vh - 120px);
  padding: 40px 20px;
}
.auth-box {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 40px;
  width: 100%;
  max-width: 440px;
}
.auth-box h1 {
  font-size: 1.6rem;
  color: var(--white);
  margin-bottom: 4px;
}
.auth-subtitle {
  color: var(--gray);
  margin-bottom: 28px;
  font-size: 14px;
}
.auth-form { display: flex; flex-direction: column; gap: 16px; }
.auth-link {
  text-align: center;
  margin-top: 20px;
  font-size: 14px;
  color: var(--gray);
}

/* ===== FORMS ===== */
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--gray);
}
.form-group input,
.form-group textarea,
.form-group select {
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--card-border);
  border-radius: 8px;
  padding: 12px 14px;
  color: var(--white);
  font-size: 15px;
  font-family: inherit;
  transition: border-color 0.2s;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--cyan);
}
.form-group textarea { resize: vertical; min-height: 100px; }

/* ===== DASHBOARD ===== */
.dashboard-header {
  padding: 40px 0 20px;
}
.dashboard-header h1 {
  font-size: 1.5rem;
  color: var(--white);
}
.dashboard-header p {
  color: var(--gray);
  font-size: 14px;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  margin: 20px 0;
}
.stat-card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
}
.stat-card .stat-value {
  font-size: 2rem;
  font-weight: 800;
  color: var(--cyan);
}
.stat-card .stat-label {
  font-size: 13px;
  color: var(--gray);
  margin-top: 4px;
}

/* ===== SIDEBAR LAYOUT ===== */
.app-layout {
  display: flex;
  min-height: 100vh;
}
.sidebar {
  width: 220px;
  background: var(--bg-light);
  border-right: 1px solid var(--card-border);
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  z-index: 50;
}
.sidebar-logo {
  padding: 20px;
  text-align: center;
  border-bottom: 1px solid var(--card-border);
}
.sidebar-logo a {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--white);
  text-decoration: none;
}
.sidebar-logo span { color: var(--cyan); }
.sidebar-section-label {
  font-size: 10px;
  color: rgba(255,255,255,0.3);
  padding: 18px 20px 6px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-weight: 700;
}
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 20px;
  color: var(--gray);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.15s;
}
.sidebar-link:hover { color: var(--white); background: rgba(255,255,255,0.04); }
.sidebar-link.active {
  color: var(--cyan);
  background: rgba(0,200,224,0.08);
  border-right: 3px solid var(--cyan);
}
.sidebar-icon { font-size: 1rem; width: 20px; text-align: center; }
.sidebar-spacer { flex: 1; }
.sidebar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 20px;
  border-top: 1px solid var(--card-border);
  margin-top: auto;
}
.sidebar-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--purple);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: var(--white);
  flex-shrink: 0;
}
.sidebar-user-info { min-width: 0; }
.sidebar-user-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--white);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sidebar-logout {
  font-size: 11px;
  color: var(--gray);
}
.app-main {
  margin-left: 220px;
  flex: 1;
  padding: 30px;
  min-height: 100vh;
}
.app-main h1 {
  color: var(--white);
  font-size: 1.4rem;
  margin-bottom: 20px;
}

/* ===== NOVINKY SPLIT ===== */
.novinky-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.novinky-item {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}
.novinky-item .novinky-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.novinky-item .novinky-datum {
  font-size: 12px;
  font-weight: 700;
  color: var(--cyan);
  background: rgba(0,200,224,0.1);
  padding: 4px 10px;
  border-radius: 6px;
}
.novinky-item .novinky-ikona {
  font-size: 1.5rem;
}
.novinky-item h3 { color: var(--white); margin-bottom: 6px; font-size: 1rem; }
.novinky-item p { color: var(--gray); font-size: 14px; }
.novinky-item .meta { font-size: 12px; color: rgba(255,255,255,0.3); margin-top: 8px; }
.prani-item {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.prani-text { flex: 1; font-size: 14px; color: var(--text); }
.prani-meta { font-size: 12px; color: var(--gray); margin-top: 4px; }
.prani-vote {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}
.prani-vote button {
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--card-border);
  color: var(--cyan);
  width: 36px;
  height: 36px;
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
}
.prani-vote button:hover { background: rgba(0,200,224,0.15); }
.prani-vote button.voted { background: var(--cyan); color: var(--bg); }
.prani-count { font-size: 14px; font-weight: 700; color: var(--cyan); }

/* ===== ZEBRICEK ===== */
.zebricek-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 20px;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  margin-bottom: 8px;
}
.zebricek-rank {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--cyan);
  width: 36px;
  text-align: center;
}
.zebricek-rank.top-1 { color: #fbbf24; font-size: 1.4rem; }
.zebricek-rank.top-2 { color: #94a3b8; }
.zebricek-rank.top-3 { color: #cd7f32; }
.zebricek-info { flex: 1; }
.zebricek-name { font-weight: 600; color: var(--white); }
.zebricek-firma { font-size: 12px; color: var(--gray); }
.zebricek-body { font-weight: 700; color: var(--cyan); font-size: 1.1rem; }

/* ===== KALENDAR ===== */
.kalendar-item {
  display: flex;
  gap: 16px;
  padding: 20px;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  margin-bottom: 12px;
}
.kalendar-datum {
  background: var(--cyan);
  color: var(--bg);
  border-radius: 10px;
  padding: 10px 14px;
  text-align: center;
  font-weight: 800;
  min-width: 60px;
  flex-shrink: 0;
}
.kalendar-datum .den { font-size: 1.5rem; line-height: 1; }
.kalendar-datum .mesic { font-size: 11px; text-transform: uppercase; }
.kalendar-detail h3 { color: var(--white); margin-bottom: 4px; }
.kalendar-detail p { color: var(--gray); font-size: 14px; }
.kalendar-meta { font-size: 12px; color: var(--gray); margin-top: 6px; }

/* ===== EMPTY STATE ===== */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--gray);
}
.empty-state .empty-icon { font-size: 3rem; margin-bottom: 12px; }
.empty-state h3 { color: var(--white); margin-bottom: 8px; }

@media (max-width: 768px) {
  .sidebar { width: 60px; }
  .sidebar-logo a { font-size: 0.9rem; }
  .sidebar-section-label, .sidebar-user-info, .sidebar-link span:not(.sidebar-icon) { display: none; }
  .sidebar-link { justify-content: center; padding: 14px; }
  .sidebar-icon { width: auto; }
  .app-main { margin-left: 60px; padding: 20px; }
  .novinky-layout { grid-template-columns: 1fr; }
}

/* ===== PROFILE ===== */
.profile-grid {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 24px;
  padding: 40px 0;
}
.profile-sidebar { text-align: center; }
.profile-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: var(--purple);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--white);
  margin: 0 auto 16px;
}
.profile-name {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--white);
}
.profile-firma {
  color: var(--gray);
  font-size: 14px;
}
.profile-badge {
  display: inline-block;
  background: var(--cyan);
  color: var(--bg);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  margin-top: 8px;
}

/* ===== PREMIUM HERO ===== */
.hero-premium {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--bg) 0%, #141460 50%, var(--bg) 100%);
  padding: 120px 20px 80px;
}
.hero-grain {
  position: absolute;
  inset: 0;
  z-index: 1;
  opacity: .03;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 128px;
}
.hero-shapes { position: absolute; inset: 0; overflow: hidden; }
.hero-shape {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
}
.hero-shape-1 {
  width: 600px; height: 600px;
  background: rgba(0,200,224,0.08);
  top: -200px; right: -100px;
}
.hero-shape-2 {
  width: 400px; height: 400px;
  background: rgba(99,102,241,0.06);
  bottom: -100px; left: -50px;
}

.hero-badge-premium {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 100px;
  padding: 8px 24px;
  font-size: .65rem;
  font-weight: 800;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
  margin-bottom: 2.5rem;
}
.hero-badge-dot {
  width: 6px; height: 6px;
  background: var(--cyan);
  border-radius: 50%;
  animation: pulse 2s infinite;
}
@keyframes pulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:.5;transform:scale(1.3)} }

.hero-title-premium {
  font-size: clamp(3rem, 12vw, 140px);
  font-weight: 900;
  line-height: 0.85;
  letter-spacing: -0.05em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 2rem;
}
.hero-title-line { display: block; }
.hero-title-gradient {
  background: linear-gradient(180deg, var(--white) 0%, rgba(255,255,255,0.3) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-sub-premium {
  font-size: clamp(1rem, 0.9rem + 0.5vw, 1.2rem);
  color: rgba(255,255,255,0.6);
  max-width: 550px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
  font-weight: 300;
}

.hero-btns-premium {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 3.5rem;
}
.btn-premium {
  padding: 1rem 2rem;
  font-size: .8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  border-radius: 0;
  background: var(--cyan);
  color: var(--bg);
  border: none;
  text-decoration: none;
  transition: all 0.3s;
}
.btn-premium:hover {
  background: var(--cyan-light, #5DE8F5);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0,200,224,0.3);
}
.btn-glass {
  padding: 1rem 2rem;
  font-size: .8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  border-radius: 0;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  color: var(--white);
  text-decoration: none;
  transition: all 0.3s;
}
.btn-glass:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.2);
}

.hero-stats-premium {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
}
.hero-stat-item strong {
  display: block;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--white);
}
.hero-stat-item span {
  font-size: .65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(255,255,255,0.4);
}
.hero-stat-div {
  width: 1px;
  height: 32px;
  background: rgba(255,255,255,0.1);
}

/* Premium hero entrance */
.hero-premium .container > * {
  opacity: 0;
  transform: translateY(30px);
  animation: heroIn 0.8s cubic-bezier(0.16,1,0.3,1) forwards;
}
.hero-premium .container > *:nth-child(1) { animation-delay: 0.1s; }
.hero-premium .container > *:nth-child(2) { animation-delay: 0.3s; }
.hero-premium .container > *:nth-child(3) { animation-delay: 0.5s; }
.hero-premium .container > *:nth-child(4) { animation-delay: 0.65s; }
.hero-premium .container > *:nth-child(5) { animation-delay: 0.8s; }
@keyframes heroIn {
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 768px) {
  .hero-premium { padding: 100px 16px 60px; min-height: auto; }
  .hero-stats-premium { flex-direction: column; gap: 1rem; }
  .hero-stat-div { width: 40px; height: 1px; }
  .hero-btns-premium { flex-direction: column; }
  .hero-btns-premium a { width: 100%; text-align: center; }
}

/* Legacy hero fallback */
.hero-section {
  text-align: center;
  padding: 80px 20px 60px;
}
.hero-section h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 900;
  color: var(--white);
  margin-bottom: 16px;
  line-height: 1.2;
}
.hero-section h1 span { color: var(--cyan); }
.hero-section p {
  color: var(--gray);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto 32px;
}
.hero-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  padding: 40px 0;
}
.feature-card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 28px;
}
.feature-icon {
  font-size: 2rem;
  margin-bottom: 12px;
}
.feature-card h3 {
  color: var(--white);
  margin-bottom: 8px;
  font-size: 1.1rem;
}
.feature-card p {
  color: var(--gray);
  font-size: 14px;
}

/* ===== FOOTER ===== */
.footer {
  border-top: 1px solid var(--card-border);
  padding: 30px 0;
  text-align: center;
  color: var(--gray);
  font-size: 13px;
  margin-top: 60px;
}
.footer a { color: var(--cyan); }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .profile-grid { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .auth-box { padding: 28px 20px; }
  .stats-grid { grid-template-columns: 1fr; }
}

/* ===== LANG SWITCH ===== */
.lang-switch {
  display: flex;
  align-items: center;
  gap: 6px;
}
.lang-btn {
  background: none;
  border: none;
  color: var(--gray);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.2s;
  font-family: 'Inter', sans-serif;
}
.lang-btn:hover { color: var(--white); }
.lang-btn.active {
  color: var(--cyan);
  background: rgba(0,200,224,0.1);
}
