
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --bg: #090e1d;
  --sidebar: #10182b;
  --card: #151e33;
  --border: #29334a;
  --text: #f3f6ff;
  --muted: #9aa9c2;
  --purple: #9b7cff;
  --blue: #55b6ff;
  --green: #36d6a0;
  --red: #ff7185;
  --yellow: #ffcb70;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', sans-serif;
}

.app {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 250px;
  padding: 30px 20px;
  background: var(--sidebar);
  border-right: 1px solid var(--border);
}

.logo {
  font-size: 24px;
  font-weight: 800;
  color: var(--purple);
  margin-bottom: 45px;
}

.nav-item {
  padding: 14px;
  margin-bottom: 10px;
  border-radius: 12px;
  color: var(--muted);
}

.nav-item.active {
  background: #29244b;
  color: #fff;
}

.main {
  flex: 1;
  min-width: 0;
  padding: 36px;
  max-width: 1600px;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 30px;
}

h1 {
  font-size: 30px;
  margin: 0 0 10px;
}

h2 {
  font-size: 19px;
  margin-top: 0;
}

.subtitle, .muted {
  color: var(--muted);
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px;
  margin-bottom: 24px;
}

.upload-zone {
  border: 2px dashed #6255a0;
  border-radius: 16px;
  padding: 30px;
  text-align: center;
  background: #191b36;
}

input[type="file"] {
  max-width: 100%;
  margin: 15px auto;
}

button, .btn {
  border: none;
  padding: 12px 20px;
  border-radius: 10px;
  background: linear-gradient(135deg, #8561ff, #527cff);
  color: white;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}

button:hover {
  filter: brightness(1.12);
}

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 24px;
}

.stat {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 22px;
}

.stat-label {
  color: var(--muted);
  font-size: 13px;
}

.stat-value {
  font-size: 32px;
  font-weight: 800;
  margin-top: 12px;
}

.positive { color: var(--green); }
.negative { color: var(--red); }
.neutral { color: var(--yellow); }

.grid-two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.chart-container {
  min-height: 290px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.chart-container canvas {
  max-height: 300px;
}

.table-wrapper {
  width: 100%;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

th, td {
  padding: 14px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

th {
  color: var(--muted);
  font-weight: 600;
}

td {
  vertical-align: top;
  line-height: 1.6;
}

.sentiment-badge {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 20px;
  font-weight: 700;
}

.sentiment-badge.positive {
  background: #123c32;
}

.sentiment-badge.negative {
  background: #482432;
}

.sentiment-badge.neutral {
  background: #483d24;
}

.insight {
  padding: 16px;
  border-left: 3px solid var(--purple);
  background: #1d2440;
  border-radius: 8px;
  margin-bottom: 14px;
  line-height: 1.7;
}

.accuracy-value {
  font-size: 42px;
  font-weight: 800;
  color: var(--green);
}

.status {
  color: var(--muted);
  margin-top: 12px;
  line-height: 1.6;
}

.actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.hidden {
  display: none !important;
}

@media (max-width: 1000px) {
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-two {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  .app {
    display: block;
  }

  .sidebar {
    width: 100%;
    padding: 18px;
  }

  .logo {
    margin-bottom: 10px;
  }

  .main {
    padding: 18px;
  }

  .stats {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .stat {
    padding: 15px;
  }

  .header {
    display: block;
  }
}
