/*
Theme Name: SPARKANDSILK
Theme URI: https://sparkandsilk.com
Author: SPARKANDSILK
Author URI: https://sparkandsilk.com
Description: A premium, feminine WooCommerce theme for intimate wellness brands. Editorial layout, refined typography, full dashboard editability, color-swatch product variations, and Nigerian Naira support.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: sparkandsilk
Tags: e-commerce, woocommerce, custom-colors, custom-menu, custom-logo, featured-images, threaded-comments, translation-ready
*/

/* ============================================================
   Base
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: #1c1917;
  background: #fffaf7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; transition: color .25s ease; }
a:hover { color: #7c524b; }
::selection { background: #e8c8c2; color: #1c1917; }

.serif { font-family: 'Cormorant Garamond', 'Playfair Display', Georgia, serif; }

.container { max-width: 1240px; margin: 0 auto; padding: 0 20px; }
@media (min-width: 640px) { .container { padding: 0 32px; } }

.eyebrow {
  display: inline-block;
  font-size: 12px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: #9b6b62;
}

/* ============================================================
   Buttons
   ============================================================ */
.ss-btn {
  display: inline-block;
  padding: 16px 32px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  transition: background .25s ease, color .25s ease, border-color .25s ease;
}
.ss-btn--light { background: #fff; color: #1c1917; }
.ss-btn--light:hover { background: #f4ded9; color: #1c1917; }
.ss-btn--dark { background: #1c1917; color: #fff; }
.ss-btn--dark:hover { background: #7c524b; color: #fff; }
.ss-btn--ghost { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.4); }
.ss-btn--ghost:hover { background: rgba(255,255,255,.1); border-color: #fff; color: #fff; }

/* ============================================================
   Header / Navbar
   ============================================================ */
.site-header {
  position: fixed; inset: 0 0 auto 0;
  height: 80px; z-index: 50;
  background: rgba(255, 250, 247, 0.9);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}
.site-header__inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 100%;
}
.brand { display: block; line-height: 1; }
.brand__name { font-family: 'Cormorant Garamond', serif; font-size: 28px; letter-spacing: .02em; color: #1c1917; }
.brand__tag { display: block; margin-top: 6px; font-size: 10px; letter-spacing: .42em; text-transform: uppercase; color: #78716c; }

.primary-nav { display: none; gap: 36px; align-items: center; }
@media (min-width: 880px) { .primary-nav { display: flex; } }
.primary-nav a {
  font-size: 12px; letter-spacing: .24em; text-transform: uppercase;
  color: #57534e; position: relative; padding: 4px 0;
}
.primary-nav a:hover, .primary-nav .current-menu-item > a { color: #1c1917; }
.primary-nav .current-menu-item > a::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -8px; height: 1px; background: #1c1917;
}
.primary-nav ul { list-style: none; padding: 0; margin: 0; display: flex; gap: 36px; }

.header-actions { display: flex; align-items: center; gap: 12px; }
.icon-btn {
  width: 40px; height: 40px; border-radius: 999px;
  border: 1px solid #e7e5e4; background: transparent;
  display: grid; place-items: center; cursor: pointer;
  color: #57534e; position: relative;
  transition: border-color .2s, color .2s;
}
.icon-btn:hover { border-color: #1c1917; color: #1c1917; }
.cart-count {
  position: absolute; top: -4px; right: -4px;
  min-width: 16px; height: 16px; padding: 0 4px;
  background: #1c1917; color: #fff; border-radius: 999px;
  font-size: 10px; display: grid; place-items: center;
}

.menu-toggle {
  display: grid; width: 40px; height: 40px; place-items: center;
  background: transparent; border: 1px solid #e7e5e4; border-radius: 999px;
  cursor: pointer; color: #57534e;
}
@media (min-width: 880px) { .menu-toggle { display: none; } }

.mobile-nav { display: none; border-top: 1px solid #e7e5e4; background: #fffaf7; }
.mobile-nav.open { display: block; }
.mobile-nav ul { list-style: none; padding: 0; margin: 0; }
.mobile-nav a {
  display: block; padding: 18px 0; border-bottom: 1px solid #e7e5e4;
  font-size: 13px; letter-spacing: .24em; text-transform: uppercase; color: #78716c;
}

/* ============================================================
   Hero
   ============================================================ */
.site-main { padding-top: 80px; }
.hero {
  position: relative; min-height: calc(100vh - 80px);
  display: flex; align-items: center;
  background: #1c1917; color: #fff; overflow: hidden;
}
.hero__media { position: absolute; inset: 0; }
.hero__media img {
  width: 100%; height: 100%; object-fit: cover; opacity: .75;
  image-rendering: -webkit-optimize-contrast;
}
.hero__media::after {
  content: ''; position: absolute; inset: 0;
  background:
    linear-gradient(to right, rgba(28,25,23,.80), rgba(28,25,23,.35), rgba(28,25,23,.05)),
    linear-gradient(to top, rgba(28,25,23,.45), transparent 55%, rgba(28,25,23,.10));
}
.hero__inner { position: relative; max-width: 720px; padding: 96px 0; }
.hero .brand__name { color: #fff; }
.hero .brand__tag { color: rgba(255,255,255,.7); }
.hero__title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(48px, 8vw, 104px);
  line-height: 0.95;
  letter-spacing: -0.04em;
  margin: 40px 0 0;
}
.hero__subtitle {
  margin: 32px 0 0;
  font-size: 18px;
  line-height: 1.7;
  color: rgba(255,255,255,.78);
  max-width: 520px;
}
.hero__cta { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 12px; }

/* ============================================================
   Sections
   ============================================================ */
.section { padding: 96px 0; }
.section--cream { background: #fffaf7; }
.section--white { background: #ffffff; }
.section--dark { background: #2b1f1e; color: #fff; }
.section--dark .eyebrow { color: #e0b8b2; }

.section-heading {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(36px, 5vw, 56px);
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin: 16px 0 0;
  color: #1c1917;
}
.section--dark .section-heading { color: #fff; }

.values-grid {
  display: grid; gap: 56px; align-items: end;
}
@media (min-width: 980px) {
  .values-grid { grid-template-columns: 0.9fr 1.1fr; }
}
.values-list { display: grid; gap: 32px; }
@media (min-width: 640px) { .values-list { grid-template-columns: repeat(3, 1fr); } }
.values-list .num { font-family: 'Cormorant Garamond', serif; font-size: 30px; color: #1c1917; }
.values-list p { margin: 12px 0 0; font-size: 14px; line-height: 1.6; color: #57534e; }

.cta-band { max-width: 720px; margin: 0 auto; text-align: center; }
.cta-band p { margin-top: 24px; color: rgba(255,255,255,.72); line-height: 1.7; }

/* ============================================================
   Product grid (custom + WooCommerce override)
   ============================================================ */
.products-header {
  display: grid; gap: 32px; padding-bottom: 48px;
  border-bottom: 1px solid #e7e5e4;
}
@media (min-width: 980px) {
  .products-header { grid-template-columns: 1fr auto; align-items: end; }
}
.products-header h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(48px, 7vw, 96px);
  letter-spacing: -0.04em; line-height: 1; margin: 16px 0 0; color: #1c1917;
}
.products-header p { max-width: 620px; margin-top: 24px; color: #57534e; }

.woocommerce ul.products,
.products-grid {
  display: grid !important;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px 16px !important;
  margin: 48px 0 0 !important;
  padding: 0 !important;
  list-style: none !important;
}
@media (min-width: 640px) { .woocommerce ul.products, .products-grid { grid-template-columns: repeat(2, 1fr); gap: 40px 24px !important; } }
@media (min-width: 980px) { .woocommerce ul.products, .products-grid { grid-template-columns: repeat(3, 1fr); gap: 48px 28px !important; } }

.woocommerce ul.products li.product,
.product-card {
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  text-align: left !important;
  background: transparent !important;
  border: 0 !important;
  list-style: none !important;
}

/* ---- Product image ---- */
.product-card__media {
  position: relative; overflow: hidden; background: #f3ebe6;
  aspect-ratio: 4 / 5;
  border-radius: 4px;
}
.product-card__media img {
  width: 100%; height: 100%; object-fit: cover;
  object-position: center top;
  transition: transform .8s cubic-bezier(.22,1,.36,1);
  image-rendering: -webkit-optimize-contrast;
  max-width: 100% !important;
  height: 100% !important;
}
.product-card:hover .product-card__media img { transform: scale(1.04); }

/* ---- Badge ---- */
.product-card__tag {
  position: absolute; top: 12px; left: 12px;
  background: #fffaf7; color: #1c1917;
  padding: 6px 10px; font-size: 10px;
  letter-spacing: .18em; text-transform: uppercase;
  border-radius: 2px;
}

/* ---- View product CTA (desktop hover) ---- */
.product-card__addtocart {
  position: absolute; inset: auto 12px 12px;
  display: block; text-align: center; padding: 13px 16px !important;
  background: #1c1917 !important; color: #fff !important;
  font-size: 11px !important; letter-spacing: .2em !important;
  text-transform: uppercase !important;
  border: 0 !important; border-radius: 2px !important;
  opacity: 0; transform: translateY(10px);
  transition: opacity .3s ease, transform .3s ease, background .25s ease;
  font-weight: 500 !important;
}
.product-card:hover .product-card__addtocart { opacity: 1; transform: translateY(0); }
.product-card__addtocart:hover { background: #7c524b !important; }

/* On mobile — always show the CTA, don't rely on hover */
@media (max-width: 639px) {
  .product-card__addtocart {
    opacity: 1 !important;
    transform: translateY(0) !important;
    font-size: 10px !important;
    padding: 10px 12px !important;
    letter-spacing: .14em !important;
  }
}

/* ---- Card body: name + price ---- */
.product-card__body {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.product-card__title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 18px;
  letter-spacing: -0.01em;
  line-height: 1.25;
  margin: 0;
  color: #1c1917;
  /* Clamp to 2 lines so cards stay uniform height */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
@media (min-width: 640px) {
  .product-card__title { font-size: 20px; }
}
@media (min-width: 980px) {
  .product-card__title { font-size: 22px; }
}

/* Short description — clamped to 2 lines, hidden on very small screens */
.product-card__desc {
  margin: 4px 0 0;
  font-size: 12px;
  line-height: 1.55;
  color: #78716c;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
@media (max-width: 400px) {
  .product-card__desc { display: none; }
}
@media (min-width: 640px) {
  .product-card__desc { font-size: 13px; }
}

/* Price — sits below name, prominent */
.product-card__price {
  margin-top: 8px;
  font-size: 15px;
  font-weight: 600;
  color: #1c1917;
  letter-spacing: -0.01em;
}
.product-card__price del { color: #a8a29e; margin-right: 6px; font-weight: 400; font-size: 13px; }

/* ---- Meta row (swatches + rating) ---- */
.product-card__meta {
  margin-top: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.product-card__swatches { display: flex; gap: 6px; flex-wrap: wrap; }
.product-swatch {
  width: 20px; height: 20px; border-radius: 999px;
  border: 1px solid #d6d3d1; display: inline-block;
  flex-shrink: 0;
}
.product-card__rating {
  font-size: 10px; letter-spacing: .14em;
  text-transform: uppercase; color: #78716c;
  white-space: nowrap;
}

/* WooCommerce overrides */
.woocommerce .price { font-size: 15px !important; color: #1c1917 !important; font-weight: 600 !important; }
.woocommerce .star-rating { display: none; }
.woocommerce-loop-product__title { display: none; }

/* ============================================================
   Sort controls
   ============================================================ */
.woocommerce-ordering { margin: 0 !important; }
.woocommerce-ordering select,
.ss-sort select {
  height: 48px; padding: 0 16px;
  border: 1px solid #d6d3d1; background: transparent;
  font-size: 14px; color: #1c1917;
  border-radius: 0;
}

/* ============================================================
   Single Product
   ============================================================ */
.single-product .product { padding-top: 24px; }
.single-product .product .summary {
  font-family: 'Inter', sans-serif !important;
}
.single-product .product h1.product_title {
  font-family: 'Cormorant Garamond', serif !important;
  font-size: clamp(36px, 5vw, 56px) !important;
  letter-spacing: -0.03em !important; line-height: 1.05 !important;
}
.single-product .single_add_to_cart_button {
  background: #1c1917 !important; color: #fff !important;
  padding: 16px 32px !important; border-radius: 999px !important;
  letter-spacing: .22em !important; text-transform: uppercase !important;
  font-size: 13px !important;
}
.single-product .single_add_to_cart_button:hover { background: #7c524b !important; }

/* Variation Swatches plugin support */
.wvs-style-squared .variable-item,
.wvs-style-rounded .variable-item {
  border: 1px solid #d6d3d1 !important;
  border-radius: 999px !important;
}
.wvs-style-rounded .variable-item.selected {
  border-color: #1c1917 !important;
  box-shadow: 0 0 0 2px #fff, 0 0 0 3px #1c1917 !important;
}

/* ============================================================
   About + Contact pages
   ============================================================ */
.page-hero { padding: 128px 0 64px; }
.page-hero h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(48px, 7vw, 96px);
  letter-spacing: -0.04em; line-height: 1; margin: 16px 0 0; color: #1c1917;
}
.page-hero p { max-width: 620px; margin-top: 24px; font-size: 18px; line-height: 1.7; color: #57534e; }

.about-grid { display: grid; gap: 48px; align-items: center; padding-bottom: 96px; }
@media (min-width: 980px) { .about-grid { grid-template-columns: 1fr 1fr; } }
.about-grid .copy p { font-size: 18px; line-height: 1.8; color: #57534e; margin: 0 0 24px; }

.contact-grid { display: grid; gap: 48px; padding-bottom: 96px; }
@media (min-width: 980px) { .contact-grid { grid-template-columns: 0.85fr 1.15fr; } }
.contact-info { font-size: 14px; color: #44403c; line-height: 2; }
.contact-info p { margin: 0 0 8px; }
.contact-form label { display: block; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: #78716c; margin-bottom: 24px; }
.contact-form input,
.contact-form textarea {
  display: block; width: 100%; margin-top: 12px;
  padding: 12px 16px; height: 48px;
  border: 1px solid #d6d3d1; background: rgba(255,255,255,.5);
  font-size: 15px; color: #1c1917; letter-spacing: normal; text-transform: none;
  border-radius: 0;
}
.contact-form textarea { height: auto; min-height: 160px; }
.contact-form input:focus, .contact-form textarea:focus { outline: none; border-color: #1c1917; }
.contact-form button { margin-top: 16px; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer { background: #1c1917; color: #fff; padding: 64px 0; }
.site-footer .brand__name { color: #fff; }
.site-footer .brand__tag { color: rgba(255,255,255,.7); }
.footer-grid { display: grid; gap: 48px; }
@media (min-width: 880px) { .footer-grid { grid-template-columns: 1.3fr 1fr 1fr; } }
.footer-grid h4 { font-size: 12px; letter-spacing: .24em; text-transform: uppercase; color: rgba(255,255,255,.52); margin: 0 0 20px; font-weight: 500; }
.footer-grid p, .footer-grid li { color: rgba(255,255,255,.7); font-size: 14px; line-height: 1.7; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.footer-grid a:hover { color: #fff; }
.site-footer__legal {
  border-top: 1px solid rgba(255,255,255,.1);
  margin-top: 56px; padding-top: 24px;
  font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: rgba(255,255,255,.42);
}

/* ============================================================
   Admin seed page
   ============================================================ */
.ss-admin-wrap { max-width: 720px; padding: 24px; }
.ss-admin-wrap h1 { font-size: 28px; margin-bottom: 16px; }
.ss-admin-wrap .button-primary { background: #1c1917; border-color: #1c1917; }
