/* =====================================================
   EDW PATCH — ecoles-du-web.fr
   Fixes for archived site rendering issues
   Applied AFTER edw-original.css
   ===================================================== */

/* === FIX 1: Hero section gradient background (lost during archival) === */
.vc_custom_1632841380512 {
  background: linear-gradient(135deg, #1a0533 0%, #2d1b69 30%, #1e3a5f 70%, #0d4a6b 100%) !important;
  padding: 60px 0 40px !important;
}

/* === FIX 2: Category links visibility in hero section === */
.vc_custom_1632841380512 a {
  color: #ffffff !important;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  padding: 8px 16px;
  margin: 4px;
  border-radius: 6px;
  transition: background-color 0.2s, transform 0.15s;
  font-size: 15px;
}

.vc_custom_1632841380512 a:hover {
  background-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-1px);
}

/* Category link icons — replace broken icon font with CSS chevron */
.vc_custom_1632841380512 .vc_icon_element,
.vc_custom_1632841380512 .ult-just-icon-wrapper {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  margin-right: 8px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  font-size: 14px;
  color: #fff;
}

/* === FIX 3: vc_col-sm-1/5 custom column width (Visual Composer) === */
.vc_col-sm-1\/5 {
  width: 20%;
  float: left;
}

@media (max-width: 767px) {
  .vc_col-sm-1\/5 {
    width: 50%;
  }
}

/* === FIX 4: Inner grid layout for category links === */
.vc_custom_1632841380512 .vc_row.vc_inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px;
}

.vc_custom_1632841380512 .vc_row.vc_inner .wpb_column {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

/* === FIX 5: H1 title in hero === */
.vc_custom_1632841380512 h1 {
  color: #ffffff !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  margin-bottom: 10px;
}

.vc_custom_1632841380512 h2 {
  color: rgba(255, 255, 255, 0.9) !important;
  font-size: 18px;
  margin-bottom: 20px;
}

/* === FIX 6: School cards grid (works with existing col_wrap_three) === */
.col_wrap_three {
  display: flex !important;
  flex-wrap: wrap;
  gap: 20px;
}

.col_wrap_three > .product,
.col_wrap_three > .col_item {
  flex: 0 0 calc(33.333% - 14px);
  max-width: calc(33.333% - 14px);
  box-sizing: border-box;
}

.col_wrap_fourth > .product,
.col_wrap_fourth > .col_item {
  flex: 0 0 calc(25% - 15px);
  max-width: calc(25% - 15px);
}

@media (max-width: 1024px) {
  .col_wrap_three > .product,
  .col_wrap_three > .col_item {
    flex: 0 0 calc(50% - 10px);
    max-width: calc(50% - 10px);
  }
}

@media (max-width: 767px) {
  .col_wrap_three > .product,
  .col_wrap_three > .col_item,
  .col_wrap_fourth > .product,
  .col_wrap_fourth > .col_item {
    flex: 0 0 100%;
    max-width: 100%;
  }
}

/* === FIX 7: Card styling === */
.product {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  overflow: hidden;
  transition: box-shadow 0.2s, transform 0.15s;
}

.product:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}

/* === FIX 8: Sidebar consistency === */
.sidebar .widget {
  background: #fff;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

/* === FIX 9: Footer === */
footer, .footer-wrap {
  background: #1a1a2e !important;
  color: #ccc;
  padding: 30px 0;
}

footer a {
  color: #8ecae6 !important;
}

/* === FIX 10: Fix hidden text caused by white-on-white === */
/* Some VC rows had background gradients that are now lost */
.vc_row-has-fill {
  background: linear-gradient(135deg, #1a0533 0%, #2d1b69 50%, #1e3a5f 100%);
}

/* Override only the hero, not all vc_row-has-fill if others exist */
.vc_row-has-fill:not(.vc_custom_1632841380512) {
  background: none;
}

/* === FIX 11: Clean up dead UI elements === */
.rehub-login-popup,
.act-rehub-login-popup,
.compare_for_grid,
.addcompare-id,
[class*="addcompare-id-"],
.wishcount,
.float-panel-woo-button,
.cookie-notice-container {
  display: none !important;
}

/* === FIX 12: Typography improvements === */
body {
  font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #333;
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  line-height: 1.3;
}

/* === FIX 13: Navigation dropdown fix === */
.top_menu .sub-menu {
  background: #2d1b69;
  border-radius: 0 0 6px 6px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  min-width: 200px;
}

.top_menu .sub-menu a {
  padding: 8px 16px !important;
  color: #fff !important;
  display: block;
}

.top_menu .sub-menu a:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* === FIX 14: Breadcrumbs === */
.breadcrumbs,
.rh-breadcrumbs {
  padding: 10px 0;
  font-size: 13px;
  color: #666;
}

.breadcrumbs a {
  color: #4285f4;
}

/* === FIX 15: Mobile responsive fixes === */
@media (max-width: 767px) {
  .rh-content-wrap {
    flex-direction: column !important;
  }

  .sidebar,
  .rh-360-sidebar {
    width: 100% !important;
    order: 2;
  }

  .main-side,
  .rh-360-content-area {
    width: 100% !important;
    padding-right: 0 !important;
  }

  .hideontablet {
    display: none !important;
  }

  .rh-container {
    padding: 0 15px !important;
  }

  .vc_custom_1632841380512 {
    padding: 30px 10px !important;
  }

  .vc_custom_1632841380512 a {
    font-size: 13px;
    padding: 6px 10px;
  }
}

/* === FIX 16: Fiche école tabs === */
.rh-big-tabs-ul {
  display: flex !important;
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
  border-bottom: 2px solid #e5e5e5;
}

.rh-big-tabs-li {
  padding: 12px 20px;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  font-weight: 500;
  color: #666;
  transition: color 0.2s, border-color 0.2s;
}

.rh-big-tabs-li.active,
.rh-big-tabs-li:hover {
  color: #2d1b69;
  border-bottom-color: #2d1b69;
}

/* === FIX 17: Star rating === */
.star-rating {
  color: #f5a623 !important;
}

/* === FIX 18: Annuaire school card images === */
.rh-cbox-right,
.woo-image-part img {
  border-radius: 8px;
  object-fit: contain;
}

/* === FIX 19: Guide section title === */
.wpsm-title {
  text-align: center;
  margin: 30px 0 20px;
}

.wpsm-title h2 {
  color: #333 !important;
}

/* === FIX 20: Guide school carousel/grid === */
.columned_grid_module {
  display: flex !important;
  flex-wrap: wrap;
  gap: 20px;
}

.columned_grid_module .col_item {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
  padding: 15px;
  text-align: center;
}

.columned_grid_module .col_item img {
  max-height: 120px;
  object-fit: contain;
  margin-bottom: 10px;
}
