/*
 Theme Name:   Beaver Builder Child
 Theme URI:    https://shops.debug.victas.uca.org.au
 Description:  Child theme for Beaver Builder Theme
 Author:       Victas Web Team
 Author URI:   https://shops.debug.victas.uca.org.au
 Template:     bb-theme
 Version:      1.0
*/
/* =========================================================
   UCA VICTAS – ACCESSIBLE BASE STYLES
   WCAG 2.1 AA – Beaver Builder Friendly
========================================================= */

/* =========================
   Default global styles (Accessible)
========================= */

/* Links: not color-only + keyboard focus */
a {
  color: #E42127;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}
a:hover,
a:focus {
  color: #353535;
  text-decoration-thickness: 2px;
}
a:focus-visible {
  outline: 3px solid #005fcc;
  outline-offset: 3px;
  background-color: rgba(0, 95, 204, 0.10);
}

/* Text spacing */
p { margin: 0 0 15px 0; }

/* Headings: keep your fonts but don’t crush readability */
h1 {
  font-family: 'Source Sans Pro', sans-serif;
  font-weight: 700;
  letter-spacing: -0.5px;
  margin: 0;
}
h4 {
  font-family: 'Oswald', sans-serif;
  letter-spacing: 0;
  text-transform: uppercase;
}

/* Lists: keep spacing, but don’t remove semantics */
ol li, ul li { margin-bottom: 15px; }

/* Avoid removing bullets globally (screen reader + semantics safe) */
.uca-page-content ul {
  color: #000000;
  font-size: 16px;
  line-height: 1.5em;
  margin-bottom: 30px !important;
  padding-left: 1.5rem; /* ensures bullets align */
}

/* Remove the risky global selector ".uca-page-content ul, li"
   (it affects ALL li site-wide). Target list items properly instead. */
.uca-page-content ul li {
  margin: 0 0 0.75em 0;
}

/* If you still want custom bullets visually, do it ONLY when you
   also keep list-style on OR apply to a special class (not globally). */

/* =====================================
   TABLES – ACCESSIBLE (WCAG 2.1 AA)
===================================== */

table {
  width: 100%;
  max-width: 100%;
  margin: 1rem auto;
  border-collapse: collapse;
  border: 1px solid #e0e0e0;
  border-bottom: 3px solid #E42127;
  background-color: #ffffff;
}

/* Caption: REQUIRED for screen readers */
table caption {
  caption-side: top;
  text-align: left;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: #000000;
}

/* Header cells */
table th {
  background-color: #E42127;
  color: #ffffff;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  text-align: left;
  border: 1px solid #ddd;
  padding: 12px 16px;
}

/* Data cells */
table td {
  color: #000000;
  border: 1px solid #ddd;
  padding: 12px 16px;
  vertical-align: top;
}

/* Zebra striping – visual aid (not meaning) */
table tbody tr:nth-child(even) {
  background-color: #f9f9f9;
}

/* Hover + keyboard focus parity */
table tbody tr:hover,
table tbody tr:focus-within {
  background-color: #f4f4f4;
}

/* Ensure links inside tables are clear */
table a {
  color: #000000;
  text-decoration: underline;
  text-decoration-thickness: 2px;
}
table a:hover,
table a:focus {
  color: #E42127;
}
table a:focus-visible {
  outline: 3px solid #005fcc;
  outline-offset: 2px;
}

/* Remove legacy last-column hack safely */
table th.last {
  border-right: 1px solid #ddd;
}

/* =====================================
   BLOCKQUOTE – ACCESSIBLE (WCAG 2.1 AA)
===================================== */

.fl-page-content blockquote {
  background-color: #f9f9f9;
  border-left: 5px solid #E42127;
  margin: 1.5em 0;
  padding: 1.25rem 1.5rem;
  font-family: 'Oswald', sans-serif;
  font-size: 1.5rem;
  line-height: 1.4;
  color: #000000;
  position: relative;
}

/* Decorative quote – visually helpful, screen-reader safe */
.fl-page-content blockquote::before {
  content: "“";
  font-size: 4rem;
  color: #ccc;
  position: absolute;
  top: 0.25rem;
  left: 0.5rem;
  line-height: 1;
  aria-hidden: true;
}

/* Remove closing quote to avoid duplication */
.fl-page-content blockquote::after {
  content: none;
}

/* Paragraphs inside blockquote */
.fl-page-content blockquote p {
  margin: 0;
  display: block;
  text-transform: none; /* REMOVE forced uppercase */
}

/* Cite / attribution */
.fl-page-content blockquote cite {
  display: block;
  margin-top: 0.75rem;
  font-size: 0.9rem;
  font-style: normal;
  color: #353535;
}

/* =====================================
   HEADER SEARCH – ACCESSIBLE
===================================== */

.site-header .search-form {
  position: relative;
}

/* Search input */
.site-header .search-field {
  background-color: transparent;
  background-image: url(images/search-icon.png);
  background-repeat: no-repeat;
  background-position: 8px center;
  background-size: 24px 24px;
  border: 2px solid transparent;
  cursor: pointer;
  height: 40px;
  padding-left: 40px;
  width: 40px;
  transition: width 300ms ease, background-color 300ms ease;
}

/* Keyboard + focus support */
.site-header .search-field:focus,
.site-header .search-field:focus-visible {
  width: 230px;
  background-color: #ffffff;
  border-color: #005fcc;
  cursor: text;
  outline: none;
}

/* Placeholder contrast */
.site-header .search-field::placeholder {
  color: #555;
}

/* Hide submit button visually, not from screen readers */
.search-submit {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}


/* =====================================
   FULL SCREEN SEARCH – ACCESSIBLE
===================================== */

#full-screen-search {
  position: fixed;
  inset: 0;
  background-color: #000000;
  z-index: 999999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease;
}

/* Open state */
#full-screen-search.open {
  opacity: 1;
  visibility: visible;
}

/* Trap visual focus */
#full-screen-search:focus-within {
  outline: none;
}

/* Close button */
#full-screen-search button.close {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 2rem;
  color: #ffffff;
  background: none;
  border: none;
  cursor: pointer;
}

/* Focus state for close button */
#full-screen-search button.close:focus-visible {
  outline: 3px solid #005fcc;
  outline-offset: 4px;
}

/* Search form container */
#full-screen-search form {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

/* Search input wrapper */
#full-screen-search form div {
  width: 90%;
  max-width: 600px;
}

/* Search input */
#full-screen-search input[type="search"] {
  width: 100%;
  height: auto;
  padding: 1.25rem 2rem;
  font-size: 2rem;
  border-radius: 999px;
  border: 3px solid transparent;
  background-color: #eeeeee;
  color: #000000;
}

/* Placeholder contrast */
#full-screen-search input[type="search"]::placeholder {
  color: #444;
}

/* Focus state */
#full-screen-search input[type="search"]:focus-visible {
  border-color: #005fcc;
  outline: none;
}

/* Hide submit button accessibly */
#full-screen-search input[type="submit"] {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

@media (prefers-reduced-motion: reduce) {
  .site-header .search-field,
  #full-screen-search {
    transition: none;
  }
}


/* =====================================
   WOOCOMMERCE – ACCESSIBLE BASE
===================================== */

.woocommerce {
  color: #000000;
}

/* Prevent zoom issues on mobile */
.woocommerce input,
.woocommerce select,
.woocommerce textarea {
  font-size: 16px;
}

/* Product titles */
.woocommerce ul.products li.product h2,
.woocommerce ul.products li.product h3 {
  font-size: 1.1rem;
  line-height: 1.4;
}

/* Prices */
.woocommerce .price {
  color: #000000;
  font-weight: 600;
}

/* Add to Cart buttons */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
  background-color: #E42127;
  color: #ffffff;
  border-radius: 999px;
  padding: 12px 24px;
  font-size: 16px;
  line-height: 1.2;
  border: none;
  text-decoration: none;
  display: inline-block;
  cursor: pointer;
}

/* Hover + focus parity */
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce a.button:focus-visible,
.woocommerce button.button:focus-visible,
.woocommerce input.button:focus-visible {
  background-color: #000000;
  color: #ffffff;
  outline: 3px solid #005fcc;
  outline-offset: 3px;
}

/* Quantity input */
.woocommerce .quantity input.qty {
  width: 4rem;
  padding: 8px;
  font-size: 16px;
}

/* Focus visibility */
.woocommerce .quantity input.qty:focus-visible {
  outline: 3px solid #005fcc;
  outline-offset: 2px;
}

/* Cart table */
.woocommerce-cart table.shop_table {
  width: 100%;
  border-collapse: collapse;
}

/* Headers */
.woocommerce-cart table.shop_table th {
  background: #E42127;
  color: #ffffff;
  text-align: left;
  padding: 12px;
}

/* Cells */
.woocommerce-cart table.shop_table td {
  padding: 12px;
  border: 1px solid #ddd;
}

/* Row hover + focus */
.woocommerce-cart table.shop_table tr:hover,
.woocommerce-cart table.shop_table tr:focus-within {
  background-color: #f4f4f4;
}


/* Checkout fields */
.woocommerce-checkout input,
.woocommerce-checkout select,
.woocommerce-checkout textarea {
  border: 2px solid #ccc;
  padding: 10px;
}

/* Focus state */
.woocommerce-checkout input:focus-visible,
.woocommerce-checkout select:focus-visible,
.woocommerce-checkout textarea:focus-visible {
  border-color: #005fcc;
  outline: none;
}

/* Required field indicator */
.woocommerce form .required {
  color: #E42127;
}

/* Notices base */
.woocommerce-error,
.woocommerce-info,
.woocommerce-message {
  border-left: 5px solid;
  padding: 1rem;
  margin-bottom: 1rem;
}

/* Error */
.woocommerce-error {
  border-color: #d63638;
  background: #fbeaea;
}

/* Info */
.woocommerce-info {
  border-color: #2271b1;
  background: #e7f0fa;
}

/* Success */
.woocommerce-message {
  border-color: #2e7d32;
  background: #e8f5e9;
}


/* Payment method list */
.woocommerce-checkout-payment ul.payment_methods li {
  margin-bottom: 1rem;
}

/* Radio buttons */
.woocommerce-checkout-payment input[type="radio"] {
  margin-right: 0.5rem;
}

/* Focus */
.woocommerce-checkout-payment input[type="radio"]:focus-visible {
  outline: 3px solid #005fcc;
  outline-offset: 2px;
}


/* Place order button */
#place_order {
  font-size: 18px;
  padding: 14px 32px;
}

/* Focus */
#place_order:focus-visible {
  outline: 4px solid #005fcc;
  outline-offset: 4px;
}





