/*
Theme Name:  Little Muzos
Theme URI:   https://www.littlemuzos.com.au
Description: Little Muzos child theme for Astra — matches the TuitionHub app's
             design system (brand palette, Nunito/DM Mono type, 12px radii).
Author:      Little Muzos
Template:    astra
Version:     2.5.0
Text Domain: littlemuzos-child
*/

/* ===========================================================================
   Design tokens — mirrored from the app (frontend/src/app/globals.css).
   Keep these in sync with the app so the site and app read as one product.
   =========================================================================== */
:root {
  /* Brand palette */
  --lm-teal:         #3ecfb2;
  --lm-sky:          #5bb8f5;
  --lm-purple:       #9b6ef3;
  --lm-pink:         #d94fad;
  --lm-magenta:      #f0288a;
  --lm-orange:       #f97040;
  --lm-yellow-green: #a8d44a;

  /* Gradient (mirrors the logo arc) */
  --lm-grad:      linear-gradient(90deg, var(--lm-teal), var(--lm-sky), var(--lm-purple), var(--lm-pink), var(--lm-magenta));
  --lm-grad-warm: linear-gradient(90deg, var(--lm-orange), var(--lm-pink), var(--lm-magenta));

  /* Light surfaces + text (site default) */
  --lm-bg:            #f5f6fa;
  --lm-bg-card:       #ffffff;
  --lm-bg-hover:      #eef0f6;
  --lm-border:        #e3e6ee;
  --lm-text-primary:  #1b1e2a;
  --lm-text-secondary:#565c70;
  --lm-text-muted:    #878da1;

  /* Accent */
  --lm-accent:        #9b6ef3;
  --lm-accent-hover:  #8558e8;

  /* Status */
  --lm-green:  #34c97a;
  --lm-amber:  #f5a623;
  --lm-red:    #f0544f;

  /* Layout */
  --lm-radius:    12px;
  --lm-radius-sm: 8px;
  --lm-shadow:    0 8px 32px rgba(20,24,40,0.12);
  --lm-font:      'Nunito', sans-serif;
  --lm-font-mono: 'DM Mono', monospace;

  /* --- Map Astra's global colour slots onto our tokens so core theme
         elements pick up the palette without touching the Customizer. --- */
  --ast-global-color-0: var(--lm-accent);         /* primary / links / buttons */
  --ast-global-color-1: var(--lm-accent-hover);   /* primary hover */
  --ast-global-color-2: var(--lm-text-primary);   /* headings */
  --ast-global-color-3: var(--lm-text-secondary); /* body text */
  --ast-global-color-4: var(--lm-bg);             /* page background */
  --ast-global-color-5: var(--lm-bg-card);        /* surface / light bg */
  --ast-global-color-6: var(--lm-border);         /* borders */
  --ast-global-color-7: var(--lm-text-primary);
  --ast-global-color-8: var(--lm-text-muted);
}

/* ===========================================================================
   Typography
   =========================================================================== */
body,
button,
input,
select,
textarea,
.ast-container {
  font-family: var(--lm-font);
  color: var(--lm-text-primary);
}

body { background-color: var(--lm-bg); }

h1, h2, h3, h4, h5, h6,
.entry-title,
.site-title {
  font-family: var(--lm-font);
  font-weight: 800;
  color: var(--lm-text-primary);
  letter-spacing: -0.01em;
}

code, pre, kbd { font-family: var(--lm-font-mono); }

a { color: var(--lm-accent); }
a:hover, a:focus { color: var(--lm-accent-hover); }

/* ===========================================================================
   Buttons (theme + WooCommerce)
   =========================================================================== */
.ast-button,
.button,
button.button,
input[type="submit"],
.wp-block-button__link,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce .button,
.woocommerce #respond input#submit,
.woocommerce a.button.alt,
.woocommerce button.button.alt {
  background: linear-gradient(90deg, var(--lm-purple), var(--lm-pink));
  background-size: 140% 100%;
  background-position: 0 0;
  color: #fff;
  border: none;
  border-radius: var(--lm-radius-sm);
  font-family: var(--lm-font);
  font-weight: 700;
  padding: 0.7em 1.4em;
  box-shadow: 0 2px 10px rgba(155,110,243,0.28);
  transition: background-position .35s ease, box-shadow .15s ease, transform .08s ease;
}

.ast-button:hover,
.button:hover,
button.button:hover,
input[type="submit"]:hover,
.wp-block-button__link:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce .button:hover,
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover {
  background-position: 100% 0;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(155,110,243,0.36);
}

/* Gradient call-to-action — add class="lm-cta" to any button/link */
.lm-cta,
.wp-block-button.is-style-lm-gradient .wp-block-button__link {
  background: var(--lm-grad) !important;
  background-size: 200% 100% !important;
  color: #fff !important;
  border: none !important;
  border-radius: var(--lm-radius-sm) !important;
  font-weight: 800 !important;
  transition: background-position .4s ease !important;
}
.lm-cta:hover { background-position: 100% 0 !important; }

/* ===========================================================================
   Cards, inputs, surfaces
   =========================================================================== */
.ast-card,
.woocommerce ul.products li.product,
.wp-block-group.has-background {
  border-radius: var(--lm-radius);
  box-shadow: var(--lm-shadow);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="search"],
input[type="number"],
input[type="password"],
textarea,
select {
  border: 1px solid var(--lm-border);
  border-radius: var(--lm-radius-sm);
  background: var(--lm-bg-card);
}
input:focus, textarea:focus, select:focus {
  border-color: var(--lm-accent);
  outline: none;
  box-shadow: 0 0 0 3px rgba(155,110,243,0.15);
}

/* WooCommerce price + sale badge in brand colours */
.woocommerce span.price,
.woocommerce div.product p.price,
.woocommerce ul.products li.product .price {
  color: var(--lm-text-primary);
  font-weight: 800;
}
.woocommerce span.onsale {
  background: var(--lm-magenta);
  color: #fff;
  border-radius: 999px;
}

/* ===========================================================================
   Brand gradient hero — add class="lm-hero" to a cover/group block
   =========================================================================== */
.lm-hero {
  background: var(--lm-grad);
  background-size: 180% 100%;
  color: #fff;
  border-radius: var(--lm-radius);
}
.lm-hero h1, .lm-hero h2, .lm-hero h3, .lm-hero p { color: #fff; }

/* Thin gradient rule — add class="lm-rule" to a separator */
.lm-rule {
  height: 4px;
  border: none;
  border-radius: 2px;
  background: var(--lm-grad);
}

/* ===========================================================================
   v2 additions — header/footer polish, cards, pills, pattern support
   =========================================================================== */

/* Header: white bar with the brand border, bold nav in Nunito */
.main-header-bar,
.ast-primary-header-bar {
  background: var(--lm-bg-card);
  border-bottom: 1px solid var(--lm-border);
}
.main-header-menu .menu-item > .menu-link {
  font-weight: 700;
  color: var(--lm-text-secondary);
}
.main-header-menu .menu-item > .menu-link:hover,
.main-header-menu .current-menu-item > .menu-link {
  color: var(--lm-accent);
}

/* Footer: rainbow top edge, quiet surface */
.site-footer {
  position: relative;
  background: var(--lm-bg-card);
  border-top: none;
  color: var(--lm-text-secondary);
}
.site-footer::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: var(--lm-grad);
}

/* Card — add class="lm-card" to a Group/Column block */
.lm-card {
  background: var(--lm-bg-card);
  border: 1px solid var(--lm-border);
  border-radius: var(--lm-radius);
  box-shadow: 0 2px 12px rgba(20,24,40,0.06);
  padding: 28px 24px;
  transition: transform .15s ease, box-shadow .15s ease;
}
.lm-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--lm-shadow);
}

/* Pill badge — add class="lm-pill" (tint variants below) */
.lm-pill {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.02em;
  background: rgba(155,110,243,0.12);
  color: var(--lm-accent);
}
.lm-pill--teal    { background: rgba(62,207,178,0.14); color: #1fa78d; }
.lm-pill--sky     { background: rgba(91,184,245,0.14); color: #2f8fd6; }
.lm-pill--pink    { background: rgba(217,79,173,0.12); color: var(--lm-pink); }
.lm-pill--magenta { background: rgba(240,40,138,0.12); color: var(--lm-magenta); }
.lm-pill--orange  { background: rgba(249,112,64,0.14); color: var(--lm-orange); }

/* Gradient text — add class="lm-grad-text" to a heading */
.lm-grad-text {
  background: var(--lm-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

/* CTA band — full-width gradient strip (used by the pattern) */
.lm-cta-band {
  background: var(--lm-grad);
  background-size: 180% 100%;
  border-radius: var(--lm-radius);
  color: #fff;
}
.lm-cta-band h1, .lm-cta-band h2, .lm-cta-band h3, .lm-cta-band p { color: #fff; }
.lm-cta-band .wp-block-button__link {
  background: #fff !important;
  color: var(--lm-accent) !important;
  font-weight: 800;
  border-radius: var(--lm-radius-sm);
}

/* White-outline button on gradient surfaces */
.lm-hero .is-style-outline .wp-block-button__link,
.lm-cta-band .is-style-outline .wp-block-button__link {
  background: transparent !important;
  border: 2px solid rgba(255,255,255,0.85) !important;
  color: #fff !important;
}

/* ===========================================================================
   v2.1 — horizontal photo strips (add the class to a Gallery block)
   =========================================================================== */

/* Swipeable strip with snap — class "lm-photo-strip" on a Gallery block */
.wp-block-gallery.lm-photo-strip {
  display: flex !important;
  flex-wrap: nowrap !important;
  gap: 16px !important;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 4px;
}
.wp-block-gallery.lm-photo-strip::-webkit-scrollbar { display: none; }
.wp-block-gallery.lm-photo-strip .wp-block-image,
.wp-block-gallery.lm-photo-strip figure.wp-block-image {
  flex: 0 0 auto !important;
  width: min(70vw, 340px) !important;
  margin: 0 !important;
  scroll-snap-align: center;
}
.wp-block-gallery.lm-photo-strip .wp-block-image img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  border-radius: var(--lm-radius);
}

/* Auto-scrolling marquee loop — class "lm-marquee" on ANY block that
   contains images (Gallery, Columns, Group, ...). assets/lm-marquee.js
   wraps the block's children in a track and duplicates them so the loop
   is seamless. Pauses on hover. */
.lm-marquee {
  display: block !important;
  overflow: hidden;
  max-width: none;
}
.lm-marquee-track {
  display: flex;
  align-items: center;
  width: max-content;
  gap: 16px;
  animation: lm-marquee-scroll 40s linear infinite;
}
.lm-marquee:hover .lm-marquee-track { animation-play-state: paused; }
.lm-marquee-track > * {
  flex: 0 0 auto;
  margin: 0 !important;
  width: auto !important;
}
.lm-marquee { --lm-marquee-h: 220px; }
.lm-marquee.lm-marquee--xxs { --lm-marquee-h: 48px; }
.lm-marquee.lm-marquee--xs { --lm-marquee-h: 80px; }
.lm-marquee.lm-marquee--sm { --lm-marquee-h: 120px; }
.lm-marquee.lm-marquee--md { --lm-marquee-h: 160px; }
.lm-marquee.lm-marquee--lg { --lm-marquee-h: 300px; }
.lm-marquee-track img {
  height: var(--lm-marquee-h) !important;
  width: auto !important;
  max-width: none !important;
  object-fit: cover;
  border-radius: var(--lm-radius);
}
@keyframes lm-marquee-scroll {
  to { transform: translateX(-50%); }
}
/* Respect reduced-motion preferences: fall back to a swipeable strip */
@media (prefers-reduced-motion: reduce) {
  .lm-marquee-track { animation: none; }
  .lm-marquee { overflow-x: auto; }
}

/* ===========================================================================
   v2.4 — hire rates table ([lm_hire_rates] shortcode, live from the app)
   =========================================================================== */
.lm-rates { max-width: 640px; margin: 0 auto; }
.lm-rates__title {
  font-size: clamp(26px, 4vw, 34px);
  font-weight: 800;
  margin: 0 0 18px;
  background: var(--lm-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
.lm-rates__scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 14px;
  box-shadow: 0 4px 24px rgba(20,24,40,0.08);
}
.lm-rates__table {
  width: 100%;
  border-collapse: collapse;
  background: var(--lm-bg-card);
  border-radius: 14px;
  overflow: hidden;
  font-size: 16px;
}
.lm-rates__table thead th {
  background: linear-gradient(90deg, var(--lm-purple), var(--lm-pink));
  color: #fff;
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: left;
  padding: 15px 22px;
  white-space: nowrap;
}
.lm-rates__table thead th:last-child { text-align: right; }
.lm-rates__table tbody td {
  padding: 13px 22px;
  border-top: 1px solid var(--lm-border);
}
.lm-rates__table tbody tr:first-child td { border-top: none; }
.lm-rates__table tbody tr:nth-child(even) { background: #f7f8fc; }
.lm-rates__table tbody tr:hover { background: rgba(155,110,243,0.07); }
.lm-rates__price {
  text-align: right;
  font-weight: 800;
  font-size: 19px;
  white-space: nowrap;
  background: linear-gradient(90deg, var(--lm-purple), var(--lm-pink));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
@media (max-width: 520px) {
  .lm-rates__table { font-size: 15px; }
  .lm-rates__table thead th { padding: 13px 16px; }
  .lm-rates__table tbody td { padding: 11px 16px; }
  .lm-rates__price { font-size: 17px; }
}

/* ===========================================================================
   v2.5 — button polish: the app's gradient, applied to the stragglers Astra
   and WooCommerce style separately from the main button selectors.
   =========================================================================== */
.woocommerce #respond input#submit.alt,
.woocommerce .widget_shopping_cart a.button,
.woocommerce-page .widget_shopping_cart a.button,
.wc-block-components-button,
.wp-block-woocommerce-cart .wc-block-cart__submit-button,
.wc-block-components-checkout-place-order-button,
.ast-custom-button,
.ast-header-button-1 .ast-custom-button,
.menu-link.ast-custom-button {
  background: linear-gradient(90deg, var(--lm-purple), var(--lm-pink)) !important;
  background-size: 140% 100% !important;
  color: #fff !important;
  border: none !important;
  border-radius: var(--lm-radius-sm) !important;
  font-weight: 700;
  box-shadow: 0 2px 10px rgba(155,110,243,0.28);
  transition: background-position .35s ease, box-shadow .15s ease, transform .08s ease;
}
.woocommerce #respond input#submit.alt:hover,
.wc-block-components-button:hover,
.wc-block-components-checkout-place-order-button:hover,
.ast-custom-button:hover,
.menu-link.ast-custom-button:hover {
  background-position: 100% 0 !important;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(155,110,243,0.36);
}

/* Quantity / secondary actions stay quiet so the primary CTA leads */
.woocommerce a.button.wc-backward,
.woocommerce button.button:disabled {
  background: var(--lm-bg-hover) !important;
  color: var(--lm-text-secondary) !important;
  box-shadow: none !important;
}
