/*
Theme Name: PicFrameBD
Theme URI: https://picframebd.com
Author: PicFrameBD
Author URI: https://www.facebook.com/PicFrameBD
Description: A custom storefront theme for PicFrameBD — a photo frame and personalised print shop. Built as a lightweight base theme designed to be fully edited with Elementor Pro, with native WooCommerce support for selling ready-made and custom photo frames.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
Tested up to: 6.6
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: picframebd
Tags: e-commerce, custom-menu, featured-images, translation-ready
*/

/* -----------------------------------------------------------
   DESIGN TOKENS
   Palette is built around a gallery wall: a deep museum-green
   wall, warm linen paper, walnut frame wood, and a brass accent
   for the metal fittings/CTAs.
----------------------------------------------------------- */
:root {
  --color-ink: #211d1a;
  --color-ink-soft: #4a433c;
  --color-paper: #f4efe4;
  --color-paper-dim: #ece4d2;
  --color-wall: #3f4e3d;
  --color-wall-dark: #2c3a2b;
  --color-walnut: #6b4226;
  --color-walnut-dark: #4f2f1a;
  --color-brass: #b8935a;
  --color-brass-dark: #9c7847;
  --color-line: rgba(33, 29, 26, 0.12);
  --color-line-on-wall: rgba(244, 239, 228, 0.18);

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --radius-sm: 4px;
  --radius-md: 8px;
  --container: 1180px;
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 40px;
  --space-5: 64px;
  --space-6: 96px;
}

/* -----------------------------------------------------------
   RESET & BASE
----------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--color-paper);
  color: var(--color-ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 var(--space-2);
  color: var(--color-ink);
}
h1 { font-size: clamp(2.2rem, 4vw, 3.4rem); }
h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 var(--space-2); }
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--space-3);
}
.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-brass-dark);
  font-weight: 600;
  margin-bottom: var(--space-1);
}
:focus-visible {
  outline: 2px solid var(--color-brass);
  outline-offset: 2px;
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.btn-primary {
  background: var(--color-brass);
  color: var(--color-ink);
}
.btn-primary:hover { background: var(--color-brass-dark); }
.btn-outline {
  background: transparent;
  border-color: var(--color-line-on-wall);
  color: var(--color-paper);
}
.btn-outline:hover { border-color: var(--color-paper); }

/* -----------------------------------------------------------
   SITE HEADER
----------------------------------------------------------- */
.site-header {
  background: var(--color-wall);
  color: var(--color-paper);
  position: relative;
  z-index: 50;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-2);
  padding-bottom: var(--space-2);
}
.site-branding { display: flex; align-items: center; gap: 12px; }
.site-branding img { max-height: 44px; width: auto; }
.site-logo-fallback {
  display: flex;
  align-items: center;
  gap: 12px;
}
.site-logo-fallback img {
  max-height: 48px;
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 50%;
  border: 2px solid var(--color-brass);
}
.site-title {
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--color-paper);
  margin: 0;
}
.site-title a { color: inherit; }

.main-navigation { display: flex; align-items: center; gap: var(--space-4); }
.main-navigation ul { display: flex; gap: var(--space-3); }
.main-navigation a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-paper);
  opacity: 0.85;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: opacity 0.2s ease, border-color 0.2s ease;
}
.main-navigation a:hover,
.main-navigation .current-menu-item a {
  opacity: 1;
  border-color: var(--color-brass);
}

.header-actions { display: flex; align-items: center; gap: var(--space-2); }
.header-cart {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--color-paper);
  font-size: 0.9rem;
}
.header-cart .count {
  background: var(--color-brass);
  color: var(--color-ink);
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--color-paper);
  font-size: 1.6rem;
  cursor: pointer;
}

@media (max-width: 860px) {
  .main-navigation { display: none; }
  .menu-toggle { display: block; }
  .main-navigation.is-open {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-wall-dark);
    padding: var(--space-2) var(--space-3) var(--space-3);
  }
  .main-navigation.is-open ul { flex-direction: column; gap: var(--space-2); }
}

/* -----------------------------------------------------------
   GALLERY WALL HERO — signature element.
   A cluster of CSS-drawn picture frames hung on a museum-green
   wall, tilted and overlapping like a real gallery wall, with
   brass "nail" dots. Frame contents are theme-color swatches by
   default — swap in real product photos via Elementor or the
   Customizer once available.
----------------------------------------------------------- */
.gallery-hero {
  background: var(--color-wall);
  color: var(--color-paper);
  position: relative;
  overflow: hidden;
  padding: var(--space-6) 0 var(--space-5);
}
.gallery-hero .container {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: var(--space-5);
  align-items: center;
}
.gallery-hero-copy h1 { color: var(--color-paper); }
.gallery-hero-copy p {
  color: var(--color-paper);
  opacity: 0.82;
  max-width: 42ch;
  font-size: 1.05rem;
}
.gallery-hero-actions {
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-3);
  flex-wrap: wrap;
}

.gallery-wall {
  position: relative;
  height: 420px;
}
.gallery-frame {
  position: absolute;
  background: var(--color-walnut);
  border-radius: 3px;
  padding: 10px;
  box-shadow: 0 18px 40px rgba(0,0,0,0.35);
}
.gallery-frame::before {
  content: "";
  position: absolute;
  top: -5px;
  left: 50%;
  transform: translateX(-50%);
  width: 8px;
  height: 8px;
  background: var(--color-brass);
  border-radius: 50%;
  box-shadow: 0 6px 0 -1px rgba(0,0,0,0.25);
}
.gallery-frame .mat {
  background: var(--color-paper);
  padding: 8px;
  height: 100%;
}
.gallery-frame .photo {
  height: 100%;
  width: 100%;
  background-color: var(--color-wall-dark);
  background-size: cover;
  background-position: center;
}
.gf-1 { width: 190px; height: 230px; top: 10px; left: 30px; transform: rotate(-6deg); z-index: 3; }
.gf-2 { width: 150px; height: 190px; top: 90px; left: 220px; transform: rotate(4deg); z-index: 2; }
.gf-3 { width: 170px; height: 150px; top: 250px; left: 0; transform: rotate(3deg); z-index: 1; }
.gf-4 { width: 130px; height: 170px; top: 20px; left: 340px; transform: rotate(-3deg); z-index: 2; }
.gf-5 { width: 140px; height: 110px; top: 300px; left: 250px; transform: rotate(-5deg); z-index: 2; }

@media (max-width: 900px) {
  .gallery-hero .container { grid-template-columns: 1fr; }
  .gallery-wall { height: 300px; margin-top: var(--space-4); }
}

/* -----------------------------------------------------------
   GENERIC SECTIONS
----------------------------------------------------------- */
.section { padding: var(--space-6) 0; }
.section-tight { padding: var(--space-5) 0; }
.section-header { max-width: 620px; margin: 0 auto var(--space-4); text-align: center; }
.section-alt { background: var(--color-paper-dim); }

/* Category / feature grid */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
}
.category-card {
  background: #fff;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.category-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 30px rgba(33,29,26,0.1);
}
.category-card .thumb {
  aspect-ratio: 4/3;
  background-color: var(--color-walnut);
  background-size: cover;
  background-position: center;
}
.category-card .body { padding: var(--space-2) var(--space-3) var(--space-3); }
.category-card h3 { margin-bottom: 4px; }
.category-card p { color: var(--color-ink-soft); font-size: 0.92rem; margin-bottom: var(--space-1); }

/* How it works */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
  counter-reset: step;
}
.step { position: relative; padding-left: 52px; }
.step::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--color-wall);
  color: var(--color-paper);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 600;
}
.step p { color: var(--color-ink-soft); }

/* Testimonials */
.testimonial {
  background: var(--color-wall);
  color: var(--color-paper);
  border-radius: var(--radius-md);
  padding: var(--space-4);
}
.testimonial p { font-family: var(--font-display); font-size: 1.25rem; opacity: 0.95; }
.testimonial cite { font-style: normal; color: var(--color-brass); font-weight: 600; font-size: 0.9rem; }

/* CTA band */
.cta-band {
  background: var(--color-walnut);
  color: var(--color-paper);
  border-radius: var(--radius-md);
  padding: var(--space-4) var(--space-5);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  flex-wrap: wrap;
}
.cta-band h2 { color: var(--color-paper); margin: 0; }

@media (max-width: 800px) {
  .grid-3, .steps { grid-template-columns: 1fr; }
}

/* -----------------------------------------------------------
   FOOTER
----------------------------------------------------------- */
.site-footer {
  background: var(--color-wall-dark);
  color: var(--color-paper);
  padding: var(--space-5) 0 var(--space-3);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: var(--space-4);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--color-line-on-wall);
}
.footer-grid h4 {
  color: var(--color-paper);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: var(--space-2);
}
.footer-grid p, .footer-grid a {
  color: var(--color-paper);
  opacity: 0.75;
  font-size: 0.92rem;
}
.footer-grid ul li { margin-bottom: 8px; }
.footer-bottom {
  padding-top: var(--space-2);
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  opacity: 0.6;
  flex-wrap: wrap;
  gap: 8px;
}
@media (max-width: 800px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

/* -----------------------------------------------------------
   WOOCOMMERCE
----------------------------------------------------------- */
.woocommerce-wrapper { padding: var(--space-5) 0; }
.woocommerce ul.products {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
  margin: 0 !important;
}
.woocommerce ul.products li.product {
  background: #fff;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-md);
  padding: var(--space-2);
  list-style: none;
}
.woocommerce ul.products li.product img {
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-1);
}
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  margin: 6px 0 4px;
}
.woocommerce ul.products li.product .price {
  color: var(--color-walnut);
  font-weight: 600;
}
.woocommerce a.button, .woocommerce button.button, .woocommerce input.button,
.woocommerce #respond input#submit {
  background: var(--color-brass) !important;
  color: var(--color-ink) !important;
  border-radius: var(--radius-sm) !important;
  font-weight: 600 !important;
  border: none !important;
}
.woocommerce a.button:hover, .woocommerce button.button:hover {
  background: var(--color-brass-dark) !important;
}
.woocommerce div.product p.price, .woocommerce div.product span.price {
  color: var(--color-walnut);
  font-size: 1.3rem;
}
.woocommerce span.onsale {
  background: var(--color-wall) !important;
  border-radius: var(--radius-sm) !important;
}
.woocommerce-message, .woocommerce-info {
  border-top-color: var(--color-brass) !important;
}
.woocommerce-message::before, .woocommerce-info::before { color: var(--color-brass) !important; }
.woocommerce table.shop_table { border-radius: var(--radius-md); border-color: var(--color-line); }
.woocommerce #respond input#submit, .woocommerce a.button.alt {
  background: var(--color-walnut) !important;
  color: var(--color-paper) !important;
}
.woocommerce form .form-row input.input-text, .woocommerce form .form-row textarea {
  border-radius: var(--radius-sm);
  border-color: var(--color-line);
}

@media (max-width: 900px) {
  .woocommerce ul.products { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .woocommerce ul.products { grid-template-columns: 1fr; }
}

/* -----------------------------------------------------------
   UTILITIES
----------------------------------------------------------- */
.screen-reader-text {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0,0,0,0); border: 0;
}
