/* School demo request — premium conversion page */
.landing-home.tc-demo-page .tc-main {
  position: relative;
}

.tc-demo-stage {
  --demo-ink: #1a1330;
  --demo-muted: #6b647c;
  --demo-purple: #7c5ce6;
  --demo-purple-deep: #5b3fd4;
  --demo-line: rgba(124, 92, 230, 0.16);
  position: relative;
  isolation: isolate;
  padding: 1.25rem 0 3.75rem;
  overflow: hidden;
}

.tc-demo-stage__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 55% at 85% 0%, rgba(167, 139, 250, 0.28), transparent 60%),
    radial-gradient(ellipse 55% 50% at 8% 90%, rgba(52, 211, 153, 0.12), transparent 55%),
    linear-gradient(180deg, #f7f4ff 0%, #ffffff 48%, #fbfaff 100%);
}

.tc-demo-stage__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(2px);
  opacity: 0.9;
  animation: tcDemoFloat 8s ease-in-out infinite;
}
.tc-demo-stage__orb--a {
  width: min(42vw, 320px);
  height: min(42vw, 320px);
  top: -8%;
  left: -6%;
  background: radial-gradient(circle, rgba(124, 92, 230, 0.28), transparent 68%);
}
.tc-demo-stage__orb--b {
  width: min(36vw, 260px);
  height: min(36vw, 260px);
  right: -4%;
  bottom: 8%;
  background: radial-gradient(circle, rgba(34, 197, 94, 0.18), transparent 70%);
  animation-delay: -2.5s;
}
.tc-demo-stage__grid {
  position: absolute;
  inset: 0;
  opacity: 0.35;
  background-image:
    linear-gradient(rgba(124, 92, 230, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 92, 230, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 20%, transparent 75%);
}

.tc-demo-stage__inner {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
}

/* ── Panel ── */
.tc-demo-panel {
  position: relative;
  width: 100%;
  max-width: 34rem;
  padding: 2rem 1.85rem 1.65rem;
  border-radius: 28px;
  background:
    linear-gradient(165deg, rgba(255, 255, 255, 0.97) 0%, rgba(250, 247, 255, 0.96) 100%);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 28px 60px -28px rgba(91, 63, 212, 0.45),
    0 12px 28px rgba(26, 19, 48, 0.06);
  animation: tcDemoRise 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
  overflow: hidden;
}

.tc-demo-panel__glow {
  position: absolute;
  inset: auto -20% -40% -20%;
  height: 55%;
  background: radial-gradient(ellipse at center, rgba(124, 92, 230, 0.16), transparent 70%);
  pointer-events: none;
}

.tc-demo-panel__badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0 0 1.1rem;
  padding: 0.4rem 0.85rem 0.4rem 0.7rem;
  border-radius: 999px;
  background: rgba(124, 92, 230, 0.1);
  color: var(--demo-purple-deep);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.tc-demo-panel__badge-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.18);
  animation: tcDemoPulse 2s ease-in-out infinite;
}

.tc-demo-panel__title {
  position: relative;
  margin: 0 0 0.85rem;
  font-family: 'Titr B', 'TitrB', Tahoma, sans-serif;
  font-size: clamp(1.55rem, 4.2vw, 2.05rem);
  line-height: 1.55;
  color: var(--demo-ink);
  font-weight: 700;
}
.tc-demo-panel__title em {
  font-style: normal;
  color: var(--demo-purple);
  background: linear-gradient(120deg, #8b6cf6, #5b3fd4);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.tc-demo-panel__lead {
  position: relative;
  margin: 0 0 1.25rem;
  color: var(--demo-muted);
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.95;
}

.tc-demo-panel__perks {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  list-style: none;
  margin: 0 0 1.45rem;
  padding: 0;
}
.tc-demo-panel__perks li {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.75rem 0.4rem 0.55rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--demo-line);
  color: var(--demo-ink);
  font-size: 0.78rem;
  font-weight: 800;
  box-shadow: 0 6px 16px rgba(88, 48, 160, 0.05);
}
.tc-demo-panel__perk-icon {
  display: inline-flex;
  line-height: 0;
}

/* ── Form ── */
.tc-demo-form {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.tc-demo-form__label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--demo-ink);
}
.tc-demo-form__label span {
  font-size: 0.75rem;
  font-weight: 600;
  color: #9a94a8;
}

.tc-demo-form__field {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 3.55rem;
  padding: 0.35rem 0.85rem;
  border-radius: 16px;
  background: #fff;
  border: 1.5px solid #e6e0f4;
  box-shadow: 0 10px 24px rgba(88, 48, 160, 0.05);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.tc-demo-form__field:focus-within {
  border-color: var(--demo-purple);
  box-shadow:
    0 0 0 4px rgba(124, 92, 230, 0.14),
    0 14px 28px rgba(91, 63, 212, 0.12);
  transform: translateY(-1px);
}
.tc-demo-form__field.is-invalid {
  border-color: #f87171;
  box-shadow: 0 0 0 4px rgba(248, 113, 113, 0.12);
}

.tc-demo-form__prefix {
  color: var(--demo-purple);
  display: inline-flex;
  flex-shrink: 0;
}

.tc-demo-form__field .tc-field--contact {
  flex: 1;
  min-width: 0;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  outline: none !important;
  padding: 0.65rem 0.15rem;
  min-height: 2.6rem;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--demo-ink);
  direction: ltr;
  text-align: left;
}
.tc-demo-form__field .tc-field--contact::placeholder {
  color: #b7b1c5;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.tc-demo-form__error {
  margin: 0;
  color: #dc2626;
  font-size: 0.84rem;
  font-weight: 700;
}

.tc-demo-form__submit {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  margin-top: 0.65rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  width: 100%;
  min-height: 3.65rem;
  padding: 0.9rem 1.35rem;
  border: 0;
  border-radius: 16px;
  cursor: pointer;
  color: #fff;
  font-size: 1.05rem;
  font-weight: 800;
  text-decoration: none;
  background: linear-gradient(135deg, #a78bfa 0%, #7c5ce6 42%, #5b3fd4 100%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.35) inset,
    0 16px 36px -10px rgba(91, 63, 212, 0.7);
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.25s ease, filter 0.25s ease;
}
.tc-demo-form__submit:hover {
  transform: translateY(-2px) scale(1.01);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.4) inset,
    0 22px 42px -10px rgba(91, 63, 212, 0.8);
  filter: brightness(1.03);
}
.tc-demo-form__submit:active {
  transform: translateY(0) scale(0.995);
}
.tc-demo-form__submit-shine {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, 0.35) 50%, transparent 65%);
  transform: translateX(-120%);
  animation: tcDemoShine 3.8s ease-in-out infinite;
  pointer-events: none;
}
.tc-demo-form__submit-label,
.tc-demo-form__submit-arrow {
  position: relative;
  z-index: 1;
}
.tc-demo-form__submit-arrow {
  display: inline-flex;
  transition: transform 0.25s ease;
}
.tc-demo-form__submit:hover .tc-demo-form__submit-arrow {
  transform: translateX(-3px);
}

.tc-demo-panel__trust {
  position: relative;
  margin: 1.15rem 0 0;
  text-align: center;
  color: #8d879a;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.7;
}

/* ── Success ── */
.tc-demo-success {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.45rem;
  padding: 0.85rem 0.5rem 0.35rem;
  animation: tcDemoRise 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.tc-demo-success__icon {
  margin-bottom: 0.35rem;
  filter: drop-shadow(0 12px 20px rgba(16, 185, 129, 0.35));
  animation: tcDemoPop 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.tc-demo-success__title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--demo-ink);
}
.tc-demo-success__text {
  margin: 0;
  color: var(--demo-muted);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.8;
  max-width: 26rem;
}

.tc-demo-flash {
  margin: 0 0 0.85rem;
  padding: 0.75rem 0.95rem;
  border-radius: 14px;
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.6;
}
.tc-demo-flash.is-ok {
  background: rgba(16, 185, 129, 0.1);
  color: #047857;
  border: 1px solid rgba(16, 185, 129, 0.22);
}
.tc-demo-flash.is-error {
  background: rgba(239, 68, 68, 0.08);
  color: #b91c1c;
  border: 1px solid rgba(239, 68, 68, 0.2);
}

@keyframes tcDemoRise {
  from { opacity: 0; transform: translateY(18px) scale(0.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes tcDemoPop {
  from { opacity: 0; transform: scale(0.7); }
  to { opacity: 1; transform: scale(1); }
}
@keyframes tcDemoFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}
@keyframes tcDemoPulse {
  0%, 100% { box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.18); }
  50% { box-shadow: 0 0 0 7px rgba(34, 197, 94, 0.08); }
}
@keyframes tcDemoShine {
  0%, 55%, 100% { transform: translateX(-120%); }
  70% { transform: translateX(120%); }
}

@media (max-width: 640px) {
  .tc-demo-stage { padding: 0.75rem 0 2.75rem; }
  .tc-demo-panel {
    padding: 1.55rem 1.15rem 1.35rem;
    border-radius: 22px;
  }
  .tc-demo-panel__perks { gap: 0.35rem; }
  .tc-demo-panel__perks li { font-size: 0.72rem; }
  .tc-demo-form__submit { font-size: 0.98rem; min-height: 3.4rem; }
}

@media (prefers-reduced-motion: reduce) {
  .tc-demo-panel,
  .tc-demo-success,
  .tc-demo-success__icon,
  .tc-demo-stage__orb,
  .tc-demo-panel__badge-dot,
  .tc-demo-form__submit-shine {
    animation: none !important;
  }
  .tc-demo-form__submit:hover,
  .tc-demo-form__field:focus-within {
    transform: none;
  }
}
