/**
 * FAGE FINANCIAL — Plan Card Styles v5
 * Mobile responsive — hamburger nav, stacked filters, single column cards
 */

:root {
  --primary:       #0077aa;
  --primary-light: #0099cc;
  --dark:          #23282d;
  --border:        #dde6ed;
  --text:          #2d3748;
  --muted:         #8a9bb0;
  --green:         #38a169;
  --header-bg:     #f2f4f5;
  --tag-bg:        #e8f4fd;
}

body.group-mode {
  --primary:       #2d6a4f;
  --primary-light: #40916c;
}
html, body {
  overflow-x: hidden;
  max-width: 100%;
}
body {
  background-color: #b8dff7 !important;
  background-image: url('https://staging-8708-info3e9083cc1e9-oqtcd.wpcomstaging.com/wp-content/uploads/2025/11/FageBGFinal.png');
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center center;
  background-attachment: fixed;
  transition: background-color 0.4s;
}
body.fage-group-bg {
  background-color: #c8ddd0 !important;
  background-blend-mode: multiply;
}

/* ─── Plan Grid ───────────────────────────────────────────────── */
.plan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 22px;
  padding: 20px 24px 40px;
  max-width: 1400px;
  margin: 0 auto;
  align-items: start;
}

/* ─── Card Shell ──────────────────────────────────────────────── */
.plan-card {
  background: #fff;
  border-radius: 14px;
  border: 1px solid var(--border);
  border-top: 3px solid var(--primary);
  overflow: hidden;
  box-shadow: 0 3px 14px rgba(0,0,0,0.08);
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
  position: relative;
  font-family: "DM Sans", sans-serif;
}
.plan-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0,119,170,0.18);
}
.plan-card.hidden { display: none; }
.plan-card.group-card { border-top-color: #2d6a4f; }

/* ─── Card Header ─────────────────────────────────────────────── */
.card-header {
  background: var(--header-bg);
  padding: 14px 18px 12px;
  border-bottom: 1px solid var(--border);
  position: relative;
  flex-shrink: 0;
}

.fage-stamp {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 58px;
  height: 25px;
  background: white;
  border-radius: 6px;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  z-index: 1;
  flex-shrink: 0;
}
.fage-stamp img {
  width: 54px;
  height: 21px;
  object-fit: contain;
}

/* Carrier row */
.carrier-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  padding-right: 75px;
}
.carrier-logo-box {
  flex-shrink: 0;
  width: 100px;
  height: 48px;
  background: white;
  border-radius: 8px;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 5px;
}
.carrier-logo-box img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.carrier-placeholder {
  flex-shrink: 0;
  width: 100px;
  height: 48px;
  background: white;
  border-radius: 8px;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: var(--muted);
  text-align: center;
  font-weight: 700;
  padding: 6px;
  line-height: 1.3;
}
.carrier-meta { flex: 1; min-width: 0; }
.assoc-label {
  font-size: 9px;
  color: #b0bec8;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.carrier-name {
  font-size: 12px;
  font-weight: 700;
  color: #4a5568;
  margin-bottom: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Plan name */
.plan-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 8px;
  line-height: 1.3;
}

/* Tags */
.plan-tags {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}
.tag {
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 10.5px;
  font-weight: 600;
  background: var(--tag-bg);
  color: var(--primary);
  white-space: nowrap;
}
.tag.guarantee { background: #f0fff4; color: var(--green); }
.tag.gold { background: #fffbeb; color: #b7791f; }

/* ─── Key Terms / Features ────────────────────────────────────── */
.key-terms {
  padding: 12px 18px;
  border-bottom: 1px solid var(--border);
}
.key-term-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 5px 0;
  border-bottom: 1px solid #f0f4f7;
  font-size: 12.5px;
  line-height: 1.4;
}
.key-term-item:last-child { border-bottom: none; }
.term-emoji {
  font-size: 14px;
  min-width: 20px;
  flex-shrink: 0;
  margin-top: 1px;
}
.term-label {
  font-weight: 600;
  color: var(--dark);
  min-width: 120px;
  font-size: 11.5px;
  flex-shrink: 0;
}
.term-value {
  color: var(--text);
  flex: 1;
}
.term-value.good { color: var(--green); font-weight: 600; }
.term-sub {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-top: 1px;
}

.green-value { color: #00875A; font-weight: 600; }
.green-value .term-sub { color: #00875A; font-weight: 400; }

/* ─── Pricing ─────────────────────────────────────────────────── */
.pricing-section {
  padding: 12px 18px;
  background: #f0f8fd;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.section-label {
  font-size: 10px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}
.pricing-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.price-type { font-size: 10.5px; color: var(--muted); margin-bottom: 2px; }
.price-amount { font-weight: 700; color: var(--dark); font-size: 13px; }
.pricing-disclaimer {
  font-size: 10px;
  color: var(--muted);
  margin-top: 8px;
  font-style: italic;
}
.group-note-text { font-size: 12px; color: var(--muted); line-height: 1.5; margin: 0; }

/* ─── Documents ───────────────────────────────────────────────── */
.documents-section {
  padding: 11px 18px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.doc-buttons {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 7px;
}
.doc-btn {
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  border: 1.5px solid var(--border);
  background: #fff;
  color: var(--dark);
  transition: all 0.2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: "DM Sans", sans-serif;
}
.doc-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: #f0f9ff;
}

/* ─── Provider Network Link ───────────────────────────────────── */
.provider-network-link { margin-top: 3px; }
.provider-network-link a {
  font-size: 12px;
  color: #0099CC;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-weight: 500;
}
.provider-network-link a:hover { text-decoration: underline; color: #007aa3; }

/* ─── Ask Fage ────────────────────────────────────────────────── */
.ask-fage {
  padding: 8px 18px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  flex-shrink: 0;
}
.ask-fage a { color: var(--primary); font-weight: 600; text-decoration: none; }
.ask-fage a:hover { text-decoration: underline; }
.ask-fage-logo {
  height: 16px;
  width: auto;
  vertical-align: middle;
  margin-left: 4px;
  display: inline-block;
}

/* ─── Card Actions ────────────────────────────────────────────── */
.card-actions {
  padding: 13px 18px;
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}
.btn-enroll {
  flex: 1;
  padding: 10px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 8px;
  font-weight: 700;
  font-size: 13.5px;
  cursor: pointer;
  font-family: "DM Sans", sans-serif;
  transition: opacity 0.2s;
  text-align: center;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.btn-enroll:hover { opacity: 0.88; color: white; }
.btn-info {
  padding: 10px 14px;
  background: #fff;
  color: var(--dark);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-weight: 600;
  font-size: 12.5px;
  cursor: pointer;
  font-family: "DM Sans", sans-serif;
  transition: all 0.2s;
  white-space: nowrap;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
.btn-info:hover { border-color: var(--primary); color: var(--primary); }
.btn-info[disabled] { opacity: 0.4; cursor: not-allowed; }
.plan-card.group-card .btn-enroll { background: #2d6a4f; }

/* ─── Prior Auth Watermark ────────────────────────────────────── */
.prior-auth-watermark {
  font-size: 9px;
  color: #aab8c2;
  text-align: right;
  padding: 4px 12px 6px;
  font-style: italic;
  flex-shrink: 0;
}

/* ─── Page wrap ───────────────────────────────────────────────── */
.fage-all-plans-wrap {
  width: 100%;
  max-width: 100%;
}

/* ─── Page Header ─────────────────────────────────────────────── */
.fage-page-header {
  position: relative;
  padding: 30px 20px 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.fage-page-header::before {
  content: '';
  position: absolute;
  top: 0; left: 5%; right: 5%;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(0,80,140,0.3), transparent);
}
.fage-page-header::after {
  content: '';
  position: absolute;
  bottom: 0; left: 5%; right: 5%;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(0,80,140,0.3), transparent);
}
.fage-header-logo-wrap {
  position: relative;
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  padding: 30px 40px 10px !important;
}
.fage-header-logo-wrap::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 15%; right: 15%;
  height: 2px;
  background: linear-gradient(to right, transparent, #0077aa, transparent);
  border-radius: 2px;
}
.fage-page-header img.fage-header-logo {
  width: 480px;
  height: auto;
  display: block;
  margin: 0 auto;
  filter: drop-shadow(4px 4px 6px rgba(0,60,120,0.25)) drop-shadow(-2px -2px 4px rgba(255,255,255,0.4));
}
.fage-mode-text {
  font-family: "Bebas Neue", sans-serif;
  font-size: 52px;
  font-weight: 400;
  letter-spacing: 6px;
  text-transform: uppercase;
  opacity: 0.35;
  color: #1a2e44;
  line-height: 1;
  user-select: none;
  filter: drop-shadow(3px 3px 5px rgba(0,60,120,0.3)) drop-shadow(-1px -1px 3px rgba(255,255,255,0.4));
  transition: color 0.4s, filter 0.4s;
}
.fage-group-mode .fage-mode-text { color: #1a3d2b; }
.fage-page-tagline {
  text-align: center;
  font-family: "DM Sans", sans-serif;
  font-size: 13px;
  color: #1a2e44;
  opacity: 0.5;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-top: 4px;
  margin-bottom: 6px;
}
.fage-bg-watermarks { display: none; }

/* ─── Hide All Plans page title ──────────────────────────────── */
.page-id-2187 h1.wp-block-post-title { display: none; }

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE — TABLET (max 900px)
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .plan-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 16px;
    padding: 16px 16px 40px;
  }
  .fage-page-header img.fage-header-logo { width: 360px; }
  .fage-mode-text { font-size: 40px; }
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE — MOBILE (max 768px)
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {

  /* Single column cards — no overflow */
  .fage-all-plans-wrap {
    overflow-x: hidden;
    max-width: 100vw;
  }
  .plan-grid {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 12px 12px 40px;
    max-width: 100%;
    box-sizing: border-box;
  }
  .plan-card {
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
  }
  .card-actions {
    box-sizing: border-box;
    width: 100%;
  }

  /* Header logo smaller */
  .fage-page-header { padding: 16px 12px 12px; }
  .fage-page-header img.fage-header-logo { width: 220px; }
  .fage-header-logo-wrap { padding: 16px 20px 8px !important; }
  .fage-mode-text { font-size: 28px; letter-spacing: 4px; }
  .fage-page-tagline { font-size: 11px; letter-spacing: 1px; }

  /* Filter bar — stack everything vertically */
  .fage-controls-wrap {
    padding: 10px 12px !important;
    gap: 8px !important;
  }
  .fage-controls-wrap > *,
  .fage-filter-row,
  .fage-filter-row > * {
    width: 100% !important;
    max-width: 100% !important;
  }

  /* Individual/Group toggle — full width centered */
  .fage-toggle-wrap {
    width: 100% !important;
    justify-content: center !important;
    margin-bottom: 4px;
  }

  /* Dropdowns full width */
  .fage-select-wrap,
  .fage-controls-wrap select,
  .fage-controls-wrap .fage-select {
    width: 100% !important;
  }

  /* Age field + button row — side by side on one line */
  .fage-age-row {
    display: flex !important;
    gap: 8px !important;
    width: 100% !important;
  }
  .fage-age-row input {
    flex: 1 !important;
    min-width: 0 !important;
  }
  .fage-age-row button {
    flex-shrink: 0 !important;
    white-space: nowrap !important;
  }

  /* Results count */
  .fage-results-count {
    text-align: center !important;
    width: 100% !important;
  }

  /* Active filter chips — wrap nicely */
  .fage-active-chips {
    flex-wrap: wrap !important;
    gap: 6px !important;
    padding: 8px 12px !important;
  }

  /* Card feature rows — tighter label */
  .term-label { min-width: 90px; font-size: 11px; }
  .key-term-item { font-size: 12px; }

  /* Pricing grid single column */
  .pricing-grid { grid-template-columns: 1fr; gap: 6px; }

  /* Doc buttons wrap tighter */
  .doc-buttons { gap: 4px; }
  .doc-btn { font-size: 11px; padding: 4px 8px; }

  /* Card action buttons full width stack */
  .card-actions { flex-direction: column; gap: 8px; padding: 12px 14px; }
  .btn-enroll { width: 100%; }
  .btn-info { width: 100%; justify-content: center; }

  /* Carrier logo smaller on mobile */
  .carrier-logo-box, .carrier-placeholder {
    width: 72px;
    height: 36px;
  }

  /* Key Terms glossary section */
  .fage-key-terms-grid {
    grid-template-columns: 1fr !important;
  }
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE — SMALL MOBILE (max 400px)
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 400px) {
  .plan-grid { padding: 8px 8px 40px; }
  .fage-page-header img.fage-header-logo { width: 180px; }
  .term-label { min-width: 76px; }
  .card-header { padding: 12px 14px 10px; }
  .key-terms { padding: 10px 14px; }
  .pricing-section { padding: 10px 14px; }
  .documents-section { padding: 10px 14px; }
  .card-actions { padding: 10px 12px; }
}