/*
Theme Name: Astra Child – Prime Medical Services
Theme URI: https://wpastra.com/
Description: Child theme for Prime Medical Services. Holds the site design system (colors, type, spacing, buttons, forms) and page component styles. Customize here, never in the parent theme.
Author: Prime Medical Services
Template: astra
Version: 2.0.6
Text Domain: astra-child
*/

/* ===============================================
   1. DESIGN TOKENS — blue & white system
   =============================================== */
:root {
  --pms-navy: #0a3d62;
  --pms-navy-deep: #071f33;
  --pms-blue: #0b5ed7;          /* primary action */
  --pms-blue-dark: #0a53be;
  --pms-sky: #38bdf8;           /* light accent */
  --pms-text: #0f172a;
  --pms-text-muted: #475569;
  --pms-border: #dbe7f2;
  --pms-bg: #ffffff;
  --pms-bg-tint: #f2f7fd;
  --pms-bg-tint-2: #e8f1fb;
  --pms-footer: #06182a;

  --pms-radius: 18px;
  --pms-radius-pill: 50px;
  --pms-shadow: 0 10px 30px rgba(10, 61, 98, 0.08);
  --pms-shadow-hover: 0 20px 45px rgba(10, 61, 98, 0.18);
  --pms-transition: all 0.25s ease;
  --pms-gradient: linear-gradient(120deg, #0a3d62 0%, #0b5ed7 70%, #38bdf8 135%);
}

/* ===============================================
   2. GLOBAL & ACCESSIBILITY
   =============================================== */
a:focus-visible, button:focus-visible, input:focus-visible,
select:focus-visible, textarea:focus-visible, [role="button"]:focus-visible {
  outline: 3px solid var(--pms-blue);
  outline-offset: 2px;
  border-radius: 4px;
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
body { -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; }
::selection { background: var(--pms-blue); color: #fff; }
:target { scroll-margin-top: 110px; }
h1, h2, h3, h4 { letter-spacing: -0.015em; }

/* Scroll-reveal (elements get .pms-reveal from js/pms-ui.js) */
.pms-reveal { opacity: 0; transform: translateY(26px); transition: opacity .6s ease, transform .6s ease; }
.pms-reveal.pms-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .pms-reveal { opacity: 1; transform: none; } }

/* ===============================================
   3. STICKY HEADER
   =============================================== */
#masthead {
  position: sticky;
  top: 0;
  z-index: 999;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--pms-border);
  transition: box-shadow .25s ease;
}
#masthead.pms-scrolled { box-shadow: 0 10px 30px rgba(10, 61, 98, 0.14); }
#masthead .main-header-bar, #masthead .ast-primary-header-bar { background: transparent; }

/* Normalize menu geometry: compact centered links, never stretched to header height */
.main-header-bar .main-header-menu { align-items: center; }
.main-header-menu > .menu-item { display: flex; align-items: center; }
.main-header-menu > .menu-item > .menu-link {
  height: auto;
  line-height: 1.5;
  padding: 10px 14px;
}
.main-header-menu .menu-link { font-weight: 500; font-size: 15px; transition: var(--pms-transition); }

/* No boxed background on hover/current items — the underline + color do that job */
.ast-builder-menu-1 .menu-link:hover,
.ast-builder-menu-1 .main-header-menu > .menu-item:hover > .menu-link,
.ast-builder-menu-1 .menu-item.current-menu-item > .menu-link,
.ast-builder-menu-1 .current-menu-ancestor > .menu-link,
.main-header-menu > .menu-item.current-menu-item > .menu-link,
.main-header-menu > .current-menu-ancestor > .menu-link { background: transparent; }
.main-header-menu > .menu-item > .menu-link:hover,
.main-header-menu > .menu-item.current-menu-item > .menu-link { color: var(--pms-blue); }

@media (min-width: 922px) {
  .main-header-menu > .menu-item > .menu-link { position: relative; }
  .main-header-menu > .menu-item > .menu-link::after {
    content: "";
    position: absolute;
    left: 1em; right: 1em; bottom: 2px;
    height: 2px;
    background: var(--pms-blue);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.25s ease;
  }
  .main-header-menu > .menu-item:hover > .menu-link::after,
  .main-header-menu > .menu-item.current-menu-item > .menu-link::after { transform: scaleX(1); }

  /* Contact = primary CTA */
  .main-header-menu > .menu-item:last-child > .menu-link {
    background: var(--pms-blue);
    color: #fff !important;
    border-radius: var(--pms-radius-pill);
    padding: 10px 26px;
    margin-left: 14px;
    align-self: center;
    height: auto;
    line-height: 1.5;
    white-space: nowrap;
    box-shadow: 0 6px 16px rgba(11, 94, 215, 0.3);
  }
  .main-header-menu > .menu-item:last-child > .menu-link::after { content: none; }
  .main-header-menu > .menu-item:last-child > .menu-link:hover,
  .main-header-menu > .menu-item:last-child > .menu-link:focus-visible {
    background: var(--pms-navy);
    color: #fff !important;
    transform: translateY(-1px);
  }

  /* The menu strip must not paint its own white box over the header bar */
  .main-header-bar-navigation, .ast-builder-menu-1 .main-header-menu,
  .ast-builder-menu .main-header-menu { background: transparent; }

  /* Dropdowns: compact, readable, and never taller than the screen */
  .main-header-menu .sub-menu {
    border-radius: 14px;
    border: 1px solid var(--pms-border);
    box-shadow: var(--pms-shadow-hover);
    padding: 6px 0;
    width: 300px;
    max-height: calc(100vh - 140px);
    overflow-y: auto;
    overscroll-behavior: contain;
  }
  .main-header-menu .sub-menu .menu-link {
    text-transform: none;
    letter-spacing: 0;
    font-size: 14px;
    line-height: 1.45;
    padding: 9px 18px;
  }
  .main-header-menu .sub-menu .menu-link:hover { background: var(--pms-bg-tint); color: var(--pms-blue); }
}

/* Narrow desktops / small laptops (e.g. 1024px wide): keep the whole menu on one row */
@media (min-width: 922px) and (max-width: 1240px) {
  .site-branding img, .custom-logo { max-width: 200px; height: auto; }
  .main-header-menu .menu-link { font-size: 13px; }
  .main-header-menu > .menu-item > .menu-link { padding: 10px 8px; }
  .main-header-menu > .menu-item:last-child > .menu-link { padding: 9px 18px; margin-left: 8px; }
}

/* ===============================================
   4. HOMEPAGE HERO
   The headline card floats over the banner image.
   =============================================== */

/* Banner image: cinematic overlay so the hero card pops */
.elementor-1311 .elementor-element.elementor-element-5c9c2ae { position: relative; }
.elementor-1311 .elementor-element.elementor-element-5c9c2ae::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7, 31, 51, 0.15) 40%, rgba(7, 31, 51, 0.6) 100%);
  pointer-events: none;
}
.elementor-1311 .elementor-element.elementor-element-5c9c2ae img { display: block; width: 100%; object-fit: cover; }

/* Headline card: overlaps the banner, brand gradient, big white type */
.elementor-1311 .elementor-element.elementor-element-8846ae9 {
  margin: -170px auto 0 !important;
  max-width: min(1080px, calc(100% - 48px));
  border-radius: 28px;
  padding: 72px 48px !important;
  background: var(--pms-gradient) !important;
  box-shadow: 0 35px 70px rgba(7, 31, 51, 0.4);
  position: relative;
  z-index: 5;
}
.elementor-1311 .elementor-element.elementor-element-710b905 .elementor-heading-title {
  color: #ffffff !important;
  font-family: 'Plus Jakarta Sans', sans-serif !important;
  font-size: clamp(34px, 5vw, 56px) !important;
  font-weight: 700 !important;
  line-height: 1.12 !important;
}
.elementor-1311 .elementor-element.elementor-element-d3994cf .elementor-heading-title {
  color: rgba(255, 255, 255, 0.93) !important;
  font-size: 19px !important;
  line-height: 1.65 !important;
}

/* Any blue-gradient band on any page: white headings, brand gradient */
.elementor-element[data-settings*="gradient"]:not(.elementor-element-8846ae9) {
  background-image: var(--pms-gradient) !important;
  border-radius: 24px;
}
.elementor-element[data-settings*="gradient"] .elementor-heading-title,
.elementor-element[data-settings*="gradient"] h1,
.elementor-element[data-settings*="gradient"] h2,
.elementor-element[data-settings*="gradient"] h3 { color: #ffffff !important; }

/* ===============================================
   5. BUTTONS — one voice, with a motion arrow
   =============================================== */
.elementor-button, .wp-block-button__link,
.srfm-button, .srfm-submit-button, button[type="submit"] {
  background: var(--pms-blue) !important;
  background-image: none !important;
  color: #fff !important;
  border: none !important;
  border-radius: var(--pms-radius-pill) !important;
  padding: 14px 32px !important;
  font-weight: 600 !important;
  letter-spacing: 0.01em;
  text-decoration: none !important;
  box-shadow: 0 6px 16px rgba(11, 94, 215, 0.28);
  transition: var(--pms-transition) !important;
}
.elementor-button:hover, .elementor-button:focus,
.wp-block-button__link:hover, .srfm-button:hover,
.srfm-submit-button:hover, button[type="submit"]:hover {
  background: var(--pms-navy) !important;
  color: #fff !important;
  transform: translateY(-2px);
  box-shadow: 0 10px 22px rgba(10, 61, 98, 0.35);
}

.pms-btn {
  display: inline-block;
  margin-top: 35px;
  padding: 15px 34px;
  background: #ffffff;
  color: var(--pms-navy) !important;
  border-radius: var(--pms-radius-pill);
  font-weight: 700;
  text-decoration: none !important;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
  transition: var(--pms-transition);
}
.pms-btn::after {
  content: "\2192";
  display: inline-block;
  margin-left: 10px;
  transition: transform .25s ease;
}
.pms-btn:hover, .pms-btn:focus-visible {
  background: var(--pms-bg-tint);
  transform: translateY(-3px);
}
.pms-btn:hover::after { transform: translateX(5px); }

/* ===============================================
   6. SECTIONS & TYPOGRAPHY
   =============================================== */
.pms-section { padding: 56px 24px; background: var(--pms-bg); }
.pms-section-large { padding: 48px 24px; }
.pms-highlight-section { background: var(--pms-bg-tint); padding: 48px 24px; }
.pms-support-section { padding: 56px 24px; background: var(--pms-bg-tint); }

/* Full-bleed section backgrounds: sections sit inside the boxed content area,
   so negative side margins stretch the band to the viewport edges while the
   inner .pms-container keeps the content centered at 1200px. */
.pms-section,
.pms-section-large,
.pms-highlight-section,
.pms-support-section {
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}
/* 50vw includes the scrollbar width; clip the few overflow pixels. */
body { overflow-x: clip; }

.pms-container { max-width: 1200px; margin: auto; }
.pms-center { text-align: center; }

.pms-title {
  font-size: clamp(30px, 3.6vw, 44px);
  font-weight: 700;
  color: var(--pms-navy);
  margin-bottom: 18px;
  position: relative;
  padding-bottom: 18px;
  line-height: 1.2;
}
.pms-title::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 64px; height: 4px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--pms-blue), var(--pms-sky));
}
.pms-center .pms-title::after,
.pms-title.pms-center::after { left: 50%; transform: translateX(-50%); }

.pms-subtitle {
  font-size: 18px;
  color: var(--pms-text-muted);
  margin: 0 auto 44px;
  max-width: 760px;
  line-height: 1.75;
}
/* No trailing dead space when the subtitle ends its section */
.pms-subtitle:last-child { margin-bottom: 0; }
.pms-title:last-child { margin-bottom: 0; padding-bottom: 14px; }

/* ===============================================
   7. CARDS
   =============================================== */
.pms-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 32px; }
.pms-support-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 40px; margin-top: 56px; }
.pms-mv-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 40px; margin-top: 60px; }

.pms-card, .pms-support-card, .pms-mv-card {
  background: var(--pms-bg);
  border-radius: var(--pms-radius);
  border: 1px solid var(--pms-border);
  box-shadow: var(--pms-shadow);
  transition: var(--pms-transition);
  position: relative;
  overflow: hidden;
}
.pms-card::before, .pms-support-card::before, .pms-mv-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--pms-blue), var(--pms-sky));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s ease;
}
.pms-card:hover::before, .pms-support-card:hover::before, .pms-mv-card:hover::before { transform: scaleX(1); }
.pms-card { padding: 36px 30px; }
.pms-support-card { padding: 40px 32px; }
.pms-mv-card { padding: 50px 42px; }
.pms-card:hover, .pms-support-card:hover, .pms-mv-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--pms-shadow-hover);
  border-color: transparent;
}

.pms-icon, .pms-support-icon {
  font-size: 30px;
  margin-bottom: 22px;
  color: var(--pms-blue);
  width: 64px; height: 64px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 16px;
  background: var(--pms-bg-tint-2);
}

.pms-card h3 { font-size: 20px; font-weight: 700; margin-bottom: 14px; color: var(--pms-navy); }
.pms-mv-card h3 { font-size: 26px; color: var(--pms-navy); margin-bottom: 20px; }
.pms-card p { font-size: 15.5px; color: var(--pms-text-muted); line-height: 1.7; }

/* ===============================================
   8. SPLIT LAYOUTS, LISTS, BOXES
   =============================================== */
.pms-split { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(350px, 100%), 1fr)); gap: 56px; align-items: start; }
.pms-two-column { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(350px, 100%), 1fr)); gap: 64px; align-items: center; }

.pms-feature-list { list-style: none; padding: 0; margin: 0; }
.pms-feature-list li {
  margin-bottom: 18px;
  font-size: 16px;
  color: var(--pms-text);
  padding-left: 34px;
  position: relative;
  line-height: 1.65;
}
.pms-feature-list li::before {
  content: "\2713";
  position: absolute;
  left: 0; top: 1px;
  width: 23px; height: 23px;
  border-radius: 50%;
  background: var(--pms-blue);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}

.pms-box {
  background: linear-gradient(135deg, var(--pms-bg-tint), var(--pms-bg-tint-2));
  padding: 44px;
  border-radius: 20px;
  border: 1px solid var(--pms-border);
  box-shadow: var(--pms-shadow);
}
.pms-focus-box {
  background: linear-gradient(135deg, var(--pms-bg-tint-2), var(--pms-bg-tint));
  padding: 56px;
  border-radius: 24px;
  border: 1px solid var(--pms-border);
  margin-top: 70px;
  text-align: center;
  box-shadow: var(--pms-shadow);
}

.pms-image-box { position: relative; }
.pms-image-box img {
  width: 100%;
  border-radius: 24px;
  box-shadow: var(--pms-shadow-hover);
}
.pms-image-box::after {
  content: "";
  position: absolute;
  top: 22px; left: 22px; right: -14px; bottom: -14px;
  border: 2px solid var(--pms-bg-tint-2);
  border-radius: 24px;
  z-index: -1;
}

/* ===============================================
   9. HERO / CTA BANDS (non-home pages)
   =============================================== */
.pms-hero {
  background: var(--pms-gradient);
  color: #fff;
  padding: clamp(80px, 12vw, 140px) 24px;
  text-align: center;
}
.pms-hero h1 { font-size: clamp(34px, 5vw, 54px); font-weight: 700; margin-bottom: 22px; color: #fff; line-height: 1.12; }
.pms-hero p { font-size: 19px; max-width: 760px; margin: auto; opacity: 0.95; line-height: 1.7; }

.pms-cta {
  background: var(--pms-gradient);
  color: #fff;
  text-align: center;
  padding: 96px 32px;
  border-radius: 28px;
  max-width: 1200px;
  margin: 48px auto 72px;
  box-shadow: 0 30px 60px rgba(10, 61, 98, 0.3);
}
.pms-cta h2 { font-size: clamp(28px, 3.4vw, 40px); margin-bottom: 20px; color: #fff; }
.pms-cta p { opacity: 0.92; }

/* ===============================================
   10. FOOTER — deep navy (plain, no cards)
   =============================================== */
.site-footer,
.site-footer .site-primary-footer-wrap,
.site-footer .site-below-footer-wrap,
.site-footer [data-section] { background-color: var(--pms-footer); }
.site-footer { border-top: 4px solid var(--pms-blue); color: #dbe6f1; }

/* widgets in the footer are plain text blocks, never cards */
.site-footer .widget {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
}
.site-footer h4.wp-block-heading {
  position: relative;
  padding-bottom: 12px;
  margin-bottom: 16px;
  font-size: 18px;
  letter-spacing: 0.02em;
}
.site-footer h4.wp-block-heading::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 36px; height: 3px;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--pms-blue), var(--pms-sky));
}
.site-footer p, .site-footer .ast-footer-copyright { color: #c7d6e5; }
.site-footer a { transition: var(--pms-transition); }
.site-footer a:hover { color: #ffffff !important; }

/* ===============================================
   11. FORMS
   =============================================== */
.srfm-form input[type="text"], .srfm-form input[type="email"],
.srfm-form input[type="tel"], .srfm-form input[type="url"],
.srfm-form input[type="number"], .srfm-form select, .srfm-form textarea,
.wp-block-search__input, input[type="search"] {
  border: 1.5px solid var(--pms-border);
  border-radius: 12px;
  padding: 13px 15px;
  background: #fff;
  transition: var(--pms-transition);
}
.srfm-form input:focus, .srfm-form select:focus, .srfm-form textarea:focus,
.wp-block-search__input:focus, input[type="search"]:focus {
  border-color: var(--pms-blue);
  box-shadow: 0 0 0 3px rgba(11, 94, 215, 0.15);
}

/* ===============================================
   12. BLOG — cards for posts, sidebar widgets only
   =============================================== */

/* Empty state (used by home.php until real posts are published) */
.pms-blog-empty {
  text-align: center;
  max-width: 640px;
  margin: 80px auto 110px;
  padding: 64px 40px;
  background: var(--pms-bg-tint);
  border: 1px solid var(--pms-border);
  border-radius: 24px;
}
.pms-blog-empty-badge {
  width: 72px; height: 72px;
  margin: 0 auto 24px;
  display: flex; align-items: center; justify-content: center;
  font-size: 30px;
  color: #fff;
  border-radius: 50%;
  background: var(--pms-gradient);
  box-shadow: 0 10px 24px rgba(11, 94, 215, 0.3);
}
.pms-blog-empty h1 { font-size: clamp(26px, 3vw, 34px); color: var(--pms-navy); margin-bottom: 14px; }
.pms-blog-empty p { color: var(--pms-text-muted); line-height: 1.7; }
.pms-blog-empty-actions { margin-top: 28px; display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.pms-empty-btn {
  display: inline-block;
  padding: 13px 30px;
  border-radius: var(--pms-radius-pill);
  background: var(--pms-blue);
  color: #fff !important;
  font-weight: 600;
  text-decoration: none !important;
  box-shadow: 0 6px 16px rgba(11, 94, 215, 0.28);
  transition: var(--pms-transition);
}
.pms-empty-btn:hover { background: var(--pms-navy); transform: translateY(-2px); }
.pms-empty-btn-ghost {
  background: transparent;
  color: var(--pms-blue) !important;
  border: 2px solid var(--pms-blue);
  box-shadow: none;
}
.pms-empty-btn-ghost:hover { background: var(--pms-blue); color: #fff !important; }
.ast-article-post, .ast-article-single {
  border-radius: var(--pms-radius);
  border: 1px solid var(--pms-border);
  box-shadow: var(--pms-shadow);
}
.sidebar-main .widget {
  background: var(--pms-bg-tint);
  border: 1px solid var(--pms-border);
  border-radius: var(--pms-radius);
  padding: 24px;
}

/* ===============================================
   13. MOBILE
   =============================================== */
@media (max-width: 768px) {
  .pms-section, .pms-support-section { padding: 40px 18px; }
  .pms-section-large, .pms-highlight-section { padding: 32px 18px; }
  .pms-subtitle { font-size: 16px; margin-bottom: 32px; }
  .pms-cta { padding: 60px 24px; margin: 32px 16px 48px; border-radius: 20px; }
  .pms-box, .pms-focus-box, .pms-mv-card { padding: 32px 24px; }
  .pms-image-box::after { display: none; }

  .elementor-1311 .elementor-element.elementor-element-8846ae9 {
    margin: -70px auto 0 !important;
    max-width: calc(100% - 28px);
    padding: 44px 24px !important;
    border-radius: 20px;
  }
}
