/* ==========================================================================
   COMPONENTS — sayfanın her yerinde tekrar kullanılan parçalar
   ========================================================================== */

/* ---------- İkon ---------- */
.i {
  width: 1.125em;
  height: 1.125em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}
/* Dolgulu marka ikonları (WhatsApp, X, yıldız) */
.i .fill, symbol .fill { fill: currentColor; stroke: none; }

/* ---------- Butonlar ---------- */
.btn {
  --btn-h: 44px;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: var(--btn-h);
  padding-inline: 18px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: 0;
  white-space: nowrap;
  transition:
    background-color .2s var(--ease-out),
    border-color .2s var(--ease-out),
    color .2s var(--ease-out),
    box-shadow .2s var(--ease-out),
    transform .2s var(--ease-out);
}

.btn:active { transform: translateY(1px); }

.btn--sm { --btn-h: 38px; padding-inline: 14px; border-radius: 9px; }
.btn--lg { --btn-h: 52px; padding-inline: 22px; font-size: var(--fs-base); border-radius: 12px; }
.btn--block { display: flex; width: 100%; }

.btn--primary {
  background: var(--navy-900);
  color: #fff;
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / .12),
    0 1px 2px rgb(7 19 40 / .2),
    0 6px 16px -6px rgb(7 19 40 / .45);
}
.btn--primary:hover { background: var(--navy-800); }

.btn--ghost {
  background: var(--surface);
  border-color: var(--line-2);
  color: var(--ink);
  box-shadow: var(--shadow-xs);
}
.btn--ghost:hover { border-color: var(--ink-2); }

/* Koyu zemin üzerinde birincil buton */
.btn--white { background: #fff; color: var(--navy-900); box-shadow: 0 8px 20px -10px rgb(0 0 0 / .5); }
.btn--white:hover { background: var(--navy-50); }

.btn--wa { background: #1fa855; color: #fff; }
.btn--wa:hover { background: #1a9449; }

/* Koyu zemin üzerinde ikincil buton */
.btn--on-dark {
  background: rgb(255 255 255 / .06);
  border-color: rgb(255 255 255 / .22);
  color: #fff;
}
.btn--on-dark:hover { background: rgb(255 255 255 / .12); border-color: rgb(255 255 255 / .4); }

.btn__arrow { transition: transform .25s var(--ease-out); }
.btn:hover .btn__arrow { transform: translateX(3px); }

.link-quiet {
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--ink-2);
  transition: color .2s;
}
.link-quiet:hover { color: var(--ink); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--ink);
  border-bottom: 1px solid var(--line-2);
  padding-bottom: 2px;
  transition: border-color .2s;
}
.link-arrow .i { transition: transform .25s var(--ease-out); }
.link-arrow:hover { border-color: var(--ink); }
.link-arrow:hover .i { transform: translateX(3px); }

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line-2);
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink);
  transition: border-color .2s, background-color .2s, opacity .2s;
}
.icon-btn:hover:not(:disabled) { border-color: var(--ink); }
.icon-btn:disabled { opacity: .35; cursor: default; }
.icon-btn--sm { width: 32px; height: 32px; }

.icon-btns { display: flex; gap: 8px; }

/* ---------- Etiketler ---------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 28px;
  padding-inline: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  font-size: var(--fs-xs);
  color: var(--ink-2);
  white-space: nowrap;
}
.chip b {
  font-weight: 500;
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 5px;
  background: var(--navy-50);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding-inline: 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
}
.pill::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.pill--ok    { background: var(--green-100); color: var(--green-600); }
.pill--warn  { background: var(--amber-100); color: var(--amber-600); }
.pill--alert { background: var(--red-100);   color: var(--red-600); }

.avatar {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  flex: none;
  border-radius: 50%;
  background: var(--navy-100);
  color: var(--navy-800);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .02em;
}
.avatar--2 { background: var(--red-100); color: var(--red-600); }
.avatar--3 { background: var(--green-100); color: var(--green-600); }

/* ---------- Uygulama penceresi mockup'ı ---------- */
.mock {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.mock__bar {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 44px;
  padding-inline: 16px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
}

.mock__dots { display: flex; gap: 6px; }
.mock__dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--line-2); }

.mock__title {
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mock__rows { padding: 6px; }

.mock-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 12px;
  border-radius: 10px;
}
.mock-row + .mock-row { box-shadow: inset 0 1px 0 var(--line); }

.mock-row__main { display: grid; gap: 2px; min-width: 0; }
.mock-row__main b {
  font-size: var(--fs-sm);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.mock-row__main small { font-size: 12px; color: var(--muted); }
.mock-row__amount { font-size: 13px; color: var(--ink); white-space: nowrap; }

/* ---------- Listeler ---------- */
.check-list { display: grid; gap: 12px; }
.check-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: var(--fs-sm);
  color: var(--ink-2);
}
.check-list .i {
  margin-top: 2px;
  padding: 3px;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--green-100);
  color: var(--green-600);
  stroke-width: 2.5;
}
.check-list .is-gift .i { background: var(--red-100); color: var(--red-600); stroke-width: 2; }

/* ---------- Form ---------- */
.field { display: grid; gap: 8px; align-content: start; }

.field label,
.calc label {
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--ink);
}
.field label span,
.calc label span { font-weight: 400; color: var(--muted); margin-left: 4px; }

.field input,
.field textarea,
.select select {
  width: 100%;
  min-height: 46px;
  padding: 11px 14px;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  background: var(--surface);
  font-size: var(--fs-base);
  transition: border-color .2s, box-shadow .2s;
}
.field textarea { resize: vertical; min-height: 92px; }

.field input::placeholder,
.field textarea::placeholder { color: #a3a8b3; }

.field input:focus,
.field textarea:focus,
.select select:focus {
  outline: none;
  border-color: var(--navy-700);
  box-shadow: 0 0 0 4px rgb(30 58 109 / .12);
}

.field.has-error input { border-color: var(--red-600); }
.field.has-error input:focus { box-shadow: 0 0 0 4px rgb(211 20 28 / .12); }

.field__error {
  display: none;
  font-size: 12px;
  color: var(--red-600);
}
.has-error > .field__error,
.field__error.is-visible { display: block; }

.select { position: relative; }
.select select { appearance: none; padding-right: 40px; cursor: pointer; }
.select::after {
  content: "";
  position: absolute;
  right: 16px; top: 50%;
  width: 8px; height: 8px;
  border-right: 1.5px solid var(--muted);
  border-bottom: 1.5px solid var(--muted);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}

.checkbox {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: var(--fs-sm);
  color: var(--ink-2);
  cursor: pointer;
}
.checkbox input {
  appearance: none;
  flex: none;
  width: 20px; height: 20px;
  margin: 1px 0 0;
  border: 1px solid var(--line-2);
  border-radius: 6px;
  background: var(--surface);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background-color .15s, border-color .15s;
}
.checkbox input::after {
  content: "";
  width: 6px; height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: translateY(-1px) rotate(45deg) scale(0);
  transition: transform .2s var(--ease-spring);
}
.checkbox input:checked { background: var(--navy-900); border-color: var(--navy-900); }
.checkbox input:checked::after { transform: translateY(-1px) rotate(45deg) scale(1); }

/* ---------- Kaydırıcı (range) ---------- */
.range {
  --fill: 50%;
  appearance: none;
  width: 100%;
  height: 28px;
  background: transparent;
  cursor: pointer;
}
.range::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 999px;
  background: linear-gradient(to right, var(--navy-900) var(--fill), var(--navy-100) var(--fill));
}
.range::-moz-range-track { height: 6px; border-radius: 999px; background: var(--navy-100); }
.range::-moz-range-progress { height: 6px; border-radius: 999px; background: var(--navy-900); }
.range::-webkit-slider-thumb {
  appearance: none;
  width: 22px; height: 22px;
  margin-top: -8px;
  border-radius: 50%;
  border: 5px solid var(--surface);
  background: var(--navy-900);
  box-shadow: 0 0 0 1px var(--line-2), 0 2px 8px rgb(11 26 51 / .2);
  transition: transform .15s var(--ease-out);
}
.range::-moz-range-thumb {
  width: 12px; height: 12px;
  border-radius: 50%;
  border: 5px solid var(--surface);
  background: var(--navy-900);
  box-shadow: 0 0 0 1px var(--line-2), 0 2px 8px rgb(11 26 51 / .2);
}
.range:active::-webkit-slider-thumb { transform: scale(1.12); }
.range:focus-visible { outline: none; }
.range:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 4px rgb(30 58 109 / .2); }

/* ---------- "Canlı" rozeti ---------- */
.live {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-left: auto;
  padding: 4px 10px 4px 8px;
  border-radius: 999px;
  background: var(--green-100);
  color: var(--green-600);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.checkbox a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line-2); }
.checkbox a:hover { text-decoration-color: currentColor; }
