:root {
  --card: rgba(255, 255, 255, 0.94);
  --line: rgba(255, 255, 255, 0.14);
  --text: #0f1728;
  --muted: #6a7284;
  --accent: #1e6bff;
  --accent-2: #15a06a;
  --danger: #ff5c57;
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.22);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: "Segoe UI", Arial, sans-serif;
  color: #fff;
  background:
    radial-gradient(circle at top, rgba(30, 107, 255, 0.18), transparent 35%),
    linear-gradient(180deg, #0c0f14 0%, #111827 100%);
}

body[data-category="politics"] {
  background:
    radial-gradient(circle at top, rgba(30, 107, 255, 0.28), transparent 35%),
    linear-gradient(180deg, #0c0f14 0%, #111827 100%);
}

body[data-category="sports"] {
  background:
    radial-gradient(circle at top, rgba(21, 160, 106, 0.26), transparent 35%),
    linear-gradient(180deg, #08110d 0%, #111827 100%);
}

body[data-category="tech"] {
  background:
    radial-gradient(circle at top, rgba(149, 86, 255, 0.24), transparent 35%),
    linear-gradient(180deg, #0d0a18 0%, #111827 100%);
}

body[data-category="entertainment"] {
  background:
    radial-gradient(circle at top, rgba(255, 123, 0, 0.26), transparent 35%),
    linear-gradient(180deg, #140d08 0%, #111827 100%);
}

.phone-app {
  width: 100%;
  max-width: 430px;
  height: 100dvh;
  margin: 0 auto;
  padding: 14px 12px 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.topbar,
.story-card,
.bottom-bar {
  backdrop-filter: blur(18px);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 4px 0;
}

.eyebrow {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.76rem;
  color: rgba(255, 255, 255, 0.72);
}

.btn {
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border-radius: 14px;
  padding: 11px 14px;
  font-weight: 700;
  cursor: pointer;
}

.btn.primary {
  background: var(--accent);
  border-color: var(--accent);
}

.btn.danger {
  background: rgba(255, 92, 87, 0.14);
  border-color: rgba(255, 92, 87, 0.18);
  color: #fff;
}

.story-stage {
  position: relative;
  flex: 1;
  min-height: 0;
  touch-action: none;
}

.left-rail {
  position: absolute;
  left: -2px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 3;
}

.nav-btn {
  width: 52px;
  height: 52px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 1.35rem;
  font-weight: 800;
  box-shadow: var(--shadow);
}

.story-card {
  position: relative;
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 16px 14px 14px 64px;
  border-radius: 28px;
  background: var(--card);
  color: var(--text);
  box-shadow: var(--shadow);
}

.story-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-bottom: 10px;
}

.count {
  color: var(--muted);
  font-weight: 700;
  letter-spacing: 0.04em;
}

.story-headline {
  margin: 0 0 10px;
  color: var(--accent-2);
  font-weight: 800;
  letter-spacing: 0.02em;
}

.story-image-wrap {
  overflow: hidden;
  border-radius: 24px;
  background: #e8edf4;
  border: 1px solid rgba(15, 23, 42, 0.08);
  flex: 1;
  min-height: 0;
}

.story-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.story-body {
  padding: 12px 4px 0;
}

.story-title {
  margin: 0 0 8px;
  font-size: clamp(1.25rem, 5vw, 1.65rem);
  line-height: 1.18;
}

.story-summary {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  font-size: 0.98rem;
}

.bottom-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 6px 2px;
}

@media (max-width: 430px) {
  .phone-app {
    padding: 12px 10px 10px;
  }

  .story-card {
    padding-left: 60px;
  }
}
