:root {
  --bg: #f5f6f8;
  --surface: #ffffff;
  --surface-soft: #f1f4f9;
  --text: #1d252f;
  --muted: #6a7481;
  --primary: #0d6e6e;
  --primary-soft: #d9efef;
  --accent: #d46c22;
  --danger: #c0392b;
  --ok: #1f8a4d;
  --radius-lg: 16px;
  --radius-md: 12px;
  --shadow: 0 10px 25px rgba(16, 24, 40, 0.08);
  --border: 1px solid #e5e9f0;
}

@font-face {
  font-family: "BYekan";
  src:
    url("../fonts/Yekan.woff2?v=20260410-1") format("woff2"),
    url("../fonts/Yekan.woff?v=20260410-1") format("woff"),
    url("../fonts/Yekan.ttf?v=20260410-1") format("truetype"),
    local("B Yekan"),
    local("BYekan"),
    local("Yekan");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  margin: 0;
  padding: 0;
  direction: rtl;
  background: radial-gradient(circle at top right, #eaf5f5 0%, #f7f7f8 40%, #eef2f7 100%);
  color: var(--text);
  font-family: "BYekan", Tahoma, Arial, sans-serif;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: min(1200px, 92vw);
  margin: 0 auto;
}

.page {
  padding: 24px 0 48px;
}

.grid {
  display: grid;
  gap: 16px;
}

.grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: var(--border);
  box-shadow: var(--shadow);
  padding: 16px;
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.section-title h2,
.section-title h3 {
  margin: 0;
  font-size: 1.2rem;
}

.muted {
  color: var(--muted);
}

.btn {
  border: none;
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, filter 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
  filter: brightness(0.97);
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-soft {
  background: var(--primary-soft);
  color: var(--primary);
}

.btn-accent {
  background: var(--accent);
  color: #fff;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.8rem;
  font-weight: 700;
}

.badge-planning {
  background: #eceff3;
  color: #5f6c7d;
}

.badge-presale {
  background: #e9f0fe;
  color: #3158a5;
}

.badge-foundation {
  background: #fff0e3;
  color: #a55a1b;
}

.badge-frame {
  background: #e7f5ff;
  color: #0f5f8f;
}

.badge-structure {
  background: #e6f7ef;
  color: #1c7f4f;
}

.badge-finishing {
  background: #f4ebff;
  color: #6d3e9a;
}

.badge-delivered {
  background: #dff6e7;
  color: #0f6b39;
}

.progress {
  background: #e6ebf2;
  border-radius: 999px;
  height: 9px;
  overflow: hidden;
}

.progress > span {
  height: 100%;
  display: block;
  border-radius: inherit;
  background: linear-gradient(90deg, #0d6e6e 0%, #2d9c9c 100%);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(5px);
  background: rgba(245, 246, 248, 0.88);
  border-bottom: var(--border);
}

.topbar-inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.brand {
  display: flex;
  gap: 10px;
  align-items: center;
  font-weight: 900;
}

.brand img {
  width: 36px;
  height: 36px;
}

.nav-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.topbar-rich .topbar-inner {
  position: relative;
  min-height: 72px;
}

.main-nav {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
}

.main-nav a {
  padding: 8px 12px;
  border-radius: 999px;
  color: #364050;
  font-weight: 700;
}

.main-nav a:hover,
.main-nav a.active {
  background: #e2f1f1;
  color: #0d6e6e;
}

.site-header-menu {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mobile-menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  border: var(--border);
  background: #f6f9fd;
  color: #2a3e52;
  font-size: 1.35rem;
  cursor: pointer;
  place-items: center;
}

.hero {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 16px;
  align-items: stretch;
  margin-top: 18px;
}

.hero h1 {
  margin: 0 0 10px;
  line-height: 1.4;
}

.kpi-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.kpi {
  background: var(--surface-soft);
  border-radius: var(--radius-md);
  padding: 12px;
}

.kpi strong {
  display: block;
  font-size: 1.2rem;
}

.inputs {
  display: grid;
  gap: 10px;
}

.input,
textarea,
select {
  width: 100%;
  border: var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  background: #fff;
  font: inherit;
}

button,
input,
select,
textarea {
  font-family: inherit;
}

textarea {
  min-height: 120px;
  resize: vertical;
}

.project-card {
  display: grid;
  gap: 10px;
}

.project-media {
  border-radius: 12px;
  overflow: hidden;
  border: var(--border);
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 0.9rem;
}

.project-meta span {
  background: var(--surface-soft);
  border-radius: 999px;
  padding: 4px 8px;
}

.timeline {
  display: grid;
  gap: 10px;
}

.timeline-item {
  padding: 10px;
  border: var(--border);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
}

.timeline-item.active {
  border-color: #0d6e6e;
  background: #f1fbfb;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  text-align: right;
  padding: 10px;
  border-bottom: 1px solid #edf0f4;
  font-size: 0.92rem;
  white-space: nowrap;
}

.alert {
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.9rem;
}

.alert-ok {
  background: #eaf8ef;
  color: var(--ok);
}

.alert-warn {
  background: #fff4e8;
  color: #9a4d12;
}

.alert-danger {
  background: #fcebea;
  color: var(--danger);
}

.footer {
  margin-top: 24px;
  color: var(--muted);
  text-align: center;
}

.mt-12 {
  margin-top: 12px;
}

.mt-16 {
  margin-top: 16px;
}

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

  .grid-2,
  .kpi-row {
    grid-template-columns: 1fr;
  }

  .topbar-inner {
    align-items: flex-start;
    padding: 10px 0;
    flex-direction: column;
  }

  .topbar-rich .topbar-inner {
    min-height: 64px;
    padding: 10px 0;
    align-items: center;
    flex-direction: row;
    justify-content: space-between;
  }

  .mobile-menu-toggle {
    display: inline-grid;
  }

  .topbar-rich .site-header-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: min(92vw, 360px);
    background: #fff;
    border: var(--border);
    border-radius: 14px;
    box-shadow: 0 16px 30px rgba(15, 34, 52, 0.16);
    padding: 12px;
    display: none;
    z-index: 35;
  }

  .topbar-rich.menu-open .site-header-menu {
    display: grid;
    gap: 10px;
  }

  .topbar-rich .main-nav {
    width: 100%;
    display: grid;
    gap: 6px;
  }

  .topbar-rich .main-nav a {
    text-align: right;
    white-space: normal;
  }

  .topbar-rich .nav-actions {
    width: 100%;
    display: grid;
    gap: 8px;
  }

  .topbar-rich .nav-actions .btn {
    width: 100%;
    text-align: center;
  }
}
