/* ==========================================================
   Сайт-визитка — Фетибек Алиев
   ========================================================== */

/* Палитра: VITYA.AI — тёплый dark-mode (espresso / terracotta).
   Разрешённые цвета: #1a1410 #1f1914 #e8e0d8 #a89a8c #6b5e52 #da7756 #2e2520 #ffffff */
:root {
  color-scheme: dark;
  --bg: #1a1410;          /* Espresso — фон страницы */
  --bg-soft: #1f1914;     /* Milk chocolate */
  --card: #1f1914;        /* Milk chocolate — карточки */
  --card-hover: #1f1914;  /* карточка не меняет фон на hover */
  --border: #2e2520;      /* Bitter chocolate — hairlines */
  --text: #e8e0d8;        /* Warm white — основной текст */
  --white: #ffffff;       /* Pure white — только h1 и strong */
  --muted: #a89a8c;       /* Latte — вторичный текст, навигация */
  --dim: #6b5e52;         /* Cappuccino — даты, подписи, футер */
  --accent: #da7756;      /* Terracotta — единственный хроматический цвет */
  --accent-2: #da7756;    /* совпадает с акцентом (доп. цветов нет) */
  --accent-warm: #da7756; /* совпадает с акцентом (доп. цветов нет) */
  --radius: 16px;
  --maxw: 1120px;
  --font: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--accent); text-decoration: none; transition: opacity .2s ease; }
a:hover { opacity: .8; }

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(26, 20, 16, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 64px;
}

.logo {
  font-weight: 800;
  letter-spacing: 0.06em;
  font-size: 15px;
  color: var(--text);
  text-transform: uppercase;
  white-space: nowrap;
}
.logo span { color: var(--accent); }
.logo:hover { text-decoration: none; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  color: var(--muted);
  font-size: 14.5px;
  font-weight: 500;
}
.nav-links a:hover { color: var(--accent); text-decoration: none; }
.nav-links a.active { color: var(--accent); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font-size: 20px;
  line-height: 1;
  padding: 8px 12px;
  cursor: pointer;
}

/* ---------- Hero ---------- */
.hero {
  padding: 72px 0 48px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 48px;
  align-items: center;
}
.eyebrow {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--border);
  background: var(--card);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 20px;
}
h1 {
  color: #ffffff;
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.1;
  margin: 0 0 14px;
  letter-spacing: -0.01em;
}
.role {
  font-size: clamp(16px, 2.2vw, 19px);
  color: var(--muted);
  margin: 0 0 26px;
  font-weight: 500;
}
.role b { color: var(--text); font-weight: 600; }

.photo-frame {
  aspect-ratio: 1 / 1.05;
  border-radius: 24px;
  border: 1px solid var(--border);
  background: var(--card);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.photo-frame img { width: 100%; height: 100%; object-fit: cover; }
.photo-placeholder {
  font-size: clamp(56px, 8vw, 92px);
  font-weight: 800;
  color: var(--dim);
  letter-spacing: 0.02em;
}
.photo-caption {
  text-align: center;
  color: var(--muted);
  font-size: 12.5px;
  margin-top: 10px;
}

/* ---------- Sections ---------- */
section { padding: 56px 0; }
.section-head { margin-bottom: 30px; }
h2 {
  font-size: clamp(24px, 3.4vw, 34px);
  margin: 0 0 10px;
  letter-spacing: -0.01em;
}
.section-sub { color: var(--muted); max-width: 760px; margin: 0; }

.divider { border: none; border-top: 1px solid var(--border); margin: 0; }

/* ---------- Intro (about) ---------- */
.intro p { margin: 0 0 18px; max-width: 860px; color: var(--text); font-size: 17px; }
.intro p strong { color: #ffffff; }

/* ---------- Achievements ---------- */
.achievements {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 18px;
  counter-reset: ach;
}
.ach-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 22px 20px 22px;
  position: relative;
}
.ach-card::before {
  counter-increment: ach;
  content: "0" counter(ach);
  display: block;
  font-size: 13px;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: 0.1em;
  margin-bottom: 10px;
}
.ach-card h3 {
  margin: 0 0 8px;
  font-size: 16.5px;
  line-height: 1.35;
}
.ach-card p { margin: 0 0 12px; color: var(--muted); font-size: 14.5px; }
.ach-card p:last-child { margin-bottom: 0; }

/* Список достижений — маркированные пункты, а не сплошной текст */
.ach-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 9px;
}
.ach-list li {
  position: relative;
  padding-left: 18px;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.5;
}
.ach-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
}
.ach-list li strong { color: var(--text); }

/* ---------- Client grid (статичная сетка, текстовые ячейки) ---------- */
.client-grid {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr); /* desktop >1200px: 5 колонок */
  gap: 24px;
}
.client-cell {
  min-height: 100px;                      /* ячейка ~180×100px */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 12px;
  background: var(--card);                /* возвышение тоном, без теней и рамок */
  border: 1px solid var(--border);
  transition: border-color 0.3s ease;
}
.client-cell span {
  color: var(--text);                     /* яркий тёплый белый — в тон сайту */
  font-weight: 700;
  font-size: 15px;
  line-height: 1.3;
  transition: color 0.3s ease;
}
.client-cell:hover { border-color: var(--accent); }
.client-cell:hover span { color: #ffffff; }
@media (max-width: 1200px) {
  .client-grid { grid-template-columns: repeat(4, 1fr); } /* tablet */
}
@media (max-width: 768px) {
  .client-grid { grid-template-columns: repeat(3, 1fr); gap: 14px; } /* mobile */
  .client-cell { min-height: 84px; padding: 10px; }
  .client-cell span { font-size: 13px; }
}
@media (max-width: 480px) {
  .client-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Product portfolio ---------- */
.products {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}
.product-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px;
  font-weight: 600;
  font-size: 15.5px;
}
.product-item .dot {
  flex: 0 0 auto;
  width: 10px; height: 10px;
  margin-top: 7px;
  border-radius: 50%;
  background: var(--accent);
}
.product-item small {
  display: block;
  color: var(--muted);
  font-weight: 400;
  font-size: 13px;
  margin-top: 4px;
}

/* ---------- Career & education ---------- */
.two-col {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 40px;
}
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li {
  position: relative;
  padding: 0 0 26px 26px;
  border-left: 2px solid var(--border);
}
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: "";
  position: absolute;
  left: -7px; top: 6px;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--accent);
  outline: 4px solid var(--bg);
}
.timeline .period {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.timeline h3 { margin: 4px 0 2px; font-size: 16.5px; }
.timeline .company { color: var(--text); font-weight: 500; }
.timeline p { margin: 6px 0 0; color: var(--muted); font-size: 14.5px; }

.edu-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}
.edu-card h3 { margin: 0 0 10px; font-size: 16.5px; }
.edu-card p { margin: 0 0 8px; color: var(--muted); font-size: 14.5px; }
.edu-card p:last-child { margin-bottom: 0; }
.edu-card b { color: var(--text); }

/* ---------- Expertise tags ---------- */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.tags li {
  background: var(--card);
  border: 1px solid var(--border);
  color: var(--muted);
  border-radius: 999px;
  padding: 7px 15px;
  font-size: 13.5px;
  font-weight: 500;
}

/* ---------- Stats strip ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
}
.stat {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
  text-align: center;
}
.stat .num {
  font-size: 30px;
  font-weight: 800;
  color: var(--accent);
  line-height: 1.1;
}
.stat .lbl { color: var(--muted); font-size: 13px; margin-top: 6px; }

/* ---------- CTA / contacts ---------- */
.cta-box {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 38px;
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 32px;
  align-items: center;
}
.cta-box h2 { margin-bottom: 8px; }
.cta-box p { color: var(--muted); margin: 0 0 22px; }

.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.contact-list a {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  font-weight: 500;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 16px;
  background: var(--bg);
  transition: border-color .15s ease, background .15s ease;
}
.contact-list a:hover {
  text-decoration: none;
  border-color: var(--accent);
  background: var(--bg);
}
.contact-list .ico { width: 20px; text-align: center; color: var(--accent); }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--accent);
  color: var(--bg);
  font-weight: 700;
  font-size: 15px;
  padding: 14px 26px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  transition: opacity .2s ease;
}
.btn:hover { text-decoration: none; opacity: .8; }
.btn.secondary {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
  box-shadow: none;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 34px 0 44px;
  margin-top: 40px;
  color: var(--muted);
  font-size: 13.5px;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.footer-inner nav a { color: var(--dim); margin-left: 18px; }
.footer-inner nav a:hover { color: var(--accent); text-decoration: none; }

/* ---------- Projects overview grid 3x3 ---------- */
.grid-3x3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.tile {
  display: flex;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  color: var(--text);
  transition: border-color .2s ease, transform .25s ease;
  position: relative;
  min-height: 100%;
}
.tile:hover {
  text-decoration: none;
  border-color: var(--accent);
  transform: translateY(-6px);
}
.tile .tile-ico {
  font-size: 26px;
  margin-bottom: 12px;
  display: inline-block;
  transition: transform .25s ease;
}
.tile:hover .tile-ico {
  transform: translate(4px, -4px) rotate(-8deg) scale(1.15);
}
@media (prefers-reduced-motion: reduce) {
  .tile, .tile .tile-ico { transition: none; }
  .tile:hover { transform: none; }
  .tile:hover .tile-ico { transform: none; }
}
.tile h3 {
  margin: 0 0 10px;
  font-size: 18px;
  line-height: 1.3;
  padding-right: 26px;
}
.tile .dirs {
  margin: 0 0 14px;
  padding: 0;
  list-style: none;
  font-size: 14px;
  color: var(--text);
}
.tile .dirs li { padding-left: 16px; position: relative; margin-bottom: 4px; }
.tile .dirs li::before {
  content: "·";
  position: absolute; left: 2px;
  color: var(--accent);
  font-weight: 800;
}
.tile .clients {
  margin-top: auto;
  font-size: 12.8px;
  color: var(--muted);
  line-height: 1.5;
}
.tile .arrow {
  position: absolute;
  top: 24px; right: 22px;
  color: var(--accent);
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity .15s ease, transform .15s ease;
  font-weight: 700;
  font-size: 13px;
}
.tile:hover .arrow { opacity: 1; transform: translateX(0); }

/* ---------- Category pages / cases ---------- */
.breadcrumbs {
  font-size: 13.5px;
  color: var(--muted);
  padding: 26px 0 0;
}
.breadcrumbs a { color: var(--muted); }
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs .sep { margin: 0 8px; color: var(--dim); }

.case {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  margin-bottom: 26px;
}
.case > h3 {
  margin: 0 0 20px;
  font-size: 20px;
  line-height: 1.35;
  letter-spacing: -0.005em;
}
.case > h3 .case-num {
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  display: block;
  margin-bottom: 6px;
}
.csr { display: grid; gap: 14px; }
.csr-step {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 16px;
  align-items: start;
}
.csr-step .tag-label {
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 8px;
  padding: 5px 0;
  text-align: center;
  margin-top: 2px;
}
.tag-task,
.tag-solution,
.tag-result {
  background: var(--bg);
  color: var(--accent);
  border: 1px solid var(--border);
}
.csr-step .body { margin: 0; color: var(--text); font-size: 15.5px; }
.csr-step ul.result-list { margin: 0; padding: 0; list-style: none; }
.csr-step ul.result-list li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 8px;
  color: var(--text);
  font-size: 15.5px;
}
.csr-step ul.result-list li::before {
  content: "✓";
  position: absolute; left: 0;
  color: var(--accent-2);
  font-weight: 700;
}
.csr-step ul.result-list li b { color: #ffffff; }

.cat-nav {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 10px;
}

/* ---------- Page hero (inner pages) ---------- */
.page-hero { padding: 34px 0 8px; }
.page-hero h1 { font-size: clamp(30px, 4.4vw, 44px); margin-bottom: 12px; }
.page-hero .lead { color: var(--muted); font-size: 17.5px; max-width: 800px; margin: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; gap: 32px; }
  .photo-frame { max-width: 340px; margin: 0 auto; }
  .two-col { grid-template-columns: 1fr; gap: 28px; }
  .cta-box { grid-template-columns: 1fr; padding: 28px; }
  .grid-3x3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 64px; left: 0; right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: rgba(26, 20, 16, 0.97);
    border-bottom: 1px solid var(--border);
    padding: 8px 24px 16px;
  }
  .nav-links.open { display: flex; }
  .nav-links li { width: 100%; }
  .nav-links a { display: block; padding: 11px 0; font-size: 16px; }
  .nav-toggle { display: block; }
  .grid-3x3 { grid-template-columns: 1fr; }
  .csr-step { grid-template-columns: 1fr; gap: 6px; }
  .csr-step .tag-label { width: 110px; }
  section { padding: 40px 0; }
  .hero { padding: 44px 0 28px; }
  .case { padding: 22px; }
}
