/* --- GLOBAL STYLES & VARIABLES --- */
:root {
    --color-primary: #b95c10; /* emerald-500 */
    --color-primary-dark: #d37716; /* emerald-600 */
    --color-bg-dark: #e9e1dc; /* slate-900 */
    --color-bg-medium: #1e293b; /* slate-800 */
    --color-bg-light: #334155; /* slate-700 */
    --color-text-light: #f97b27; /* slate-300 */
    --color-text-medium: #f8610f; /* slate-400 */
    --color-white: #ffffff;
    --font-family-base: 'Poppins', sans-serif;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--color-bg-dark);
    color: var(--color-text-light);
    font-family: var(--font-family-base);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.hidden {
    display: none !important;
}

/* --- TYPOGRAPHY & SHARED COMPONENTS --- */
h1, h2, h3, h4 {
    color: var(--color-white);
    line-height: 1.2;
}

.section {
    padding: 80px 0;
}
.section-dark {
    background-color: var(--color-bg-medium);
}
.section-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}
.section-subtitle {
    color: var(--color-primary);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1px;
}
.section-description {
    max-width: 600px;
    margin: 0 auto 50px auto;
    color: var(--color-text-medium);
    font-size: 1.1rem;
}

.text-center {
    text-align: center;
}

.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}
.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-white);
}
.btn-primary:hover {
    background-color: var(--color-primary-dark);
    transform: translateY(-2px);
}
.btn-secondary {
    background-color: var(--color-bg-light);
    color: var(--color-white);
}
.btn-secondary:hover {
    background-color: #475569; /* slate-600 */
    transform: translateY(-2px);
}
.btn-full {
    width: 100%;
    text-align: center;
}
.logo {
    display: inline-flex;           /* تا لوگو وسط‌چین و منعطف بشه */
    align-items: center;
    text-decoration: none;
  }
  
  .logo img {
    height: 90px;                   /* ارتفاع لوگو */
    width: auto;                    /* عرض متناسب با نسبت اصلی */
    display: block;
    transition: transform 0.3s ease;
  }
  
  /* افکت هنگام هاور روی لوگو */
  .logo:hover img {
    transform: scale(1.05);
  }
  

/* --- HEADER --- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}
.header.scrolled {
    background-color: rgba(15, 23, 42, 0.9);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(5px);
}
.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}
.main-nav {
    display: flex;
    gap: 25px;
}
.main-nav a {
    color: var(--color-text-light);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}
.main-nav a:hover {
    color: var(--color-primary);
}

/* --- MOBILE MENU --- */
.mobile-menu-button {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
}
.mobile-menu-button .icon {
    width: 24px;
    height: 24px;
    stroke: var(--color-white);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    fill: none;
}
.mobile-menu {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 80px;
    left: 0;
    width: 100%;
    background-color: var(--color-bg-medium);
    padding: 20px;
    gap: 15px;
}
.mobile-menu.open {
    display: flex;
}
.mobile-menu a {
    color: var(--color-text-light);
    text-decoration: none;
    font-size: 1.1rem;
    padding: 10px;
    border-radius: 6px;
}
.mobile-menu a:hover {
    background-color: var(--color-bg-light);
}

/* --- HERO SECTION --- */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--color-white);
    padding: 20px;
}
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('siterecoopmedia/94106AEE-F0E4-40A2-A533-6A8002BEB960.png') no-repeat center center/cover;
    z-index: -2;
}
.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 23, 42, 0.7);
    z-index: -1;
}
.hero-content h1 {
    font-size: 4rem;
    font-weight: 800;
    text-shadow: 2px 2px 8px rgba(0,0,0,0.5);
}
.hero-content h1 .subtitle {
    display: block;
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--color-primary);
    margin-top: 10px;
}
.hero-content p {
    max-width: 700px;
    margin: 20px auto 40px;
    font-size: 1.2rem;
}
.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

/* --- ABOUT SECTION --- */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
}
.feature-card {
    background-color: var(--color-bg-dark);
    padding: 30px;
    border-radius: 8px;
    text-align: center;
}
.feature-icon-wrapper {
    width: 60px;
    height: 60px;
    background-color: var(--color-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}
.feature-icon {
    width: 28px;
    height: 28px;
    color: var(--color-white);
}
.feature-card h4 {
    font-size: 1.2rem;
    margin-bottom: 10px;
}
.feature-card p {
    color: var(--color-text-medium);
}

/* --- SERVICES SECTION (updated) --- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
  }
  
  /* Card */
  .service-card {
    background-color: var(--color-bg-light);
    padding: 20px;
    border-radius: 8px;
    text-align: left;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
  }
  .service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.12);
  }
  
  /* Header (icon + title) */
  .service-card-header {
    display: flex;
    align-items: center;
    gap: 15px;              /* فاصله بین آیکون و متن */
    margin-bottom: 12px;
  }
  
  /* Icon wrapper: ثابت، کوچک و مرتب */
  .service-icon-wrapper {
    width: 150px;            /* اندازه قاب آیکون */
    height: 150px;
    min-width: 56px;
    background-color: var(--color-primary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 0;        /* gap در .service-card-header کنترل می‌شود */
    overflow: hidden;       /* اگر عکس بزرگ باشه، قالب رو نشکنه */
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
  }
  
  /* تصویر واقعی داخل قاب */
  .service-icon {
    width: 100%;            /* پر کردن کامل قاب */
    height: 100%;
    max-width: 300px;
    max-height: 300px;
    object-fit: cover;      /* حفظ نسبت و برش شکیل */
    display: block;
    border-radius: inherit; /* گوشه‌ها با قاب هماهنگ باشه */
    padding: 0;             /* padding نذاریم تا عکس بصورت کامل قاب رو بگیره */
    transition: transform 0.25s ease;
  }
  .service-icon-wrapper:hover .service-icon {
    transform: scale(1.05);
  }
  
  /* اگر از SVG به‌عنوان آیکون استفاده می‌کنی (بدون img) */
  .service-icon-wrapper svg,
  .service-icon-wrapper .svg-icon {
    width: 48%;
    height: 48%;
    fill: none;
    stroke: currentColor;
  }
  
  /* عنوان در کارت */
  .service-card h4 {
    font-size: 1.05rem;
    margin: 0;
    line-height: 1.2;
    color: var(--color-text);
  }
  
  /* لیست آیتم‌ها */
  .service-card ul {
    list-style: none;       /* استایل دلخواه - می‌تونیم چک یا بولت دلخواه بذاریم */
    padding-left: 0;
    margin-top: 10px;
    color: var(--color-text-medium);
    display: block;
  }
  .service-card ul li {
    margin-bottom: 6px;
    padding-left: 22px;
    position: relative;
    font-size: 0.95rem;
  }
  
  /* علامت تیپ لیست (✓) با pseudo-element */
  .service-card ul li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--color-primary);
    font-weight: 600;
    font-size: 0.9rem;
  }
  
  /* ریسپانسیو: وقتی صفحه خیلی کوچک شد، هدر ستونی میشه */
  @media (max-width: 420px) {
    .service-card-header {
      flex-direction: row; /* می‌تونیم column هم بذاریم؛ اینجا نگه‌داشتیم در یک خط */
      gap: 12px;
    }
    .service-icon-wrapper {
      width: 48px;
      height: 48px;
      min-width: 48px;
    }
    .service-card {
      padding: 16px;
    }
  }
  
/* --- GALLERY SECTION --- */
.gallery-container {
    display: flex;
    flex-direction: column;
    gap: 60px;
}
.gallery-category h4 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    text-align: left;
}
.gallery-grid, .gallery-grid-double {
    display: grid;
    gap: 20px;
}
.gallery-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}
.gallery-grid-double {
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
}
.before-after-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.gallery-item {
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    max-height: 200px;
}
.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}
.gallery-item:hover img {
    transform: scale(1.05);
}

/* --- TWO COLUMN LAYOUT (MATERIALS, QUOTE) --- */
.two-column-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}
.column-text h3.section-title, .column-text h2.section-subtitle {
    text-align: left;
    margin-left: 0;
}
.column-image img {
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    max-height: 400px;
    max-width: 400px;
}
.materials-list {
    list-style: none;
    margin-top: 20px;
}
.materials-list li {
    padding-left: 30px;
    position: relative;
    margin-bottom: 10px;
    font-size: 1.1rem;
}
.materials-list li::before {
    content: '✓';
    color: var(--color-primary);
    position: absolute;
    left: 0;
    font-weight: bold;
}

/* --- FORM --- */
.form-container {
    background-color: var(--color-bg-dark);
    padding: 40px;
    border-radius: 8px;
}
.form-group {
    margin-bottom: 20px;
}
.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}
.form-group input, .form-group textarea {
    width: 100%;
    padding: 12px;
    background-color: var(--color-bg-medium);
    border: 1px solid var(--color-bg-light);
    border-radius: 6px;
    color: var(--color-white);
    font-family: inherit;
}
.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.5);
}
#success-message {
    text-align: center;
    padding: 20px;
}
#success-message h3 {
    font-size: 1.8rem;
    color: var(--color-primary);
}

/* --- FOOTER --- */
.footer {
    background-color: var(--color-bg-dark);
    padding-top: 60px;
    border-top: 1px solid var(--color-bg-medium);
}
.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-bottom: 40px;
}
.footer-column h4 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: var(--color-white);
}
.footer-column p, .footer-column li {
    color: var(--color-text-medium);
}
.contact-list {
    list-style: none;
}
.contact-list li {
    margin-bottom: 10px;
}
.contact-list a {
    color: var(--color-text-medium);
    text-decoration: none;
    transition: color 0.3s ease;
}
.contact-list a:hover {
    color: var(--color-primary);
}
.social-links {
    display: flex;
    gap: 20px;
}
.social-links a {
    color: var(--color-text-medium);
}
.social-links a:hover {
    color: var(--color-primary);
}
.social-links svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
}
.footer-bottom {
    border-top: 1px solid var(--color-bg-medium);
    padding: 20px 0;
    text-align: center;
    color: var(--color-text-medium);
}

/* --- RESPONSIVE STYLES --- */
@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
    .two-column-layout {
        grid-template-columns: 1fr;
    }
    .column-text {
        text-align: center;
    }
    .column-text h3.section-title, .column-text h2.section-subtitle {
        text-align: center;
    }
    .materials-list {
        display: inline-block;
        text-align: left;
    }
}

@media (max-width: 768px) {
    .section-title {
        font-size: 2rem;
    }
    .hero-content h1 {
        font-size: 3rem;
    }
    .main-nav, .hidden-mobile {
        display: none;
    }
    .mobile-menu-button {
        display: block;
    }
    .features-grid, .footer-grid {
        grid-template-columns: 1fr;
    }
    .footer-grid {
        text-align: center;
    }
    .social-links, .contact-list {
        justify-content: center;
    }
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    .gallery-grid-double {
        grid-template-columns: 1fr;
    }
}


/* Hero icon initial */
#hero-icon {
    width: 96px;
    height: 96px;
    object-fit: contain;
    border-radius: 8px;
    vertical-align: middle;
    transition: opacity 120ms linear;
    will-change: transform, opacity;
    display: inline-block;
  }
  
    /* container موقعیت دهی کن */
  /* ---------- PIN + ICON FIXES ---------- */

/* container positioning (unchanged) */
#servicos .container { position: relative; }

/* services pin: اندازه منطقی و قابل تنظیم */
.services-pin {
  position: absolute;
  top: -40px;            /* تنظیم دلخواه */
  right: 2.5rem;        /* استفاده از فاصله نسبی بهتر از مقدار ثابت px */
  width: 120px;         /* اندازه کلی پن */
  height: 120px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 30;
  background: transparent;
  transition: box-shadow .18s ease, transform .18s ease;
  /* یک مقدار پیش‌فرض سایه کم برای دیده شدن قاب روی پس‌زمینه */
  box-shadow: none;
}

/* حالت پر شده (وقتی تصویر درون pin گذاشته می‌شود) */
.services-pin.pin-filled {
  /* کادر نارنجیِ قابل کنترل:
     - use outline-like look via box-shadow so it won't change layout
  */
  box-shadow: 0 0 0 6px rgba(255, 165, 0, 0.14), 0 6px 18px rgba(0,0,0,0.08);
  transform: translateY(-2px);
}

/* تصویر داخل pin: فقط یک تعریف منظم (بدون تکرار width) */
.services-pin img.pin-img {
  width: 84%;
  height: 84%;
  max-width: 104px;   /* حداکثر منطقی */
  max-height: 104px;
  object-fit: contain;
  display: block;
  border-radius: 8px;
  pointer-events: none;
  transition: opacity .12s ease, transform .12s ease;
}

/* برای زمانی که می‌خواهی تصویر دایره‌ای باشد:
.services-pin img.pin-img { border-radius: 50%; } */

/* کارت‌ها: بزرگ‌تر کردن آیکون داخل کارت */
.services-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin-top: 20px; }
.service-card { background:#f8f8f8; padding:14px; border-radius:8px; box-shadow:0 1px 6px rgba(0,0,0,0.06); cursor:pointer; transition:transform .12s; }
.service-card:hover { transform: translateY(-4px); }
.service-card-header { display:flex; gap:14px; align-items:center; }

/* افزایش اندازه آیکون کارت -> واضح‌تر دیده شود */
.service-icon {
  width: 150px;          /* بزرگ‌تر از قبلی */
  height: 150px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
  box-shadow: 0 4px 14px rgba(0,0,0,0.06);
}

/* کوچک‌تر کردن عنوان کنار آیکون در موبایل تا layout بهتر بماند */
.service-card h4 { margin:0; font-size:1rem; }

/* لیست داخل کارت */
.service-card ul { margin:8px 0 0 18px; padding:0; color:#333; font-size:0.92rem; }

/* RESPONSIVE: روی موبایل همه چیز جمع‌وجورتر شود */
@media (max-width: 640px) {
  .services-pin { right: 1rem; top: -30px; width: 84px; height: 84px; }
  .services-pin img.pin-img { width: 78%; max-width: 72px; max-height: 72px; }
  .service-icon { width: 52px; height: 52px; }
  .services-grid { gap: 12px; }
}



  /* clone که به body اضافه میشه - follow mode (بدون transition برای همگامی دقیق) */
  .floating-clone {
    position: fixed;
    z-index: 9999;
    pointer-events: none;
    will-change: transform, width, height, left, top;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.18);
    opacity: 1;
    transform: translate(20,0);
  }
  
  /* هنگام snap نهایی، transition کوتاه فعال می‌شود */
  .floating-clone.smooth-snap {
    transition: transform 320ms cubic-bezier(.22,.9,.29,1), opacity 180ms linear;
  }
  