/* ============================================
   Chingiz Abdujalilov — Targetolog | vizitka
   ============================================ */

/* --- YORUG' MAVZU (asosiy) --- */
:root{
  color-scheme:light;

  --page:#f3f2ef;
  --card:#ffffff;
  --ink:#111111;
  --muted:#6f6f6a;
  --faint:#e6e5e1;
  --shadow:0 1px 2px rgba(0,0,0,.04),0 12px 40px rgba(0,0,0,.06);

  /* yashil blok */
  --block-bg:#c6efd8;
  --block-ink:#12281d;
  --block-line:rgba(18,40,29,.14);

  /* "Targetolog" tabletkasi */
  --pill-bg:#e0d0fb;
  --pill-ink:#2e2245;

  /* monogramma */
  --mono-bg:#c6efd8;
  --mono-ink:#163527;

  /* tugmalar */
  --btn1-bg:#111111;
  --btn1-ink:#ffffff;
  --btn2-bg:#ffffff;
  --btn2-hover:#fafaf8;

  --img-bg:#f0efec;
  --nav-bg:rgba(243,242,239,.82);

  --sun-bg:#fce8a4;
  --sun-ink:#3d3111;
}

/* --- QORONG'I MAVZU --- */
:root[data-theme="dark"]{
  color-scheme:dark;

  --page:#101114;
  --card:#191b1f;
  --ink:#f1f2f4;
  --muted:#9aa0a8;
  --faint:#2b2f35;
  --shadow:0 1px 2px rgba(0,0,0,.3),0 16px 44px rgba(0,0,0,.45);

  --block-bg:#2c5c45;
  --block-ink:#e4f5ea;
  --block-line:rgba(228,245,234,.18);

  --pill-bg:#3a2f57;
  --pill-ink:#e3d7fb;

  --mono-bg:#2c5c45;
  --mono-ink:#dff2e6;

  --btn1-bg:#f1f2f4;
  --btn1-ink:#16181c;
  --btn2-bg:#191b1f;
  --btn2-hover:#22252a;

  --img-bg:#24272c;
  --nav-bg:rgba(16,17,20,.82);

  --sun-bg:#4a3c1c;
  --sun-ink:#f7e9bd;
}

/* --- asos --- */
*{box-sizing:border-box;margin:0;padding:0}

/* menyudan bo'limga silliq o'tish */
html{scroll-behavior:smooth}

body{
  min-height:100vh;
  padding:0 20px 48px;
  background:var(--page);
  color:var(--ink);
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
  line-height:1.6;
  -webkit-font-smoothing:antialiased;
  transition:background .25s ease,color .25s ease;
}

/* --- yopishib turadigan menyu --- */
.nav{
  position:sticky;
  top:0;
  z-index:50;
  margin:0 -20px;
  padding:0 20px;
  background:var(--nav-bg);
  backdrop-filter:blur(12px);
  -webkit-backdrop-filter:blur(12px);
  border-bottom:1px solid var(--faint);
}

.nav-inner{
  max-width:900px;
  margin:0 auto;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:12px 0;
}

.nav-brand{text-decoration:none;flex-shrink:0}

.nav-links{
  display:flex;
  align-items:center;
  gap:6px;
  overflow-x:auto;
  scrollbar-width:none;
  scroll-snap-type:x proximity;
}

.nav-links::-webkit-scrollbar{display:none}
.nav-links a{scroll-snap-align:start}

/* telefonda qisqa nom ko'rinadi */
.l-short{display:none}

.nav-links a{
  padding:8px 14px;
  border-radius:999px;
  text-decoration:none;
  color:var(--muted);
  font-size:14px;
  font-weight:600;
  white-space:nowrap;
  transition:background .18s ease,color .18s ease;
}

.nav-links a:hover{background:var(--btn2-hover);color:var(--ink)}

.card{
  width:100%;
  max-width:900px;
  margin:28px auto 0;
  background:var(--card);
  border-radius:32px;
  padding:40px;
  box-shadow:var(--shadow);
  transition:background .25s ease,box-shadow .25s ease;
}

/* menyu sarlavhani berkitmasligi uchun */
[id]{scroll-margin-top:84px}

/* --- monogramma --- */
.mono{
  width:64px;height:64px;
  border-radius:20px;
  background:var(--mono-bg);
  display:flex;align-items:center;justify-content:center;
  font-size:22px;font-weight:800;
  letter-spacing:-.02em;
  color:var(--mono-ink);
  overflow:hidden;
  flex-shrink:0;
}

/* menyudagi kichik variant */
.mono-sm{
  width:42px;height:42px;
  border-radius:14px;
  font-size:15px;
}

.pill{
  display:inline-block;
  margin-bottom:16px;
  padding:9px 16px;
  border-radius:999px;
  background:var(--pill-bg);
  font-size:12px;
  font-weight:700;
  text-transform:uppercase;
  letter-spacing:.14em;
  color:var(--pill-ink);
  white-space:nowrap;
}

/* mavzu almashtirish tugmasi */
.theme-btn{
  width:40px;height:40px;
  flex-shrink:0;
  display:flex;align-items:center;justify-content:center;
  border-radius:999px;
  border:1px solid var(--faint);
  background:transparent;
  color:var(--ink);
  cursor:pointer;
  transition:background .18s ease,transform .18s ease;
}

.theme-btn:hover{background:var(--btn2-hover);transform:translateY(-1px)}
.theme-btn svg{width:18px;height:18px}

/* yorug'da oy, qorong'ida quyosh ko'rinadi */
.icon-sun{display:none}
:root[data-theme="dark"] .icon-sun{display:block}
:root[data-theme="dark"] .icon-moon{display:none}

/* --- HERO: chapda matn, o'ngda surat --- */
.hero{
  display:grid;
  grid-template-columns:1.05fr .95fr;
  gap:40px;
  align-items:center;
}

h1{
  font-size:52px;
  font-weight:800;
  line-height:1.03;
  letter-spacing:-.035em;
}

.about{
  margin-top:20px;
  max-width:44ch;
  color:var(--muted);
  font-size:16px;
}

/* sarlavha ustidagi kichik qator */
.eyebrow{
  display:flex;
  align-items:center;
  gap:9px;
  margin-bottom:14px;
  font-size:14px;
  font-weight:600;
  color:var(--muted);
}

.eyebrow-dot{
  width:8px;height:8px;
  border-radius:999px;
  background:var(--block-bg);
  box-shadow:0 0 0 4px rgba(198,239,216,.28);
  flex-shrink:0;
}

/* hero ichidagi mijozlar qatori */
.hero-proof{margin-top:30px}

.hero-proof-label{
  font-size:13px;
  font-weight:600;
  color:var(--muted);
}

.proof-logos{
  display:flex;
  align-items:center;
  gap:10px;
  margin-top:12px;
  text-decoration:none;
}

.proof-logos img{
  width:38px;height:38px;
  border-radius:11px;
  object-fit:cover;
  filter:grayscale(1);
  opacity:.5;
  transition:filter .2s ease,opacity .2s ease;
}

.proof-logos:hover img{filter:grayscale(0);opacity:1}

.proof-more{
  font-size:13px;
  font-weight:700;
  color:var(--muted);
}

.hero-photo img{
  display:block;
  width:100%;
  aspect-ratio:4/5;
  object-fit:cover;
  object-position:center 20%;
  border-radius:24px;
  background:var(--img-bg);
}

/* --- xizmat + byudjet bloki --- */
.service{
  margin-top:32px;
  padding:32px 30px 34px;
  border-radius:26px;
  background:var(--block-bg);
  color:var(--block-ink);
  transition:background .25s ease,color .25s ease;
}

.service-title{
  font-size:26px;
  font-weight:700;
  line-height:1.35;
  letter-spacing:-.02em;
}

.service-stat{
  margin-top:24px;
  padding-top:20px;
  border-top:1px solid var(--block-line);
}

.service-num{
  display:block;
  font-size:22px;
  font-weight:800;
  line-height:1.1;
  letter-spacing:-.03em;
}

.service-cap{
  display:block;
  margin-top:4px;
  font-size:13px;
  font-weight:600;
  line-height:1.4;
  opacity:.68;
}

/* --- ishlagan loyihalar --- */
.section-title{
  margin-top:36px;
  font-size:26px;
  font-weight:800;
  letter-spacing:-.03em;
  line-height:1.1;
}

.logos{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(140px,1fr));
  gap:14px;
  margin-top:20px;
}

.logo img{
  display:block;
  width:100%;
  aspect-ratio:1;
  object-fit:cover;
  border-radius:16px;
  background:var(--img-bg);
}

.logo figcaption{
  margin-top:9px;
  text-align:center;
  font-size:12px;
  font-weight:600;
  line-height:1.3;
  color:var(--muted);
}

/* --- ishlarim --- */
.works{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(250px,1fr));
  gap:16px;
  margin-top:20px;
}

.work{
  border:1px solid var(--faint);
  border-radius:22px;
  overflow:hidden;
  background:var(--btn2-bg);
}

.work-img{
  aspect-ratio:16/9;
  background:var(--img-bg);
  display:flex;
  align-items:center;
  justify-content:center;
  color:var(--muted);
  font-size:13px;
  font-weight:600;
}

.work-img img{width:100%;height:100%;object-fit:cover;display:block}

.work-body{padding:18px 20px 22px}

.work h3{
  font-size:19px;
  font-weight:700;
  letter-spacing:-.015em;
}

.work p{margin-top:6px;font-size:15px;color:var(--muted)}

/* --- mijozlar fikri --- */
.reviews{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(230px,1fr));
  gap:14px;
  margin-top:20px;
}

.review{
  padding:24px 22px 22px;
  border:1px solid var(--faint);
  border-radius:22px;
  background:var(--btn2-bg);
}

.rev-mono{
  width:46px;height:46px;
  border-radius:999px;
  display:flex;align-items:center;justify-content:center;
}

.rev-mono svg{width:22px;height:22px}
.rev-1{background:var(--mono-bg);color:var(--mono-ink)}
.rev-2{background:var(--pill-bg);color:var(--pill-ink)}
.rev-3{background:var(--sun-bg);color:var(--sun-ink)}

.rev-text{margin-top:16px;font-size:16px;line-height:1.55}

.rev-name{
  margin-top:12px;
  font-size:14px;
  font-weight:600;
  color:var(--muted);
}

/* vaqtinchalik matn - haqiqiy matn kelguncha */
.placeholder{
  color:var(--muted);
  font-style:italic;
  opacity:.7;
}

/* --- savol-javob --- */
.faq{
  margin-top:20px;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.faq-item{
  border:1px solid var(--faint);
  border-radius:18px;
  background:var(--btn2-bg);
  overflow:hidden;
}

/* savol tugmasi */
.faq-q{
  width:100%;
  padding:20px 22px;
  border:0;
  background:transparent;
  color:var(--ink);
  font-family:inherit;
  font-size:17px;
  font-weight:700;
  letter-spacing:-.01em;
  text-align:left;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  transition:background .18s ease;
}

.faq-q:hover{background:var(--btn2-hover)}

/* + belgisi, ochilganda 45° burilib × bo'ladi */
.faq-icon{
  position:relative;
  width:16px;height:16px;
  flex-shrink:0;
  transition:transform .25s ease;
}

.faq-icon::before,
.faq-icon::after{
  content:"";
  position:absolute;
  background:var(--muted);
  border-radius:2px;
}

.faq-icon::before{left:0;top:7px;width:16px;height:2px}
.faq-icon::after{top:0;left:7px;width:2px;height:16px}

.faq-item.open .faq-icon{transform:rotate(45deg)}

/* javob: 0fr -> 1fr silliq ochiladi */
.faq-a{
  display:grid;
  grid-template-rows:0fr;
  transition:grid-template-rows .25s ease;
}

.faq-item.open .faq-a{grid-template-rows:1fr}

.faq-a-inner{overflow:hidden}

.faq-a p{
  padding:0 22px 22px;
  color:var(--muted);
  font-size:16px;
}

/* --- aloqa bo'limi --- */
.contact{margin-top:8px}
.contact-title{margin-top:36px}
.contact .note{margin-top:8px;text-align:left}

/* --- aloqa tugmalari --- */
.actions{margin-top:28px;display:flex;flex-direction:column;gap:12px}

/* aloqa bo'limida yonma-yon */
.actions-row{flex-direction:row;flex-wrap:wrap}
.actions-row .btn{flex:1 1 240px}

/* hero'da ixcham, yonma-yon */
.actions-hero{flex-direction:row;flex-wrap:wrap;gap:10px}
.actions-hero .btn{flex:0 0 auto}

/* o'q belgisi doira ichida */
.btn-arrow{padding-right:8px;gap:14px}

.btn-circle{
  width:32px;height:32px;
  border-radius:999px;
  background:rgba(255,255,255,.16);
  display:flex;align-items:center;justify-content:center;
  flex-shrink:0;
}

.btn-circle svg{width:15px;height:15px}
.btn-arrow:hover .btn-circle{background:rgba(255,255,255,.26)}

:root[data-theme="dark"] .btn-circle{background:rgba(0,0,0,.14)}
:root[data-theme="dark"] .btn-arrow:hover .btn-circle{background:rgba(0,0,0,.22)}

.btn{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  padding:18px 22px;
  border-radius:999px;
  text-decoration:none;
  font-size:16px;
  font-weight:600;
  transition:transform .18s ease,box-shadow .18s ease,background .18s ease,color .18s ease;
}

.btn:hover{transform:translateY(-2px)}

.btn-primary{
  background:var(--btn1-bg);
  color:var(--btn1-ink);
  box-shadow:0 6px 18px rgba(0,0,0,.16);
}

.btn-secondary{
  background:var(--btn2-bg);
  color:var(--ink);
  border:1.5px solid var(--faint);
}

.btn-secondary:hover{background:var(--btn2-hover)}
.btn svg{width:19px;height:19px;flex-shrink:0}

.note{
  margin-top:24px;
  text-align:center;
  font-size:14px;
  color:var(--muted);
}

/* ============================================
   JONLANISH
   ============================================ */

/* --- 1. scroll qilganda pastdan ko'tarilib chiqish --- */
.reveal{
  opacity:0;
  transform:translateY(14px);
  transition:opacity .35s ease-out,transform .35s ease-out;
}

.reveal.in{opacity:1;transform:none}

/* katakdagi elementlar ketma-ket chiqadi */
.works .reveal:nth-child(2),
.reviews .reveal:nth-child(2),
.logos .reveal:nth-child(2),
.faq .reveal:nth-child(2){transition-delay:.06s}

.works .reveal:nth-child(3),
.reviews .reveal:nth-child(3),
.logos .reveal:nth-child(3){transition-delay:.12s}

.logos .reveal:nth-child(4){transition-delay:.18s}
.logos .reveal:nth-child(5){transition-delay:.24s}
.logos .reveal:nth-child(6){transition-delay:.30s}
.logos .reveal:nth-child(7){transition-delay:.36s}
.logos .reveal:nth-child(8){transition-delay:.42s}
.logos .reveal:nth-child(9){transition-delay:.48s}

/* --- 2. kartalar ustiga sichqoncha kelganda --- */
.work,
.review,
.logo{transition:transform .18s ease,box-shadow .18s ease}

.work:hover,
.review:hover{
  transform:translateY(-3px);
  box-shadow:0 10px 26px rgba(0,0,0,.09);
}

.logo:hover{transform:translateY(-3px)}
.faq-item:hover{border-color:var(--muted)}

/* paydo bo'lish tugagach hover ishlashi uchun */
.reveal.in.work:hover,
.reveal.in.review:hover,
.reveal.in.logo:hover{transform:translateY(-3px)}

/* --- 4. sahifa ochilganda hero yumshoq chiqadi --- */
@keyframes rise{
  from{opacity:0;transform:translateY(12px)}
  to{opacity:1;transform:none}
}

.hero-text > *{animation:rise .5s ease-out both}
.hero-text > *:nth-child(1){animation-delay:0s}
.hero-text > *:nth-child(2){animation-delay:.06s}
.hero-text > *:nth-child(3){animation-delay:.12s}
.hero-text > *:nth-child(4){animation-delay:.18s}
.hero-text > *:nth-child(5){animation-delay:.24s}
.hero-text > *:nth-child(6){animation-delay:.30s}

.hero-photo{animation:rise .5s ease-out .1s both}

/* --- 5. harakatni kamaytirish sozlamasi yoqilgan bo'lsa --- */
@media (prefers-reduced-motion: reduce){
  *,*::before,*::after{
    animation-duration:.01ms !important;
    animation-iteration-count:1 !important;
    transition-duration:.01ms !important;
    scroll-behavior:auto !important;
  }
  .reveal{opacity:1;transform:none}
}

/* --- telefon: menyu ikki qatorga bo'linadi --- */
@media (max-width:620px){
  .nav-inner{flex-wrap:wrap;gap:8px}

  .nav-links{
    order:3;
    width:100%;
    margin-top:-2px;
    padding-bottom:2px;
    /* o'ng chekkada xiralashish - surish mumkinligi bildiradi */
    -webkit-mask-image:linear-gradient(to right,#000 88%,transparent 100%);
    mask-image:linear-gradient(to right,#000 88%,transparent 100%);
  }

  /* barmoq bilan bosish qulay bo'lishi uchun balandlik */
  .nav-links a{
    display:flex;
    align-items:center;
    min-height:42px;
    padding:0 13px;
    font-size:14px;
  }

  .l-full{display:none}
  .l-short{display:inline}

  /* menyu balandroq bo'lgani uchun bo'lim ham pastroqdan boshlansin */
  [id]{scroll-margin-top:112px}
}

/* --- planshet / tor ekran: hero bir ustunga tushadi --- */
@media (max-width:760px){
  .hero{grid-template-columns:1fr;gap:28px}
  .hero-photo{order:-1}
  /* telefonda kvadrat va yuqoridan boshlanadi - bosh kesilmasin */
  .hero-photo{max-width:420px}
  .hero-photo img{aspect-ratio:1/1;object-position:center top;border-radius:20px}
  h1{font-size:44px}
  .about{max-width:none}
}

/* --- telefon uchun --- */
@media (max-width:480px){
  .card{padding:30px 24px;border-radius:26px;margin-top:20px}
  h1{font-size:38px}
  .mono{width:56px;height:56px;border-radius:17px;font-size:19px}
  .mono-sm{width:38px;height:38px;border-radius:12px;font-size:14px}
  .pill{padding:8px 12px;font-size:10px;letter-spacing:.08em}
  .theme-btn{width:36px;height:36px}
  .nav-inner{gap:10px;padding:10px 0}
  .nav-links a{padding:7px 11px;font-size:13px}
  .faq-q{padding:17px 18px;font-size:16px}
  .faq-a p{padding:0 18px 18px;font-size:15px}
  /* ustun holatida flex-basis balandlikka aylanadi -
     shuning uchun uni bekor qilamiz, aks holda tugma cho'ziladi */
  .actions-row{flex-direction:column}
  .actions-row .btn{flex:0 0 auto}
  .actions-hero{flex-direction:column}
  .actions-hero .btn{flex:0 0 auto}
  .eyebrow{font-size:13px}
  .proof-logos img{width:34px;height:34px;border-radius:10px}
  .service{padding:26px 22px 28px;border-radius:22px}
  .service-title{font-size:21px}
  .service-stat{margin-top:20px;padding-top:16px}
  .service-num{font-size:20px}
  .service-cap{font-size:12px}
  .section-title{font-size:22px;margin-top:30px}
  .logos{grid-template-columns:repeat(auto-fill,minmax(104px,1fr));gap:10px}
  .logo figcaption{font-size:11px}
}
