* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  background: #f5f5f5;
  display: flex;
  height: 100vh;
}

a {
  color: #1abc9c;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* Sidebar */
.sidebar {
  width: 250px;
  background: #2c3e50;
  color: white;
  padding: 20px;
  overflow-y: auto;
  box-shadow: 2px 0 5px rgba(0, 0, 0, 0.1);
}

.sidebar h1 {
  font-size: 20px;
  margin-bottom: 30px;
}

.sidebar ul {
  list-style: none;
}

.sidebar li {
  margin-bottom: 0;
}

.sidebar button {
  width: 100%;
  padding: 12px;
  background: #34495e;
  color: white;
  border: none;
  text-align: left;
  cursor: pointer;
  font-size: 14px;
  margin-bottom: 5px;
  border-radius: 4px;
  transition: background 0.2s;
}

.sidebar button:hover {
  background: #1abc9c;
}

.sidebar button.active {
  background: #1abc9c;
}

/* Main Content */
.main {
  flex: 1;
  padding: 30px;
  overflow-y: auto;
}

h2 {
  color: #2c3e50;
  margin-bottom: 20px;
  font-size: 28px;
}

h3 {
  font-size: 20px;
}

/* Pages */
.page {
  display: none;
}

.page.active {
  display: block;
}

/* Forms */
.form-group {
  margin-bottom: 15px;
}

label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
  color: #333;
  font-size: 16px;
}

input,
select,
textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 16px;
  font-family: Arial, sans-serif;
}

textarea {
  min-height: 120px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #1abc9c;
  box-shadow: 0 0 5px rgba(26, 188, 156, 0.3);
}

/* Buttons */
button.search-btn {
  width: 100%;
  padding: 12px;
  background: #1abc9c;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  font-weight: bold;
  margin-top: 10px;
  min-height: 44px;
  transition: background 0.2s;
}

button.search-btn:hover {
  background: #16a085;
}

button.search-btn:disabled {
  background: #cccccc;
  cursor: not-allowed;
}

button.delete-btn {
  background: #d32f2f;
}

button.delete-btn:hover {
  background: #b71c1c;
}

/* Containers */
.intro-section {
  background: white;
  padding: 20px;
  border-radius: 4px;
  margin-bottom: 20px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.intro-section p {
  color: #555;
  line-height: 1.6;
  font-size: 16px;
}

.intro-section.green-bg {
  background: #e8f5e9;
}

.form-container {
  background: white;
  padding: 20px;
  border-radius: 4px;
  margin-bottom: 20px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.form-container.danger-zone {
  background: #ffebee;
  border-left: 4px solid #d32f2f;
}

/* Results */
.results {
  margin-top: 20px;
  padding: 15px;
  background: white;
  border-radius: 4px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Statistics */
.stat-box {
  display: inline-block;
  background: white;
  padding: 20px;
  margin-right: 20px;
  margin-bottom: 20px;
  border-radius: 4px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  min-width: 200px;
  text-align: center;
}

.stat-number {
  font-size: 32px;
  font-weight: bold;
  color: #1abc9c;
}

.stat-label {
  font-size: 14px;
  color: #666;
  margin-top: 5px;
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  font-size: 16px;
}

th,
td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid #eee;
}

th {
  background: #f8f9fa;
  font-weight: bold;
  color: #2c3e50;
}

tr:hover {
  background: #f8f9fa;
}

/* Messages */
.error {
  color: #d32f2f;
  padding: 10px;
  background: #ffebee;
  border-radius: 4px;
  font-size: 16px;
}

.success {
  color: #388e3c;
  padding: 10px;
  background: #e8f5e9;
  border-radius: 4px;
  font-size: 16px;
}

.info {
  color: #1976d2;
  padding: 10px;
  background: #e3f2fd;
  border-radius: 4px;
  font-size: 16px;
}

/* AI Assistant Styles */
.agent-section {
  background: #ffffff;
  padding: 40px;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  margin-bottom: 30px;
  max-width: 900px;
}

.agent-title {
  font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 32px;
  font-weight: 300;
  letter-spacing: -0.5px;
  color: #1a1a1a;
  margin: 0 0 30px 0;
}

.status-line {
  font-family: 'SF Mono', Monaco, 'Courier New', monospace;
  font-size: 13px;
  color: #666;
  margin-bottom: 30px;
  padding: 12px 16px;
  background: #f8f8f8;
  border-radius: 4px;
  border-left: 3px solid #1abc9c;
}

#agentQuery {
  width: 100%;
  padding: 16px 20px;
  margin: 0 0 16px 0;
  font-size: 16px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  transition: all 0.2s;
}

#agentQuery:focus {
  outline: none;
  border-color: #1abc9c;
  box-shadow: 0 0 0 3px rgba(26, 188, 156, 0.1);
}

#queryButton {
  width: 100%;
  padding: 16px;
  background: #1abc9c;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 15px;
  font-weight: 500;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  transition: all 0.2s;
  letter-spacing: 0.3px;
}

#queryButton:hover:not(:disabled) {
  background: #16a085;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(26, 188, 156, 0.3);
}

#queryButton:disabled {
  background: #bdc3c7;
  cursor: not-allowed;
  transform: none;
}

#agentResult {
  margin-top: 30px;
  padding: 20px;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 6px;
  white-space: pre-wrap;
  font-family: 'SF Mono', Monaco, 'Courier New', monospace;
  font-size: 14px;
  line-height: 1.6;
  color: #2c3e50;
  display: none;
  max-height: 500px;
  overflow-y: auto;
}

.loading {
  color: #95a5a6;
  font-style: normal;
  animation: pulse 1.5s ease-in-out infinite;
}

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

/* Example Queries */
.examples-container {
  background: white;
  padding: 30px;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  max-width: 900px;
}

.example-queries {
  margin: 30px 0 0 0;
}

.examples-title {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: #7f8c8d;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.example-query {
  background-color: #f8f9fa;
  padding: 10px 16px;
  margin: 0 8px 8px 0;
  border-radius: 20px;
  display: inline-block;
  cursor: pointer;
  font-size: 14px;
  border: 1px solid #e9ecef;
  transition: all 0.2s;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #495057;
}

.example-query:hover {
  background-color: #e9ecef;
  border-color: #dee2e6;
  transform: translateY(-1px);
}

/* Mobile Styles */
@media (max-width: 768px) {
  body {
    flex-direction: column;
    height: auto;
  }

  .sidebar {
    width: 100%;
    padding: 15px;
    overflow-y: visible;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  }

  .sidebar h1 {
    font-size: 24px;
    margin-bottom: 15px;
  }

  .sidebar ul {
    display: flex;
    gap: 5px;
    overflow-x: auto;
  }

  .sidebar li {
    flex: 1;
    min-width: 100px;
  }

  .sidebar button {
    padding: 10px;
    font-size: 14px;
    margin-bottom: 0;
  }

  .main {
    padding: 15px;
  }

  h2 {
    font-size: 24px;
    margin-bottom: 15px;
  }

  h3 {
    font-size: 18px;
  }

  .stat-box {
    display: block;
    width: 100%;
    margin-right: 0;
    margin-bottom: 15px;
  }

  .stat-number {
    font-size: 40px;
  }

  table {
    font-size: 14px;
    overflow-x: auto;
    display: block;
  }

  th,
  td {
    padding: 10px;
    font-size: 14px;
  }

  .example-query {
    display: block;
    margin: 5px 0;
  }
}

@media (max-width: 480px) {
  .main {
    padding: 10px;
  }

  h2 {
    font-size: 20px;
  }

  h3 {
    font-size: 16px;
  }

  table {
    font-size: 13px;
  }

  th,
  td {
    padding: 8px;
    font-size: 13px;
  }
}
