* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg-main: #060913;
  --bg-card: rgba(15, 23, 42, 0.72);
  --bg-card-hover: rgba(22, 33, 58, 0.88);
  --border-subtle: rgba(148, 163, 184, 0.14);
  --border-glow: rgba(56, 189, 248, 0.45);
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --accent-cyan: #06b6d4;
  --accent-blue: #3b82f6;
  --accent-purple: #6366f1;
  --danger: #f43f5e;
  --warning: #f59e0b;
  --success: #10b981;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: var(--bg-main);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  position: relative;
}

/* Pozadie */
.bg-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(130px);
  z-index: -1;
  pointer-events: none;
}

.bg-glow-1 {
  width: 520px;
  height: 520px;
  background: rgba(14, 165, 233, 0.14);
  top: -120px;
  left: 20%;
}

.bg-glow-2 {
  width: 480px;
  height: 480px;
  background: rgba(99, 102, 241, 0.12);
  bottom: -100px;
  right: 15%;
}

/* Navigácia */
.navbar {
  max-width: 1180px;
  width: 100%;
  margin: 0 auto;
  padding: 24px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-primary);
}

.brand-icon {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #22d3ee, #3b82f6);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 16px;
  color: #04101d;
  box-shadow: 0 0 20px rgba(34, 211, 238, 0.45);
}

.brand-text {
  font-weight: 700;
  letter-spacing: 0.22em;
  font-size: 14px;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Tlačidlá */
button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
}

.btn-primary {
  background: linear-gradient(90deg, #06b6d4 0%, #3b82f6 50%, #6366f1 100%);
  color: #ffffff;
  font-weight: 600;
  font-size: 14px;
  padding: 13px 26px;
  border-radius: 12px;
  box-shadow: 0 8px 28px rgba(59, 130, 246, 0.35);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 34px rgba(59, 130, 246, 0.5);
}

.btn-secondary {
  background: rgba(30, 41, 59, 0.65);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  font-size: 13px;
  font-weight: 500;
  padding: 10px 18px;
  border-radius: 10px;
  backdrop-filter: blur(8px);
}

.btn-secondary:hover {
  background: rgba(51, 65, 85, 0.8);
  border-color: rgba(148, 163, 184, 0.3);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  font-size: 14px;
  font-weight: 500;
  padding: 13px 22px;
  border-radius: 12px;
}

.btn-ghost:hover {
  color: var(--text-primary);
  border-color: rgba(148, 163, 184, 0.35);
}

/* Hero sekcia */
main {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.hero {
  flex: 1;
  max-width: 780px;
  margin: 0 auto;
  padding: 80px 24px 90px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(34, 211, 238, 0.25);
  color: #67e8f9;
  font-size: 12px;
  font-weight: 500;
  margin-bottom: 26px;
}

.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #22d3ee;
  box-shadow: 0 0 10px #22d3ee;
}

.hero h1 {
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}

.hero h1 span {
  background: linear-gradient(90deg, #e2e8f0, #38bdf8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  color: var(--text-secondary);
  font-size: 17px;
  line-height: 1.65;
  max-width: 560px;
  margin-bottom: 36px;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
}

/* Galéria príbehov */
.gallery-section {
  max-width: 1180px;
  width: 100%;
  margin: 0 auto;
  padding: 20px 28px 80px;
  animation: fadeIn 0.35s ease;
}

.gallery-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
  margin-bottom: 32px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.gallery-header h2 {
  font-size: 26px;
  margin-bottom: 6px;
}

.gallery-header p {
  color: var(--text-secondary);
  font-size: 14px;
}

.filter-tabs {
  display: flex;
  gap: 8px;
  background: rgba(15, 23, 42, 0.8);
  padding: 5px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
}

.tab-btn {
  background: transparent;
  color: var(--text-secondary);
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
}

.tab-btn.active {
  background: rgba(56, 189, 248, 0.16);
  color: #38bdf8;
}

.stories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 22px;
}

/* Karta správy */
.story-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 18px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  backdrop-filter: blur(12px);
  transition: transform 0.2s ease, border-color 0.2s ease, opacity 0.4s ease;
}

.story-card:hover {
  transform: translateY(-3px);
  background: var(--bg-card-hover);
  border-color: var(--border-glow);
}

.story-card.highlighted {
  border-color: rgba(245, 158, 11, 0.65);
  box-shadow: 0 0 28px rgba(245, 158, 11, 0.14);
}

.story-card.fading {
  border-color: rgba(244, 63, 94, 0.5);
}

.story-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.category-tag {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: 6px;
  background: rgba(56, 189, 248, 0.12);
  color: #38bdf8;
}

.timer-badge {
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid var(--border-subtle);
  color: #e2e8f0;
}

.timer-badge.urgent {
  color: #fb7185;
  border-color: rgba(244, 63, 94, 0.4);
  animation: pulse 1.5s infinite;
}

.story-body {
  font-size: 15px;
  line-height: 1.65;
  color: #e2e8f0;
  margin-bottom: 18px;
  white-space: pre-wrap;
  word-break: break-word;
}

.whispers-list {
  margin-bottom: 16px;
  padding-top: 12px;
  border-top: 1px dashed rgba(148, 163, 184, 0.16);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.whisper-item {
  font-size: 12.5px;
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.6);
  padding: 8px 11px;
  border-radius: 8px;
  border-left: 2px solid #38bdf8;
}

.life-bar-wrap {
  width: 100%;
  height: 4px;
  background: rgba(30, 41, 59, 0.9);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 16px;
}

.life-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #06b6d4, #6366f1);
  transition: width 1s linear;
}

.story-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.action-btn {
  flex: 1;
  min-width: 90px;
  background: rgba(30, 41, 59, 0.75);
  color: #cbd5e1;
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.action-btn:hover {
  background: rgba(56, 189, 248, 0.15);
  border-color: rgba(56, 189, 248, 0.45);
  color: #ffffff;
}

.action-btn.boost-btn:hover {
  background: rgba(245, 158, 11, 0.16);
  border-color: rgba(245, 158, 11, 0.5);
  color: #fbbf24;
}

/* Modálne okná */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(3, 6, 15, 0.8);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 100;
}

.modal-card {
  background: #0f172a;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 20px;
  max-width: 480px;
  width: 100%;
  padding: 26px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.65);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}

.close-btn {
  background: transparent;
  color: var(--text-secondary);
  font-size: 24px;
  line-height: 1;
}

.close-btn:hover {
  color: #ffffff;
}

.modal-desc {
  color: var(--text-secondary);
  font-size: 13.5px;
  line-height: 1.5;
  margin-bottom: 16px;
}

.quoted-story {
  background: rgba(15, 23, 42, 0.9);
  border-left: 3px solid #38bdf8;
  padding: 10px 14px;
  font-size: 13px;
  color: #cbd5e1;
  margin-bottom: 16px;
  border-radius: 6px;
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 7px;
}

textarea, select {
  width: 100%;
  background: #060913;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 10px;
  color: var(--text-primary);
  padding: 12px;
  font-family: inherit;
  font-size: 14px;
}

textarea:focus, select:focus {
  outline: none;
  border-color: #38bdf8;
}

.char-counter {
  text-align: right;
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 5px;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
}

.boost-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.boost-option {
  width: 100%;
  text-align: left;
  background: #060913;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 12px;
  padding: 16px;
  color: var(--text-primary);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.boost-option:hover {
  border-color: #f59e0b;
  background: rgba(245, 158, 11, 0.08);
}

.boost-option strong {
  display: block;
  font-size: 14px;
  margin-bottom: 4px;
}

.boost-option span {
  font-size: 12px;
  color: var(--text-secondary);
}

.price-tag {
  font-weight: 700;
  color: #fbbf24 !important;
  font-size: 15px !important;
  white-space: nowrap;
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-secondary);
}

.empty-state p {
  margin-bottom: 18px;
}

.footer {
  text-align: center;
  padding: 26px;
  color: #475569;
  font-size: 12px;
}

.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #1e293b;
  color: #f8fafc;
  border: 1px solid rgba(56, 189, 248, 0.45);
  padding: 12px 18px;
  border-radius: 12px;
  font-size: 13.5px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.25s ease;
  z-index: 200;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.hidden {
  display: none !important;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.55; }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 640px) {
  .navbar {
    padding: 18px 16px;
  }
  .brand-text {
    font-size: 12px;
    letter-spacing: 0.14em;
  }
  .nav-actions span {
    font-size: 12px;
  }
}

/* Legal footer & modals */
.footer-links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
  font-size: 13px;
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: #38bdf8;
  text-decoration: underline;
}

.legal-card {
  max-width: 560px !important;
}

.legal-content {
  color: var(--text-secondary);
  font-size: 13.5px;
  line-height: 1.6;
  max-height: 360px;
  overflow-y: auto;
  padding-right: 6px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.legal-content ul {
  padding-left: 20px;
}

.legal-content strong {
  color: var(--text-primary);
}

/* 1. Rozsirenie zlatisteho pruzku na zvyraznenych spravach */
.story-card.highlighted {
  border: 3px solid #f59e0b !important; /* Rozsirene o 2px pre vyraznejsi efekt */
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.25) !important;
}

/* 2. Farebne odtiene kariet a stitkov podla kategorie */
/* Thought / Myslienka - jemny modry nadych */
.story-card.cat-thought {
  background: linear-gradient(145deg, rgba(30, 58, 138, 0.22), rgba(15, 23, 42, 0.9)) !important;
  border-color: rgba(59, 130, 246, 0.35);
}
.story-card.cat-thought .category-tag {
  background: rgba(59, 130, 246, 0.2);
  color: #93c5fd;
}

/* Confession / Priznanie - jemny fialovy nadych */
.story-card.cat-confession {
  background: linear-gradient(145deg, rgba(88, 28, 135, 0.22), rgba(15, 23, 42, 0.9)) !important;
  border-color: rgba(168, 85, 247, 0.35);
}
.story-card.cat-confession .category-tag {
  background: rgba(168, 85, 247, 0.2);
  color: #d8b4fe;
}

/* Secret / Tajomstvo - jemny ruzovo-cerveny nadych */
.story-card.cat-secret {
  background: linear-gradient(145deg, rgba(136, 19, 55, 0.22), rgba(15, 23, 42, 0.9)) !important;
  border-color: rgba(244, 63, 94, 0.35);
}
.story-card.cat-secret .category-tag {
  background: rgba(244, 63, 94, 0.2);
  color: #fda4af;
}

/* Advice / Rada alebo Vent - jemny smaragdovy nadych */
.story-card.cat-advice,
.story-card.cat-vent {
  background: linear-gradient(145deg, rgba(6, 78, 59, 0.22), rgba(15, 23, 42, 0.9)) !important;
  border-color: rgba(16, 185, 129, 0.35);
}
.story-card.cat-advice .category-tag,
.story-card.cat-vent .category-tag {
  background: rgba(16, 185, 129, 0.2);
  color: #6ee7b7;
}
.coffee-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 18px;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.45);
  color: #fbbf24;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.coffee-btn:hover {
  background: rgba(245, 158, 11, 0.28);
  border-color: #fbbf24;
  transform: translateY(-1px);
}
