/* styles1.css */

/* Reset some default styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background: black;
  color: grey;
  font-family: 'Segoe UI', Arial, sans-serif;
  min-height: 100vh;
  line-height: 1.5;
}

/* Header */
header {
  background: black;
  padding: 1.5rem 1rem;
  text-align: center;
  border-bottom: 1px solid #222;
}

header h1 {
  font-size: 2rem;
  color: white;
  letter-spacing: 1px;
}

/* Main Content */
main {
  padding: 1rem;
  max-width: 800px;
  margin: 0 auto;
}

/* Chart Section */
#chart-container {
  background: black;
  border-radius: 12px;
  padding: 1rem;
  margin-bottom: 2rem;
  box-shadow: 0 2px 16px rgba(0,0,0,0.3);
}

#chart-container select {
  background: #222;
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 0.5rem 1rem;
  margin-right: 0.5rem;
  font-size: 1rem;
  margin-bottom: 1rem;
}

#historyChart {
  width: 100% !important;
  max-height: 320px;
  background: #222;
  border-radius: 8px;
  margin-top: 1rem;
}

/* Loading Indicator */
#loading-indicator {
  color: #00ffb3;
  text-align: center;
  padding: 1rem 0;
  font-size: 1.2rem;
  display: none; /* Show/hide via JS */
}

/* Crypto Table */
#crypto-table {
  width: 100%;
  border-collapse: collapse;
  background: #181818;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 2rem;
  box-shadow: 0 2px 16px rgba(0,0,0,0.3);
}

#crypto-table th,
#crypto-table td {
  padding: 0.75rem 0.5rem;
  text-align: left;
}

#crypto-table th {
  background: #222;
  color: #00ffb3;
  font-weight: 600;
  letter-spacing: 0.5px;
}

#crypto-table tbody tr {
  border-bottom: 1px solid #222;
}

#crypto-table tbody tr:last-child {
  border-bottom: none;
}

#crypto-table td {
  color: #f5f5f5;
}

#crypto-table td:nth-child(4) {
  font-weight: bold;
}

#crypto-table td.positive {
  color: #00ffb3;
}

#crypto-table td.negative {
  color: #ff4f4f;
}

/* News Section */
section h2 {
  color: yellow;
  margin-bottom: 0.75rem;
  font-size: 1.3rem;
}

#news {
  list-style: none;
  padding-left: 0;
}

#news li {
  background: #181818;
  padding: 0.75rem;
  margin-bottom: 0.5rem;
  border-radius: 8px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.16);
  font-size: 1rem;
}

/* Responsive Design */
@media (max-width: 600px) {
  header h1 {
    font-size: 1.3rem;
  }
  main {
    padding: 0.5rem;
  }
  #chart-container,
  #crypto-table,
  #news li {
    padding: 0.5rem;
    font-size: 0.95rem;
  }
  #crypto-table th,
  #crypto-table td {
    padding: 0.5rem 0.25rem;
    font-size: 0.95rem;
  }
  #historyChart {
    max-height: 200px;
  }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
  width: 8px;
  background: #181818;
}
::-webkit-scrollbar-thumb {
  background: #222;
  border-radius: 8px;
}
