/* Important Numbers Page Specific Styles - Chandrapur District */
:root {
  --primary-color: #1a5276;
  --secondary-color: #d4ac0d;
  --accent-color: #e74c3c;
  --emergency-color: #e74c3c;
  --medical-color: #3498db;
  --government-color: #27ae60;
  --education-color: #9b59b6;
  --utility-color: #f39c12;
  --transport-color: #16a085;
  --financial-color: #2980b9;
  --light-bg: #f8f9fa;
  --dark-text: #2c3e50;
}

.contacts-page-body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  color: var(--dark-text);
  background-color: var(--light-bg);
}

.section-title {
  color: var(--primary-color);
  border-bottom: 3px solid var(--secondary-color);
  padding-bottom: 10px;
  margin-bottom: 25px;
  font-weight: 700;
}

.section-subtitle {
  color: var(--primary-color);
  border-left: 4px solid var(--secondary-color);
  padding-left: 15px;
  margin-bottom: 20px;
  font-weight: 600;
}

/* Emergency Cards */
.emergency-card {
  background: linear-gradient(135deg, #e74c3c, #c0392b);
  color: white;
  border-radius: 10px;
  transition: transform 0.3s ease;
  border: none;
  box-shadow: 0 4px 15px rgba(231, 76, 60, 0.3);
}

.emergency-card:hover {
  transform: translateY(-5px);
}

.emergency-icon {
  font-size: 2.5rem;
  margin-bottom: 15px;
}

/* Service Category Cards */
.service-card {
  background: white;
  border-radius: 10px;
  transition: all 0.3s ease;
  border: none;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  border-left: 4px solid var(--primary-color);
}

.service-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.service-card.education {
  border-left-color: var(--education-color);
}

.service-card.medical {
  border-left-color: var(--medical-color);
}

.service-card.government {
  border-left-color: var(--government-color);
}

.service-card.utility {
  border-left-color: var(--utility-color);
}

.service-card.transport {
  border-left-color: var(--transport-color);
}

.service-card.financial {
  border-left-color: var(--financial-color);
}

.service-icon {
  font-size: 2rem;
  margin-bottom: 10px;
  color: var(--primary-color);
}

/* Search Styles */
.contacts-search-container {
  position: relative;
  max-width: 600px;
  margin: 30px auto;
}

.contacts-search-box {
  background: white;
  border-radius: 50px;
  padding: 5px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  border: 2px solid transparent;
  transition: border-color 0.3s;
}

.contacts-search-box:focus-within {
  border-color: var(--secondary-color);
}

.contacts-search-input-group {
  display: flex;
  align-items: center;
  padding: 0 15px;
}

.contacts-search-icon {
  color: var(--primary-color);
  margin-right: 10px;
  font-size: 18px;
}

.contacts-search-input {
  border: none;
  outline: none;
  flex: 1;
  padding: 12px 0;
  font-size: 16px;
  background: transparent;
}

.contacts-search-input::placeholder {
  color: #999;
}

.contacts-clear-search {
  background: none;
  border: none;
  color: #999;
  cursor: pointer;
  padding: 5px;
  border-radius: 50%;
  transition: all 0.3s;
}

.contacts-clear-search:hover {
  background: #f0f0f0;
  color: var(--accent-color);
}

/* Search Results Dropdown */
.contacts-search-results-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border-radius: 10px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  margin-top: 10px;
  overflow: hidden;
  display: none;
  border: 1px solid #e0e0e0;
}

.contacts-search-results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  background: var(--light-bg);
  border-bottom: 1px solid #eee;
  font-weight: 600;
  color: var(--primary-color);
}

.contacts-close-results {
  background: none;
  border: none;
  color: #999;
  cursor: pointer;
  font-size: 18px;
  transition: color 0.3s;
}

.contacts-close-results:hover {
  color: var(--accent-color);
}

.contacts-search-results-body {
  max-height: 400px;
  overflow-y: auto;
}

.contacts-search-result-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #f0f0f0;
  cursor: pointer;
  transition: background 0.2s;
}

.contacts-search-result-item:hover {
  background: #f8f9fa;
}

.contacts-search-result-item:last-child {
  border-bottom: none;
}

.contacts-result-content {
  flex: 1;
}

.contacts-result-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 5px;
}

.contacts-result-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--dark-text);
}

.contacts-result-category {
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 20px;
  background: var(--light-bg);
  color: var(--primary-color);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.contacts-result-category.emergency {
  background: #ffeaea;
  color: var(--emergency-color);
}

.contacts-result-category.medical {
  background: #e8f4fd;
  color: var(--medical-color);
}

.contacts-result-category.government {
  background: #e8f5e9;
  color: var(--government-color);
}

.contacts-result-category.educational {
  background: #f3e8fd;
  color: var(--education-color);
}

.contacts-result-category.utility {
  background: #fef5e7;
  color: var(--utility-color);
}

.contacts-result-category.transport {
  background: #e8f6f3;
  color: var(--transport-color);
}

.contacts-result-category.financial {
  background: #e8f4fd;
  color: var(--financial-color);
}

.contacts-result-category.helpline {
  background: #fff0e6;
  color: #e67e22;
}

.contacts-result-contact {
  margin: 0;
  font-size: 14px;
  color: #666;
  font-weight: 500;
}

.contacts-result-description {
  margin: 5px 0 0;
  font-size: 13px;
  color: #888;
  line-height: 1.4;
}

.contacts-result-arrow {
  color: #ccc;
  font-size: 14px;
  transition: color 0.3s;
}

.contacts-search-result-item:hover .contacts-result-arrow {
  color: var(--primary-color);
}

.contacts-no-results {
  padding: 40px 20px;
  text-align: center;
  color: #999;
}

.contacts-no-results-icon {
  font-size: 40px;
  margin-bottom: 15px;
  color: #ddd;
}

/* Table Styles */
.contacts-table {
  width: 100%;
  margin-bottom: 1rem;
  background-color: transparent;
}

.contacts-table th {
  background-color: var(--primary-color);
  color: white;
  border: none;
  padding: 15px 12px;
  font-weight: 600;
  text-align: center;
  vertical-align: middle;
}

.contacts-table td {
  padding: 12px;
  vertical-align: middle;
  text-align: center;
  border-color: #dee2e6;
}

.contacts-table tbody tr:hover {
  background-color: rgba(26, 82, 118, 0.05);
}

.contacts-table .table-responsive {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Section Headers */
.section-header {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  padding: 15px;
  background: linear-gradient(135deg, var(--primary-color), #2c3e50);
  color: white;
  border-radius: 8px;
}

.section-header i {
  font-size: 24px;
  margin-right: 15px;
}

.section-header h4 {
  margin: 0;
  font-weight: 600;
}

/* Quick Action Buttons */
.quick-actions {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.quick-action-btn {
  background: white;
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
  padding: 8px 16px;
  border-radius: 25px;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  gap: 5px;
}

.quick-action-btn:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-2px);
}

/* District Badge */
.district-badge {
  background: var(--secondary-color);
  color: var(--dark-text);
  padding: 5px 15px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 14px;
  display: inline-block;
  margin-bottom: 20px;
}

/* Contact Number Styling */
.contact-number {
  font-family: "Courier New", monospace;
  font-weight: 600;
  color: var(--primary-color);
  background: #f8f9fa;
  padding: 2px 8px;
  border-radius: 4px;
  border: 1px solid #e9ecef;
}

.toll-free-number {
  color: var(--government-color);
  font-weight: 700;
}

.emergency-number {
  color: var(--emergency-color);
  font-weight: 700;
  background: #ffeaea;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .contacts-search-container {
    margin: 20px 15px;
  }

  .emergency-card {
    margin-bottom: 15px;
  }

  .contacts-table {
    font-size: 14px;
  }

  .contacts-table th,
  .contacts-table td {
    padding: 8px 6px;
  }

  .contacts-result-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .contacts-result-category {
    margin-top: 5px;
    font-size: 10px;
  }

  .quick-actions {
    justify-content: center;
  }

  .quick-action-btn {
    font-size: 14px;
    padding: 6px 12px;
  }

  .section-header {
    padding: 12px;
  }

  .section-header h4 {
    font-size: 18px;
  }
}

@media (max-width: 576px) {
  .contacts-search-input {
    font-size: 14px;
  }

  .contacts-table {
    font-size: 12px;
  }

  .contacts-result-title {
    font-size: 14px;
  }

  .contacts-result-contact {
    font-size: 13px;
  }
}

/* Print Styles */
@media print {
  .contacts-search-container,
  .quick-actions,
  .section-header {
    display: none;
  }

  .contacts-table {
    box-shadow: none;
    border: 1px solid #000;
  }

  .contacts-table th {
    background-color: #000 !important;
    color: #fff !important;
    -webkit-print-color-adjust: exact;
  }
}

/* Animation for search results */
@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.contacts-search-results-dropdown[style*="display: block"] {
  animation: slideDown 0.3s ease;
}

/* Scrollbar styling for search results */
.contacts-search-results-body::-webkit-scrollbar {
  width: 6px;
}

.contacts-search-results-body::-webkit-scrollbar-track {
  background: #f1f1f1;
}

.contacts-search-results-body::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 3px;
}

.contacts-search-results-body::-webkit-scrollbar-thumb:hover {
  background: #154360;
}
