/* base.css — Reset, theme tokens, dark theme, body, header. (split from design3.css) */

/* ===== Reset ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  line-height: 1.5;
  min-height: 100vh;
}

img, svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font: inherit;
  color: inherit;
}

ul, ol {
  list-style: none;
}

h1, h2, h3, h4, h5, h6 {
  font-size: inherit;
  font-weight: inherit;
}

/* ===== Design 3: Twitter/X Timeline ===== */

:root {
  --bg-primary: #ffffff;
  --bg-secondary: #f7f9f9;
  --bg-hover: #f0f2f5;
  --border-color: #eff3f4;
  --text-primary: #0f1419;
  --text-secondary: #536471;
  --text-tertiary: #8899a6;
  --accent: #1d9bf0;
  --accent-hover: #1a8cd8;
  --unread: #1d9bf0;
  --new-badge: #f91880;
  --avatar-size: 48px;
  --max-width: 600px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --scrollbar-bg: transparent;
  --scrollbar-thumb: #cfd9de;
}

/* ===== Dark Theme ===== */
[data-theme="dark"] {
  --bg-primary: #15202b;
  --bg-secondary: #1e2d3d;
  --bg-hover: #1c2938;
  --border-color: #38444d;
  --text-primary: #e7e9ea;
  --text-secondary: #8b98a5;
  --text-tertiary: #6e767d;
  --accent: #1d9bf0;
  --accent-hover: #1a8cd8;
  --unread: #1d9bf0;
  --new-badge: #f91880;
  --scrollbar-bg: transparent;
  --scrollbar-thumb: var(--border-color);
}

[data-theme="dark"] .top-bar {
  background: rgba(21, 32, 43, 0.85);
}

[data-theme="dark"] .story-title-bar {
  background: rgba(21, 32, 43, 0.92);
}

body {
  font-family: var(--font);
  background: var(--bg-primary);
  color: var(--text-primary);
}

/* ===== Header ===== */
.top-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
}

.top-bar-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
}

.back-link {
  color: var(--accent);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.15s;
}

.back-link:hover {
  color: var(--accent-hover);
  text-decoration: underline;
}

.logo {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.5px;
}

.logo-t {
  color: var(--accent);
}

.top-bar-right {
  font-size: 13px;
  color: var(--text-secondary);
}

