/* Medical Network Page Styles */

/* Hero Section */
.network-hero {
  background-image: url("../images/services_heroImage.jpg");
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
  color: white;
  padding: 5rem 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.network-hero h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  font-weight: 800;
}

.network-hero p {
  font-size: 1.25rem;
  max-width: 700px;
  margin: 0 auto;
  opacity: 0.9;
}

/* Search Section */
.search-section {
  background: white;
  padding: 2rem 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  position: relative;
  z-index: 10;
  margin-top: -30px;
  border-radius: 10px;
  margin-left: 20px;
  margin-right: 20px;
}

.search-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.search-filters {
  display: grid;
  /*grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));*/
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.filter-group {
  margin-bottom: 1rem;
}

.filter-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: #333;
}

.filter-select {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 1rem;
  background-color: #f8f9fa;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23333' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 16px 12px;
}

select.filter-select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23333' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 16px 12px;
}

input.filter-select {
  background-image: none !important;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-color: #fff;
}

.search-btn {
  background: #2196f3;
  color: white;
  border: none;
  border-radius: 6px;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 1.5rem auto 0;
}

.search-btn:hover {
  background: #1976d2;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Stats Section */
.stats-section {
  padding: 4rem 0;
  background-color: #f8fafc;
}

.stats-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-header h2 {
  font-size: 2rem;
  color: #1e293b;
  margin-bottom: 1rem;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.stat-card {
  background: white;
  border-radius: 10px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  text-align: center;
  transition: transform 0.3s ease;
}

.stat-card:hover {
  transform: translateY(-5px);
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: #2196f3;
  margin-bottom: 0.5rem;
  line-height: 1;
}

.stat-label {
  color: #64748b;
  font-size: 1rem;
}

/* Features Section */
.features-section {
  padding: 4rem 0;
  background: white;
}

.features-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.feature-card {
  background: #f8fafc;
  border-radius: 10px;
  padding: 2rem;
  transition: all 0.3s ease;
  border-left: 4px solid #2196f3;
  text-align: justify;
  text-justify: inter-word;
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.feature-card h3 {
  color: #1e293b;
  margin-bottom: 1rem;
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.feature-card h3 i {
  color: #2196f3;
  font-size: 1.5rem;
}

.feature-card ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.feature-card ul li {
  margin-bottom: 0.5rem;
  padding-left: 1.5rem;
  position: relative;
  color: #475569;
  text-align: justify;
  text-justify: inter-word;
}

.feature-card ul li:before {
  text-align: justify;
  text-justify: inter-word;
  content: "✓";
  color: #10b981;
  position: absolute;
  left: 0;
  font-weight: bold;
}

/* Provider Form Section */
.provider-form-section {
  padding: 4rem 0;
  background: #f8fafc;
}

.provider-form-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1rem;
}

.provider-form {
  background: white;
  border-radius: 10px;
  padding: 2.5rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.form-title {
  text-align: center;
  margin-bottom: 2rem;
}

.form-title h2 {
  color: #1e293b;
  margin-bottom: 0.5rem;
}

.form-title p {
  color: #64748b;
  font-size: 1.1rem;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: #333;
}

.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 1rem;
  background-color: #f8f9fa;
}

.form-control:focus {
  outline: none;
  border-color: #2196f3;
  box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
  background-color: white;
}

textarea.form-control {
  min-height: 120px;
  resize: vertical;
}

.btn-submit {
  background: #2196f3;
  color: white;
  border: none;
  border-radius: 6px;
  padding: 0.75rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: block;
  width: 100%;
  max-width: 300px;
  margin: 2rem auto 0;
}

.btn-submit:hover {
  background: #1976d2;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Contact Person section divider */
.form-section-divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 0.5rem 0 1.5rem;
}

.form-section-divider::before,
.form-section-divider::after {
  content: "";
  flex: 1;
  height: 2px;
  background: linear-gradient(90deg, #e2e8f0, #2563eb40);
  border-radius: 2px;
}

.form-section-divider::after {
  background: linear-gradient(90deg, #2563eb40, #e2e8f0);
}

.form-section-divider span {
  font-size: 0.85rem;
  font-weight: 700;
  color: #2563eb;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  white-space: nowrap;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  padding: 4px 14px;
  border-radius: 99px;
}

/* Responsive Styles */
@media (max-width: 992px) {
  .search-filters {
    grid-template-columns: 1fr 1fr;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .features-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .search-filters {
    grid-template-columns: 1fr;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }

  .network-hero h1 {
    font-size: 2rem;
  }

  .provider-form {
    padding: 1.5rem;
  }
}

@media (max-width: 480px) {
  .network-hero h1 {
    font-size: 1.75rem;
  }

  .section-header h2 {
    font-size: 1.5rem;
  }
}
/* =============================================
   Network Providers Table Section
   ============================================= */

.network-table-section {
  padding: 60px 1.5rem;
}

.network-table-section .section-header {
  margin-bottom: 2rem;
}

.table-wrapper {
  width: 100%;
  overflow-x: auto;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 40, 80, 0.08);
}

.providers-table {
  width: 100%;
  border-collapse: collapse;
  font-family: "Cairo", sans-serif;
  font-size: 0.95rem;
  min-width: 600px;
}

/* ── THEAD ── */
.providers-table thead tr {
  background-color: #5b9bd5;
}

.providers-table thead th {
  color: #ffffff;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 14px 20px;
  text-align: left;
  white-space: nowrap;
  border: none;
}

html[dir="rtl"] .providers-table thead th {
  text-align: right;
}

/* paired columns: Name wide, No narrow */
.providers-table thead th.col-name {
  width: 40%;
}
.providers-table thead th.col-no {
  width: 10%;
  text-align: left;
}

html[dir="rtl"] .providers-table thead th.col-no {
  text-align: right;
}
/* ── TBODY alternating rows ── */
.providers-table tbody tr:nth-child(odd) {
  background-color: #d0deef;
}
.providers-table tbody tr:nth-child(even) {
  background-color: #e9eff7;
}

.providers-table tbody tr {
  transition: filter 0.15s ease;
}
.providers-table tbody tr:hover {
  filter: brightness(0.96);
}

.providers-table tbody td {
  padding: 12px 20px;
  color: #1a3a5c;
  border: none;
  vertical-align: middle;
}

html[dir="rtl"] .providers-table tbody td {
  text-align: right;
}

.providers-table tbody td.col-no {
  text-align: center;
  font-weight: 700;
  color: #5b9bd5;
  font-size: 1rem;
}

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .network-table-section {
    padding: 40px 1rem;
  }

  .providers-table {
    font-size: 0.85rem;
  }

  .providers-table thead th,
  .providers-table tbody td {
    padding: 10px 12px;
  }
}

@media (max-width: 480px) {
  .providers-table {
    font-size: 0.8rem;
    min-width: 400px;
  }

  .providers-table thead th,
  .providers-table tbody td {
    padding: 8px 10px;
  }
}
.providers-table thead th {
  color: #ffffff;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 14px 20px;
  text-align: left;
  white-space: nowrap;
  border: none;
}

html[dir="rtl"] .providers-table thead th {
  text-align: right;
}

.providers-table thead th.col-name {
  width: 40%;
}

.providers-table thead th.col-no {
  width: 10%;
  text-align: left;
}

html[dir="rtl"] .providers-table thead th.col-no {
  text-align: right;
}

.providers-table tbody td {
  padding: 12px 20px;
  color: #1a3a5c;
  border: none;
  vertical-align: middle;
  text-align: left;
}

html[dir="rtl"] .providers-table tbody td {
  text-align: right;
}

.providers-table tbody td.col-no {
  text-align: left;
  font-weight: 700;
  color: #5b9bd5;
  font-size: 1rem;
}

html[dir="rtl"] .providers-table tbody td.col-no {
  text-align: right;
}
/* Network Table + Map side-by-side layout */
.network-table-layout {
  display: grid;
  grid-template-columns: 1fr 1.8fr;
  gap: 2rem;
  align-items: start;
}

/* Override table-wrapper width ONLY inside the layout grid */
.network-table-layout .table-wrapper {
  width: 100%;
  min-width: 0; /* ← THIS is the key fix: prevents grid blowout */
  overflow-x: auto;
}

.network-map-image {
  position: sticky;
  top: 100px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 40, 80, 0.12);
}

.network-map-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
}

@media (max-width: 900px) {
  .network-table-layout {
    grid-template-columns: 1fr;
  }

  .network-map-image {
    position: static;
    max-width: 500px;
    margin: 0 auto;
  }
}
.network-table-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}

.network-table-layout .table-wrapper {
  width: 100%;
  min-width: 0;
  overflow-x: auto;
}

.network-map-image {
  position: sticky;
  top: 100px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 40, 80, 0.12);
}

.network-map-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
}

@media (max-width: 900px) {
  .network-table-layout {
    grid-template-columns: 1fr;
  }

  .network-map-image {
    position: static;
    max-width: 500px;
    margin: 0 auto;
  }
}
/* =============================================
   Mobile Responsive Overrides – Search & Form
   ============================================= */

@media (max-width: 768px) {
  /* Search section: reset inline grid to single column */
  .search-section {
    margin-left: 8px;
    margin-right: 8px;
    padding: 1.5rem 0;
  }

  #provider-search-form .search-filters {
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }

  .filter-group {
    margin-bottom: 0;
  }

  .filter-select {
    font-size: 0.95rem;
    padding: 0.65rem 2rem 0.65rem 0.85rem;
  }

  /* Provider application form grid: single column */
  .provider-form .form-grid {
    grid-template-columns: 1fr !important;
    gap: 0 !important;
  }

  .provider-form .form-group {
    margin-bottom: 1rem;
  }

  .provider-form .form-group.full-width {
    grid-column: auto !important;
  }

  .form-control {
    font-size: 0.95rem;
    padding: 0.65rem 0.85rem;
  }

  textarea.form-control {
    min-height: 100px;
  }

  .btn-submit {
    max-width: 100%;
    padding: 0.85rem 1rem;
  }

  /* Network figures grid: 2 columns on small screens */
  .figures-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 1rem !important;
  }

  /* Stats grid already handled above but reinforce */
  .stats-grid {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 480px) {
  .search-section {
    margin-left: 4px;
    margin-right: 4px;
    border-radius: 8px;
  }

  .filter-select,
  .form-control {
    font-size: 1rem; /* prevents iOS zoom on focus */
    padding: 0.7rem 0.8rem;
  }

  select.filter-select {
    padding-right: 2rem;
  }

  /* Figures grid: single column on very small screens */
  .figures-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .figure-image-wrap,
  .figure-image-wrap img {
    width: 80px !important;
    height: 80px !important;
  }

  .figure-reflection {
    width: 80px !important;
  }

  .figure-reflection img {
    width: 80px !important;
    height: 80px !important;
  }

  .figure-number {
    font-size: 1rem !important;
  }

  .figure-label {
    font-size: 0.8rem !important;
  }

  /* Provider form padding */
  .provider-form {
    padding: 1.25rem;
  }

  .provider-form-container {
    padding: 0 0.5rem;
  }
}
.mobile-nav a.active {
  display: inline-block;
  width: fit-content;
  margin: auto;
}
