/* Faqja publike e abonimit — subscribe.supershpejt.com.
   Ngarkohet pas tokens.css (ngjyrat, fonti, rrezet, hijet). Mobile-first: stilet
   bazë janë për telefonin; pikat e kthesës vetëm shtojnë hapësirë dhe kolona.
   Asnjë `style=` te HTML-ja (CSP) — çdo pamje jeton këtu.
   Këtu stilohen edhe faqet e gabimit të serverit (body.error-page / main.error-card). */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: 16px;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--fg);
  background-color: var(--bg);
  /* Dritë e ngrohtë terrakote në skaje — dekor, pa imazh. */
  background-image:
    radial-gradient(70rem 36rem at 105% -12%, color-mix(in oklch, var(--brand-100) 85%, transparent), transparent 62%),
    radial-gradient(48rem 30rem at -18% 8%, color-mix(in oklch, var(--gold-400) 14%, transparent), transparent 60%);
  background-repeat: no-repeat;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

::selection {
  background: var(--brand-100);
  color: var(--brand-950);
}

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

a {
  color: var(--brand-700);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 3px solid var(--ring);
  outline-offset: 3px;
}

strong {
  font-weight: 700;
}

.nowrap {
  white-space: nowrap;
}

.icon {
  width: 1.25rem;
  height: 1.25rem;
  flex: none;
}

.icon--lg {
  width: 2rem;
  height: 2rem;
  stroke-width: 2.5;
}

/* ── Skeleti ─────────────────────────────────────────────────────────── */

.skip-link {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  background: var(--fg);
  color: var(--surface);
  font-weight: 700;
  text-decoration: none;
}

.skip-link:focus {
  top: 12px;
}

.page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

.site-main {
  flex: 1 0 auto;
}

.site-main:focus {
  outline: none;
}

.container {
  width: min(100% - 32px, 1080px);
  margin-inline: auto;
}

.container.narrow {
  width: min(100% - 32px, 560px);
  padding-block: 16px 56px;
}

.site-header {
  padding-block: 16px;
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  color: var(--fg);
  text-decoration: none;
  border-radius: var(--radius-sm);
}

.brand__logo {
  width: 40px;
  height: 40px;
}

.brand__name {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1;
}

.brand__accent {
  color: var(--brand-600);
}

.site-header__link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: color-mix(in oklch, var(--surface) 70%, transparent);
  color: var(--fg-muted);
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.15s, border-color 0.15s, background-color 0.15s;
}

.site-header__link:hover {
  color: var(--brand-700);
  border-color: var(--brand-200);
  background: var(--brand-50);
}

@media (max-width: 359px) {
  .site-header__link {
    display: none;
  }
}

.site-footer {
  margin-top: 24px;
  padding-block: 24px 32px;
  border-top: 1px solid var(--border);
  color: var(--fg-muted);
  font-size: 0.875rem;
}

.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
}

.site-footer__copy {
  margin: 0;
}

.site-footer__nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer__nav a {
  display: inline-block;
  padding-block: 8px;
  color: var(--fg-muted);
}

.site-footer__nav a:hover {
  color: var(--brand-700);
}

/* ── Kartat, njoftimet, butonat ──────────────────────────────────────── */

.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-lg);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 6px 12px;
  border: 1px solid var(--brand-200);
  border-radius: var(--radius-pill);
  background: var(--brand-50);
  color: var(--brand-800);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.2;
}

.eyebrow__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand-600);
  box-shadow: 0 0 0 0 color-mix(in oklch, var(--brand-600) 45%, transparent);
  animation: pulse 2.4s ease-out infinite;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 color-mix(in oklch, var(--brand-600) 45%, transparent);
  }
  70%,
  100% {
    box-shadow: 0 0 0 8px color-mix(in oklch, var(--brand-600) 0%, transparent);
  }
}

.alert {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 0 18px;
  padding: 12px 14px;
  border: 1px solid;
  border-radius: var(--radius);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.5;
}

.alert p {
  margin: 0;
}

.alert .icon {
  margin-top: 1px;
}

.alert--error {
  background: var(--danger-bg);
  border-color: color-mix(in oklch, var(--danger) 35%, transparent);
  color: var(--danger);
}

.alert--info {
  background: var(--info-bg);
  border-color: color-mix(in oklch, var(--info) 30%, transparent);
  color: var(--info);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px 22px;
  border: 1.5px solid transparent;
  border-radius: var(--radius);
  font: inherit;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s, box-shadow 0.15s, transform 0.1s;
}

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

.btn .icon {
  transition: transform 0.15s;
}

.btn--primary {
  background: var(--brand-600);
  color: var(--on-brand);
  box-shadow:
    inset 0 1px 0 color-mix(in oklch, white 18%, transparent),
    0 8px 20px -8px color-mix(in oklch, var(--brand-600) 75%, transparent);
}

.btn--primary:hover {
  background: var(--brand-700);
}

.btn--primary:hover .icon {
  transform: translateX(3px);
}

.btn--dark {
  background: var(--fg);
  color: var(--surface);
  box-shadow: var(--shadow-md);
}

.btn--dark:hover {
  background: var(--brand-950);
}

.btn--ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--brand-700);
}

.btn--ghost:hover {
  background: var(--brand-50);
  border-color: var(--brand-200);
}

.btn--lg {
  min-height: 56px;
  border-radius: 14px;
  font-size: 1.0625rem;
}

.btn--block {
  width: 100%;
}

.btn:disabled,
.btn.is-busy {
  cursor: progress;
}

.btn.is-busy {
  opacity: 0.88;
}

.btn.is-busy .icon {
  display: none;
}

.btn.is-busy::after {
  content: '';
  width: 18px;
  height: 18px;
  border: 2.5px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 28px;
}

.actions .btn {
  flex: 1 1 210px;
}

/* ── Format ──────────────────────────────────────────────────────────── */

.form {
  display: grid;
  gap: 18px;
}

.form__row--split {
  display: grid;
  gap: 18px;
}

@media (min-width: 480px) {
  .form__row--split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
}

.field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.field__label {
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--fg);
}

.input,
.select {
  width: 100%;
  min-height: 52px;
  margin: 0;
  padding: 12px 16px;
  border: 1.5px solid var(--border-field);
  border-radius: var(--radius);
  background-color: var(--surface);
  color: var(--fg);
  font: inherit;
  font-size: 1rem; /* ≥ 16px: iOS nuk e zmadhon faqen te fokusi */
  line-height: 1.4;
  transition: border-color 0.15s, background-color 0.15s, box-shadow 0.15s;
  -webkit-appearance: none;
  appearance: none;
}

.input::placeholder {
  color: var(--fg-subtle);
  opacity: 1;
}

.input:hover,
.select:hover {
  border-color: var(--fg-muted);
}

.input:focus,
.select:focus {
  outline: 3px solid var(--ring);
  outline-offset: 2px;
  border-color: var(--brand-600);
}

.input--phone {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}

.select {
  padding-right: 46px;
  cursor: pointer;
  text-overflow: ellipsis;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2367544b' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 20px 20px;
}

.select:invalid,
.select option[value=''] {
  color: var(--fg-muted);
}

.select option,
.select optgroup {
  color: var(--fg);
}

.field--invalid .input,
.field--invalid .select {
  border-color: var(--danger);
  background-color: color-mix(in oklch, var(--danger-bg) 55%, var(--surface));
}

.field__hint,
.field__preview,
.field__error {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.45;
}

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

.field__error,
.field__preview {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  font-weight: 600;
}

.field__error {
  color: var(--danger);
}

/* `subscribe.js` e fsheh gabimin e serverit sapo numri ndryshon; `display: flex` më
   sipër do ta mundte `[hidden]`-in e shfletuesit. */
.field__error[hidden] {
  display: none;
}

.field__error::before,
.field__preview.is-error::before,
.field__preview.is-ok::before {
  flex: none;
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  margin-top: 1px;
  border-radius: 50%;
  color: var(--on-brand);
  font-size: 0.75rem;
  font-weight: 800;
  line-height: 1;
}

.field__error::before,
.field__preview.is-error::before {
  content: '!';
  background: var(--danger);
}

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

/* Bosh, rajoni i gjallë mbetet te DOM-i (lexuesit e ekranit e ndjekin), por pa zënë vend. */
.field__preview:empty {
  margin-top: -6px;
}

.field__preview.is-ok {
  color: var(--success);
}

.field__preview.is-ok::before {
  content: '✓';
  background: var(--success);
}

.field__preview.is-error {
  color: var(--danger);
}

/* Fusha-kurth: jashtë ekranit, jo `display:none` (disa robotë e kapërcejnë atë). */
.hp {
  position: absolute !important;
  left: -10000px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Turnstile «flexible» kërkon ≥ 300 px: në telefonat e ngushtë (360 px) zë edhe
   një pjesë të mbushjes së kartës, që të mos dalë jashtë saj. */
.turnstile {
  display: flex;
  justify-content: center;
  min-height: 65px;
  margin-inline: -10px;
}

@media (min-width: 480px) {
  .turnstile {
    margin-inline: 0;
  }
}

.consent {
  margin: 2px 0 0;
  color: var(--fg-muted);
  font-size: 0.875rem;
  line-height: 1.55;
}

/* ── Faqja kryesore ──────────────────────────────────────────────────── */

.home {
  display: grid;
  grid-template-areas:
    'hero'
    'form'
    'perks';
  gap: 24px;
  padding-block: 8px 48px;
}

.hero {
  grid-area: hero;
  min-width: 0;
}

.hero__title {
  margin: 14px 0 12px;
  font-size: clamp(2rem, 1.3rem + 3.2vw, 3.5rem);
  font-weight: 800;
  line-height: 1.07;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.hero__lead {
  max-width: 34em;
  margin: 0;
  color: var(--fg-muted);
  font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem);
  line-height: 1.55;
  text-wrap: pretty;
}

.form-card {
  grid-area: form;
  min-width: 0;
  padding: 26px 18px 22px;
  /* Vija e markës në krye: sfond (jo element), që ta presë vetë rrezja e kartës
     pa «overflow: hidden» — widget-i i Turnstile duhet të mund të dalë jashtë. */
  background:
    linear-gradient(90deg, var(--brand-500), var(--brand-700) 55%, var(--gold-400)) top / 100% 4px no-repeat,
    var(--surface);
}

.form-card__head {
  margin-bottom: 20px;
}

.form-card__title {
  margin: 0;
  font-size: 1.3125rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.form-card__subtitle {
  margin: 4px 0 0;
  color: var(--fg-muted);
  font-size: 0.9375rem;
}

.perks {
  grid-area: perks;
  min-width: 0;
}

.perks__list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.perk {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  background: color-mix(in oklch, var(--surface) 72%, transparent);
}

.perk__icon {
  display: grid;
  flex: none;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--brand-100);
  border-radius: 12px;
  background: var(--brand-50);
  color: var(--brand-600);
}

.perk__icon .icon {
  width: 22px;
  height: 22px;
}

.perk__text {
  color: var(--fg-muted);
  font-size: 0.9375rem;
  line-height: 1.5;
}

.perk__text strong {
  display: block;
  margin-bottom: 2px;
  color: var(--fg);
  font-size: 1rem;
}

@media (min-width: 480px) {
  .form-card {
    padding: 30px 28px 28px;
  }
}

@media (min-width: 640px) and (max-width: 919px) {
  .perks__list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .perk {
    flex-direction: column;
  }
}

@media (min-width: 920px) {
  .home {
    grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
    grid-template-areas:
      'hero form'
      'perks form';
    column-gap: 64px;
    row-gap: 36px;
    align-items: start;
    padding-block: 40px 80px;
  }

  .hero {
    align-self: end;
  }

  .form-card {
    padding: 36px 36px 32px;
  }

  .perk {
    padding: 0;
    border: 0;
    background: transparent;
  }
}

/* ── Faqet e rezultatit dhe e çregjistrimit ──────────────────────────── */

.result-card {
  padding: 36px 22px 32px;
  text-align: center;
}

.result-card__icon {
  display: inline-grid;
  place-items: center;
  width: 68px;
  height: 68px;
  margin-bottom: 18px;
  border-radius: 50%;
}

.result-card__icon--success {
  background: var(--success-bg);
  color: var(--success);
  box-shadow: 0 0 0 8px color-mix(in oklch, var(--success-bg) 45%, transparent);
}

.result-card__icon--warning {
  background: var(--warning-bg);
  color: var(--warning);
}

.result-card__icon--warning .icon {
  width: 2rem;
  height: 2rem;
}

.result-card__title,
.stop-card__title {
  margin: 0 0 10px;
  font-size: clamp(1.625rem, 1.3rem + 1.4vw, 2.125rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.15;
  text-wrap: balance;
}

.result-card__lead {
  max-width: 32em;
  margin: 0 auto 10px;
  font-size: 1.0625rem;
}

.result-card__text {
  max-width: 34em;
  margin: 0 auto;
  color: var(--fg-muted);
  font-size: 0.9375rem;
}

.stop-card {
  padding: 28px 18px 24px;
}

.stop-card__lead {
  margin: 0 0 22px;
  color: var(--fg-muted);
}

.stop-card__note {
  margin: 18px 0 0;
  color: var(--fg-muted);
  font-size: 0.875rem;
}

@media (min-width: 480px) {
  .result-card {
    padding: 44px 40px 40px;
  }

  .stop-card {
    padding: 36px 36px 32px;
  }

  .container.narrow {
    padding-block: 32px 72px;
  }
}

/* ── Njoftimi i privatësisë ──────────────────────────────────────────── */

.prose-wrap {
  width: min(100% - 32px, 860px);
  padding-block: 8px 56px;
}

.prose {
  padding: 28px 20px 32px;
  box-shadow: var(--shadow-md);
}

.prose h1 {
  margin: 14px 0 12px;
  font-size: clamp(1.75rem, 1.35rem + 1.8vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.12;
}

.prose h2 {
  margin: 36px 0 14px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.015em;
  line-height: 1.3;
  scroll-margin-top: 16px;
}

.prose p,
.prose li {
  max-width: 70ch;
}

.prose ul {
  margin: 0;
  padding-left: 1.25rem;
}

.prose li {
  margin: 6px 0;
}

.prose li::marker {
  color: var(--brand-600);
}

.prose__lead {
  margin: 0 0 8px;
  color: var(--fg-muted);
  font-size: 1.0625rem;
}

.prose__meta {
  margin: 0;
  color: var(--fg-subtle);
  font-size: 0.8125rem;
}

.toc {
  margin: 24px 0 0;
  padding: 16px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-muted);
}

.toc ol {
  margin: 0;
  padding-left: 1.25rem;
}

.toc li {
  margin: 0;
  padding-block: 4px;
  break-inside: avoid;
}

.toc a {
  font-weight: 600;
}

.facts {
  margin: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.facts > div {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
}

.facts > div + div {
  border-top: 1px solid var(--border);
}

.facts > div:nth-child(odd) {
  background: color-mix(in oklch, var(--surface-muted) 55%, var(--surface));
}

.facts dt {
  color: var(--fg);
  font-size: 0.9375rem;
  font-weight: 700;
}

.facts dd {
  margin: 0;
  color: var(--fg-muted);
}

.note {
  margin: 16px 0 0;
  padding: 12px 16px;
  border-left: 4px solid var(--gold-600);
  border-radius: var(--radius-sm);
  background: var(--warning-bg);
  color: var(--fg);
  font-size: 0.9375rem;
}

.prose .retention {
  margin: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  list-style: none;
}

.prose .retention li {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 2px 16px;
  max-width: none;
  margin: 0;
  padding: 12px 16px;
}

.prose .retention li + li {
  border-top: 1px solid var(--border);
}

.retention span {
  color: var(--fg-muted);
}

.retention strong {
  color: var(--fg);
}

@media (min-width: 640px) {
  .prose {
    padding: 44px 48px 48px;
  }

  .toc ol {
    columns: 2;
    column-gap: 32px;
  }

  .facts > div {
    grid-template-columns: 180px minmax(0, 1fr);
    gap: 20px;
  }
}

/* ── Faqet e gabimit të serverit (web/server.ts) ─────────────────────── */

body.error-page {
  display: grid;
  place-items: center;
  padding: 24px 16px;
}

main.error-card {
  width: min(100%, 460px);
  padding: 36px 28px 32px;
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  text-align: center;
}

main.error-card img {
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
}

main.error-card h1 {
  margin: 0 0 8px;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

main.error-card p {
  margin: 0 0 8px;
  color: var(--fg-muted);
}

main.error-card a {
  display: inline-block;
  margin-top: 8px;
  padding-block: 6px;
  font-weight: 700;
}

/* ── Printimi (njoftimi i privatësisë) ───────────────────────────────── */

@media print {
  body {
    background: none;
  }

  .site-header__link,
  .site-footer,
  .skip-link,
  .toc {
    display: none;
  }

  .card {
    border: 0;
    box-shadow: none;
  }
}
