/* Daily Trading OS — shared site styles */
:root {
  --bg: #f1f5f9;
  --card: #ffffff;
  --border: #e2e8f0;
  --text: #0f172a;
  --muted: #64748b;
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
}

* { box-sizing: border-box; }

body {
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  margin: 0;
  min-height: 100vh;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); text-decoration: underline; }

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem 1.25rem;
  flex-wrap: wrap;
  padding: 0.85rem 1.5rem;
  background: var(--card);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-nav .brand {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
  margin-right: auto;
}

.site-nav .brand:hover { text-decoration: none; color: var(--accent); }

.site-nav a.nav-link {
  color: var(--muted);
  font-size: 0.92rem;
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
}

.site-nav a.nav-link:hover {
  color: var(--accent);
  background: #f8fafc;
  text-decoration: none;
}

.site-nav a.nav-link.active {
  color: var(--accent);
  font-weight: 600;
  background: #eff6ff;
}

.page-wrap {
  max-width: 960px;
  margin: 0 auto;
  padding: 1.75rem 1.25rem 3rem;
}

.page-title { margin: 0 0 0.35rem; font-size: 1.55rem; }
.muted { color: var(--muted); font-size: 0.9rem; }

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

.card {
  display: block;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.1rem 1.2rem;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.card:hover {
  border-color: #93c5fd;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.08);
  text-decoration: none;
}

.card h2 {
  margin: 0 0 0.35rem;
  font-size: 1rem;
  color: var(--text);
}

.card p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.45;
}

.panel {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  margin-top: 1.25rem;
}

.panel h2 {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.5rem;
}

table.data-table {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.9rem;
}

table.data-table th,
table.data-table td {
  border: 1px solid var(--border);
  padding: 0.55rem 0.7rem;
  text-align: left;
  vertical-align: top;
}

table.data-table th { background: #f8fafc; font-weight: 600; }
table.data-table tr:nth-child(even) td { background: #fafbfc; }

.badge {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 5px;
  font-size: 0.78rem;
  font-weight: 600;
}

.badge-ok { background: #dcfce7; color: #166534; }
.badge-warn { background: #fef9c3; color: #854d0e; }
.badge-muted { background: #f1f5f9; color: #64748b; }

.link-row { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.link-row a { font-size: 0.88rem; }

.stats-bar {
  display: flex;
  align-items: center;
  gap: 0.5rem 0.75rem;
  flex-wrap: wrap;
  font-size: 0.92rem;
}

.timeline {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-top: 1.25rem;
}

.timeline-item {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 1rem;
  align-items: start;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1.15rem;
  transition: border-color 0.15s, box-shadow 0.15s;
  color: inherit;
}

.timeline-item:hover {
  border-color: #93c5fd;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.08);
  text-decoration: none;
}

.timeline-item.done { border-left: 4px solid #22c55e; }
.timeline-item.pending { border-left: 4px solid #e2e8f0; opacity: 0.92; }

.timeline-time {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent);
  padding-top: 0.15rem;
}

.timeline-title { font-weight: 600; font-size: 1rem; margin-bottom: 0.2rem; }
.timeline-sub { font-size: 0.85rem; color: var(--muted); line-height: 1.4; }
.timeline-status { margin-top: 0.5rem; }

@media (max-width: 520px) {
  .timeline-item { grid-template-columns: 1fr; gap: 0.35rem; }
}

.empty {
  color: var(--muted);
  text-align: center;
  padding: 2rem 1rem;
}
