:root {
  --clr-bg:         #ffffff;
  --clr-surface:    #EBEBEB;
  --clr-border:     #d5dbdb;
  --clr-main:       #66CDC0;
  --clr-gold-lt:    #E8B82A;
  --clr-text:       #1A1A1A;
  --clr-muted:      #6B6560;
  --clr-sub:        #9B9590;
  --clr-white:      #FFFFFF;
  --clr-footer-bg:  #141210;

  --ff-en: 'Outfit', sans-serif;    
  --ff-fa: 'Vazirmatn', sans-serif;

  --radius-sm:  6px;
  --radius-md: 14px;
  --radius-lg: 22px;

  --shadow-card:  0 2px 16px rgba(0,0,0,0.07);
  --shadow-hover: 0 10px 36px rgba(0,0,0,0.14);
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --header-h: 70px;

  --hero-ratio: 16/1;
  --skew: 5rem;
}

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

html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

body {
  background: var(--clr-bg);
  color: var(--clr-text);
  font-family: var(--ff-en); 
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden; 
}

img { display: block; max-width: 100%; }
a   { text-decoration: none; color: inherit; }
ul  { list-style: none; }

.lang-en { font-family: var(--ff-en); }
.lang-fa { font-family: var(--ff-fa); }

html[lang="en"] .lang-fa { display: none !important; }
html[lang="fa"] .lang-en { display: none !important; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 900;
  background: rgba(250, 248, 243, 0.93);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--clr-border);
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
  gap: 1rem;
}

.site-logo-group { display: flex; align-items: center; gap: 0.7rem; flex-shrink: 0; }

.site-logo-mark {
  width: 38px; height: 38px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm);
}
.site-logo-mark svg { width: 100%; height: 100%; }

.site-logo { font-size: 1.15rem; font-weight: 700; color: var(--clr-text); line-height: 1.25; }

.header-actions { display: flex; align-items: center; gap: 0.6rem; }

.btn-contact {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 18px; border-radius: var(--radius-md);
  background: var(--clr-text); color: #fff;
  border: 1.5px solid transparent; cursor: pointer;
  font-size: 0.85rem; font-weight: 600;
  transition: var(--transition);
}
.btn-contact:hover { background: var(--clr-main); }
.btn-contact svg { flex-shrink: 0; }

.lang-switch {
  display: flex; align-items: center; gap: 2px;
  padding: 3px; border-radius: var(--radius-md);
  background: var(--clr-surface); border: 1.5px solid var(--clr-border);
}
.lang-btn {
  padding: 6px 12px; border-radius: calc(var(--radius-md) - 4px);
  border: none; background: transparent; cursor: pointer;
  font-size: 0.78rem; font-weight: 600; color: var(--clr-sub);
  transition: var(--transition);
}
.lang-btn[aria-pressed="true"] { background: var(--clr-main); color: var(--clr-text); box-shadow: var(--shadow-card); }
.lang-btn:hover { color: var(--clr-text); }

.lang-btn[data-lang="en"] { font-family: var(--ff-en); }
.lang-btn[data-lang="fa"] { font-family: var(--ff-fa); }

.hero-section {
  position: relative;
  z-index: 4;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--skew)), 0 100%);
  margin-bottom: calc(-2 * var(--skew));
}

.hero-banner {
  position: relative;
  width: 100%;
  aspect-ratio: var(--hero-ratio);
  padding-bottom: var(--skew);
  background: #0E0C0A;
}

.menus-wrap {
  position: relative;
  background: var(--clr-surface);
  z-index: 1;
  padding-top: calc(var(--skew) + 2rem);
  padding-bottom: calc(var(--skew) * 2);
  margin-bottom: 0;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 calc(100% - var(--skew)));
}

.menus-wrap > .section { border-top: 4px solid var(--Clr-main); }

.section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

.section-header { margin-bottom: 2.5rem; }
.section-title {
  display: block; font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 700; line-height: 1.3;
}
.section-title::after { content: ''; display: block; width: 40px; height: 2.5px; margin-top: 0.5rem; border-radius: 2px; background: linear-gradient(90deg, var(--Clr-main), var(--Clr-main-lt)); }
.section-desc { display: block; font-size: 0.95rem; color: var(--clr-muted); line-height: 1.9; margin-top: 0.8rem; max-width: 660px; }

.projects-grid { display: grid; grid-template-columns: 1fr; gap: 2.5rem; }

.project-card {
  background: var(--clr-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--clr-border);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: box-shadow var(--transition), transform var(--transition);
}
.project-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-2px); }

.project-header {
  padding: 1.6rem 1.8rem 1.4rem;
  border-bottom: 1px solid var(--clr-border);
}

.project-name { display: block; font-size: 1.2rem; font-weight: 700; margin-bottom: 0.5rem; }
.project-desc { display: block; font-size: 0.9rem; color: var(--clr-muted); line-height: 1.85; }

.menu-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 1rem;
  padding: 8px 18px;
  background: var(--clr-text);
  color: var(--clr-white);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  transition: var(--transition);
  border: 1.5px solid transparent;
}
.menu-link:hover { background: var(--clr-main); color: var(--clr-text); border-radius: var(--radius-md); }
.menu-link svg { flex-shrink: 0; }

.project-gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 0; }
.gallery-item {
  position: relative;
  background: var(--clr-surface);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  border-top: 1px solid var(--clr-border);
  border-right: 1px solid var(--clr-border);
  aspect-ratio: 4/3;
  transition: var(--transition);
}
.gallery-item.logo-item { cursor: default; }
.gallery-item:last-child { border-right: none; }

.logo-image { max-width: 100%; max-height: 100%; object-fit: contain; }

.logo-placeholder { display: none; flex-direction: column; align-items: center; justify-content: center; gap: 1rem; width: 100%; height: 100%; padding: 2rem; text-align: center; }
.logo-placeholder-frame { width: 120px; height: 120px; border-radius: var(--radius-md); background: var(--clr-border); display: flex; align-items: center; justify-content: center; border: 2px dashed var(--clr-sub); opacity: 0.5; }
.logo-placeholder-frame svg { opacity: 0.4; }
.logo-placeholder-text { font-size: 0.75rem; color: var(--clr-sub); }

.gallery-video-wrap { position: relative; width: 100%; height: 100%; overflow: hidden; background: #000; }
.gallery-video-wrap iframe { width: 100%; height: 100%; border: none; pointer-events: none; background: #000; }

.gallery-item.video-native .video-play-btn { display: none; }

.gallery-item.video-native .gallery-video-wrap { --aparat-ratio: 16/9; --aparat-zoom: 1; }
.gallery-item.video-native .gallery-video-wrap iframe {
  position: absolute;
  top: 50%; left: 0;
  width: 100%; height: auto;
  aspect-ratio: var(--aparat-ratio);
  transform: translateY(-50%) scale(var(--aparat-zoom));
}
.video-play-btn { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,0.32); cursor: pointer; transition: var(--transition); }
.video-play-btn:hover { background: rgba(75, 81, 94, 0.4); }
.video-play-btn svg { filter: drop-shadow(0 2px 8px rgba(0,0,0,0.5)); }

.gallery-item-label {
  position: absolute; bottom: 0.6rem; left: 50%; transform: translateX(-50%);
  font-size: 0.65rem; font-weight: 600; color: var(--clr-sub);
  background: rgba(250,248,243,0.88); border: 1px solid var(--clr-border);
  padding: 2px 10px; border-radius: 999px; white-space: nowrap; opacity: 0.8; backdrop-filter: blur(4px);
}

.lightbox { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.9); z-index: 2000; align-items: center; justify-content: center; }
.lightbox.open { display: flex; }
.lightbox-close { position: absolute; top: 1.25rem; right: 1.25rem; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.15); color: #fff; width: 40px; height: 40px; border-radius: 50%; cursor: pointer; font-size: 1rem; display: flex; align-items: center; justify-content: center; transition: var(--transition); }
.lightbox-close:hover { background: rgba(200,150,12,0.5); }
.lightbox img { max-width: 90vw; max-height: 87vh; border-radius: var(--radius-md); box-shadow: 0 24px 64px rgba(0,0,0,0.6); }

.site-footer {
  background: var(--clr-footer-bg);
  color: #9B9590;
  clip-path: polygon(0 var(--skew), 100% 0, 100% 100%, 0 100%);
  padding: calc(var(--skew) + 2.5rem) 1.5rem 1.75rem;
  position: relative;
  z-index: 0;
}

.footer-inner { max-width: 1200px; margin: 0 auto; }
.footer-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 3rem; padding-bottom: 2rem; border-bottom: 1px solid #242220; }

.footer-brand .site-logo { color: #E8E4DC; }
.footer-tagline { display: block; font-size: 0.85rem; color: #5A5754; line-height: 1.8; margin-top: 0.75rem; }

.footer-contact-heading { display: block; font-size: 0.95rem; font-weight: 700; color: #E8E4DC; margin-bottom: 0.3rem; }

.contact-links { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1rem; }
.contact-link { display: flex; align-items: center; gap: 10px; padding: 12px 30px; border-radius: var(--radius-md); font-size: 0.85rem; font-weight: 500; transition: var(--transition); border: 1.5px solid transparent; }

.contact-link.telegram { background: #162432; border-color: #1A4F72; color: #64B5F6; }
.contact-link.telegram:hover { background: #1A4F72; color: #fff; }

.contact-link.whatsapp { background: #162418; border-color: #1B5E20; color: #66BB6A; }
.contact-link.whatsapp:hover { background: #1B5E20; color: #fff; }

.contact-link.instagram { background: #2A1A2E; border-color: #833AB4; color: #E1306C; }
.contact-link.instagram:hover {
  background: linear-gradient(45deg, #FEDA75 0%, #FA7E1E 25%, #D62976 50%, #962FBF 75%, #4F5BD5 100%);
  border-color: transparent; color: #fff;
}

.footer-bottom { padding-top: 1.5rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.footer-copy { font-size: 0.8rem; color: #3A3836; }
.footer-copy a { color: inherit; text-decoration: none; border-bottom: 1px dotted currentColor; }
.footer-copy a:hover { opacity: .8; }

.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.65s ease, transform 0.65s ease; }
.reveal.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
}

@media (max-width: 900px) {
  .footer-top { flex-direction: column; gap: 2rem; }
  .logo-placeholder-frame { width: 90px; height: 90px; }
}

@media (max-width: 640px) {
  :root {
    --header-h: 60px;
    --skew: 2.5rem;
  }

  .btn-contact span { display: none; }
  .btn-contact { padding: 9px; }
  .header-inner { gap: 0.5rem; padding: 0 1rem; }

  .project-gallery { grid-template-columns: 1fr; }
  .gallery-item { border-right: none; aspect-ratio: 4/3; }

  .contact-links { flex-direction: column; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }

  .section { padding: 2rem 1rem; }
}
