/*
Theme Name: Aria Mersad Products
Theme URI: https://products.ariamersad.com/
Author: Aria Mersad
Description: قالب معرفی محصولات آریا مرصاد با هدر/فوتر هماهنگ با blog.ariamersad.com — سازگار با Elementor
Version: 1.0.2
Text Domain: aria-mersad-products
*/

:root {
  --am-primary: #159b82;
  --am-primary-dark: #0f7a66;
  --am-bg: #fff;
  --am-text: #222;
  --am-muted: #666;
  --am-dark: rgb(12 12 12);
  --am-dark-footer: #424342;
  --am-white: #fff;
  --am-border: #e8e8e8;
  --am-soft: #f6faf9;
}

* { box-sizing: border-box; }
html { overflow-x: clip; }

body.am-products-body {
  margin: 0;
  padding: 0;
  direction: rtl;
  background: var(--am-bg);
  color: var(--am-text);
  font-family: IranSans, IRANSans, Tahoma, sans-serif;
  font-size: 14px;
  line-height: 2em;
  min-width: 320px;
}

body.am-products-body .fa,
body.am-products-body .fas,
body.am-products-body .far,
body.am-products-body .fab,
body.am-products-body .fa-solid,
body.am-products-body .fa-regular,
body.am-products-body .fa-brands,
body.am-products-body i.fa,
body.am-products-body i.fas,
body.am-products-body i.fab {
  font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands", FontAwesome !important;
}
body.am-products-body .fab,
body.am-products-body .fa-brands {
  font-family: "Font Awesome 6 Brands" !important;
  font-weight: 400 !important;
}
body.am-products-body .fa,
body.am-products-body .fas,
body.am-products-body .fa-solid {
  font-weight: 900 !important;
}

a { color: var(--am-primary); text-decoration: none; }
img { max-width: 100%; height: auto; }
main.site-main { min-height: 50vh; }

.am-page-header,
.page-header.am-page-header {
  position: relative;
  width: 100%;
  height: 400px;
  overflow: hidden;
  margin: 0;
  padding: 0;
}
.am-page-header .cover {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(12,12,12,.45) 0%, rgba(12,12,12,.55) 100%);
  z-index: 1;
}
.am-page-header picture,
.am-page-header .bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.am-page-header .content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  align-items: center;
  color: #fff;
}
.am-page-header .title {
  margin: 0 0 12px;
  font-size: 42px;
  font-weight: 800;
  color: #fff;
  font-family: IranSans, IRANSans, Tahoma, sans-serif;
}
.am-page-header .breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
  color: rgba(255,255,255,.9);
}
.am-page-header .breadcrumb a { color: #fff; }
.am-page-header .breadcrumb-item + .breadcrumb-item::before {
  content: "/";
  margin-left: 8px;
  opacity: .7;
}
@media (max-width: 767px) {
  .am-page-header,
  .page-header.am-page-header { height: 220px; }
  .am-page-header .title { font-size: 26px; }
}

.am-products-wrap { padding: 48px 0 72px; }
.am-products-section-title {
  margin: 0 0 12px;
  font-size: 32px;
  font-weight: 800;
  color: var(--am-dark);
}
.am-products-section-lead {
  margin: 0 0 28px;
  color: var(--am-muted);
  max-width: 720px;
}
.am-products-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 10px 28px;
  border-radius: 8px;
  background: var(--am-primary);
  color: #fff !important;
  font-weight: 700;
  border: 0;
  cursor: pointer;
  transition: background .2s ease;
}
.am-products-btn:hover { background: var(--am-primary-dark); }
.am-products-btn--ghost {
  background: transparent;
  color: var(--am-primary) !important;
  border: 1px solid var(--am-primary);
}
.am-products-btn--ghost:hover {
  background: var(--am-primary);
  color: #fff !important;
}

.am-products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 22px;
  margin-top: 24px;
}
.am-product-card {
  border: 1px solid var(--am-border);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  display: flex;
  flex-direction: column;
  transition: box-shadow .2s ease, border-color .2s ease, transform .2s ease;
}
.am-product-card:hover {
  border-color: var(--am-primary);
  box-shadow: 0 12px 30px rgba(21,155,130,.14);
  transform: translateY(-2px);
}
.am-product-card__media {
  display: block;
  aspect-ratio: 16 / 10;
  background: var(--am-soft);
  overflow: hidden;
}
.am-product-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.am-product-card__body {
  padding: 18px 20px 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
  text-align: center;
}
.am-product-card__title {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 800;
  color: var(--am-dark);
  line-height: 1.7;
  min-height: 3.4em;
}
.am-product-card__excerpt {
  color: var(--am-muted);
  font-size: 13px;
  margin: 0 0 16px;
  flex: 1;
}
.am-product-card__meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 14px;
  margin: 0 0 14px;
  color: var(--am-muted);
  font-size: 12px;
}

.am-product-detail { padding: 40px 0 72px; }
.am-product-detail__hero {
  background: var(--am-soft);
  border-radius: 16px;
  padding: 28px;
  margin-bottom: 28px;
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 28px;
  align-items: center;
}
.am-product-detail__title {
  margin: 0 0 12px;
  font-size: 30px;
  font-weight: 800;
}
.am-product-detail__tagline {
  margin: 0 0 16px;
  color: var(--am-muted);
  font-size: 15px;
}
.am-product-detail__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 20px;
  color: var(--am-muted);
  margin-bottom: 20px;
}
.am-product-detail__hero-media img {
  width: 100%;
  border-radius: 12px;
  display: block;
}
.am-product-detail__section { margin-bottom: 28px; }
.am-product-detail__section h2 {
  margin: 0 0 12px;
  font-size: 22px;
  font-weight: 800;
  color: var(--am-dark);
  border-right: 4px solid var(--am-primary);
  padding-right: 12px;
}
.am-product-detail__section ul { margin: 0; padding-right: 20px; }
.am-product-detail__section li { margin-bottom: 8px; }

.am-product-specs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}
.am-product-spec {
  background: #fff;
  border: 1px solid var(--am-border);
  border-radius: 10px;
  padding: 14px 16px;
}
.am-product-spec strong {
  display: block;
  color: var(--am-primary-dark);
  margin-bottom: 4px;
}

.am-product-cta {
  background: var(--am-dark);
  color: #fff;
  border-radius: 16px;
  padding: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  margin-top: 36px;
}
.am-product-cta h2 {
  margin: 0 0 8px;
  font-size: 22px;
  color: #fff;
}
.am-product-cta p {
  margin: 0;
  color: rgba(255,255,255,.85);
}
.am-product-cta__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.am-home-fallback { padding: 8px 0 24px; }
.am-home-intro {
  display: grid;
  grid-template-columns: 1.3fr .7fr;
  gap: 32px;
  align-items: center;
  margin-bottom: 40px;
}
.am-home-intro__logo {
  max-width: 280px;
  background: #0c0c0c;
  padding: 24px;
  border-radius: 12px;
}
.am-home-highlights {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  margin: 28px 0 48px;
}
.am-home-highlight {
  background: var(--am-soft);
  border-radius: 12px;
  padding: 18px;
}
.am-home-highlight h3 {
  margin: 0 0 8px;
  font-size: 16px;
  color: var(--am-primary-dark);
}

@media (max-width: 991px) {
  .am-product-detail__hero,
  .am-home-intro { grid-template-columns: 1fr; }
}
.elementor-page .site-main,
body.elementor-page main.site-main { padding: 0; }

/* Footer: match blog.ariamersad.com dark surface (local images for _main.min.css) */
body.am-products-body footer,
body.am-blog-body footer {
  background-color: var(--am-dark-footer) !important;
  background-image: url("assets/images/bg-footer.png") !important;
  background-repeat: no-repeat !important;
  background-size: cover !important;
  background-position: bottom right !important;
  color: #fff;
}
body.am-products-body footer .develop-copyright,
body.am-blog-body footer .develop-copyright,
body.am-products-body .develop-copyright,
body.am-blog-body .develop-copyright {
  background-color: var(--am-dark-footer) !important;
  background-image: url("assets/images/bg-develop-copyright.png") !important;
  background-repeat: no-repeat !important;
  background-size: cover !important;
  background-position: center center !important;
  color: #fff;
}

/* Dark footer — match blog.ariamersad.com (_main.min.css + bg images).
   Local themes load _main.min.css without assets/images/bg-footer.png; override absolute URLs. */
footer {
  background-color: #424342 !important;
  background-image: url("https://www.ariamersad.com/template/default/fa/assets/images/bg-footer.png") !important;
  background-repeat: no-repeat !important;
  background-size: cover !important;
  background-position: bottom right !important;
  padding-top: 108px !important;
  margin-top: 80px !important;
  border-top: 18px solid #159b82 !important;
  position: relative !important;
  color: #fff !important;
}
footer .develop-copyright,
.develop-copyright {
  background-color: #2f2f2f !important;
  background-image: url("https://www.ariamersad.com/template/default/fa/assets/images/bg-develop-copyright.png") !important;
  background-repeat: no-repeat !important;
  background-size: cover !important;
  background-position: center center !important;
  padding: 24px 0 !important;
  margin-top: 60px !important;
  color: #fff !important;
}
footer .col-title,
footer .links-box .links li a,
footer .contact-items .item .value,
footer .contact-items .item .value a,
footer .develop-copyright .col-copyright,
footer .develop-copyright .develop .des,
footer .develop-copyright .develop .des a {
  color: #fff !important;
}
footer .links-box .links li a:hover,
footer .contact-items .item .value a:hover {
  color: #159b82 !important;
}

