/*
Theme Name: Astra Child (iHait)
Template: astra
Version: 1.0.0
Description: iHait custom header/footer styling.
*/

:root {
  --ihait-teal: #0f766e;
  --ihait-teal-light: #14b8a6;
  --ihait-ink: #1f2937;
  --ihait-slate: #374151;
  --ihait-bg: #f8fafc;
  --ihait-border: #e5e7eb;
}

/* ================= HEADER (redesign v2) ================= */

/* Kill Astra's bloated header padding & force a compact bar */
.ast-primary-header-bar,
.ast-primary-header-bar.ast-primary-header {
  min-height: 0 !important;
  padding: 0 !important;
  background: rgba(255, 255, 255, .85) !important;
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid rgba(15, 23, 42, .07);
  box-shadow: 0 4px 24px -12px rgba(15, 23, 42, .18);
}
.ast-primary-header-bar .ast-container {
  max-width: 1200px;
  padding-left: 24px;
  padding-right: 24px;
}
.ast-primary-header-bar .site-header-primary-wrap,
.ast-primary-header-bar .ast-builder-grid-row {
  min-height: 68px;
  align-items: center;
}
.ast-primary-header-bar .site-header-primary-section-left,
.ast-primary-header-bar .site-header-primary-section-right {
  align-items: center;
}

/* Logo: force sane size, drop the 160px blowup */
.site-branding .custom-logo,
.site-branding img.custom-logo {
  max-height: 38px !important;
  width: auto !important;
  height: 38px;
  display: block;
}
.site-branding { padding: 0; margin: 0; display: flex; align-items: center; }

/* ---------- Announcement strip ---------- */
.ihait-topbar {
  background: linear-gradient(90deg, #0f766e 0%, #14b8a6 100%);
  color: #fff;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: .3px;
  text-align: center;
  padding: 8px 16px;
}
.ihait-topbar strong { color: #fff; }

/* ---------- Desktop nav: pills ---------- */
.ast-builder-menu-1 .main-header-menu {
  gap: 6px;
  align-items: center;
}

/* Dropdown trigger — pill, not a lonely box */
.ihait-catnav { position: relative; display: inline-flex; align-items: center; }
.ihait-cat-trigger {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: linear-gradient(135deg, #0f766e 0%, #14b8a6 100%);
  color: #fff !important;
  font-weight: 600;
  font-size: 14.5px;
  line-height: 1;
  padding: 11px 20px;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  user-select: none;
  box-shadow: 0 6px 16px -6px rgba(15, 118, 110, .55);
  transition: transform .16s ease, box-shadow .16s ease, filter .16s ease;
}
.ihait-cat-trigger:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px -8px rgba(15, 118, 110, .65);
  filter: brightness(1.04);
}
.ihait-cat-trigger:active { transform: translateY(0); }
.ihait-cat-trigger .ihait-caret { font-size: 11px; transition: transform .22s ease; }
.ihait-cat-trigger[aria-expanded="true"] .ihait-caret { transform: rotate(180deg); }

/* Dropdown panel */
.ihait-cat-panel {
  position: absolute;
  top: calc(100% + 12px);
  left: 0;
  min-width: 280px;
  background: #fff;
  border: 1px solid rgba(15, 23, 42, .06);
  border-radius: 16px;
  box-shadow: 0 24px 60px -18px rgba(15, 23, 42, .32), 0 2px 8px -4px rgba(15, 23, 42, .1);
  padding: 10px;
  display: none;
  z-index: 999;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity .18s ease, transform .18s ease;
}
.ihait-cat-panel.ihait-open {
  display: block;
  opacity: 1;
  transform: translateY(0);
}
.ihait-cat-panel a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 14px;
  border-radius: 10px;
  color: var(--ihait-ink);
  font-size: 14.5px;
  font-weight: 500;
  text-decoration: none;
  transition: background .14s ease, color .14s ease, padding-left .14s ease;
}
.ihait-cat-panel a:hover {
  background: #f0fdfa;
  color: var(--ihait-teal);
  padding-left: 18px;
}
.ihait-cat-panel a.ihait-cat-all {
  color: var(--ihait-teal);
  border-bottom: 1px solid rgba(15, 23, 42, .06);
  border-radius: 10px 10px 0 0;
  margin-bottom: 4px;
}
.ihait-cat-panel a .ihait-count {
  color: #94a3b8;
  font-size: 12px;
  font-weight: 600;
  background: #f1f5f9;
  border-radius: 999px;
  padding: 2px 9px;
  min-width: 24px;
  text-align: center;
}

/* Inline header links (Shop / About / Contact) */
.ihait-hdrlink {
  display: inline-flex;
  align-items: center;
  height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  color: var(--ihait-slate) !important;
  font-weight: 600;
  font-size: 14.5px;
  text-decoration: none;
  transition: background .14s ease, color .14s ease;
}
.ihait-hdrlink:hover { background: #f1f5f9; color: var(--ihait-teal) !important; }

/* Right-side icon buttons (search, cart, account) */
.ihait-icons { display: inline-flex; align-items: center; gap: 6px; margin-left: 10px; }
.ihait-iconbtn {
  width: 42px; height: 42px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 50%;
  color: var(--ihait-ink) !important;
  text-decoration: none;
  position: relative;
  transition: background .14s ease, color .14s ease;
  font-size: 18px;
}
.ihait-iconbtn:hover { background: #f1f5f9; color: var(--ihait-teal) !important; }
.ihait-iconbtn .ihait-badge {
  position: absolute; top: 4px; right: 2px;
  background: var(--ihait-teal); color: #fff;
  font-size: 10px; font-weight: 700;
  min-width: 17px; height: 17px; line-height: 17px;
  border-radius: 999px; text-align: center; padding: 0 4px;
}

/* Hide Astra's native submenu arrows */
.ast-builder-menu-1 .menu-item-has-children > .menu-link .ast-menu-toggle,
.ast-builder-menu-1 .menu-item-has-children > .menu-link::after { display: none; }

/* Native cart badge accent */
.ast-header-woo-cart .ast-cart-menu-wrap .count {
  background: var(--ihait-teal) !important;
  color: #fff !important;
  border-color: var(--ihait-teal) !important;
}

/* Hide Astra's auto page-title block entirely on the front page:
   remove the whole <header class="entry-header"> wrapper (h1 + padding) */
body.home .entry-header {
  display: none !important;
}
@media (max-width: 921px) {
  .ast-mobile-header-wrap .ast-primary-header-bar { min-height: 0 !important; }
  .ast-mobile-header-wrap .site-branding img.custom-logo { max-height: 32px !important; height: 32px; }
  .ihait-topbar { font-size: 11.5px; padding: 7px 12px; }
  .ihait-catnav--mobile { width: 100%; }
  .ihait-cat-panel { min-width: min(320px, 88vw); }
  .ihait-cat-trigger { width: 100%; justify-content: center; }
}
/* Keep the mobile drawer content readable */
.ast-mobile-header-content .ihait-catnav--mobile { padding: 16px; }

/* ---------- Footer ---------- */
.ihait-footer {
  background: #0f172a;
  color: #cbd5e1;
  font-size: 14px;
}
.ihait-footer a { color: #cbd5e1; text-decoration: none; }
.ihait-footer a:hover { color: #ffffff; text-decoration: underline; }

.ihait-footer__grid {
  max-width: 1200px;
  margin: 0 auto;
  padding: 56px 24px 32px;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 40px;
}
@media (max-width: 900px) {
  .ihait-footer__grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 560px) {
  /* Brand spans full width; Shop + Help & Info side by side; Contact full width */
  .ihait-footer__grid { grid-template-columns: 1fr 1fr; gap: 28px 20px; }
  .ihait-footer__brand { grid-column: 1 / -1; }
  .ihait-footer__grid > div:nth-child(4) { grid-column: 1 / -1; }
}

.ihait-footer__brand img { max-width: 160px; margin-bottom: 14px; }
.ihait-footer__brand p { line-height: 1.7; margin: 0 0 16px; }

.ihait-footer h4 {
  color: #ffffff;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  margin: 0 0 16px;
}
.ihait-footer ul { list-style: none; margin: 0; padding: 0; }
.ihait-footer ul li { margin-bottom: 10px; }

.ihait-footer__contact li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  line-height: 1.55;
}
.ihait-footer__contact .ic { flex: 0 0 18px; opacity: .85; }

.ihait-footer__social {
  display: flex;
  gap: 12px;
  margin-top: 6px;
}
.ihait-footer__social a {
  width: 34px; height: 34px;
  border: 1px solid #334155;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px;
  transition: all .2s ease;
}
.ihait-footer__social a:hover {
  background: var(--ihait-teal);
  border-color: var(--ihait-teal);
  text-decoration: none;
  color: #fff;
}

.ihait-footer__pay {
  display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px;
}
.ihait-footer__pay span {
  background: #1e293b;
  border: 1px solid #334155;
  border-radius: 4px;
  padding: 4px 10px;
  font-size: 11px;
  letter-spacing: .5px;
  color: #e2e8f0;
}

.ihait-footer__bar {
  border-top: 1px solid #1e293b;
  text-align: center;
  padding: 18px 24px;
  font-size: 13px;
  color: #94a3b8;
}

/* Hide Astra's default footer widgets/copyright when our custom footer renders */
.ihait-has-custom-footer .site-footer .ast-footer-widget-area,
.ihait-has-custom-footer .site-footer .ast-footer-copyright,
.ihait-has-custom-footer .site-footer .ast-small-footer {
  display: none !important;
}
