/* ============================================================
   KURIPPEDU — Unified Subpages Design System & Component Styles
   Used across Core Academic, Operation, & Intelligence Subpages
   ============================================================ */

:root {
  /* Brand palette */
  --violet-700: #5a35e0;
  --violet-600: #6d49f8;
  --violet-500: #6d49f8;
  --violet-400: #8a6bff;
  --indigo-500: #6366F1;
  --lavender-50: #F7F5FF;
  --lavender-100: #EEEBFB;
  --lavender-200: #E2DDF7;
  --ink-900: #171331;
  --ink-700: #3B3654;
  --ink-500: #6E6A85;
  --white: #FFFFFF;
  --success: #16A34A;
  --amber: #F59E0B;
  --footer-bg: #0D0B1E;
  --footer-line: rgba(255, 255, 255, 0.08);

  /* Typography */
  --font-display: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;

  /* Shape & shadow */
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --shadow-card: 0 10px 30px -12px rgba(91, 33, 182, 0.14);
  --shadow-hover: 0 18px 42px -14px rgba(91, 33, 182, 0.26);
  --grad-brand: linear-gradient(120deg, var(--violet-500), var(--indigo-500));
  --grad-soft: linear-gradient(180deg, var(--lavender-50), #FFFFFF 60%);
}

/* ---------- Global Reset & Base ---------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

html,
body {
  overflow-x: hidden;
  overflow-x: clip;
}

body {
  font-family: var(--font-body);
  color: var(--ink-700);
  background: var(--white);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  color: var(--ink-900);
  line-height: 1.2;
  letter-spacing: -0.02em;
}

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

a {
  text-decoration: none;
  color: inherit;
}

.container {
  width: min(1160px, 92%);
  margin-inline: auto;
}

section {
  padding: 88px 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--violet-600);
  background: var(--lavender-100);
  border: 1px solid var(--lavender-200);
  padding: 7px 14px;
  border-radius: 999px;
}

.eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--grad-brand);
}

.grad-text {
  background: var(--grad-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.section-head {
  max-width: 680px;
  margin: 0 auto 52px;
  text-align: center;
}

.section-head h2 {
  font-size: clamp(1.7rem, 3.4vw, 2.4rem);
  margin: 16px 0 12px;
}

.section-head p {
  color: var(--ink-500);
}

/* ---------- Button System ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 13px 26px;
  border-radius: 999px;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  border: none;
}

.btn:hover {
  transform: translateY(-3px) scale(1.025);
}

.btn-primary {
  background: var(--grad-brand);
  color: #fff !important;
  box-shadow: 0 10px 24px -8px rgba(124, 58, 237, 0.5);
  position: relative;
  overflow: hidden;
}

.btn-primary::after {
  content: "";
  position: absolute;
  top: 0;
  left: -80%;
  width: 50%;
  height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  transform: skewX(-20deg);
  animation: shine 4.2s ease-in-out infinite;
}

@keyframes shine {
  0%, 60% { left: -80%; }
  80%, 100% { left: 130%; }
}

.btn-primary:hover {
  box-shadow: 0 16px 32px -8px rgba(124, 58, 237, 0.55);
}

.btn-ghost {
  background: #fff;
  color: var(--violet-600);
  border: 1.5px solid var(--lavender-200);
}

.btn-ghost:hover {
  border-color: var(--violet-400);
}

/* ---------- Hero Component ---------- */
.hero {
  background: var(--grad-soft);
  padding: 80px 0 64px;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto -10% -55% -10%;
  height: 70%;
  background: radial-gradient(60% 100% at 50% 100%, rgba(139, 92, 246, 0.16), transparent 70%);
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 40px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: clamp(2rem, 4vw, 2.9rem);
  margin: 18px 0 16px;
  font-weight: 800;
}

.hero p.lead {
  font-size: 1.06rem;
  color: var(--ink-500);
  max-width: 520px;
  line-height: 1.6;
}

.hero-ctas {
  display: flex;
  gap: 14px;
  margin-top: 30px;
  flex-wrap: wrap;
}

.hero-badges {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 26px;
}

@media (min-width: 1025px) {
  .hero-badges {
    flex-wrap: nowrap;
  }
}

.badge {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--violet-700);
  background: #fff;
  border: 1px solid var(--lavender-200);
  border-radius: 999px;
  padding: 6px 13px;
  white-space: nowrap;
}

.hero-img-card {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 20px 50px -10px rgba(109, 73, 248, 0.22), 0 0 0 1px rgba(109, 73, 248, 0.1);
  background: #fff;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-img-card:hover {
  transform: translateY(-4px) scale(1.015);
  box-shadow: 0 28px 64px -12px rgba(109, 73, 248, 0.3), 0 0 0 1px rgba(109, 73, 248, 0.18);
}

.hero-dashboard-img {
  width: 100%;
  height: auto;
  display: block;
}

/* ---------- Workflow Chips ---------- */
.workflow {
  background: #fff;
}

.chip-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(215px, 1fr));
  gap: 14px;
}

.chip {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--lavender-50);
  border: 1px solid var(--lavender-100);
  border-radius: var(--radius-md);
  padding: 15px 16px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--ink-700);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.chip:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card);
  border-color: var(--violet-400);
}

.chip .dot {
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: var(--grad-brand);
  color: #fff;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 800;
}

/* ---------- Workflow Showcase ---------- */
.workflow {
  background: #fff;
  padding: 60px 0 36px;
}

.workflow .section-head {
  margin: 0 auto 28px;
}

.qb-collage-wrap {
  margin-top: 0;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.qb-collage-img {
  width: 100%;
  max-width: 1140px;
  height: auto;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 16px 44px rgba(109, 73, 248, 0.14));
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1), filter 0.45s ease;
}

.qb-collage-img:hover {
  transform: translateY(-4px) scale(1.01);
  filter: drop-shadow(0 24px 54px rgba(109, 73, 248, 0.22));
}

@media (max-width: 768px) {
  .workflow {
    padding: 40px 0 24px;
  }
  .workflow .section-head {
    margin: 0 auto 20px;
  }
}

/* ---------- Feature Rows ---------- */
.features {
  background: var(--lavender-50);
  padding: 64px 0;
}

.feature-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(24px, 4vw, 56px);
  align-items: center;
  padding: clamp(28px, 4vw, 44px) 0;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.feature-row + .feature-row {
  border-top: 1px solid var(--lavender-200);
}

.feature-row:nth-child(even) .feature-copy {
  order: 2;
}

.feature-copy {
  width: 100%;
  max-width: 100%;
}

.feature-copy h3 {
  font-size: clamp(1.25rem, 3vw, 1.55rem);
  margin: 14px 0 12px;
  letter-spacing: -0.01em;
}

.feature-copy p {
  color: var(--ink-500);
  margin-bottom: 16px;
  line-height: 1.6;
}

.feature-list {
  list-style: none;
  display: grid;
  gap: 10px;
}

.feature-list li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 0.95rem;
  line-height: 1.5;
}

.feature-list li::before {
  content: "";
  flex: none;
  width: 18px;
  height: 18px;
  margin-top: 3px;
  border-radius: 6px;
  background: var(--grad-brand);
  clip-path: polygon(14% 44%, 0 60%, 40% 100%, 100% 18%, 84% 4%, 40% 70%);
}

.feature-visual {
  background: #fff;
  border: 1px solid var(--lavender-200);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: clamp(16px, 3vw, 26px);
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s ease;
}

.feature-visual:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
}

.feature-visual svg,
.hero-visual svg,
.svg-anim svg {
  width: 100% !important;
  max-width: 100% !important;
  height: auto !important;
  display: block;
}

/* ---------- OBE / Interconnected Modules Band ---------- */
.obe {
  background: var(--grad-brand);
  color: #fff;
  border-radius: clamp(20px, 3vw, 28px);
  padding: clamp(36px, 6vw, 64px) clamp(20px, 6vw, 8%);
  position: relative;
  overflow: hidden;
  max-width: 100%;
  box-sizing: border-box;
}

.obe::before {
  content: "";
  position: absolute;
  width: min(420px, 80vw);
  height: min(420px, 80vw);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  top: -180px;
  right: -120px;
  pointer-events: none;
}

.obe h2 {
  color: #fff;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 14px;
}

.obe p {
  color: rgba(255, 255, 255, 0.85);
  max-width: 640px;
}

.obe-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 14px;
  margin-top: 34px;
}

.obe-card {
  --tint: 109, 73, 248;
  position: relative;
  border-radius: 20px;
  padding: 24px 20px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  overflow: hidden;
  transition: transform 0.45s cubic-bezier(0.22, 0.61, 0.36, 1), background-color 0.45s, border-color 0.45s, box-shadow 0.45s;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  text-align: left;
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 700;
  box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.15);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.obe-card::before {
  content: "";
  position: absolute;
  top: -60%;
  left: -60%;
  width: 90%;
  height: 220%;
  background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, 0.4) 50%, transparent 70%);
  transform: translateX(-120%) rotate(8deg);
  transition: transform 0.8s cubic-bezier(0.22, 0.61, 0.36, 1);
  pointer-events: none;
}

.obe-card:hover {
  transform: translateY(-8px) scale(1.02);
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 20px 40px rgba(109, 73, 248, 0.35);
}

.obe-card:hover::before {
  transform: translateX(340%) rotate(8deg);
}

.obe-card span {
  display: block;
  color: rgba(255, 255, 255, 0.82);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.82rem;
  line-height: 1.6;
  margin-top: 8px;
}

@media (min-width: 992px) {
  .obe {
    padding: 48px 6%;
  }
  .obe-grid {
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
  }
  .obe-card {
    padding: 16px 12px;
  }
}

/* ---------- Benefits ---------- */
.benefits .stat {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 6vw, 4rem);
  font-weight: 800;
  background: var(--grad-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.benefit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 18px;
  margin-top: 44px;
}

.benefit-card {
  background: #fff;
  border: 1px solid var(--lavender-100);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-card);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.4s;
}

.benefit-card:hover {
  transform: translateY(-6px) scale(1.01);
  box-shadow: 0 20px 40px rgba(109, 73, 248, 0.15);
  border-color: var(--violet-400);
}

.benefit-card h4 {
  font-size: 1rem;
  margin: 12px 0 6px;
}

.benefit-card p {
  font-size: 0.88rem;
  color: var(--ink-500);
}

.benefit-ic {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--lavender-100);
  display: grid;
  place-items: center;
  color: var(--violet-600);
}

/* ---------- Animations ---------- */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in {
  opacity: 1;
  transform: none;
}

@keyframes growBar {
  from { transform: scaleY(0); }
  to { transform: scaleY(1); }
}

@keyframes drawLine {
  to { stroke-dashoffset: 0; }
}

@keyframes seatPop {
  0% { opacity: 0; transform: scale(0.4); }
  70% { transform: scale(1.15); }
  100% { opacity: 1; transform: scale(1); }
}

@keyframes pulseDot {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}

@keyframes scanQR {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(26px); }
}

@keyframes typeIn {
  from { width: 0; }
  to { width: 100%; }
}

@keyframes hphFloatSlow {
  0% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-8px) rotate(0.4deg); }
  100% { transform: translateY(0px) rotate(0deg); }
}

.svg-anim .bar {
  transform-origin: bottom;
  animation: growBar 1s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.svg-anim .line {
  stroke-dasharray: 320;
  stroke-dashoffset: 320;
  animation: drawLine 1.6s 0.3s ease both;
}

.svg-anim .seat {
  opacity: 0;
  animation: seatPop 0.5s ease both;
}

.svg-anim .pulse {
  animation: pulseDot 2.2s ease-in-out infinite;
}

.svg-anim .scanline {
  animation: scanQR 2.4s ease-in-out infinite;
}

.hero-visual .float {
  animation: floaty 5s ease-in-out infinite;
}

.feature-visual svg,
.hero-visual svg {
  animation: hphFloatSlow 6s ease-in-out infinite;
}

/* ---------- Mobile Spacing & Polish ---------- */
@media (max-width: 900px) {
  .hero {
    padding: 64px 0 48px;
  }
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero-visual {
    order: -1;
    max-width: 480px;
    margin-inline: auto;
  }
  .feature-row {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 32px 0;
  }
  .feature-row:nth-child(even) .feature-copy {
    order: 0;
  }
  .feature-visual {
    max-width: 480px;
    margin-inline: auto;
    width: 100%;
  }
}

@media (max-width: 768px) {
  section {
    padding: 64px 0;
  }
  .section-head {
    margin: 0 auto 36px;
  }
}

@media (max-width: 600px) {
  section {
    padding: 48px 0;
  }
  .hero {
    padding: 48px 0 36px;
  }
  .hero-visual {
    max-width: 400px;
  }
  .section-head {
    margin: 0 auto 28px;
  }
  .chip {
    padding: 12px 14px;
    font-size: 0.86rem;
  }
  .obe {
    padding: 40px 7%;
    border-radius: 22px;
  }
  .obe::before {
    width: 280px;
    height: 280px;
    top: -120px;
    right: -90px;
  }
  .benefit-card {
    padding: 20px;
  }
  .feature-visual {
    padding: 18px;
  }
}

/* ---------- Form input anti-zoom on mobile ---------- */
@media (max-width: 860px) {
  input,
  select,
  textarea {
    font-size: 16px !important;
  }
}

/* ---------- Reduced Motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}

/* ---------- Ambient Live Background Canvas & Floating Blobs ---------- */
.live-background-canvas {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: -1;
}

.live-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.6;
  pointer-events: none;
  will-change: transform;
}

.live-blob-1 {
  width: 50vw;
  height: 50vw;
  max-width: 600px;
  max-height: 600px;
  background: radial-gradient(circle, rgba(109, 73, 248, 0.14) 0%, transparent 70%);
  top: -10%;
  left: -10%;
  animation: liveDrift1 24s ease-in-out infinite alternate;
}

.live-blob-2 {
  width: 45vw;
  height: 45vw;
  max-width: 550px;
  max-height: 550px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.12) 0%, transparent 70%);
  top: 40%;
  right: -5%;
  animation: liveDrift2 28s ease-in-out infinite alternate;
}

.live-blob-3 {
  width: 55vw;
  height: 55vw;
  max-width: 700px;
  max-height: 700px;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.1) 0%, transparent 75%);
  bottom: -10%;
  left: 20%;
  animation: liveDrift3 30s ease-in-out infinite alternate;
}

.live-blob-4 {
  width: 65vw;
  height: 65vw;
  max-width: 850px;
  max-height: 850px;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.1) 0%, transparent 80%);
  right: 15%;
  bottom: 15%;
  animation: liveDrift4 32s ease-in-out infinite alternate;
}

@keyframes liveDrift1 {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(10vw, 8vh) scale(1.1); }
  100% { transform: translate(-5vw, -5vh) scale(0.95); }
}

@keyframes liveDrift2 {
  0% { transform: translate(0, 0) scale(0.95); }
  50% { transform: translate(-8vw, 12vh) scale(1.05); }
  100% { transform: translate(5vw, -3vh) scale(1); }
}

@keyframes liveDrift3 {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(12vw, -10vh) scale(0.9); }
  100% { transform: translate(-8vw, 5vh) scale(1.1); }
}

@keyframes liveDrift4 {
  0% { transform: translate(0, 0) scale(1.05); }
  50% { transform: translate(-10vw, -8vh) scale(0.95); }
  100% { transform: translate(6vw, 10vh) scale(1.02); }
}

/* ---------- Scroll Reveal System (Safe Vertical Offsets) ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.65s cubic-bezier(0.16, 1, 0.3, 1), transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.reveal.in {
  opacity: 1;
  transform: none;
}

/* Safe directional classes that never cause horizontal scroll */
.reveal.from-left,
.reveal.from-right {
  opacity: 0;
  transform: translateY(20px);
}

.reveal.from-left.in,
.reveal.from-right.in {
  opacity: 1;
  transform: none;
}


/* ---------- Staggered Chip Entrance ---------- */
.chip {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.chip.chip-in {
  opacity: 1;
  transform: none;
}

.chip .dot {
  transition: transform 0.3s ease;
}

.chip:hover .dot {
  transform: rotate(-8deg) scale(1.12);
}

/* ---------- 1. Hide Up Arrow (Go To Top) on Pluto Screen Only ---------- */
.has-pluto-bot #backToTop,
.has-pluto-bot .back-to-top,
body:has(#pluto-launch) #backToTop,
body:has(#pluto-launch) .back-to-top {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* ---------- 2. Pluto Floating AI Mascot Widget ---------- */
#pluto-launch {
  position: fixed;
  bottom: 8px;
  right: 24px;
  width: 92px;
  height: 92px;
  border-radius: 50%;
  background: transparent;
  border: none;
  cursor: pointer;
  z-index: 10002;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1), bottom 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), filter 0.3s ease;
  animation: plutoFloat 3.2s ease-in-out infinite;
  filter: drop-shadow(0 12px 26px rgba(109, 73, 248, 0.48));
}

/* When Book a Demo FAB is visible at bottom-right, display Pluto AI button immediately before it (to its left) */
.has-pluto-bot.fab-active #pluto-launch,
body.fab-active #pluto-launch,
body:has(#bookFab.show) #pluto-launch {
  right: 206px;
  bottom: 8px;
}

@keyframes plutoFloat {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-11px);
  }
}

#pluto-launch:hover {
  animation-play-state: paused;
  transform: translateY(-12px) scale(1.08);
  filter: drop-shadow(0 18px 36px rgba(109, 73, 248, 0.7));
}

#pluto-launch:active {
  transform: scale(0.95);
}

#pluto-launch .pluto-bot-avatar {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  pointer-events: none;
  filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.15));
}

#pluto-panel {
  position: fixed;
  bottom: 104px;
  right: 24px;
  width: min(390px, calc(100vw - 32px));
  height: min(540px, calc(100vh - 140px));
  background: #ffffff;
  border: 1px solid var(--lavender-200);
  border-radius: 22px;
  box-shadow: 0 30px 70px -18px rgba(23, 19, 49, 0.35), 0 0 1px 1px rgba(109, 73, 248, 0.1);
  z-index: 10005;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  transform: translateY(24px) scale(0.96);
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

#pluto-panel.open {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.pluto-head {
  background: var(--grad-brand);
  color: #fff;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.pluto-head .pav {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
}

.pluto-head h4 {
  color: #fff;
  font-size: 1rem;
  margin: 0;
}

.pluto-head small {
  display: block;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.82);
  font-weight: 400;
}

.pluto-head button {
  margin-left: auto;
  background: rgba(255, 255, 255, 0.18);
  border: none;
  color: #fff;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  display: grid;
  place-items: center;
}

#pluto-msgs {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--lavender-50);
}

.pmsg {
  max-width: 84%;
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 0.88rem;
  line-height: 1.5;
  animation: msgIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes msgIn {
  from { opacity: 0; transform: translateY(12px) scale(0.97); }
  to { opacity: 1; transform: none; }
}

.pmsg.bot {
  background: #ffffff;
  border: 1px solid var(--lavender-200);
  color: var(--ink-700);
  border-bottom-left-radius: 4px;
  align-self: flex-start;
}

.pmsg.user {
  background: var(--grad-brand);
  color: #ffffff;
  border-bottom-right-radius: 4px;
  align-self: flex-end;
}

.ptyping {
  align-self: flex-start;
  background: #ffffff;
  border: 1px solid var(--lavender-200);
  border-radius: 16px;
  border-bottom-left-radius: 4px;
  padding: 12px 16px;
  display: flex;
  gap: 5px;
}

.ptyping span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--violet-400);
  animation: tdot 1.1s ease-in-out infinite;
}

.ptyping span:nth-child(2) { animation-delay: 0.18s; }
.ptyping span:nth-child(3) { animation-delay: 0.36s; }

@keyframes tdot {
  0%, 100% { opacity: 0.35; transform: translateY(0); }
  50% { opacity: 1; transform: translateY(-4px); }
}

.pchips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 0 16px 10px;
  background: var(--lavender-50);
}

.pchips button {
  background: #ffffff;
  border: 1px solid var(--lavender-200);
  color: var(--violet-600);
  font-family: var(--font-body);
  font-size: 0.76rem;
  font-weight: 500;
  padding: 7px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.25s ease;
}

.pchips button:hover {
  border-color: var(--violet-400);
  transform: translateY(-2px);
}

.pluto-input {
  display: flex;
  gap: 10px;
  padding: 12px 14px;
  border-top: 1px solid var(--lavender-100);
  background: #ffffff;
}

.pluto-input input {
  flex: 1;
  border: 1.5px solid var(--lavender-200);
  border-radius: 999px;
  padding: 10px 16px;
  font-family: var(--font-body);
  font-size: 0.88rem;
  outline: none;
  transition: border-color 0.25s ease;
}

.pluto-input input:focus {
  border-color: var(--violet-400);
}

.pluto-input button {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: none;
  background: var(--grad-brand);
  color: #ffffff;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: transform 0.25s ease;
}

.pluto-input button:hover {
  transform: scale(1.08);
}

.pluto-note {
  text-align: center;
  font-size: 0.68rem;
  color: var(--ink-500);
  padding: 0 12px 10px;
  background: #ffffff;
}

@media (max-width: 768px) {
  #bookFab,
  .fab {
    bottom: 14px !important;
    right: 14px !important;
    padding: 11px 18px !important;
    font-size: 13.5px !important;
    gap: 7px !important;
  }
  #pluto-panel {
    right: 12px;
    left: 12px;
    bottom: 80px;
    width: auto;
  }
  #pluto-launch {
    right: 14px;
    bottom: 8px;
    width: 72px;
    height: 72px;
  }
  .has-pluto-bot.fab-active #pluto-launch,
  body.fab-active #pluto-launch,
  body:has(#bookFab.show) #pluto-launch {
    right: 165px;
    bottom: 4px;
  }
}

@media (max-width: 390px) {
  #bookFab,
  .fab {
    bottom: 12px !important;
    right: 12px !important;
    padding: 10px 14px !important;
    font-size: 12.5px !important;
    gap: 6px !important;
  }
  #pluto-launch {
    right: 12px;
    bottom: 6px;
    width: 64px;
    height: 64px;
  }
  .has-pluto-bot.fab-active #pluto-launch,
  body.fab-active #pluto-launch,
  body:has(#bookFab.show) #pluto-launch {
    right: 146px;
    bottom: 2px;
  }
}

