/**
 * START Center button standardization
 *
 * Implements the client Figma "The START Center | Button Style
 * Standardization", recommended column.
 *
 * EVERY rule is scoped to body.postid-1587 so installing this plugin
 * changes only the program pages. Remove the scope once the client has
 * signed off and the spec is meant to apply site-wide.
 */

/* 1. PRIMARY BUTTON
   Get Started Today, Find Your Specialist, Learn How, Get In Touch.
   :focus-visible is not in the Figma, but hover alone leaves keyboard
   users with no feedback. */
body.postid-1587 .primary-button {
	background-color: #15478a;
	color: #fff;
	border-radius: 8px;
	min-height: 52px;
	padding: 8px 32px;
	font-size: 16px;
	font-weight: 700;
	letter-spacing: -0.32px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	transition: background-color 250ms ease-out, color 250ms ease-out;
}

body.postid-1587 .primary-button:hover,
body.postid-1587 .primary-button:focus-visible {
	background-color: #85d469;
	color: #15478a;
}

/* 2. HEADER CTA BUTTONS
   "Make a Payment" (#top-menu) and "Request Appointment"
   (#site-navigation) look identical but are styled by separate theme
   rule sets, hence the duplicated selectors. Selectors mirror the
   theme's own shapes to tie on specificity and win on source order.

   Figma "Secondary": white fill, 2px #85D469 border, navy label, 42px.
   Hover inverts to a green fill with the same navy label.

   Contrast: navy on white 9.13, navy on green 5.05. The green border is
   1.81 against white, but the white fill already defines the button edge
   against both the navy bar and the gradient, so 1.4.11 does not apply. */

/* Theme puts green on the <li> as well as the <a>. Clearing it also
   hides the square corners it painted behind the rounded link. */
body.postid-1587 .primary:is(:is(#top-menu .menu) > li),
body.postid-1587 .primary:is(:is(#site-navigation .menu) > li) {
	background-color: transparent;
}

/* Theme gives every #top-menu link a 1px border, which renders the phone
   number and Contact Us as outline buttons. The Figma has them as plain
   text; only the CTA keeps its green stroke. */
body.postid-1587 #top-menu .menu > li:not(.primary) > a,
body.postid-1587 #site-navigation .menu > li:not(.primary) > a:not(.submenu-carat) {
	border-color: transparent;
}

body.postid-1587 #top-menu .menu > li.primary.menu-item > a,
body.postid-1587 #top-menu .menu > li.primary.menu-item > a,
body.postid-1587 #site-navigation .menu > li.primary.menu-item > a:not(.submenu-carat) {
	background-color: #fff;
	color: #15478a;
	border: 2px solid #85d469;
	border-radius: 8px;
	min-height: 42px;
	padding: 8px 20px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	transition: background-color 250ms ease-out, color 250ms ease-out;
}

body.postid-1587 #top-menu .menu > li.primary.menu-item > a:hover,
body.postid-1587 #top-menu .menu > li.primary.menu-item > a:hover,
body.postid-1587 #top-menu .menu > li.primary.menu-item > a:focus-visible,
body.postid-1587 #site-navigation .menu > li.primary.menu-item > a:not(.submenu-carat):hover,
body.postid-1587 #site-navigation .menu > li.primary.menu-item > a:not(.submenu-carat):focus-visible {
	background-color: #85d469;
	color: #15478a;
}

/* Clinical Trials CTA, same treatment. */
body.postid-1587 a.bg-\[var\(--clinical-trials-highlight-color\)\] {
	background-color: #85d469;
	color: #15478a;
	transition: background-color 250ms ease-out, color 250ms ease-out;
}

/* 3. UNDERLINES
   Theme sets text-decoration-line (not the shorthand) on
   :is(.primary-button, .wp-element-button):hover, so the longhand has to
   be matched or the shorthand loses to it. */
body.postid-1587 .primary-button,
body.postid-1587 .wp-block-button__link,
body.postid-1587 :is(.primary-button, .wp-element-button):hover,
body.postid-1587 :is(.primary-button, .wp-element-button):focus-visible,
body.postid-1587 .wp-block-button__link:hover,
body.postid-1587 .wp-block-button__link:focus-visible {
	text-decoration-line: none;
}

/* 4. CONTRAST FAILURES IN THE FIGMA SPEC - NOT IMPLEMENTED
   Flagged to Alex; build as specified if she confirms.

   a) Secondary button border, #85D469 on white, 1.81:1 against a 3:1
      requirement (1.4.11). The border is the only thing defining the
      button edge, so it is not decorative. Suggested #468132 (4.72:1).

   b) Green hover underline on text buttons and links, light variants
      only. Same 1.81:1. Dark variants pass at 5.05:1 on #15478A.
      Suggested #15478A for light variants.

   5. NOT YET IMPLEMENTED

   Mapped in the Figma, selectors not confirmed on the site:
     Secondary button, outline buttons (phone / Contact Us), text
     buttons, hyperlinks, icon buttons (42px).

   CSS-reachable from the annotations:
     Remove outline styling from phone / Contact Us; nav background to
     neutral (needs its own check, nav links are white); remove the
     Clinical Trials outline; remove program tab outlines; carousel
     indicators to brand blue; remove black outlines on form fields;
     icon and social buttons to blue.

   Needs markup or JS:
     Swap arrow icons for checkmarks; nav dropdowns on click rather
     than hover (also fixes top-level nav items pointing at href="#"). */
