/*
Theme Name:   Fast Meds USA Senior
Theme URI:    https://fastmedsusa.com
Description:  Senior-friendly WooCommerce theme for Fast Meds USA: large text, high contrast, big buttons, simple menu. Child theme of Storefront.
Author:       Fast Meds USA
Template:     storefront
Version:      1.0.0
Requires at least: 6.4
Requires PHP: 7.4
Text Domain:  fastmeds
*/

/* Colors: all text is at least 7:1 on its background. Base text 20px, buttons 56px+. */
:root {
  --fm-navy: #0b2e59;
  --fm-blue: #0a4fa6;
  --fm-green: #1b6b2f;
  --fm-green-h: #134f22;
  --fm-text: #1a1a1a;
  --fm-muted: #3d4a5c;
  --fm-soft: #f1f5fa;
  --fm-line: #c9d4e3;
  --fm-focus: #ffbf00;
  --fm-warn-bg: #fff4c2;
  --fm-warn-line: #8a6d00;
  --fm-body: 'Atkinson Hyperlegible', Verdana, 'Segoe UI', Arial, sans-serif;
  --fm-head: 'Lexend', 'Atkinson Hyperlegible', Verdana, sans-serif;
}

html { font-size: 125%; }               /* 20px base, scales with browser zoom */
body, button, input, select, textarea {
  font-family: var(--fm-body);
  color: var(--fm-text);
  line-height: 1.6;
}
body { background: #fff; }
h1, h2, h3, h4, .site-title, .entry-title, .product_title {
  font-family: var(--fm-head);
  color: var(--fm-navy);
  line-height: 1.25;
  font-weight: 700;
}
h1, .entry-title, .product_title { font-size: 1.9rem; }
h2 { font-size: 1.5rem; margin-top: 1.4em; }
h3 { font-size: 1.25rem; }

a { color: var(--fm-blue); text-decoration: underline; text-underline-offset: 3px; }
a:hover { color: var(--fm-navy); }

/* Big, obvious keyboard focus */
a:focus, button:focus, input:focus, select:focus, textarea:focus, .button:focus {
  outline: 4px solid var(--fm-focus) !important;
  outline-offset: 3px;
}

/* Placeholder highlighting: anything not filled in yet */
.fm-placeholder {
  background: var(--fm-warn-bg);
  border: 2px dashed var(--fm-warn-line);
  color: #4a3a00;
  padding: 0 .3em;
  border-radius: 3px;
}

/* ---------- Help bar ---------- */
.fm-helpbar {
  background: var(--fm-soft);
  border-bottom: 2px solid var(--fm-line);
  text-align: center;
  font-size: 1rem;
  padding: .6rem 1rem;
}
.fm-helpbar strong a { color: var(--fm-text); font-weight: 700; }

/* ---------- Header ---------- */
.site-header { background: #fff !important; border-bottom: 0; padding-top: 1.2rem; }
.site-header .site-title a, .site-branding .site-title a { color: var(--fm-navy) !important; font-size: 1.8rem; text-decoration: none; }
.site-header .site-description { display: none; }
.site-search .widget_product_search input[type="search"],
.site-search .widget_product_search input[type="text"] {
  height: 56px; font-size: 1rem; padding: 0 1rem 0 2.6rem; border: 2px solid var(--fm-muted); border-radius: 8px; background: #fff;
}
.site-header-cart .cart-contents { color: var(--fm-text) !important; font-weight: 700; font-size: 1rem; }

/* Main menu: one flat row on navy, no drop-downs */
.storefront-primary-navigation { background: var(--fm-navy) !important; }
.main-navigation ul.menu > li > a, .main-navigation ul.nav-menu > li > a {
  color: #fff !important; font-weight: 700; font-size: 1.05rem; padding: 1rem 1.1rem; text-decoration: none;
}
.main-navigation ul.menu > li > a:hover, .main-navigation ul.menu > li.current-menu-item > a {
  background: rgba(255,255,255,.16); text-decoration: underline;
}
.main-navigation ul.menu ul, .main-navigation ul.nav-menu ul { display: none !important; }
.menu-toggle { color: #fff !important; border-color: #fff !important; font-size: 1.1rem; min-height: 56px; }
.main-navigation.toggled ul.menu > li > a, .handheld-navigation a { color: #fff !important; }
.handheld-navigation { background: var(--fm-navy); }

/* ---------- Buttons ---------- */
button, input[type="button"], input[type="reset"], input[type="submit"], .button, .added_to_cart, .wc-block-components-button {
  background: var(--fm-green) !important;
  border: 2px solid var(--fm-green) !important;
  color: #fff !important;
  font-weight: 700;
  font-size: 1.05rem;
  min-height: 56px;
  padding: .7rem 1.6rem;
  border-radius: 8px;
  text-decoration: none;
}
button:hover, input[type="submit"]:hover, .button:hover { background: var(--fm-green-h) !important; border-color: var(--fm-green-h) !important; }
.button.alt, .single_add_to_cart_button, .checkout-button, #place_order {
  font-size: 1.25rem !important; min-height: 64px; width: 100%;
}
.fm-btn-outline { background: #fff !important; color: var(--fm-blue) !important; border-color: var(--fm-blue) !important; }

/* ---------- Forms ---------- */
input[type="text"], input[type="email"], input[type="tel"], input[type="number"], input[type="password"], input[type="search"], textarea, select {
  font-size: 1rem; border: 2px solid var(--fm-muted); border-radius: 8px; padding: .7rem 1rem; background: #fff; color: var(--fm-text);
}
input[type="text"], input[type="email"], input[type="tel"], input[type="password"], select { min-height: 56px; }
label { font-weight: 700; }
.quantity .qty { width: 5em; min-height: 56px; font-size: 1.2rem; }

/* ---------- Shop / category grid ---------- */
ul.products li.product {
  border: 2px solid var(--fm-line); border-radius: 10px; padding: 1.2rem; text-align: left;
}
ul.products li.product .woocommerce-loop-product__title { font-size: 1.2rem !important; font-weight: 700; color: var(--fm-text); }
ul.products li.product .price, .single-product .summary .price { color: var(--fm-navy) !important; font-family: var(--fm-head); font-weight: 700; }
ul.products li.product .price { font-size: 1.5rem !important; }
.single-product .summary .price { font-size: 2.2rem !important; }
ul.products li.product .button { width: 100%; }
.storefront-sorting { font-size: 1rem; }
.onsale { display: none; }
.woocommerce-breadcrumb, .storefront-breadcrumb { font-size: 1rem; }

/* Product page */
.single-product div.product .woocommerce-tabs ul.tabs li a { font-size: 1.1rem; padding: .9rem 1rem; }
.single-product .product_meta { font-size: .9rem; }

/* Help panel (product, cart, contact) */
.fm-help {
  background: var(--fm-soft);
  border-left: 8px solid var(--fm-blue);
  padding: 1.1rem 1.4rem;
  border-radius: 4px;
  margin: 1.5rem 0;
}
.fm-help p { margin: .3rem 0; }
.fm-bigphone { font-family: var(--fm-head); font-size: 1.8rem; font-weight: 700; }

/* Home page */
.fm-hero { background: var(--fm-soft); border-radius: 12px; padding: 2rem; margin-bottom: 2rem; }
.fm-hero p { font-size: 1.2rem; max-width: 40ch; }
.fm-actions { display: flex; flex-wrap: wrap; gap: 1rem; }
.fm-cats { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.fm-cats a { display: block; height: 100%; padding: 1.1rem 1.3rem; border: 2px solid var(--fm-line); border-radius: 10px; font-weight: 700; font-size: 1.2rem; }
.fm-cats a span { display: block; color: var(--fm-muted); font-weight: 400; font-size: .9rem; text-decoration: none; }
.fm-promise { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.fm-promise li { border-top: 3px solid var(--fm-navy); padding-top: .8rem; }

/* Text pages: readable width */
.page .entry-content { max-width: 780px; }
.page .entry-content li { margin-bottom: .5rem; }
.home.page .entry-content { max-width: none; }
.home .entry-header { display: none; }

/* Contact form */
.fm-form p { margin-bottom: 1.1rem; }
.fm-form input[type="text"], .fm-form input[type="email"], .fm-form input[type="tel"], .fm-form textarea { width: 100%; }
.fm-form .fm-hp { position: absolute; left: -9999px; }
.fm-notice { background: var(--fm-soft); border: 2px solid var(--fm-green); padding: .8rem 1rem; border-radius: 8px; font-weight: 700; }
.fm-notice.fm-error { border-color: #a4161a; }

/* ---------- Footer ---------- */
.site-footer { background: var(--fm-navy) !important; color: #fff !important; font-size: 1rem; }
.site-footer a { color: #fff !important; }
.fm-footer-links { list-style: none; margin: 0 0 1rem; padding: 0; display: flex; flex-wrap: wrap; gap: .8rem 2rem; font-weight: 700; }
.fm-disclaimer { font-size: .85rem; border-top: 1px solid rgba(255,255,255,.4); padding-top: 1rem; margin: 1rem 0 0; }
.site-footer .fm-placeholder { color: #4a3a00; }
.site-footer .fm-placeholder a { color: #4a3a00 !important; }

@media (max-width: 767px) {
  html { font-size: 118.75%; }  /* 19px */
  .fm-hero { padding: 1.3rem; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
