/**
 * AIPM Frontend Styles
 * Breadcrumbs and SEO elements
 */

/* ==========================================================================
   BREADCRUMBS
   ========================================================================== */

.breadcrumbs {
  margin-bottom: 15px;
  padding: 12px 0;
}

.breadcrumb-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 14px;
}

.breadcrumb-item {
  display: inline-flex;
  align-items: center;
  color: #666;
}

.breadcrumb-item a {
  color: #555;
  text-decoration: none;
  transition: color 0.2s ease;
}

.breadcrumb-item a:hover {
  color: #000;
  text-decoration: underline;
}

.breadcrumb-item a .icon-home {
  margin-right: 4px;
  font-size: 13px;
}

.breadcrumb-item + .breadcrumb-item::before {
  content: "›";
  display: inline-block;
  padding: 0 10px;
  color: #999;
  font-size: 16px;
  font-weight: 300;
}

.breadcrumb-item.active {
  color: #333;
  font-weight: 500;
}

/* Mobile adjustments */
@media (max-width: 767px) {
  .breadcrumbs {
    padding: 10px 0;
    margin-bottom: 10px;
  }

  .breadcrumb-list {
    font-size: 13px;
  }

  .breadcrumb-item + .breadcrumb-item::before {
    padding: 0 6px;
  }
}

/* ==========================================================================
   ACCESSIBILITY FIXES
   ========================================================================== */

/* Screen reader only - visually hidden but accessible */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* ==========================================================================
   COLOR CONTRAST FIXES (WCAG AA Compliance)
   ========================================================================== */

/* Store count in sidebar - improve contrast */
.store-count {
  color: #595959 !important; /* Darker gray for better contrast on white */
}

/* Expire dates - improve contrast */
.expire {
  color: #d32f2f !important; /* Darker red for better visibility */
  font-weight: 500;
}

/* Coupon buttons - ensure good contrast */
.code-text-full {
  color: #ffffff !important;
  font-weight: 600;
}

/* GET DEAL button text */
.btn-get-deal .code-text-full,
.coupon-action .code-text-full {
  color: #ffffff !important;
}

/* Visit store link - improve contrast */
.visit-store-link {
  color: #1565c0 !important; /* Darker blue for better contrast */
  text-decoration: underline;
}

.visit-store-link:hover {
  color: #0d47a1 !important;
}

/* Breadcrumb home link */
.breadcrumbs a {
  color: #1565c0 !important;
  text-decoration: underline;
}

.breadcrumbs a:hover {
  color: #0d47a1 !important;
}

/* Footer copyrights - improve contrast */
.copyrights,
.copyrights .flex-left {
  color: #424242 !important; /* Darker text for footer */
}

/* Subscribe button - ensure contrast */
.footer-subscribe .submit-ajax-form,
.btn.submit-ajax-form {
  color: #ffffff !important;
  background-color: #1976d2 !important;
}

.footer-subscribe .submit-ajax-form:hover {
  background-color: #1565c0 !important;
}

/* GET ALERTS button */
.btn-primary.btn-block {
  color: #ffffff !important;
  background-color: #1976d2 !important;
}

/* Links in description - add underline for distinguishability */
.rich-text.description a,
.store-sidebar-section a:not(.visit-store-link) {
  text-decoration: underline;
  color: #1565c0;
}

.rich-text.description a:hover,
.store-sidebar-section a:hover {
  color: #0d47a1;
}

/* Social links in sidebar - improve visibility */
#similar-stores a {
  text-decoration: underline;
  color: #1565c0;
}

/* Focus states for keyboard navigation */
a:focus,
button:focus,
input:focus,
.btn:focus {
  outline: 2px solid #1976d2 !important;
  outline-offset: 2px;
}

/* Subscribe heading (replaced h4 for proper heading order) */
.subscribe-heading {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: #333;
}

/* ==========================================================================
   HEADING HIERARCHY FIXES
   ========================================================================== */

/* Sidebar widget titles - styled as H2 but look like H4 */
.store-sidebar-section h2.widget-title {
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 15px 0;
  padding: 0;
  color: #333;
  line-height: 1.4;
}

/* Coupon titles - H3 styled to match original H4 */
h3.coupon-title {
  font-size: 15px;
  font-weight: 600;
  margin: 0 0 8px 0;
  line-height: 1.4;
  color: #333;
}

h3.coupon-title a {
  color: #333;
  text-decoration: none;
}

h3.coupon-title a:hover {
  color: #1976d2;
}
