/* ============================================================== birga
   Kichik uchrashuv soʻrovnomasi — uslublar.
   Ranglar bitta joyda (:root), shriftlar Google Fonts dan.
   ================================================================== */

:root {
  --bg-1:        #FDF5F2;
  --bg-2:        #FBE9E4;
  --bg-3:        #F7DCD6;

  --ink:         #2B2120;
  --ink-2:       #5E4F4C;
  --muted:       #A3908B;
  --line:        #F2DED8;

  --rose:        #D6416A;
  --rose-2:      #E8618A;
  --rose-deep:   #B92F55;
  --rose-tint:   #FCEBF0;

  --card:        #FFFFFF;
  --card-soft:   #FFF9F7;

  --r-sm: 12px;
  --r-md: 18px;
  --r-lg: 26px;
  --r-pill: 999px;

  --shadow-sm: 0 2px 10px rgba(178, 104, 96, .07);
  --shadow-md: 0 14px 38px rgba(178, 104, 96, .12);
  --shadow-rose: 0 12px 30px rgba(214, 65, 106, .30);

  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'Outfit', 'Segoe UI', system-ui, sans-serif;
  --font-script: 'Caveat', cursive;

  --gutter: 16px;
}

* { box-sizing: border-box; }

/* `hidden` atributi har doim ustun boʻlsin — quyida display: grid/flex
   qoʻyilgan bloklar (modal, .custom-when) aks holda yashirilmaydi. */
[hidden] { display: none !important; }

html, body { margin: 0; padding: 0; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg-1);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  min-height: 100vh;
}

h1, h2 { font-family: var(--font-display); font-weight: 700; letter-spacing: -.5px; }
button, input, textarea { font: inherit; color: inherit; }

/* Emoji belgilar rangli chiqsin. Aks holda Windows'da Outfit fallback'i
   ularni oq-qora "symbol" shriftidan oladi va ikonkalar xunuk koʻrinadi. */
.ic, .choice-ic, .modal-pin {
  font-family: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif;
  font-style: normal;
}

/* ------------------------------------------------------------ dekor fon */
.bg { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
      background:
        radial-gradient(1100px 700px at 78% -10%, var(--bg-3) 0%, transparent 62%),
        radial-gradient(900px 620px at 4% 84%, #FBE4DC 0%, transparent 58%),
        linear-gradient(168deg, var(--bg-1) 0%, var(--bg-2) 100%); }

.blob { position: absolute; border-radius: 50%; filter: blur(2px); }
.blob-1 { width: 58vw; height: 58vw; max-width: 760px; max-height: 760px;
          right: -14vw; top: -26vw;
          background: radial-gradient(circle at 34% 34%, #FBDDD7 0%, #F9E3DD 55%, transparent 72%); }
.blob-2 { width: 34vw; height: 34vw; max-width: 430px; max-height: 430px;
          left: -13vw; bottom: -12vw;
          background: radial-gradient(circle at 60% 40%, #FAE0D8 0%, transparent 70%); }
.blob-3 { width: 16vw; height: 16vw; max-width: 200px; max-height: 200px;
          left: 6%; top: 18%;
          background: radial-gradient(circle, #FCE7E1 0%, transparent 72%); }

.spark { position: absolute; color: var(--rose); opacity: .35; font-size: 14px;
         animation: twinkle 4.5s ease-in-out infinite; }
.spark-1 { left: 4.5%; top: 17%; }
.spark-2 { left: 9.5%; bottom: 25%; font-size: 18px; animation-delay: 1.4s; }
.spark-3 { right: 12%; top: 62%; font-size: 11px; animation-delay: 2.6s; }
@keyframes twinkle { 0%,100% { opacity: .18; transform: scale(.85); }
                     50%     { opacity: .55; transform: scale(1.1); } }

/* yon yozuvlar */
.side-quote {
  position: fixed; left: 24px; bottom: 16%; z-index: 1; max-width: 130px;
  font-family: var(--font-display); font-style: italic; font-size: 19px;
  line-height: 1.45; color: #C8AFA9; padding-left: 14px;
  border-left: 2px solid #EBD3CD; transform: rotate(-4deg);
}
.side-quote em { color: var(--rose); font-style: italic; }

.side-note {
  position: fixed; right: 28px; bottom: 96px; z-index: 1; max-width: 130px;
  font-family: var(--font-script); font-size: 21px; line-height: 1.15;
  color: #CBAEA8; transform: rotate(-9deg); text-align: center;
}

/* --------------------------------------------------------------- karkas */
.shell {
  position: relative; z-index: 2;
  max-width: 1120px; margin: 0 auto;
  padding: 26px var(--gutter) 34px;
  min-height: 100vh; display: flex; flex-direction: column;
}

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

.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; color: inherit; }
.brand-mark {
  width: 40px; height: 40px; border-radius: 13px; display: grid; place-items: center;
  background: linear-gradient(145deg, var(--rose-2), var(--rose-deep));
  box-shadow: var(--shadow-rose);
}
.brand-mark svg { width: 21px; height: 21px; fill: #fff; }
.brand-name { font-family: var(--font-display); font-size: 27px; font-weight: 700; letter-spacing: -.6px; }

.topbar-tag { font-size: 12px; letter-spacing: 2.6px; font-weight: 500; color: var(--muted); }

/* ------------------------------------------------------------- progress */
/* Havolasiz kirilgan ekranda qadamlar chizigʻi keraksiz */
body.no-progress .progress { display: none; }

.progress { margin-top: 30px; }
.progress-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; }
.progress-title { font-size: 11px; letter-spacing: 2.8px; font-weight: 600; color: #B79E99; }
.progress-count { font-size: 12px; letter-spacing: 2.4px; font-weight: 500; color: #B79E99; font-variant-numeric: tabular-nums; }

.progress-track { height: 3px; border-radius: var(--r-pill); background: #F0DDD8; overflow: hidden; }
.progress-fill {
  height: 100%; width: 20%; border-radius: var(--r-pill);
  background: linear-gradient(90deg, var(--rose-2), var(--rose));
  transition: width .55s cubic-bezier(.4,.1,.2,1);
}

.progress-steps {
  list-style: none; margin: 11px 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(5, 1fr);
  font-size: 13px; font-weight: 500; color: #C6B2AD;
}
.progress-steps li { transition: color .35s ease; }
.progress-steps li:nth-child(n+2) { text-align: center; }
.progress-steps li:last-child { text-align: right; }
.progress-steps li.is-done { color: #D2A9B4; }
.progress-steps li.is-now { color: var(--rose); font-weight: 600; }

/* ---------------------------------------------------------------- sahna */
.stage { flex: 1; display: flex; align-items: center; padding: 26px 0 10px; }
.step { width: 100%; animation: stepIn .5s cubic-bezier(.22,.7,.3,1) both; }
@keyframes stepIn { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

.hero { display: grid; grid-template-columns: minmax(0,1fr) 380px; gap: 30px; align-items: center; }
/* min-width: 0 shart — boʻlmasa ichkaridagi `auto-fit` gridlar (choices,
   summary) oʻz kengligini oʻzlari belgilab, telefonda ekrandan chiqib ketadi. */
.hero > * { min-width: 0; }
.hero-text { max-width: 640px; min-width: 0; }

.eyebrow {
  display: flex; align-items: center; gap: 9px;
  margin: 0 0 20px; font-size: 12px; font-weight: 600;
  letter-spacing: 2.6px; color: var(--rose);
}
.eyebrow .ic { font-size: 15px; line-height: 1; }

h1 { margin: 0 0 22px; font-size: clamp(38px, 6.4vw, 70px); line-height: 1.02; }
h1 em { font-style: italic; color: var(--rose); }
.h1-tight { margin-bottom: 16px; }

.lead { margin: 0 0 26px; font-size: clamp(15px, 1.6vw, 18px); line-height: 1.6;
        color: var(--ink-2); font-weight: 300; max-width: 46ch; }

/* --------------------------------------------------------------- tugma */
.actions { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin-top: 6px; }

.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  border: 0; cursor: pointer; border-radius: var(--r-pill);
  padding: 16px 34px; font-size: 16px; font-weight: 600; letter-spacing: .1px;
  transition: transform .2s ease, box-shadow .25s ease, background .25s ease, color .2s ease;
}
a.btn { text-decoration: none; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn:not(:disabled):hover { transform: translateY(-2px); }
.btn:not(:disabled):active { transform: translateY(0); }
.btn:focus-visible { outline: 3px solid rgba(214,65,106,.35); outline-offset: 3px; }

.btn-primary {
  color: #fff; min-width: 240px;
  background: linear-gradient(135deg, var(--rose-2) 0%, var(--rose) 55%, var(--rose-deep) 100%);
  box-shadow: var(--shadow-rose);
}
.btn-primary:not(:disabled):hover { box-shadow: 0 16px 36px rgba(214,65,106,.38); }

.btn-ghost {
  background: rgba(255,255,255,.72); color: var(--ink-2);
  border: 1px solid var(--line); box-shadow: var(--shadow-sm);
}
.btn-ghost:not(:disabled):hover { background: #fff; color: var(--ink); }

.btn-soft {
  background: var(--rose-tint); color: var(--rose-deep);
  padding: 11px 18px; font-size: 14px; font-weight: 600; box-shadow: none;
}
.btn-soft:not(:disabled):hover { background: #FAD9E3; }

.btn-ic { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8;
          stroke-linecap: round; }
.arrow { font-size: 19px; line-height: 1; }
.ic-heart { color: #fff; }
.btn-ghost .ic-heart { color: var(--rose); }

.btn-shy { transition: transform .32s cubic-bezier(.3,1.4,.5,1), background .25s ease; }

/* ------------------------------------------------------------- ism maydoni */
.name-field { margin: 0 0 24px; max-width: 360px; }
.name-field label { display: block; font-size: 13px; font-weight: 500; color: var(--ink-2); margin-bottom: 7px; }
.name-field label span { color: var(--muted); font-weight: 300; }
.name-field input, .note-field textarea, .map-search input, .custom-when input {
  width: 100%; padding: 13px 16px; border-radius: var(--r-md);
  border: 1px solid var(--line); background: rgba(255,255,255,.85);
  font-size: 15px; transition: border-color .2s ease, box-shadow .2s ease;
}
.name-field input::placeholder, .note-field textarea::placeholder, .map-search input::placeholder { color: #C9B5B0; }
.name-field input:focus, .note-field textarea:focus, .map-search input:focus, .custom-when input:focus {
  outline: 0; border-color: var(--rose-2); box-shadow: 0 0 0 4px rgba(232,97,138,.13);
}

.note-field { display: block; margin: 20px 0 24px; max-width: 460px; }
.note-field > span { display: block; font-size: 13px; font-weight: 500; color: var(--ink-2); margin-bottom: 7px; }
.note-field > span em { color: var(--muted); font-style: normal; font-weight: 300; }
.note-field textarea { resize: vertical; min-height: 58px; font-family: inherit; }

.form-error { margin: 12px 0 0; font-size: 14px; color: var(--rose-deep); font-weight: 500; }
.fine { margin: 16px 0 0; font-size: 14px; color: var(--muted); }

/* -------------------------------------------------------------- vizual */
.hero-visual { position: relative; display: grid; place-items: center; min-height: 340px; }

.orbit { position: absolute; inset: 0; display: grid; place-items: center; }
.orbit svg { width: 100%; max-width: 330px; height: auto; animation: spin 46s linear infinite; }
.orbit ellipse { fill: none; stroke: #EFD4CE; stroke-width: 1; stroke-dasharray: 3 7; }
@keyframes spin { to { transform: rotate(360deg); } }

.dot { position: absolute; width: 7px; height: 7px; border-radius: 50%; }
.dot-a { background: var(--rose-2); top: 16%; right: 8%; }
.dot-b { background: #F0C24A; bottom: 20%; left: 12%; }
.dot-c { background: #EBA8BE; top: 34%; left: 4%; width: 5px; height: 5px; }

.orb {
  position: relative; width: 132px; height: 132px; border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(150deg, #F692AE 0%, var(--rose-2) 45%, var(--rose) 100%);
  box-shadow: 0 22px 50px rgba(214,65,106,.34), inset 0 -10px 24px rgba(155,26,66,.24);
  animation: float 6.5s ease-in-out infinite;
}
.orb svg { width: 62px; height: 62px; fill: #fff; }
.orb-beat { animation: float 6.5s ease-in-out infinite, beat 2.2s ease-in-out infinite; }
.orb-mute { background: linear-gradient(150deg, #E6CFCB, #CDB0AB); box-shadow: 0 18px 40px rgba(150,120,115,.25); animation: none; }
@keyframes float { 0%,100% { transform: translateY(-9px); } 50% { transform: translateY(9px); } }
@keyframes beat  { 0%,100% { box-shadow: 0 22px 50px rgba(214,65,106,.34), inset 0 -10px 24px rgba(155,26,66,.24); }
                   50%     { box-shadow: 0 22px 62px rgba(214,65,106,.52), inset 0 -10px 24px rgba(155,26,66,.24); } }

/* --------------------------------------------------------------- xarita */
.map-search { position: relative; max-width: 620px; margin: 0 0 8px; display: flex; align-items: center; }
.map-search input { padding-left: 44px; padding-right: 54px; }
.search-ic { position: absolute; left: 15px; width: 18px; height: 18px; fill: none;
             stroke: #C9B5B0; stroke-width: 1.9; stroke-linecap: round; pointer-events: none; }
.btn-mini {
  position: absolute; right: 7px; width: 36px; height: 36px; border: 0; cursor: pointer;
  border-radius: 50%; background: var(--rose-tint); display: grid; place-items: center;
  transition: background .2s ease, transform .2s ease;
}
.btn-mini:hover { background: #FAD9E3; transform: scale(1.05); }
.btn-mini svg { width: 18px; height: 18px; fill: none; stroke: var(--rose); stroke-width: 1.7; stroke-linecap: round; }

.search-results {
  list-style: none; margin: 0 0 12px; padding: 6px; max-width: 620px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-md);
  box-shadow: var(--shadow-md); max-height: 230px; overflow: auto;
}
.search-results li { padding: 11px 14px; border-radius: var(--r-sm); cursor: pointer;
                     font-size: 14px; color: var(--ink-2); line-height: 1.4; }
.search-results li:hover, .search-results li:focus { background: var(--rose-tint); color: var(--ink); outline: 0; }
.search-results li.empty { color: var(--muted); cursor: default; }

.map-card {
  display: grid; grid-template-columns: minmax(0,1fr) 320px;
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow-md);
  margin-bottom: 22px;
}
.map-holder { position: relative; min-height: 360px; background: #F3E7E3; }
#map { position: absolute; inset: 0; }

.map-hint {
  position: absolute; left: 50%; top: 14px; transform: translateX(-50%); z-index: 500;
  background: rgba(255,255,255,.94); border-radius: var(--r-pill);
  padding: 8px 18px; font-size: 13px; font-weight: 500; color: var(--ink-2);
  box-shadow: var(--shadow-sm); pointer-events: none; white-space: nowrap;
  transition: opacity .3s ease;
}
.map-hint.hide { opacity: 0; }

.map-loading {
  position: absolute; inset: 0; z-index: 600; display: flex; gap: 10px;
  align-items: center; justify-content: center;
  background: #F6EBE7; color: var(--ink-2); font-size: 14px;
}
.map-loading.hide { display: none; }
.spinner { width: 17px; height: 17px; border-radius: 50%; border: 2px solid #E3CCC6;
           border-top-color: var(--rose); animation: spin 0.9s linear infinite; }

.map-side { padding: 24px 22px; display: flex; flex-direction: column; gap: 6px;
            background: var(--card-soft); border-left: 1px solid var(--line); }
.map-side-label { margin: 0 0 4px; font-size: 11px; letter-spacing: 2.2px; font-weight: 600; color: var(--muted); }
.map-addr { margin: 0; font-size: 17px; font-weight: 600; line-height: 1.35; word-break: break-word; }
.map-coords { margin: 6px 0 16px; font-family: ui-monospace, 'Cascadia Mono', Consolas, monospace;
              font-size: 13px; color: var(--muted); }
.map-side-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.map-side-note { margin: auto 0 0; font-size: 12.5px; color: var(--muted); line-height: 1.5; padding-top: 16px; }

/* leaflet marker rangi */
.pin-marker { display: grid; place-items: center; }
.pin-marker svg { width: 34px; height: 44px; filter: drop-shadow(0 5px 7px rgba(150,40,70,.35));
                  animation: pinDrop .42s cubic-bezier(.2,1.5,.4,1) both; }
@keyframes pinDrop { from { transform: translateY(-16px) scale(.7); opacity: 0; } to { transform: none; opacity: 1; } }
.leaflet-container { font-family: var(--font-body) !important; background: #F3E7E3 !important; }

/* ---------------------------------------------------------- vaqt tanlash */
.choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
           gap: 12px; max-width: 640px; margin-bottom: 18px; }
.choice {
  display: flex; align-items: center; gap: 11px; text-align: left;
  padding: 17px 18px; border-radius: var(--r-md); cursor: pointer;
  background: #fff; border: 1.5px solid var(--line); color: var(--ink);
  font-size: 15px; font-weight: 500; box-shadow: var(--shadow-sm);
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.choice:hover { transform: translateY(-2px); border-color: #F0C3D0; }
.choice.is-on { border-color: var(--rose); background: #FFF4F7; box-shadow: 0 8px 20px rgba(214,65,106,.16); }
.choice.is-on::after { content: '✓'; margin-left: auto; color: var(--rose); font-weight: 700; }
.choice-ic { font-size: 19px; line-height: 1; }

.custom-when { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 4px; }
.custom-when label { font-size: 13px; font-weight: 500; color: var(--ink-2); }
.custom-when input { margin-top: 6px; min-width: 165px; }

/* --------------------------------------------------------------- xulosa */
.summary {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 8px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 22px 26px; margin-bottom: 26px; box-shadow: var(--shadow-sm); max-width: 640px;
}
.summary-label { margin: 0 0 7px; font-size: 11px; letter-spacing: 2.2px; font-weight: 600; color: var(--rose); }
.summary-value { margin: 0; font-size: 16px; font-weight: 600; line-height: 1.4; word-break: break-word; }

/* ---------------------------------------------------------------- modal */
.modal { position: fixed; inset: 0; z-index: 900; display: grid; place-items: center; padding: var(--gutter); }
.modal-backdrop { position: absolute; inset: 0; background: rgba(60,32,36,.42);
                  backdrop-filter: blur(4px); animation: fadeIn .25s ease both; }
.modal-card {
  position: relative; width: min(430px, 100%); background: #fff;
  border-radius: var(--r-lg); padding: 34px 30px 26px; text-align: center;
  box-shadow: 0 30px 70px rgba(90,40,50,.28);
  animation: popIn .32s cubic-bezier(.2,1.2,.4,1) both;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes popIn { from { opacity: 0; transform: translateY(18px) scale(.95); } to { opacity: 1; transform: none; } }

.modal-pin { display: grid; place-items: center; width: 54px; height: 54px; margin: 0 auto 16px;
             border-radius: 50%; background: var(--rose-tint); font-size: 25px; }
.modal-card h2 { margin: 0 0 12px; font-size: 25px; line-height: 1.22; }
.modal-addr { margin: 0 0 6px; font-size: 15px; font-weight: 500; color: var(--ink-2); line-height: 1.45; }
.modal-coords { margin: 0 0 22px; font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; color: var(--muted); }
.modal-actions { display: flex; flex-direction: column; gap: 10px; }
.modal-actions .btn { width: 100%; min-width: 0; padding: 14px 20px; }

/* ---------------------------------------------------------------- toast */
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%);
  z-index: 950; background: var(--ink); color: #fff;
  padding: 12px 22px; border-radius: var(--r-pill); font-size: 14px; font-weight: 500;
  box-shadow: 0 12px 30px rgba(43,33,32,.3); animation: toastIn .3s ease both;
}
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 12px); } to { opacity: 1; transform: translate(-50%, 0); } }

.foot { text-align: center; font-size: 12.5px; color: var(--muted); padding-top: 20px; }
.foot .ic-heart { color: var(--rose); }

/* ------------------------------------------------------------ moslashuv */
/* Yon yozuvlar faqat kontent chetida joy qolganda koʻrinsin —
   aks holda tugmalar ustiga chiqib ketadi (1120 + 2×145 ≈ 1410). */
@media (max-width: 1410px) {
  .side-quote, .side-note { display: none; }
}

@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; gap: 24px; }
  .hero-visual { order: -1; min-height: 190px; }
  .orb { width: 104px; height: 104px; }
  .orb svg { width: 48px; height: 48px; }
  .orbit svg { max-width: 230px; }
  .map-card { grid-template-columns: 1fr; }
  .map-side { border-left: 0; border-top: 1px solid var(--line); }
  .map-holder { min-height: 320px; }
}

@media (max-width: 620px) {
  .shell { padding: 18px var(--gutter) 26px; }
  .topbar-tag { display: none; }
  .spark { display: none; }
  .choices, .summary { grid-template-columns: 1fr; }
  .custom-when { flex-direction: column; gap: 10px; }
  .custom-when input { min-width: 0; width: 100%; }
  .brand-name { font-size: 23px; }
  .progress { margin-top: 22px; }
  .progress-steps { font-size: 10.5px; gap: 2px; }
  .progress-title { font-size: 10px; letter-spacing: 1.8px; }
  .stage { padding: 20px 0 6px; align-items: flex-start; }
  h1 { font-size: clamp(32px, 9.6vw, 44px); }
  .lead { font-size: 15px; }
  .actions { flex-direction: column; align-items: stretch; }
  .btn { width: 100%; min-width: 0; padding: 15px 22px; }
  .hero-visual { min-height: 150px; }
  .orbit svg { max-width: 190px; }
  .map-holder { min-height: 300px; }
  .map-side { padding: 20px 18px; }
  .name-field, .note-field { max-width: none; }
  .map-hint { font-size: 12px; padding: 7px 14px; }
  .modal-card { padding: 28px 22px 22px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important;
                           transition-duration: .01ms !important; }
}
