/*
Theme Name:  Pashamal Child
Theme URI:   https://pashamal.ir
Description: فروشگاه چنددسته‌ای سبک پینترستی برای پاشامال — RTL و فارسی
Author:      Pashamal
Template:    astra
Version:     1.0.0
Text Domain: pashamal-child
*/

@font-face {
  font-family: "Vazirmatn";
  src: url("fonts/Vazirmatn.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --pm-ink: #1a2332;
  --pm-muted: #5b677a;
  --pm-line: #e6ebf2;
  --pm-bg: #f4f7fb;
  --pm-card: #ffffff;
  --pm-accent: #0f766e;
  --pm-accent-dark: #0b5a54;
  --pm-warm: #d97706;
  --pm-radius: 18px;
  --pm-shadow: 0 14px 36px rgba(26, 35, 50, 0.08);
}

html { scroll-behavior: smooth; }

body,
button,
input,
select,
textarea,
.site-title,
.site-content,
.ast-container {
  font-family: "Vazirmatn", Tahoma, "Segoe UI", sans-serif !important;
  color: var(--pm-ink);
}

body {
  background:
    radial-gradient(circle at 8% 0%, rgba(15, 118, 110, 0.08), transparent 36%),
    radial-gradient(circle at 92% 8%, rgba(217, 119, 6, 0.08), transparent 32%),
    linear-gradient(180deg, #f7fafc 0%, #ffffff 48%, #f3f8f7 100%);
}

a { color: var(--pm-accent-dark); }
a:hover { color: var(--pm-accent); }

.site-header,
.main-header-bar,
.ast-primary-header-bar {
  background: rgba(255, 255, 255, 0.9) !important;
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--pm-line) !important;
  box-shadow: 0 8px 28px rgba(26, 35, 50, 0.05);
}

.site-title a,
.ast-site-title-wrap .site-title a {
  font-weight: 900 !important;
  letter-spacing: -0.02em;
  color: var(--pm-ink) !important;
}

.main-header-menu > .menu-item > .menu-link {
  font-weight: 600;
  color: var(--pm-ink) !important;
}

.ast-button,
.button,
.wp-block-button__link,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce #respond input#submit,
.woocommerce a.button.alt,
.woocommerce button.button.alt {
  background: var(--pm-accent) !important;
  border-color: var(--pm-accent) !important;
  color: #fff !important;
  border-radius: 999px !important;
  font-weight: 700 !important;
  box-shadow: 0 10px 24px rgba(15, 118, 110, 0.22);
  transition: transform .18s ease, background .18s ease;
}

.ast-button:hover,
.button:hover,
.wp-block-button__link:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover {
  background: var(--pm-accent-dark) !important;
  border-color: var(--pm-accent-dark) !important;
  transform: translateY(-1px);
}

.pm-hero {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background:
    radial-gradient(circle at 12% 20%, rgba(15, 118, 110, 0.18), transparent 42%),
    radial-gradient(circle at 88% 12%, rgba(217, 119, 6, 0.16), transparent 40%),
    linear-gradient(135deg, #ffffff 0%, #f0faf8 55%, #fff8ef 100%);
  border: 1px solid var(--pm-line);
  padding: clamp(2rem, 5vw, 4.2rem);
  margin: 1.25rem 0 2rem;
  box-shadow: var(--pm-shadow);
  animation: pm-fade-up .7s ease both;
}

.pm-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: #fff;
  color: var(--pm-accent-dark);
  border: 1px solid #cfe8e5;
  border-radius: 999px;
  padding: .35rem .9rem;
  font-size: .9rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.pm-hero h1 {
  font-size: clamp(2rem, 4.5vw, 3.3rem);
  line-height: 1.25;
  margin: 0 0 1rem;
  font-weight: 900;
  color: var(--pm-ink);
}

.pm-hero p {
  max-width: 40rem;
  font-size: 1.08rem;
  line-height: 1.9;
  color: var(--pm-muted);
  margin: 0 0 1.5rem;
}

.pm-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
}

.pm-hero__actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: .75rem 1.4rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 800;
}

.pm-hero__actions .primary {
  background: var(--pm-accent);
  color: #fff;
  box-shadow: 0 12px 28px rgba(15, 118, 110, 0.28);
}

.pm-hero__actions .ghost {
  background: #fff;
  color: var(--pm-ink);
  border: 1px solid var(--pm-line);
}

.pm-cats {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: .75rem;
  margin: 0 0 2.25rem;
}

.pm-cat {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 64px;
  padding: .75rem;
  border-radius: 16px;
  background: #fff;
  border: 1px solid var(--pm-line);
  text-decoration: none !important;
  color: var(--pm-ink) !important;
  font-weight: 800;
  box-shadow: 0 8px 20px rgba(26, 35, 50, 0.04);
  transition: transform .18s ease, border-color .18s ease;
}

.pm-cat:hover {
  transform: translateY(-2px);
  border-color: #b7ddd8;
}

.pm-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin: 1.5rem 0 2.5rem;
}

.pm-card {
  background: #fff;
  border: 1px solid var(--pm-line);
  border-radius: var(--pm-radius);
  padding: 1.25rem;
  box-shadow: 0 12px 30px rgba(26, 35, 50, 0.04);
}

.pm-card h3 {
  margin: 0 0 .5rem;
  font-size: 1.15rem;
}

.pm-card p {
  margin: 0;
  color: var(--pm-muted);
  line-height: 1.8;
}

.pm-section-title {
  text-align: center;
  margin: 0 0 .4rem;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 900;
}

.pm-section-sub {
  text-align: center;
  color: var(--pm-muted);
  margin: 0 0 1.5rem;
}

/* Pinterest-style masonry product grid */
.woocommerce ul.products {
  display: columns !important;
  columns: 4 220px;
  column-gap: 1rem;
  margin: 0 !important;
  padding: 0 !important;
}

.woocommerce ul.products::before,
.woocommerce ul.products::after {
  display: none !important;
  content: none !important;
}

.woocommerce ul.products li.product,
.woocommerce-page ul.products li.product {
  display: inline-block !important;
  width: 100% !important;
  float: none !important;
  margin: 0 0 1rem !important;
  break-inside: avoid;
  background: var(--pm-card);
  border: 1px solid var(--pm-line);
  border-radius: 22px;
  padding: .7rem .7rem 1rem;
  box-shadow: var(--pm-shadow);
  transition: transform .2s ease, box-shadow .2s ease;
  animation: pm-fade-up .55s ease both;
}

.woocommerce ul.products li.product:nth-child(2) { animation-delay: .05s; }
.woocommerce ul.products li.product:nth-child(3) { animation-delay: .1s; }
.woocommerce ul.products li.product:nth-child(4) { animation-delay: .15s; }
.woocommerce ul.products li.product:nth-child(5) { animation-delay: .2s; }
.woocommerce ul.products li.product:nth-child(6) { animation-delay: .25s; }

.woocommerce ul.products li.product:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 42px rgba(15, 118, 110, 0.14);
}

.woocommerce ul.products li.product a img {
  border-radius: 16px;
  width: 100%;
  height: auto;
  margin-bottom: .65rem;
}

.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-size: 1.02rem !important;
  font-weight: 800;
  padding: 0 .2rem;
}

.woocommerce ul.products li.product .price {
  color: var(--pm-accent-dark) !important;
  font-weight: 800;
  padding: 0 .2rem;
}

.site-footer,
.ast-footer-overlay {
  background: #152033 !important;
  color: #eef3f8 !important;
}

.site-footer a { color: #9fe0d8 !important; }

@keyframes pm-fade-up {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1100px) {
  .pm-cats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .woocommerce ul.products { columns: 3 200px; }
}

@media (max-width: 921px) {
  .pm-grid { grid-template-columns: 1fr; }
  .pm-cats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .woocommerce ul.products { columns: 2 160px; }
}

@media (max-width: 560px) {
  .woocommerce ul.products { columns: 1 140px; }
}
