/* =========================================
   InboxOS — Theme CSS
   Dark editorial, electric green accent
   ========================================= */

:root {
  --bg: #0d0d12;
  --bg-alt: #111118;
  --surface: #18181f;
  --surface-2: #1e1e28;
  --border: #252530;
  --accent: #00e5a0;
  --accent-dim: rgba(0, 229, 160, 0.12);
  --accent-glow: rgba(0, 229, 160, 0.06);
  --text: #e8e8ed;
  --text-muted: #7a7a8c;
  --text-dim: #4a4a5a;
  --font-display: 'Instrument Serif', Georgia, serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --radius: 10px;
  --radius-lg: 16px;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* === HERO === */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 80px 48px 64px;
  position: relative;
  background: var(--bg);
  background-image:
    radial-gradient(ellipse 60% 40% at 80% 50%, rgba(0, 229, 160, 0.04) 0%, transparent 70%),
    radial-gradient(ellipse 40% 60% at 10% 80%, rgba(99, 102, 241, 0.04) 0%, transparent 60%);
}

.hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0,229,160,0.2), transparent);
}

.hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.hero-eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-eyebrow::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent);
}

.hero-headline {
  font-family: var(--font-display);
  font-size: clamp(48px, 5vw, 72px);
  font-weight: 400;
  line-height: 1.08;
  color: var(--text);
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.hero-headline em {
  font-style: italic;
  color: var(--text-muted);
}

.hero-sub {
  font-size: 1.0625rem;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 440px;
  font-weight: 300;
}

/* === INBOX WIDGET === */
.hero-inbox {
  display: flex;
  justify-content: flex-end;
}

.inbox-window {
  width: 100%;
  max-width: 420px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.03);
}

.inbox-titlebar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}

.inbox-dots {
  display: flex;
  gap: 6px;
}

.inbox-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border);
}

.inbox-dots span:nth-child(1) { background: #ff5f57; }
.inbox-dots span:nth-child(2) { background: #febc2e; }
.inbox-dots span:nth-child(3) { background: #28c840; }

.inbox-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  flex: 1;
}

.inbox-status {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.inbox-status.live {
  background: var(--accent-dim);
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 5px;
}

.inbox-status.live::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s ease-in-out infinite;
}

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

.inbox-body {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 320px;
  overflow-y: auto;
}

.inbox-body::-webkit-scrollbar { width: 4px; }
.inbox-body::-webkit-scrollbar-track { background: transparent; }
.inbox-body::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.inbox-thread {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 14px;
  transition: border-color 0.2s;
}

.inbox-thread.triage { border-left: 2px solid var(--text-dim); }
.inbox-thread.important { border-left: 2px solid var(--accent); }

.thread-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 4px;
}

.sender {
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--text-muted);
}

.time {
  font-size: 0.65rem;
  color: var(--text-dim);
}

.thread-subject {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 4px;
}

.thread-snippet {
  font-size: 0.7rem;
  color: var(--text-dim);
  line-height: 1.5;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 8px;
}

.thread-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.badge {
  font-size: 0.65rem;
  padding: 2px 8px;
  border-radius: 20px;
  font-weight: 500;
}

.badge.draft { background: rgba(99, 102, 241, 0.15); color: #818cf8; }
.badge-sent { font-size: 0.65rem; color: var(--text-dim); }
.badge.archive { background: rgba(255,255,255,0.04); color: var(--text-dim); }
.badge.flag { background: var(--accent-dim); color: var(--accent); }
.badge.bulk { background: rgba(255,255,255,0.03); color: var(--text-dim); font-size: 0.6rem; }

.inbox-summary {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  padding: 10px;
  background: var(--surface-2);
  border-radius: var(--radius);
  margin-top: 4px;
}

.summary-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 6px 4px;
  background: var(--bg-alt);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.stat-num {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 2px;
}

.stat-label {
  font-size: 0.6rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.inbox-agent-bar {
  padding: 10px 16px;
  background: var(--surface-2);
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.7rem;
  color: var(--text-muted);
}

.agent-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 6px var(--accent);
  flex-shrink: 0;
}

/* === MANIFESTO === */
.manifesto {
  padding: 100px 48px;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background-image: radial-gradient(ellipse 80% 50% at 50% 50%, rgba(0, 229, 160, 0.02) 0%, transparent 70%);
}

.manifesto-inner {
  max-width: 760px;
  margin: 0 auto;
}

.manifesto-label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 32px;
}

.manifesto-statement {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.5vw, 48px);
  font-weight: 400;
  line-height: 1.2;
  color: var(--text);
  margin-bottom: 40px;
  font-style: normal;
  border: none;
}

.manifesto-body {
  font-size: 1.0625rem;
  color: var(--text-muted);
  line-height: 1.75;
  font-weight: 300;
  margin-bottom: 20px;
  max-width: 640px;
}

.manifesto-body strong {
  color: var(--text);
  font-weight: 500;
}

/* === HOW IT WORKS === */
.howitworks {
  padding: 100px 48px;
}

.hiw-inner {
  max-width: 1000px;
  margin: 0 auto;
}

.section-label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}

.section-headline {
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 40px);
  font-weight: 400;
  color: var(--text);
  margin-bottom: 60px;
  line-height: 1.2;
}

.hiw-steps {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.hiw-step {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 32px;
  padding: 40px 0;
  border-bottom: 1px solid var(--border);
  position: relative;
}

.hiw-step:last-child { border-bottom: none; }

.step-num {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 400;
  color: var(--border);
  line-height: 1;
  padding-top: 4px;
}

.step-content h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 12px;
}

.step-content p {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.7;
  font-weight: 300;
  max-width: 540px;
}

/* === FEATURES === */
.features {
  padding: 100px 48px;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
}

.features-inner {
  max-width: 1000px;
  margin: 0 auto;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.feature-card {
  background: var(--surface);
  padding: 36px 32px;
  transition: background 0.2s;
}

.feature-card:hover { background: var(--surface-2); }

.feature-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-dim);
  border-radius: 10px;
  margin-bottom: 20px;
  color: var(--accent);
}

.feature-card h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 10px;
}

.feature-card p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.65;
  font-weight: 300;
}

/* === DAILY REPORT === */
.daily-report {
  padding: 100px 48px;
}

.dr-inner {
  max-width: 1000px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.dr-body {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.7;
  font-weight: 300;
  margin-bottom: 32px;
}

.report-preview {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 16px 48px rgba(0,0,0,0.3);
}

.report-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}

.report-logo {
  font-family: var(--font-display);
  font-size: 1rem;
  color: var(--accent);
}

.report-date {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.report-body {
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.report-section {}

.rs-label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 8px;
}

.rs-item {
  font-size: 0.8125rem;
  color: var(--text-muted);
  padding: 6px 10px;
  background: var(--bg-alt);
  border-radius: 8px;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.rs-item.email { flex-direction: column; align-items: flex-start; }
.rs-item.urgent { border-left: 2px solid var(--accent); }

.rs-action {
  font-size: 0.65rem;
  font-weight: 600;
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--border);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  flex-shrink: 0;
}

.rs-from { font-weight: 600; color: var(--text); margin-bottom: 2px; }
.rs-subject { font-size: 0.75rem; color: var(--text-muted); margin-bottom: 6px; }
.rs-draft { font-size: 0.75rem; color: var(--text-muted); font-style: italic; padding: 8px 10px; background: var(--surface-2); border-radius: 6px; border-left: 2px solid #818cf8; margin: 4px 0; }
.rs-meta { font-size: 0.65rem; color: #818cf8; }
.rs-body { font-size: 0.75rem; color: var(--text-muted); margin-top: 4px; line-height: 1.5; }

/* === CLOSING === */
.closing {
  padding: 120px 48px;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  text-align: center;
  background-image:
    radial-gradient(ellipse 50% 40% at 50% 60%, rgba(0, 229, 160, 0.05) 0%, transparent 70%);
}

.closing-inner {
  max-width: 680px;
  margin: 0 auto;
}

.closing-statement {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.5vw, 32px);
  font-weight: 400;
  color: var(--text);
  line-height: 1.4;
  margin-bottom: 24px;
}

.closing-sub {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.7;
  font-weight: 300;
}

/* === FOOTER === */
.footer {
  padding: 40px 48px;
  border-top: 1px solid var(--border);
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.footer-name {
  font-family: var(--font-display);
  font-size: 1.125rem;
  color: var(--text);
}

.footer-tagline {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.footer-meta {
  font-size: 0.75rem;
  color: var(--text-dim);
}

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-inbox { display: none; }
  .hero-headline { font-size: 42px; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .dr-inner { grid-template-columns: 1fr; }
  .hiw-step { grid-template-columns: 48px 1fr; gap: 20px; }
  .step-num { font-size: 32px; }
}

@media (max-width: 600px) {
  .hero { padding: 60px 24px 48px; }
  .manifesto, .howitworks, .features, .daily-report, .closing { padding: 64px 24px; }
  .footer { padding: 32px 24px; }
  .feature-grid { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; gap: 16px; align-items: flex-start; }
}

/* === SCROLLBAR === */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
