/* Homepage — editorial trailhead aesthetic: dawn wash, topographic
   overlay, DM Serif Display headings, Geist body, generous rhythm,
   product screenshots as the visual anchor of each section. */

/* ---------- Page backdrop ---------- */

.ts-home {
  position: relative;
  isolation: isolate;
  font-family: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text-primary);
  background:
    radial-gradient(ellipse 55% 40% at 82% 12%, rgba(242,100,25,0.10), transparent 60%),
    radial-gradient(ellipse 55% 45% at 12% 92%, rgba(74,107,138,0.08), transparent 65%),
    linear-gradient(180deg, #FBFAF7 0%, #F4F3EF 100%);
}

.ts-home::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image: url("/images/auth-topo.svg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.06;
  pointer-events: none;
}

.ts-home::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.1 0 0 0 0 0.1 0 0 0 0 0.1 0 0 0 0.35 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)' opacity='0.6'/></svg>");
  opacity: 0.06;
  mix-blend-mode: multiply;
  pointer-events: none;
}

.ts-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Hero ---------- */

.ts-hero {
  position: relative;
  padding: 100px 0 48px;
}

.ts-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: 56px;
  align-items: center;
}

.ts-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--flame);
  margin-bottom: 14px;
  padding: 5px 11px;
  background: rgba(242,100,25,0.08);
  border: 1px solid rgba(242,100,25,0.18);
  border-radius: 999px;
  animation: ts-in 640ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.ts-hero__eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--flame);
  box-shadow: 0 0 0 3px rgba(242,100,25,0.2);
}

.ts-hero__title {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: clamp(40px, 5.2vw, 68px);
  font-weight: 600;
  line-height: 1.04;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin: 0 0 16px;
  animation: ts-in 700ms cubic-bezier(0.22, 1, 0.36, 1) 80ms both;
}

.ts-hero__title em {
  font-style: italic;
  font-weight: 500;
  color: var(--flame);
  background: linear-gradient(135deg, #F26419 0%, #FF8A50 60%, #D44D00 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.ts-hero__subtitle {
  font-size: clamp(15px, 1.3vw, 17px);
  line-height: 1.55;
  color: var(--text-secondary);
  max-width: 520px;
  margin: 0 0 24px;
  animation: ts-in 700ms cubic-bezier(0.22, 1, 0.36, 1) 160ms both;
}

.ts-hero__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  margin-bottom: 20px;
  animation: ts-in 700ms cubic-bezier(0.22, 1, 0.36, 1) 240ms both;
}

.ts-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Geist', sans-serif;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.01em;
  padding: 14px 22px;
  border-radius: 12px;
  text-decoration: none;
  transition: transform 120ms ease, box-shadow 160ms ease, filter 160ms ease, background 160ms ease;
  cursor: pointer;
  border: 0;
}

.ts-btn--flame {
  background: linear-gradient(180deg, #F26419 0%, #D44D00 100%);
  color: #FFFFFF;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.2) inset,
    0 6px 18px -4px rgba(242,100,25,0.45),
    0 1px 2px rgba(26,26,26,0.08);
}

.ts-btn--flame:hover {
  filter: brightness(1.04);
  color: #FFFFFF;
  text-decoration: none;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.22) inset,
    0 10px 24px -4px rgba(242,100,25,0.55),
    0 1px 2px rgba(26,26,26,0.1);
}

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

.ts-btn--ghost {
  background: rgba(255,255,255,0.6);
  color: var(--text-primary);
  border: 1px solid rgba(26,26,26,0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.ts-btn--ghost:hover {
  background: #FFFFFF;
  border-color: rgba(26,26,26,0.18);
  color: var(--text-primary);
  text-decoration: none;
}

.ts-btn svg { width: 16px; height: 16px; }

.ts-hero__stores {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  list-style: none;
  animation: ts-in 700ms cubic-bezier(0.22, 1, 0.36, 1) 320ms both;
}

.ts-hero__stores img {
  height: 40px;
  width: auto;
  display: block;
  border-radius: 8px;
  transition: transform 140ms ease, filter 140ms ease;
}

.ts-hero__stores a:hover img {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

/* Trust strip — inline in the hero */
.ts-hero__trust {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(26,26,26,0.06);
  animation: ts-in 700ms cubic-bezier(0.22, 1, 0.36, 1) 400ms both;
}

.ts-hero__trust .ts-trust__label {
  font-size: 11px;
}

.ts-hero__trust .ts-trust__logos {
  gap: 18px;
}

.ts-hero__trust .ts-trust__logos img {
  height: 26px;
}

/* Hero visual — phone frame with floating accent tiles */
.ts-hero__visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  animation: ts-in 900ms cubic-bezier(0.22, 1, 0.36, 1) 200ms both;
}

.ts-hero__phone-wrap {
  position: relative;
  width: 100%;
  max-width: 360px;
}

.ts-hero__phone-wrap::before {
  content: "";
  position: absolute;
  inset: -8% -18% -12% -18%;
  background: radial-gradient(ellipse at center, rgba(242,100,25,0.22), transparent 70%);
  filter: blur(40px);
  z-index: -1;
  animation: ts-pulse 4s ease-in-out infinite;
}

.ts-hero__phone {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 30px 60px rgba(26,26,26,0.18));
  animation: ts-float 6s ease-in-out infinite;
}

@keyframes ts-float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

@keyframes ts-pulse {
  0%, 100% { opacity: 0.7; }
  50%      { opacity: 1; }
}

/* Floating accent chips around the phone */
.ts-hero__chip {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Geist', sans-serif;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-primary);
  padding: 10px 14px;
  background: #FFFFFF;
  border: 1px solid rgba(26,26,26,0.08);
  border-radius: 12px;
  box-shadow: 0 10px 24px -8px rgba(26,26,26,0.18), 0 1px 2px rgba(26,26,26,0.04);
  animation: ts-chip-in 700ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.ts-hero__chip svg { width: 16px; height: 16px; color: var(--flame); }

.ts-hero__chip--distance { top: 8%; left: -8%; animation-delay: 420ms; }
.ts-hero__chip--elev     { bottom: 26%; right: -12%; animation-delay: 560ms; }
.ts-hero__chip--export   { bottom: 4%; left: -4%; animation-delay: 700ms; }

@keyframes ts-chip-in {
  from { opacity: 0; transform: translateY(6px) scale(0.95); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* ---------- Trust strip ---------- */

.ts-trust {
  padding: 32px 0 24px;
}

.ts-trust__inner {
  display: flex;
  align-items: center;
  gap: 32px;
  flex-wrap: wrap;
  padding: 18px 24px;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(26,26,26,0.06);
  border-radius: 16px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.ts-trust__label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  flex-shrink: 0;
}

.ts-trust__logos {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
}

.ts-trust__logos img {
  height: 30px;
  width: auto;
  opacity: 0.78;
  filter: grayscale(0.2);
  transition: opacity 160ms ease, filter 160ms ease;
}

.ts-trust__logos a:hover img {
  opacity: 1;
  filter: grayscale(0);
}

/* ---------- Section heading ---------- */

.ts-section {
  padding: 96px 0;
  position: relative;
}

.ts-section--alt {
  padding: 112px 0;
}

.ts-section__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 40px;
}

.ts-section__eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--flame);
  margin: 0 0 10px;
}

.ts-section__title {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: clamp(28px, 3vw, 40px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.015em;
  color: var(--text-primary);
  margin: 0;
  max-width: 560px;
}

.ts-section__link {
  font-family: 'Geist', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--flame);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  padding-bottom: 6px;
  transition: color 140ms ease, gap 160ms ease;
}

.ts-section__link:hover {
  color: var(--flame-dark);
  gap: 10px;
  text-decoration: none;
}

.ts-section__link svg { width: 14px; height: 14px; }

/* ---------- Events strip ---------- */

.ts-events__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 18px;
}

.ts-event-card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  background: #FFFFFF;
  border: 1px solid rgba(26,26,26,0.06);
  border-radius: 18px;
  transition: transform 180ms ease, box-shadow 200ms ease, border-color 180ms ease;
}

.ts-event-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 28px -14px rgba(26,26,26,0.2);
  border-color: rgba(242,100,25,0.3);
  color: inherit;
  text-decoration: none;
}

.ts-event-card__media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #F0F1F3 0%, #E4E5E7 100%);
}

.ts-event-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms ease;
}

.ts-event-card:hover .ts-event-card__media img { transform: scale(1.04); }

.ts-event-card__media-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(26,26,26,0.12);
}

.ts-event-card__media-fallback svg { width: 48px; height: 48px; }

.ts-event-card__date-chip {
  position: absolute;
  top: 12px;
  left: 12px;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 54px;
  padding: 8px 10px 6px;
  background: rgba(255,255,255,0.96);
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(26,26,26,0.12);
  font-family: 'Geist', sans-serif;
  line-height: 1;
}

.ts-event-card__date-chip__day {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.ts-event-card__date-chip__month {
  font-size: 10px;
  font-weight: 600;
  color: var(--flame);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-top: 3px;
}

.ts-event-card__body {
  padding: 16px 16px 18px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ts-event-card__title {
  font-family: 'Geist', sans-serif;
  font-size: 15.5px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ts-event-card__location {
  font-size: 13px;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.ts-event-card__location svg { width: 12px; height: 12px; }

.ts-events__empty {
  padding: 40px 20px;
  text-align: center;
  color: var(--text-muted);
  background: rgba(255,255,255,0.5);
  border: 1px dashed rgba(26,26,26,0.1);
  border-radius: 16px;
}

/* ---------- Editorial feature blocks ---------- */

.ts-feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 72px;
  align-items: center;
  padding: 56px 0;
}

.ts-feature--reverse .ts-feature__visual { order: -1; }

.ts-feature__eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--flame);
  margin: 0 0 14px;
}

.ts-feature__title {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: clamp(28px, 3.2vw, 42px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.015em;
  color: var(--text-primary);
  margin: 0 0 18px;
}

.ts-feature__copy {
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-secondary);
  margin: 0 0 24px;
  max-width: 480px;
}

.ts-feature__bullets {
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  display: grid;
  gap: 10px;
}

.ts-feature__bullets li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14.5px;
  color: var(--text-primary);
}

.ts-feature__bullets svg {
  flex-shrink: 0;
  margin-top: 3px;
  width: 16px;
  height: 16px;
  color: var(--flame);
}

/* Product shot frame — large rounded card with gradient halo */
.ts-feature__visual {
  position: relative;
}

.ts-feature__frame {
  position: relative;
  display: block;
  padding: 12px;
  border-radius: 24px;
  background: linear-gradient(145deg, rgba(255,255,255,0.8), rgba(255,255,255,0.5));
  border: 1px solid rgba(26,26,26,0.06);
  box-shadow:
    0 1px 2px rgba(26,26,26,0.04),
    0 24px 48px -18px rgba(26,26,26,0.18);
  overflow: hidden;
  aspect-ratio: 9 / 14;
}

.ts-feature__frame::before {
  content: "";
  position: absolute;
  inset: -1px;
  background: radial-gradient(ellipse at 30% 0%, rgba(242,100,25,0.15), transparent 60%);
  pointer-events: none;
  opacity: 0.6;
}

.ts-feature__frame img {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  border-radius: 14px;
  box-shadow: 0 10px 24px -12px rgba(26,26,26,0.2);
}

/* ---------- Closing CTA ---------- */

.ts-cta {
  padding: 96px 0 112px;
}

.ts-cta__card {
  position: relative;
  padding: 72px 48px;
  text-align: center;
  border-radius: 28px;
  overflow: hidden;
  background:
    radial-gradient(ellipse 60% 100% at 50% 120%, rgba(242,100,25,0.2), transparent 70%),
    linear-gradient(180deg, #FFFFFF 0%, #FDF8F3 100%);
  border: 1px solid rgba(26,26,26,0.06);
  box-shadow:
    0 1px 2px rgba(26,26,26,0.04),
    0 30px 60px -24px rgba(242,100,25,0.28);
}

.ts-cta__card::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("/images/auth-topo.svg");
  background-size: cover;
  background-position: center;
  opacity: 0.06;
  pointer-events: none;
}

.ts-cta__inner {
  position: relative;
  max-width: 620px;
  margin: 0 auto;
}

.ts-cta__title {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.015em;
  color: var(--text-primary);
  margin: 0 0 16px;
}

.ts-cta__copy {
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin: 0 0 32px;
}

.ts-cta__stores {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
}

.ts-cta__stores img {
  height: 50px;
  width: auto;
  display: block;
  border-radius: 10px;
  transition: transform 140ms ease;
}

.ts-cta__stores a:hover img { transform: translateY(-2px); }

/* ---------- Motion ---------- */

@keyframes ts-in {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- Responsive ---------- */

@media (max-width: 1024px) {
  .ts-hero__grid { gap: 40px; }
  .ts-feature { gap: 40px; padding: 44px 0; }
}

@media (max-width: 860px) {
  .ts-hero { padding: 108px 0 72px; }
  .ts-hero__grid { grid-template-columns: 1fr; gap: 48px; }
  .ts-hero__visual { order: -1; max-width: 320px; margin: 0 auto; }
  .ts-hero__chip--distance { top: 4%; left: -4%; }
  .ts-hero__chip--elev { bottom: 30%; right: -4%; }
  .ts-hero__chip--export { bottom: 6%; left: 0; }

  .ts-section { padding: 72px 0; }
  .ts-section__head { flex-direction: column; align-items: flex-start; gap: 12px; }

  .ts-feature { grid-template-columns: 1fr; gap: 32px; padding: 36px 0; }
  .ts-feature--reverse .ts-feature__visual { order: 0; }
  .ts-feature__copy { max-width: none; }

  .ts-cta { padding: 72px 0 88px; }
  .ts-cta__card { padding: 56px 28px; border-radius: 22px; }

  .ts-trust__inner { flex-direction: column; align-items: flex-start; gap: 14px; padding: 16px 18px; }
}

@media (max-width: 480px) {
  .ts-container { padding: 0 16px; }
  .ts-hero__ctas { width: 100%; }
  .ts-hero__ctas .ts-btn { flex: 1; justify-content: center; }
  .ts-hero__stores img { height: 42px; }
  .ts-cta__stores img { height: 44px; }
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  .ts-hero__eyebrow,
  .ts-hero__title,
  .ts-hero__subtitle,
  .ts-hero__ctas,
  .ts-hero__stores,
  .ts-hero__visual,
  .ts-hero__chip { animation: none; }
  .ts-hero__phone { animation: none; }
  .ts-hero__phone-wrap::before { animation: none; }
}
