/* Templates marketing — mirrors community/chat-marketing.css */

/* Match landing index.html reset — without this, UA body margin: 8px
   insets the sticky nav (narrower + lower than qava.ai/). */
*,
*::before,
*::after {
  box-sizing: border-box;
}

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

/* Self-contained landing nav layout (does not rely on page-local index/about CSS) */
.header-container {
  width: calc(100% - 22px) !important;
  margin: 0 auto !important;
  padding: 8px 20px !important;
  border-radius: 0 !important;
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  min-height: 58px !important;
  box-sizing: border-box !important;
  position: sticky !important;
  top: 0 !important;
  z-index: 1200 !important;
  background: rgba(255, 255, 255, 0.24) !important;
  -webkit-backdrop-filter: blur(18px) saturate(150%) !important;
  backdrop-filter: blur(18px) saturate(150%) !important;
  border: 0 !important;
  box-shadow: none !important;
  isolation: isolate !important;
  overflow: visible !important;
}

.header-container::before {
  content: "" !important;
  position: absolute !important;
  left: 6px !important;
  right: 6px !important;
  top: 3px !important;
  bottom: 3px !important;
  border-radius: 12px !important;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.62) 0%,
    rgba(255, 255, 255, 0.5) 55%,
    rgba(255, 255, 255, 0.44) 100%
  ) !important;
  -webkit-backdrop-filter: blur(26px) saturate(165%) !important;
  backdrop-filter: blur(26px) saturate(165%) !important;
  box-shadow:
    0 10px 24px rgba(17, 24, 39, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.7) !important;
  z-index: 0 !important;
  pointer-events: none !important;
}

.header-container > * {
  position: relative !important;
  z-index: 1 !important;
}

.header-logo,
.header-container .logo-container,
.header-container .logo {
  display: flex !important;
  align-items: center !important;
  flex-shrink: 0 !important;
}

.header-center {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  flex: 1 !important;
  margin-left: 40px !important;
  min-width: 0 !important;
}

.header-right {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  flex-shrink: 0 !important;
}

.header-container .navigation {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  flex-wrap: nowrap !important;
}

.header-container .nav-item {
  display: inline-flex !important;
  align-items: center !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
  cursor: pointer;
}

.header-container .navigation .nav-item .nav-text {
  font-family: "Inter", sans-serif !important;
  font-size: 14px !important;
  font-weight: 300 !important;
  color: #6b6b6b !important;
  line-height: 1.4 !important;
  padding: 0 4px !important;
  white-space: nowrap !important;
  background: none !important;
}

.header-container .nav-item:hover .nav-text,
.header-container .nav-item.is-active .nav-text,
.header-container .nav-item.active .nav-text {
  color: #000000 !important;
  background: none !important;
}

.header-container .auth-section {
  display: flex !important;
  align-items: center !important;
  gap: 28px !important;
}

.header-container .qava-premium-nav-btn {
  padding: 0 !important;
  border: none !important;
  background: transparent !important;
  cursor: pointer;
  font-family: "Inter", sans-serif !important;
  font-size: 14px !important;
  font-weight: 300 !important;
  color: #6b6b6b !important;
  white-space: nowrap !important;
  display: inline-flex !important;
  align-items: center !important;
  text-decoration: none !important;
  line-height: 1.4 !important;
}

.header-container .qava-premium-nav-btn .nav-text {
  color: inherit !important;
  font-family: "Inter", sans-serif !important;
  font-size: 14px !important;
  font-weight: 300 !important;
  padding: 0 4px !important;
}

.header-container .qava-premium-nav-btn:hover,
.header-container .qava-premium-nav-btn:hover .nav-text {
  color: #000000 !important;
}

.header-container .join-button {
  padding: 6px 12px !important;
  border-radius: 6px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  cursor: pointer;
  background: #2b2b2b !important;
  border: 1px solid #2b2b2b !important;
  color: #ffffff !important;
  box-shadow: none !important;
}

.header-container .join-button .join-text {
  font-family: "Inter", sans-serif !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  line-height: 1.2 !important;
  color: #ffffff !important;
  white-space: nowrap !important;
}

.header-container .join-button:hover {
  background: #000000 !important;
  border-color: #000000 !important;
}

.header-container .logo img,
.header-container .header-logo img,
.qava-nav-logo-face {
  width: 24px !important;
  height: 24px !important;
  display: block !important;
  border-radius: 6px !important;
}

.qava-nav-logo-flip {
  width: 24px;
  height: 24px;
  perspective: 700px;
}

.qava-nav-logo-inner {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.65s cubic-bezier(0.4, 0.2, 0.2, 1);
}

.qava-nav-logo-inner.is-flipped {
  transform: rotateY(180deg);
}

.qava-nav-logo-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.qava-nav-logo-front {
  object-fit: contain !important;
  background: transparent;
}

.qava-nav-logo-back {
  object-fit: cover !important;
  transform: rotateY(180deg);
}

.header-container .hamburger-menu {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  padding: 6px;
  width: 32px;
  height: 32px;
  border-radius: 4px;
}

.header-container .hamburger-line {
  width: 18px;
  height: 2px;
  background-color: #000;
  margin: 2px 0;
}

.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: #fff;
  padding: 72px 28px 40px;
  overflow-y: auto;
}

.mobile-menu.active {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mobile-menu .close-menu {
  position: absolute;
  top: 22px;
  right: 22px;
  font-size: 22px;
  cursor: pointer;
  line-height: 1;
  color: #111827;
}

.mobile-menu .mobile-nav-item {
  display: block;
  padding: 12px 0;
  text-decoration: none;
  font-family: "Inter", sans-serif;
  font-size: 16px;
  font-weight: 300;
  color: #6b6b6b;
}

.mobile-menu .mobile-nav-item:hover,
.mobile-menu .mobile-nav-item.is-active {
  color: #000;
}

.mobile-menu .mobile-menu-join-button {
  margin-top: 16px;
  width: fit-content;
}

@media (max-width: 900px) {
  .header-container .header-center,
  .header-container .auth-section {
    display: none !important;
  }

  .header-container .hamburger-menu {
    display: flex !important;
  }
}

.tpl-story {
  position: relative;
}

.tpl-marketing-hero {
  text-align: center;
  width: min(920px, calc(100vw - 32px));
  margin: 100px auto 0;
  position: relative;
  z-index: 1;
}

.tpl-marketing-hero .qava-hero-icon {
  width: 124px;
  height: 124px;
  border-radius: 28px;
  object-fit: cover;
  display: block;
  margin: 0 auto 26px auto;
  box-shadow: 0 16px 50px rgba(20, 10, 22, 0.18);
  transform-style: preserve-3d;
  backface-visibility: hidden;
  will-change: transform;
  animation: qavaSideToSideFlip 2.4s linear infinite;
}

@keyframes qavaSideToSideFlip {
  0% {
    transform: perspective(900px) rotateY(-22deg) rotateZ(-1deg);
  }
  25% {
    transform: perspective(900px) rotateY(0deg) rotateZ(0deg);
  }
  50% {
    transform: perspective(900px) rotateY(22deg) rotateZ(1deg);
  }
  75% {
    transform: perspective(900px) rotateY(0deg) rotateZ(0deg);
  }
  100% {
    transform: perspective(900px) rotateY(-22deg) rotateZ(-1deg);
  }
}

.tpl-marketing-hero h1.qava-hero-heading {
  font-family: "Libre Caslon Display", "Canela", "Canela Deck", "Iowan Old Style", "Baskerville", "Times New Roman", serif;
  font-weight: 400;
  letter-spacing: -0.012em;
  font-size: clamp(34px, 3.6vw, 54px);
  line-height: 1.08;
  white-space: normal !important;
  max-width: none;
  margin: 0 auto 10px auto;
  text-align: center;
  color: #111827;
}

.tpl-marketing-hero .qava-hero-heading .qava-hero-line {
  display: block !important;
}

.tpl-marketing-hero p.qava-hero-subheader {
  font-family: Inter, system-ui, sans-serif;
  font-size: 14px;
  font-weight: 300;
  color: #6b6b6b;
  text-align: center;
  margin: 0 auto 72px !important;
  line-height: 1.45;
  max-width: none;
  white-space: nowrap;
}

.tpl-static-flow {
  width: min(960px, calc(100vw - 32px));
  margin: 0 auto 64px;
  display: flex;
  flex-direction: column;
  gap: 72px;
}

.tpl-static-section {
  display: grid;
  grid-template-columns: minmax(140px, 168px) minmax(0, 1fr);
  gap: 28px 36px;
  align-items: start;
}

.tpl-story .seq-rail,
.tpl-story .seq-main {
  width: 100%;
  min-width: 0;
}

.seq-rail {
  padding-top: 4px;
}

.seq-rail-item {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
}

.seq-rail-label {
  display: inline-block;
  font-family: Inter, system-ui, sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #111827;
  line-height: 1.25;
  border-bottom: 2px solid #111827;
  padding-bottom: 8px;
  box-sizing: border-box;
}

.seq-rail .seq-stage-count {
  margin-top: 22px;
  font-family: Inter, system-ui, sans-serif;
  font-size: 11px;
  font-weight: 300;
  color: #9ca3af;
}

/* Demo cards — static template previews (no API) */
.tpl-demo-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.tpl-demo-card {
  border: 1px solid rgba(17, 24, 39, 0.08);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(17, 24, 39, 0.04);
  overflow: hidden;
  min-width: 0;
}

.tpl-demo-card + .tpl-demo-card {
  margin-top: 0;
}

.tpl-static-section .seq-main > .tpl-demo-card + .tpl-demo-card {
  margin-top: 12px;
}

.tpl-demo-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px 10px;
  border-bottom: 1px solid rgba(17, 24, 39, 0.06);
}

.tpl-demo-thumb {
  width: 36px;
  height: 36px;
  border-radius: 6px;
  background: #f0f0f0;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  color: #111827;
}

.tpl-demo-thumb svg {
  width: 18px;
  height: 18px;
  display: block;
}

.tpl-demo-meta {
  min-width: 0;
}

.tpl-demo-title {
  margin: 0;
  font-family: "Libre Caslon Display", Georgia, serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.2;
  color: #111827;
}

.tpl-demo-sub {
  margin: 3px 0 0;
  font-family: Inter, system-ui, sans-serif;
  font-size: 12px;
  font-weight: 300;
  color: #9ca3af;
}

.tpl-demo-body {
  padding: 14px 16px 16px;
}

.tpl-demo-line {
  height: 8px;
  border-radius: 4px;
  background: #f3f4f6;
  margin-bottom: 8px;
}

.tpl-demo-line.is-short {
  width: 62%;
}

.tpl-demo-line.is-med {
  width: 84%;
}

.tpl-demo-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}

.tpl-demo-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 999px;
  border: 1px solid rgba(17, 24, 39, 0.1);
  background: #fafafa;
  font-family: Inter, system-ui, sans-serif;
  font-size: 11px;
  font-weight: 300;
  color: #4b5563;
}

.tpl-demo-slide {
  margin: 14px 16px 16px;
  border-radius: 8px;
  border: 1px solid rgba(17, 24, 39, 0.08);
  background: linear-gradient(180deg, #fafafa 0%, #f3f4f6 100%);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px 22px 18px;
  gap: 18px;
  min-height: 420px;
}

.tpl-demo-slide-art {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  min-height: 0;
}

.tpl-slide-heading {
  margin: 0;
  font-family: "Libre Caslon Display", Georgia, serif;
  font-size: clamp(22px, 2.4vw, 30px);
  font-weight: 400;
  line-height: 1.15;
  color: #111827;
  letter-spacing: -0.01em;
}

.tpl-slide-sub {
  margin: 10px 0 0;
  max-width: none;
  font-family: Inter, system-ui, sans-serif;
  font-size: 13px;
  font-weight: 300;
  line-height: 1.45;
  color: #6b7280;
  white-space: nowrap;
}

.tpl-beachhead-diagram {
  width: min(100%, 380px);
  margin: 18px auto 0;
}

.tpl-beachhead-diagram svg {
  display: block;
  width: 100%;
  height: auto;
}

.tpl-demo-slide-footer {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  text-align: left;
}

.tpl-demo-slide-kicker {
  font-family: Inter, system-ui, sans-serif;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #9ca3af;
}

.tpl-demo-slide-title {
  font-family: "Libre Caslon Display", Georgia, serif;
  font-size: 18px;
  font-weight: 400;
  color: #111827;
  line-height: 1.2;
  max-width: none;
  white-space: nowrap;
}

.tpl-demo-fields {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px 16px 16px;
}

.tpl-demo-field {
  border: 1px solid rgba(17, 24, 39, 0.1);
  border-radius: 6px;
  padding: 8px 10px;
  background: #fff;
}

.tpl-demo-field-label {
  display: block;
  font-family: Inter, system-ui, sans-serif;
  font-size: 10px;
  font-weight: 500;
  color: #9ca3af;
  margin-bottom: 4px;
}

.tpl-demo-field-value {
  font-family: Inter, system-ui, sans-serif;
  font-size: 13px;
  font-weight: 300;
  color: #111827;
}

.room-thesis {
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: center;
  padding: 96px 16px 40px;
  background: transparent;
}

.room-thesis-inner {
  width: min(920px, calc(100vw - 32px));
  text-align: center;
  padding: 36px 40px 40px;
  border-radius: 12px;
  background: #111827;
}

.room-thesis h2 {
  margin: 0 0 14px;
  font-family: "Libre Caslon Display", Georgia, serif;
  font-size: clamp(17px, 3.35vw, 36px);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: #fff;
  white-space: normal;
}

.room-thesis p {
  margin: 0 auto;
  max-width: none;
  font-family: Inter, system-ui, sans-serif;
  font-size: clamp(13px, 1.65vw, 16px);
  font-weight: 300;
  line-height: 1.55;
  color: #9ca3af;
}

.premium-pitch {
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: center;
  padding: 56px 16px 100px;
}

.premium-pitch-inner {
  width: min(560px, calc(100vw - 32px));
  text-align: center;
}

.premium-pitch-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 18px;
  padding: 5px 10px;
  border-radius: 999px;
  background: #111827;
  color: #fff;
  font-family: Inter, system-ui, sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.premium-pitch-badge svg {
  display: block;
  width: 13px;
  height: 13px;
}

.premium-pitch h3 {
  margin: 0 0 8px;
  font-family: "Libre Caslon Display", Georgia, serif;
  font-size: clamp(26px, 3.6vw, 34px);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: #111827;
}

.premium-pitch-lead {
  margin: 0 0 28px;
  font-family: Inter, system-ui, sans-serif;
  font-size: 15px;
  font-weight: 300;
  line-height: 1.5;
  color: #6b7280;
}

.premium-pitch-card {
  text-align: left;
  margin: 0 0 28px;
  border: 1px solid rgba(17, 24, 39, 0.08);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(17, 24, 39, 0.04), 0 8px 24px rgba(17, 24, 39, 0.06);
  overflow: hidden;
}

.premium-pitch-feats {
  padding: 8px 20px 4px;
}

.premium-pitch-feat {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(17, 24, 39, 0.08);
  font-family: Inter, system-ui, sans-serif;
  font-size: 15px;
  font-weight: 300;
  color: #111827;
}

.premium-pitch-feat:last-child {
  border-bottom: 0;
}

.premium-pitch-icon {
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: #f3f4f6;
  color: #111827;
  display: flex;
  align-items: center;
  justify-content: center;
}

.premium-pitch-icon svg {
  display: block;
  width: 16px;
  height: 16px;
}

.premium-pitch-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 160px;
  padding: 12px 22px;
  border-radius: 8px;
  background: #111827;
  color: #fff;
  font-family: Inter, system-ui, sans-serif;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.15s ease;
}

.premium-pitch-cta:hover {
  background: #000;
  color: #fff;
}

@media (max-width: 720px) {
  .tpl-marketing-hero {
    margin-top: 60px;
  }

  .tpl-marketing-hero .qava-hero-icon {
    width: 96px;
    height: 96px;
    border-radius: 22px;
  }

  .tpl-marketing-hero h1.qava-hero-heading {
    font-size: clamp(28px, 8vw, 40px);
  }

  .tpl-static-section {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .seq-rail-label {
    font-size: 11px;
  }

  .seq-rail .seq-stage-count {
    margin-top: 10px;
  }

  .tpl-static-flow {
    gap: 48px;
  }

  .tpl-demo-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .room-thesis h2,
  .room-thesis p {
    white-space: normal;
  }

  .room-thesis-inner {
    padding: 28px 20px 32px;
  }

  .tpl-slide-sub,
  .tpl-demo-slide-title,
  .tpl-marketing-hero p.qava-hero-subheader {
    white-space: normal;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tpl-marketing-hero .qava-hero-icon {
    animation: none;
  }
}
