/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html, body {
    font-family: 'Inter', sans-serif;
    background: #f8fafc;
    color: #0f172a;
    overflow-x: hidden;
}

/************************************
    GLOBAL DESIGN TOKENS
************************************/
:root {
    --primary: #4f46e5;
    --secondary: #0ea5e9;
    --dark: #0f172a;
    --light: #f8fafc;

    --gradient: linear-gradient(135deg, #4f46e5, #0ea5e9);
    --gradient-soft: linear-gradient(135deg, #eef2ff, #e0e7ff);

    --radius-lg: 24px;
    --radius-md: 16px;

    --shadow-sm: 0 4px 15px rgba(0,0,0,0.07);
    --shadow-md: 0 12px 30px rgba(79,70,229,0.18);
    --shadow-lg: 0 22px 70px rgba(0,0,0,0.22);
}

/************************************
            NAVBAR
************************************/
.navbar {
    position: sticky;
    top: 0;
    background: rgba(248,250,252,0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(79,70,229,0.15);
    padding: 1.2rem 5%;
    z-index: 1000;
}
.nav-container {
    max-width: 1400px;
    margin: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo {
    font-size: 1.7rem;
    font-weight: 700;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.logo-tagline {
    font-size: 0.9rem;
    opacity: 0.8;
}
.nav-links {
    display: flex;
    gap: 2rem;
}
.nav-links a {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    transition: 0.2s;
}
.nav-links a:hover {
    color: var(--primary);
}
.nav-cta {
    background: var(--gradient);
    color: white;
    padding: 0.7rem 1.8rem;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    font-weight: 600;
    box-shadow: var(--shadow-md);
    transition: 0.2s;
}
.nav-cta:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/************************************
            HERO SECTION
************************************/
.hero {
    max-width: 1400px;
    margin: auto;
    padding: 6rem 5%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}
.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 800;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.hero-content p {
    font-size: 1.2rem;
    color: #475569;
    margin: 1.5rem 0 2rem;
}
.hero-badges {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}
.badge {
    padding: 0.4rem 1rem;
    border-radius: var(--radius-md);
    background: var(--gradient-soft);
    font-size: 0.85rem;
    border: 1px solid rgba(79,70,229,0.15);
}
.hero-buttons {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1rem;
}
.btn-primary {
    background: var(--gradient);
    color: white;
    padding: 1rem 2rem;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1.05rem;
    font-weight: 600;
    box-shadow: var(--shadow-md);
    cursor: pointer;
    transition: 0.2s;
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}
.btn-secondary {
    background: white;
    border: 2px solid var(--primary);
    color: var(--primary);
    padding: 1rem 2rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
}
.btn-secondary:hover {
    background: var(--primary);
    color: white;
}
.hero-note {
    font-size: 0.95rem;
    color: #64748b;
}

/************************************
           AI PANEL (HERO)
************************************/
.ai-panel {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2rem;
    border: 1px solid rgba(79,70,229,0.15);
    box-shadow: var(--shadow-md);
}
.chat-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 1rem;
    margin-bottom: 1rem;
}
.ai-avatar {
    width: 42px;
    height: 42px;
    background: var(--gradient);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}
.chat-messages {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.message {
    padding: 1rem 1.25rem;
    border-radius: var(--radius-md);
    max-width: 85%;
    font-size: 0.95rem;
}
.message.user {
    margin-left: auto;
    background: var(--gradient);
    color: white;
}
.message.ai {
    background: #f1f5f9;
    border: 1px solid rgba(79,70,229,0.12);
}
.ai-tag {
    background: #eef2ff;
    padding: 0.7rem 1rem;
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    border-left: 3px solid var(--primary);
}
.typing-indicator {
    display: flex;
    gap: 0.35rem;
}
.dot {
    width: 8px;
    height: 8px;
    background: #cbd5e1;
    border-radius: 50%;
    animation: bounce 1.4s infinite;
}
@keyframes bounce {
    0%, 80%, 100% { transform: translateY(0) }
    40% { transform: translateY(-7px) }
}
.suggestions {
    display: flex;
    gap: 0.7rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}
.suggestion-btn {
    padding: 0.5rem 1rem;
    background: white;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    color: #475569;
    cursor: pointer;
    transition: 0.2s;
}
.suggestion-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: var(--shadow-sm);
}

/************************************
            FEATURES
************************************/
.features {
    max-width: 1400px;
    margin: auto;
    text-align: center;
    padding: 6rem 5%;
}
.features h2 {
    font-size: 2.7rem;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.features-subtitle {
    margin-top: 0.5rem;
    color: #475569;
    margin-bottom: 3rem;
}
.features-grid {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 2rem;
}
.feature-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(79,70,229,0.1);
    transition: 0.25s;
    box-shadow: var(--shadow-sm);
}
.feature-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}
.feature-icon {
    width: 70px;
    height: 70px;
    background: var(--gradient);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: auto;
    border-radius: var(--radius-md);
    font-size: 2rem;
    margin-bottom: 1rem;
}

/************************************
         HOW IT WORKS
************************************/
.how-container {
    max-width: 1200px;
    margin: auto;
    padding: 6rem 5%;
}
.how-container h2 {
    font-size: 2.7rem;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-align: center;
}
.how-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: #475569;
    margin-bottom: 3rem;
}
.how-grid {
    display: grid;
    grid-template-columns: repeat(3,1fr);
    gap: 2rem;
}
.how-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(0,0,0,0.08);
    box-shadow: var(--shadow-sm);
    transition: 0.25s;
}
.how-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}
.step-number {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

/************************************
            TECH STACK
************************************/
.stack-section {
    padding: 6rem 5%;
    background: var(--gradient-soft);
    text-align: center;
}
.stack-section h2 {
    font-size: 2.7rem;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.stack-subtitle {
    color: #475569;
    margin-bottom: 3rem;
}
.stack-grid {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 2rem;
}
.stack-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(79,70,229,0.12);
    box-shadow: var(--shadow-sm);
    transition: 0.25s;
}
.stack-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}

/************************************
    INTERACTIVE DEMO CHAT
************************************/
.ai-interactive {
    background: var(--gradient-soft);
    padding: 6rem 5%;
}
.ai-interactive h2 {
    text-align: center;
    font-size: 2.7rem;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.ai-interactive-subtitle {
    text-align: center;
    color: #475569;
    margin-bottom: 3rem;
}
.chat-interface {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(79,70,229,0.12);
    box-shadow: var(--shadow-md);
}
.chat-display {
    height: 400px;
    overflow-y: auto;
    padding-right: 1rem;
    margin-bottom: 1.5rem;
}
.chat-input-container {
    display: flex;
    gap: 1rem;
}
.chat-input {
    flex: 1;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    border: 2px solid #e2e8f0;
    font-size: 1rem;
    transition: 0.2s;
}
.chat-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79,70,229,0.15);
}
.send-btn {
    padding: 1rem 2rem;
    border-radius: var(--radius-md);
    border: none;
    background: var(--gradient);
    color: white;
    font-weight: 600;
    cursor: pointer;
    box-shadow: var(--shadow-md);
}

/************************************
            FORM
************************************/
.form-section {
    max-width: 900px;
    margin: auto;
    padding: 6rem 5%;
}
.contact-form {
    background: white;
    padding: 3rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(79,70,229,0.1);
    box-shadow: var(--shadow-md);
}
.form-group {
    margin-bottom: 1.5rem;
}
.form-group label {
    font-weight: 600;
    margin-bottom: 0.3rem;
}
.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 1rem 1.2rem;
    border-radius: var(--radius-md);
    border: 2px solid #e2e8f0;
    transition: 0.2s;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(79,70,229,0.15);
}
.submit-btn {
    width: 100%;
    padding: 1rem;
    background: var(--gradient);
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 1.1rem;
    color: white;
    box-shadow: var(--shadow-md);
}
.success-message {
    display: none;
    margin-top: 1rem;
    padding: 1rem;
    background: #10b981;
    color: white;
    border-radius: var(--radius-md);
    font-weight: 600;
}

/************************************
         TESTIMONIALS
************************************/
.testimonials {
    padding: 6rem 5%;
}
.testimonials h2 {
    font-size: 2.7rem;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-align: center;
}
.testimonials-subtitle {
    text-align: center;
    color: #475569;
    margin-bottom: 3rem;
}
.testimonial-slider {
    display: grid;
    grid-template-columns: repeat(3,1fr);
    gap: 2rem;
}
.testimonial-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(79,70,229,0.1);
    box-shadow: var(--shadow-sm);
    transition: 0.25s;
}
.testimonial-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-md);
}
.author-avatar {
    width: 50px;
    height: 50px;
    background: var(--gradient);
    border-radius: 50%;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

/************************************
            CTA BANNER
************************************/
.cta-banner {
    background: var(--gradient);
    text-align: center;
    padding: 5rem 5%;
}
.cta-banner h2 {
    color: white;
    font-size: 2.8rem;
}
.cta-banner p {
    color: rgba(255,255,255,0.9);
    font-size: 1.2rem;
    margin: 1rem auto 2rem;
}
.cta-big-btn {
    background: white;
    color: var(--primary);
    padding: 1rem 2.5rem;
    border-radius: var(--radius-md);
    font-weight: 700;
    cursor: pointer;
    box-shadow: var(--shadow-md);
}

/************************************
            FOOTER
************************************/
.footer {
    background: var(--dark);
    padding: 4rem 5%;
    color: #cbd5e1;
}
.footer-container {
    max-width: 1400px;
    margin: auto;
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 3rem;
}
.footer-column h3 {
    font-size: 1.2rem;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.footer-links a {
    color: #94a3b8;
    transition: 0.2s;
}
.footer-links a:hover {
    color: var(--secondary);
}

/************************************
        RESPONSIVE BREAKPOINTS
************************************/
@media (max-width: 1024px) {
    .hero {
        grid-template-columns: 1fr;
    }
    .features-grid,
    .testimonial-slider,
    .stack-grid {
        grid-template-columns: repeat(2,1fr);
    }
}
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    .features-grid,
    .testimonial-slider,
    .stack-grid,
    .how-grid,
    .footer-container {
        grid-template-columns: 1fr;
    }
    .hero-content h1 {
        font-size: 2.4rem;
    }
}
/* === AI Interactive Layout Enhancements === */

.ai-layout {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
  gap: 2rem;
  align-items: flex-start;
  margin-top: 1.5rem;
}

@media (max-width: 900px) {
  .ai-layout {
    grid-template-columns: 1fr;
  }
}

.chat-interface {
  background: #b5c2f721;
  border-radius: 1.25rem;
  padding: 1.25rem;
  border: 1px solid #1f2937;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.65);
}

.chat-display {
  max-height: 360px;
  overflow-y: auto;
  padding-right: 0.5rem;
  margin-bottom: 1rem;
}

/* Smooth scrollbar */
.chat-display::-webkit-scrollbar {
  width: 6px;
}
.chat-display::-webkit-scrollbar-track {
  background: #020617;
}
.chat-display::-webkit-scrollbar-thumb {
  background: #334155;
  border-radius: 999px;
}

.chat-input-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.5rem;
}

.chat-input {
  flex: 1;
  border-radius: 999px;
  border: 1px solid #1f2937;
  background: #02061705;
  padding: 0.6rem 0.9rem;
  color: #e5e7eb;
  font-size: 0.95rem;
  outline: none;
}

.chat-input::placeholder {
  color: #6b7280;
}

.send-btn,
.mic-btn {
  border-radius: 999px;
  border: none;
  padding: 0.55rem 0.9rem;
  cursor: pointer;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  transition: transform 0.1s ease, box-shadow 0.1s ease, background 0.15s ease;
}

.send-btn {
  background: #4f46e5;
  color: white;
}
.send-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(79, 70, 229, 0.5);
}

.mic-btn {
  background: #121c33b8;
  color: #f97316;
  border: 1px solid #1f2937;
}
.mic-btn.recording {
  background: #b91c1c;
  color: #fee2e2;
  box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.4);
}

/* Messages */
.message {
  margin-bottom: 0.6rem;
  padding: 0.6rem 0.8rem;
  border-radius: 0.9rem;
  font-size: 0.9rem;
  line-height: 1.5;
}

.message.user {
  background: linear-gradient(to right, #4f46e5, #7c3aed);
  color: white;
  margin-left: auto;
  max-width: 80%;
}

.message.ai {
  background: #f4f4f4;
  border: 1px solid #1f2937;
  color: #020617;
  margin-right: auto;
  max-width: 90%;
}

.ai-response-card {
  border-radius: 0.9rem;
  border: 1px dashed #334155;
  background: rgba(15, 23, 42, 0.85);
  padding: 0.75rem 0.9rem;
  margin-bottom: 0.8rem;
  font-size: 0.85rem;
}

/* Typing Indicator */
.typing-indicator {
  display: inline-flex;
  gap: 0.25rem;
  padding: 0.35rem 0.6rem;
  border-radius: 999px;
  background: #6da3e961;
  border: 1px solid #1f2937;
  margin-bottom: 0.5rem;
}

.dot {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: #9ca3af;
  animation: blink 1s infinite ease-in-out;
}
.dot:nth-child(2) {
  animation-delay: 0.15s;
}
.dot:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes blink {
  0%, 80%, 100% { opacity: 0.2; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-2px); }
}

/* Side Panel */
.ai-side-panel {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.ticket-panel,
.flow-card {
  background: #e0e0e0;
  border-radius: 1.25rem;
  padding: 1rem 1.05rem;
  border: 1px solid #1f2937;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.7);
}

.ticket-panel h3,
.flow-card h3 {
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
}

.ticket-empty {
  font-size: 0.85rem;
  color: #9ca3af;
}

.ticket-details.hidden {
  display: none;
}

.ticket-details {
  margin-top: 0.45rem;
  font-size: 0.85rem;
}

.ticket-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.3rem;
  gap: 0.75rem;
}

.ticket-label {
  color: #000000;
}
.ticket-value {
  color: #000000;
  font-weight: 500;
}

/* Flow Diagram */
.flow-subtitle {
  font-size: 0.8rem;
  color: #9ca3af;
  margin-bottom: 0.6rem;
}

.flow-steps {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.flow-step {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.6rem;
  border-radius: 0.8rem;
  border: 1px solid #111827;
  background: #020617;
  transition: border 0.15s ease, background 0.15s ease, transform 0.12s ease;
}

.flow-step.active {
  border-color: #4f46e5;
  background: radial-gradient(circle at top left, rgba(79, 70, 229, 0.25), #020617);
  transform: translateY(-1px);
}

.step-badge {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #111827;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  color: #e5e7eb;
}

.flow-step.active .step-badge {
  background: #4f46e5;
}

.step-title {
  font-size: 0.85rem;
  font-weight: 600;
}
.step-desc {
  font-size: 0.75rem;
  color: #f4f4f4;
}

.flow-footnote {
  margin-top: 0.5rem;
  font-size: 0.75rem;
  color: #6b7280;
}

/* Toast Notifications */
#toast-container {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  z-index: 9999;
}

.toast {
  min-width: 240px;
  max-width: 320px;
  background: #020617;
  border-radius: 0.9rem;
  border: 1px solid #1f2937;
  padding: 0.65rem 0.9rem;
  font-size: 0.8rem;
  color: #e5e7eb;
  box-shadow: 0 16px 45px rgba(15, 23, 42, 0.85);
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  animation: toast-in 0.18s ease-out;
}

.toast-success {
  border-color: #16a34a;
}
.toast-error {
  border-color: #ef4444;
}
.toast-info {
  border-color: #4f46e5;
}

.toast-icon {
  font-size: 1rem;
  margin-top: 1px;
}
.toast-message {
  flex: 1;
}

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