/*
Theme Name: Lugufelo Wear the Art
Theme URI: https://lugufelo.com/
Author: Sunny Carrandi
Description: A gallery-inspired WordPress and WooCommerce theme for Lugufelo's Wear the Art campaign, sculpture archive, artist story, merchandise, and PSP awareness initiative.
Version: 1.0.0
Requires at least: 6.4
Tested up to: 6.8
Requires PHP: 8.0
Text Domain: lugufelo-wear-the-art
*/

:root {
  --lwta-cream: #f5f3ee;
  --lwta-cream-deep: #e9e6df;
  --lwta-berry: #b4212d;
  --lwta-berry-dark: #8f1721;
  --lwta-gold: #a5a7a9;
  --lwta-espresso: #0b0b0b;
  --lwta-ink: #242424;
  --lwta-sage: #dedede;
  --lwta-white: #ffffff;
  --lwta-border: rgba(11, 11, 11, .14);
  --lwta-shadow: 0 18px 50px rgba(11, 11, 11, .13);
  --lwta-radius-sm: 10px;
  --lwta-radius: 18px;
  --lwta-radius-lg: 28px;
  --lwta-content: 1200px;
  --lwta-wide: 1440px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--lwta-ink);
  background: #ffffff;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--lwta-berry); text-underline-offset: 3px; }
a:hover { color: var(--lwta-berry-dark); }
h1, h2, h3, h4, h5, h6 {
  margin: 0 0 .65em;
  color: var(--lwta-espresso);
  font-family: "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -.025em;
}
h1 { font-size: clamp(2.7rem, 6vw, 5.8rem); }
h2 { font-size: clamp(2.05rem, 4vw, 3.8rem); }
h3 { font-size: clamp(1.4rem, 2.3vw, 2rem); }
p { margin: 0 0 1.15em; }
button, input, select, textarea { font: inherit; }

.screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.screen-reader-text:focus {
  clip: auto !important; width: auto; height: auto; padding: 12px 18px;
  top: 10px; left: 10px; z-index: 100000; background: #fff;
}

.lwta-container,
.site-main > .entry-content > :where(:not(.alignfull):not(.alignwide)),
.site-main > .entry-header {
  width: min(calc(100% - 40px), var(--lwta-content));
  margin-inline: auto;
}
.alignwide { width: min(calc(100% - 40px), var(--lwta-wide)); margin-inline: auto; }
.alignfull { width: 100%; }

/* Announcement bar */
.lwta-announcement {
  padding: 8px 20px;
  color: #fff;
  background: var(--lwta-espresso);
  font-size: .78rem;
  text-align: center;
  letter-spacing: .035em;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 999;
  background: rgba(11,11,11,.96);
  border-bottom: 1px solid var(--lwta-border);
  backdrop-filter: blur(14px);
}
.lwta-header-inner {
  min-height: 76px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 28px;
}
.site-branding { min-width: 160px; }
.site-logo img { max-height: 52px; width: auto; display: block; }
.site-title { margin: 0; font-size: 1.3rem; }
.site-title a { color: var(--lwta-gold); text-decoration: none; }
.site-description { margin: 2px 0 0; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; }
.primary-menu { display: flex; justify-content: center; flex-wrap: wrap; gap: 7px 24px; padding: 0; margin: 0; list-style: none; }
.primary-menu a { color: #fff; text-decoration: none; font-size: .88rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.primary-menu a:hover, .primary-menu .current-menu-item > a { color: var(--lwta-berry); }
.lwta-header-actions { display: flex; align-items: center; gap: 12px; }
.lwta-menu-toggle { display: none; border: 0; background: transparent; padding: 8px; cursor: pointer; }
.lwta-menu-toggle span { display: block; width: 24px; height: 2px; margin: 5px 0; background: var(--lwta-espresso); }

/* Buttons */
.lwta-button,
.wp-block-button__link,
.elementor-button,
button:not(.lwta-menu-toggle),
input[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 11px 22px;
  color: #fff;
  background: var(--lwta-berry);
  border: 1px solid var(--lwta-berry);
  border-radius: 2px;
  text-decoration: none;
  font-weight: 700;
  font-size: .86rem;
  line-height: 1.2;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.lwta-button:hover,
.wp-block-button__link:hover,
.elementor-button:hover,
input[type="submit"]:hover {
  color: #fff;
  background: var(--lwta-berry-dark);
  border-color: var(--lwta-berry-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(151,35,63,.22);
}
.lwta-button--gold { color: var(--lwta-espresso); background: var(--lwta-gold); border-color: var(--lwta-gold); }
.lwta-button--ghost { color: var(--lwta-berry); background: transparent; }

/* Hero */
.lwta-hero {
  position: relative;
  min-height: min(720px, 78vh);
  display: grid;
  align-items: center;
  color: #fff;
  background: var(--lwta-espresso);
  overflow: hidden;
}
.lwta-hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(42,28,22,.82), rgba(42,28,22,.42) 55%, rgba(42,28,22,.16)); }
.lwta-hero__media { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .82; }
.lwta-hero__content { position: relative; z-index: 1; max-width: 720px; padding-block: 100px; }
.lwta-eyebrow { display: block; margin-bottom: 14px; color: var(--lwta-gold); font-family: Georgia, serif; font-size: 1rem; font-style: italic; }
.lwta-hero h1 { color: #fff; max-width: 750px; }
.lwta-hero p { max-width: 620px; font-size: clamp(1rem, 1.4vw, 1.2rem); }
.lwta-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* Generic layout utilities: usable in Gutenberg, Classic Editor, or custom HTML widgets */
.lwta-section { padding-block: clamp(70px, 9vw, 125px); }
.lwta-section--compact { padding-block: clamp(45px, 6vw, 80px); }
.lwta-section--cream-deep { background: var(--lwta-cream-deep); }
.lwta-section--sage { background: var(--lwta-sage); }
.lwta-section--berry { color: #fff; background: var(--lwta-berry); }
.lwta-section--espresso { color: #fff; background: var(--lwta-espresso); }
.lwta-section__header { max-width: 720px; margin: 0 auto 42px; text-align: center; }
.lwta-section__header p { color: rgba(48,41,35,.72); }
.lwta-section--berry h2, .lwta-section--espresso h2 { color: #fff; }
.lwta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: var(--lwta-gap, 24px);
}
.lwta-col { flex: 1 1 var(--lwta-col-basis, 280px); min-width: 0; }
.lwta-grid { display: grid; grid-template-columns: repeat(var(--lwta-cols, 3), minmax(0, 1fr)); gap: var(--lwta-gap, 24px); }
.lwta-stack { display: flex; flex-direction: column; gap: var(--lwta-gap, 18px); }

/* Cards */
.lwta-card,
.woocommerce ul.products li.product,
.wp-block-post-template > li {
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--lwta-border);
  border-radius: 3px;
  box-shadow: 0 8px 30px rgba(58,43,36,.05);
  transition: transform .25s ease, box-shadow .25s ease;
}
.lwta-card:hover,
.woocommerce ul.products li.product:hover { transform: translateY(-5px); box-shadow: var(--lwta-shadow); }
.lwta-card__media { aspect-ratio: 4 / 3; overflow: hidden; background: var(--lwta-cream-deep); }
.lwta-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.lwta-card:hover .lwta-card__media img { transform: scale(1.045); }
.lwta-card__body { padding: 22px; }
.lwta-card__meta { color: var(--lwta-berry); font-size: .74rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.lwta-price { color: var(--lwta-berry); font-weight: 800; }

/* Forms */
input[type="text"], input[type="email"], input[type="tel"], input[type="url"], input[type="search"], input[type="number"], select, textarea {
  width: 100%; min-height: 48px; padding: 12px 15px; color: var(--lwta-ink); background: #fff;
  border: 1px solid var(--lwta-border); border-radius: 2px; outline: none;
}
textarea { min-height: 150px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--lwta-berry); box-shadow: 0 0 0 3px rgba(151,35,63,.12); }

/* Footer */
.site-footer { color: rgba(255,255,255,.78); background: var(--lwta-espresso); }
.lwta-newsletter { padding: 70px 20px; text-align: center; background: var(--lwta-berry); }
.lwta-newsletter h2 { color: #fff; }
.lwta-footer-grid { display: grid; grid-template-columns: 1.25fr repeat(3, 1fr); gap: 42px; padding-block: 65px; }
.site-footer h3, .site-footer h4 { color: #fff; }
.site-footer a { color: rgba(255,255,255,.78); text-decoration: none; }
.site-footer a:hover { color: var(--lwta-gold); }
.site-footer ul { margin: 0; padding: 0; list-style: none; }
.lwta-footer-bottom { padding: 18px 0; border-top: 1px solid rgba(255,255,255,.12); font-size: .82rem; }

/* WordPress and Elementor integration */
.elementor-section.elementor-section-boxed > .elementor-container,
.e-con-boxed > .e-con-inner { max-width: var(--lwta-content); }
.elementor-widget-text-editor { color: inherit; }
.widget { margin-bottom: 30px; }
.widget-title { font-size: 1.45rem; }
.entry-content { padding-block: 55px; }
.entry-content > *:first-child { margin-top: 0; }
.entry-content > *:last-child { margin-bottom: 0; }

/* WooCommerce */
.woocommerce ul.products { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 24px; }
.woocommerce ul.products::before, .woocommerce ul.products::after { display: none; }
.woocommerce ul.products li.product { width: auto !important; margin: 0 !important; padding: 14px; }
.woocommerce ul.products li.product .woocommerce-loop-product__title { font-size: 1.25rem; }
.woocommerce ul.products li.product .button { margin-top: 12px; }
.woocommerce span.onsale { background: var(--lwta-berry); }

@media (max-width: 980px) {
  .lwta-menu-toggle { display: block; }
  .lwta-header-inner { grid-template-columns: 1fr auto; }
  .site-navigation { grid-column: 1 / -1; display: none; padding-bottom: 18px; }
  .site-navigation.is-open { display: block; }
  .primary-menu { flex-direction: column; align-items: flex-start; }
  .lwta-header-actions .lwta-button { display: none; }
  .lwta-grid { grid-template-columns: repeat(min(var(--lwta-cols, 3), 2), minmax(0,1fr)); }
  .lwta-footer-grid { grid-template-columns: repeat(2, 1fr); }
  .woocommerce ul.products { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 640px) {
  .lwta-container, .site-main > .entry-content > :where(:not(.alignfull):not(.alignwide)), .site-main > .entry-header { width: min(calc(100% - 28px), var(--lwta-content)); }
  .lwta-hero { min-height: 650px; }
  .lwta-grid { grid-template-columns: 1fr; }
  .lwta-row { flex-direction: column; }
  .lwta-footer-grid { grid-template-columns: 1fr; }
  .woocommerce ul.products { grid-template-columns: 1fr; }
}

/* ================================================================
   Hero-first and full-width page layout
   ================================================================ */
.lwta-full-width-page,
.lwta-full-width-page article,
.lwta-full-width-page .entry-content,
.lwta-page--title-hidden,
.lwta-page--title-hidden > .entry-content {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
}

/* Do not reserve title/header space on pages where the title is hidden. */
.lwta-page--title-hidden > .entry-header,
.home .entry-header,
.front-page .entry-header {
  display: none;
}

/* Ensure the first full-width block or LWTA hero touches the site header. */
.lwta-page--title-hidden .entry-content > :first-child,
.lwta-full-width-page .entry-content > :first-child {
  margin-top: 0;
}

.lwta-page--title-hidden .entry-content > .alignfull,
.lwta-full-width-page .entry-content > .alignfull,
.lwta-page--title-hidden .entry-content > .wp-block-lwta-hero-banner,
.lwta-full-width-page .entry-content > .wp-block-lwta-hero-banner,
.lwta-page--title-hidden .entry-content > .lwta-hero,
.lwta-full-width-page .entry-content > .lwta-hero {
  width: 100%;
  max-width: none;
  margin-left: 0;
  margin-right: 0;
}

/* Normal interior-page title treatment. */
.lwta-page-header {
  padding-block: clamp(48px, 8vw, 110px);
}

/* ================================================================
   Remove space between the site header and homepage hero
   ================================================================ */

.home .site-main,
.home .site-main > article,
.home .site-main .entry-content,
.lwta-full-width-page,
.lwta-full-width-page > article,
.lwta-full-width-page .entry-content {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

    .home .entry-content > :first-child,
    .lwta-full-width-page .entry-content > :first-child {
        margin-top: 0 !important;
    }

    /* Remove Gutenberg block spacing before the first hero */
    .home .entry-content > .alignfull:first-child,
    .home .entry-content > .wp-block-lwta-hero-banner:first-child,
    .home .entry-content > .lwta-hero:first-child,
    .home .entry-content > .lwta-hero-banner:first-child,
    .lwta-full-width-page .entry-content > .alignfull:first-child,
    .lwta-full-width-page .entry-content > .wp-block-lwta-hero-banner:first-child,
    .lwta-full-width-page .entry-content > .lwta-hero:first-child,
    .lwta-full-width-page .entry-content > .lwta-hero-banner:first-child {
        margin-top: 0 !important;
    }

    /* Prevent the homepage article from reserving vertical space */
    .home article.page,
    .home article.type-page,
    .lwta-full-width-page article.page {
        padding-top: 0 !important;
        margin-top: 0 !important;
    }

/* ================================================================
   Shared card-row width
   Apply "lwta-matching-card-width" to both the Home Cards container
   and the Product Cards container in Gutenberg.
   ================================================================ */

.lwta-matching-card-width {
  box-sizing: border-box;
  width: min(calc(100% - 64px), var(--lwta-content, 1200px)) !important;
  max-width: var(--lwta-content, 1200px) !important;
  margin-inline: auto !important;
}

/* Support Gutenberg Columns, Grid, and Group layouts. */
.lwta-matching-card-width.wp-block-columns,
.lwta-matching-card-width.wp-block-group,
.lwta-matching-card-width.wp-block-group-is-layout-grid,
.lwta-matching-card-width.is-layout-grid {
  width: min(calc(100% - 64px), var(--lwta-content, 1200px)) !important;
  max-width: var(--lwta-content, 1200px) !important;
  margin-inline: auto !important;
}

/* Give both card rows the same horizontal and vertical gaps. */
.lwta-matching-card-width.wp-block-columns,
.lwta-matching-card-width.wp-block-group-is-layout-grid,
.lwta-matching-card-width.is-layout-grid {
  column-gap: 24px;
  row-gap: 24px;
}

/* Prevent child columns/cards from overflowing their assigned width. */
.lwta-matching-card-width > .wp-block-column,
.lwta-matching-card-width .lwta-home-card,
.lwta-matching-card-width .lwta-product-card {
  min-width: 0;
  max-width: 100%;
}

/* Tablet */
@media (max-width: 900px) {
  .lwta-matching-card-width,
  .lwta-matching-card-width.wp-block-columns,
  .lwta-matching-card-width.wp-block-group,
  .lwta-matching-card-width.wp-block-group-is-layout-grid,
  .lwta-matching-card-width.is-layout-grid {
    width: calc(100% - 40px) !important;
  }
}

/* Mobile */
@media (max-width: 600px) {
  .lwta-matching-card-width,
  .lwta-matching-card-width.wp-block-columns,
  .lwta-matching-card-width.wp-block-group,
  .lwta-matching-card-width.wp-block-group-is-layout-grid,
  .lwta-matching-card-width.is-layout-grid {
    width: calc(100% - 28px) !important;
  }

  .lwta-matching-card-width.wp-block-columns,
  .lwta-matching-card-width.wp-block-group-is-layout-grid,
  .lwta-matching-card-width.is-layout-grid {
    column-gap: 16px;
    row-gap: 16px;
  }
}

/* Wear the Art campaign utilities */
.lwta-kicker { color: var(--lwta-berry); font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.lwta-impact-strip { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); background:var(--lwta-espresso); color:#fff; }
.lwta-impact-strip > div { padding:28px; text-align:center; border-right:1px solid rgba(255,255,255,.16); }
.lwta-impact-strip strong { display:block; color:#fff; font-size:clamp(1.4rem,3vw,2.3rem); }
.lwta-art-label { font-size:.72rem; letter-spacing:.14em; text-transform:uppercase; color:var(--lwta-berry); }
@media(max-width:700px){.lwta-impact-strip{grid-template-columns:1fr}.lwta-impact-strip>div{border-right:0;border-bottom:1px solid rgba(255,255,255,.16)}}
