﻿/* CSS Variables for Consistency */
:root {
  --primary-purple: #663399;
  --primary-purple-dark: #4b2667;
  --accent-red: #ff3131;
  --cta-red: #E74C3C;
  --accent-green: #6AA84F;
  --background-gray: #EDEDED;
  --background-light: #F4F4F4;
  --white: #fff;
  --shadow: 0 4px 24px rgba(102, 51, 153, 0.10), 0 1.5px 0 #e5e5f7;
  --radius: 8px;
  --font-main: 'Segoe UI', Arial, sans-serif;
}

/* General Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-main);
  line-height: 1.6;
  color: #333;
  background-color: var(--background-gray);
  padding: 0 20px;
  font-size: 1.08rem;
}

/* Header */
.header {
  text-align: center;
  padding: 2.5rem 1rem 2rem 1rem;
  background: var(--primary-purple);
  color: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 2rem;
}

.header-content {
  margin-bottom: 1.5rem;
}

.header h1 {
  font-size: 2.7rem;
  margin-bottom: 1rem;
  color: var(--accent-red);
  font-weight: 800;
  letter-spacing: 1.5px;
}

.header h3 {
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--white);
  margin-bottom: 0.5rem;
}

.header p {
  font-size: 1.2rem;
  color: var(--white);
}

.header-image {
  margin-top: 1.5rem;
}

.book-cover-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0.5rem 0;
  background-color: var(--primary-purple);
  margin: 0 auto;
  border-radius: var(--radius);
}

.book-cover-container img {
  max-width: 80%;
  max-height: 400px;
  width: auto;
  height: auto;
  border-radius: var(--radius);
  box-shadow: 0 4px 16px rgba(102, 51, 153, 0.18);
}

@media (max-width: 768px) {
  .book-cover {
    margin-top: 0.5rem;
  }
}

main {
  margin: 2rem auto;
  max-width: 900px;
}

/* About Section */
.about {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: 0 4px 12px rgba(102, 51, 153, 0.08);
  margin-bottom: 2rem;
  text-align: center;
  color: #333;
}

.about h2 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: var(--primary-purple);
  font-weight: 700;
}

.about p {
  font-size: 1.1rem;
}

.learn {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: 0 4px 12px rgba(102, 51, 153, 0.08);
  margin-bottom: 2rem;
  text-align: center;
  color: #333;
}

.learn h2 {
  font-size: 1.7rem;
  margin-bottom: 1.1rem;
  color: var(--primary-purple);
  font-weight: 700;
  letter-spacing: 0.5px;
  text-align: center;
}

.learn ul {
  list-style: none;
  padding-left: 0;
  margin: 1.5rem 0 1rem 0;
  list-style-position: inside;
}

.learn li {
  display: flex;
  align-items: flex-start;
  background: var(--background-light);
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(102, 51, 153, 0.06);
  margin-bottom: 1.1rem;
  padding: 1.1rem 1.2rem;
  color: inherit;
  position: relative;
  transition: box-shadow 0.2s, background 0.2s;
}
.learn li:hover {
  box-shadow: 0 4px 16px rgba(102, 51, 153, 0.13);
  background: #f7f5fa;
}

.learn li::before {
  content: '\2714'; /* Checkmark */
  color: var(--accent-green);
  font-size: 1.3em;
  margin-right: 1em;
  line-height: 1.2;
  flex-shrink: 0;
  display: inline-block;
}

.learn li strong {
  color: var(--primary-purple);
  font-weight: 700;
  margin-right: 0.5rem;
  min-width: 180px;
  text-align: left;
  flex-shrink: 0;
  display: inline-block;
}

.learn li div {
  color: #222;
  font-weight: 400;
  margin: 0;
  text-align: left;
  display: inline;
  flex: 1 1 0%;
  margin-left: 0;
}

@media (max-width: 600px) {
  .learn li {
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem 0.7rem;
  }
  .learn li strong {
    min-width: 0;
    margin-bottom: 0.2rem;
  }
}

/* Conversion Section */
.conversion {
  background: var(--white);
  text-align: center;
  padding: 2rem;
  border-radius: var(--radius);
  margin-top: 2rem;
  margin-bottom: 2rem;
  box-shadow: 0 2px 8px rgba(102, 51, 153, 0.08);
}

.conversion h2 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: var(--cta-red);
  font-weight: 700;
}

.cta-buttons {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

/* Testimonials Section */
.testimonials {
  text-align: center;
  padding: 2rem;
  background: var(--white);
  border-radius: var(--radius);
  margin-bottom: 2rem;
  box-shadow: 0 4px 12px rgba(102, 51, 153, 0.08);
}

.testimonials blockquote {
  margin: 1rem 0;
  font-style: italic;
  background: #F9F9F9;
  padding: 1rem;
  border-radius: var(--radius);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.08);
}

.testimonials cite {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.95rem;
  color: #555;
}

/* Button base styles */
.button, .navbutton, .nav .button {
  display: inline-block;
  padding: 0.7rem 1.5rem;
  font-size: 1.08rem;
  background: linear-gradient(90deg, var(--primary-purple) 0%, #836fa9 100%);
  color: var(--white);
  text-decoration: none;
  border-radius: 7px;
  border: none;
  font-weight: 600;
  font-family: var(--font-main);
  box-shadow: 0 2px 8px rgba(102, 51, 153, 0.10);
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
  margin: 5px;
  outline: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  width: auto;
  min-width: 127px;
  max-width: none;
  flex: 0 0 auto;
  justify-content: center; /* Add this for horizontal centering */
}

.button:hover, .navbutton:hover, .nav .button:hover, .button:focus {
  background: linear-gradient(90deg, var(--primary-purple-dark) 0%, var(--primary-purple) 100%);
  transform: translateY(-2px) scale(1.045);
  box-shadow: 0 4px 16px rgba(102, 51, 153, 0.18);
  color: var(--white);
}

.nav .active.button, .nav .button.active {
  box-shadow: 0 6px 24px rgba(102, 51, 153, 0.18);
  border: 2px solid #836fa9;
  background: linear-gradient(90deg, #836fa9 0%, var(--primary-purple) 100%);
  color: var(--white);
}

@media (max-width: 900px) {
  .navbar {
    padding: 0.7rem 0.5rem;
    border-radius: 0;
  }
  .navbar-brand-themed {
    font-size: 1.3rem;
    padding-bottom: 0.1rem;
  }
  .button, .nav .button {
    font-size: 0.98rem;
    padding: 0.6rem 1rem;
    margin: 0 0.2rem 0.5rem 0.2rem;
  }
}

@media (max-width: 768px) {
  .button, .navbutton, .nav .button {
    margin-bottom: 0.8rem;
    max-width: 100%;
  }
  .book-cover-container img {
    max-width: 100%;
    max-height: 250px;
  }
  main {
    padding: 0 0.5rem;
  }
}

.footer {
  text-align: center;
  padding: 1rem;
  background: var(--primary-purple);
  color: var(--white);
  font-size: 0.98rem;
  border-radius: var(--radius);
  margin-top: 2rem;
}

/* Navbar Styles */
.navbar {
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 1.2rem 2.2rem;
  background: var(--background-gray);
  margin-bottom: 2.2rem !important;
  font-family: var(--font-main);
}

.navbar-brand-themed {
  font-family: var(--font-main);
  font-size: 2.1rem;
  font-weight: 800;
  color: var(--primary-purple);
  text-shadow: 0 2px 8px rgba(102, 51, 153, 0.10);
  letter-spacing: 2px;
  text-transform: uppercase;
  border-bottom: 2.5px solid #836fa9;
  padding-bottom: 0.2rem;
  margin-bottom: 0.5rem;
  background: linear-gradient(90deg, var(--primary-purple) 0%, #836fa9 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.navbar-brand-themed:hover {
  color: var(--primary-purple-dark);
  text-shadow: 0 4px 16px rgba(102, 51, 153, 0.18);
  border-bottom: 2.5px solid var(--primary-purple-dark);
}

.navbar-nav,
.navbar-collapse,
.navbar-expand-sm,
.nav-item,
.nav-link {
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  margin-bottom: 4px;
  padding-bottom: 0;
}

/* Utility and Section Styles (unchanged, but use variables where possible) */
.role-group-container {
  border: 1px solid #ccc;
  border-radius: var(--radius);
  padding: 15px;
  width: fit-content;
  margin-bottom: 15px;
}

.role-group-title {
  font-weight: bold;
  margin-bottom: 10px;
}

.radio-group {
  display: flex;
  flex-direction: column;
}

.radio-group div {
  display: flex;
  align-items: center;
  margin-bottom: 5px;
}

.radio-group label {
  margin-left: 8px;
}

.checkbox-group {
  display: flex;
  align-items: center;
  margin-top: 5px;
}

.checkbox-group label {
  margin-left: 8px;
}

body.waitlist-page .container,
body.waitlist-page main {
  margin-top: 0;
  padding-top: 0;
}

.waitlistform-container {
  margin-top: 0;
  padding-top: 0;
}

.waitlistform-heading {
  margin-bottom: 10px;
}

.no-bullets-no-border {
  list-style: none;
  padding: 0;
  margin: 0;
  border: none;
  display: flex;
  flex-direction: row;
}

.no-bullets-no-border li {
  margin: 0px 0;
}

.no-bullets-no-border li a {
  display: inline-block;
  padding: 6px 12px;
  text-decoration: none;
  color: var(--white);
  background-color: #6c2eb9;
  border-radius: 5px;
}

@media (max-width: 800px) {
  .no-bullets-no-border {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* Chatbot and Modal Styles (unchanged, but use variables where possible) */
.empowered-sales-agent-window {
  position: fixed;
  bottom: 2vw;
  right: 2vw;
  min-width: 260px;
  max-width: 20vw;
  min-height: 120px;
  max-height: 70vh;
  z-index: 1000;
  box-shadow: 0px 4px 24px rgba(102, 51, 153, 0.13), 0 1.5px 0 #e5e5f7;
  border: 1.5px solid #d1c4e9;
  border-radius: 12px;
  overflow: hidden;
  background: var(--white);
  display: flex;
  flex-direction: column;
  padding: 0;
}

@media (max-width: 900px), (max-height: 700px) {
  .empowered-sales-agent-window {
    max-width: 95vw;
    min-width: 180px;
    min-height: 80px;
    max-height: 60vh;
  }
}

@media (max-width: 600px) {
  .empowered-sales-agent-window {
    width: 100vw;
    right: 0;
    bottom: 0;
    height: 40vh;
    min-width: 120px;
    min-height: 120px;
    max-width: 100vw;
    max-height: 50vh;
    border-radius: 0;
  }
}

.chat-container {
  display: flex;
  flex-direction: column;
  height: auto;
  min-height: 0;
  max-width: 100%;
  margin: 0;
  border: none;
  border-radius: 0;
  overflow: hidden;
  box-shadow: none;
  background: transparent;
}

.chat-header {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  flex-wrap: nowrap; /* Prevent wrapping */
  background-color: var(--primary-purple);
  color: var(--white);
  padding: 0.7rem 2.5rem 0.7rem 1rem;
  font-size: 1rem;
  font-weight: bold;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
  box-sizing: border-box;
  width: 100%;
  margin: 0;
  gap: 2rem;
}

.chat-header-title {
  flex: 1 1 0%;
  min-width: 0;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.chat-header-title h3 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--white);
  word-break: break-word;
  overflow-wrap: break-word;
  white-space: normal;
  width: 100%;
}

.chat-header-buttons {
  display: flex;
  gap: 8px;
  flex: 0 0 auto;
  align-items: center;
  margin-left: 1rem;
  min-width: 0;
}

.chat-header-btn {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.3rem;
  cursor: pointer;
  padding: 0 6px;
  line-height: 1;
  transition: color 0.2s, background 0.2s;
  text-align: center;
  border-radius: 4px;
  min-width: 32px;
  min-height: 32px;
  box-sizing: border-box;
}

@media (max-width: 600px) {
  .chat-header {
    padding: 1px 1px 1px 1px !important; /* less left/right padding */
    gap: 0.5rem;
  }
  .chat-header-title h3 {
    font-size: 0.95rem !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
  }
  .chat-header-buttons {
    flex-direction: row !important;
    gap: 2px !important;
    padding: 0 !important;
    margin-left: 0 !important;
  }
  .chat-header-btn {
    min-width: 24px !important;
    min-height: 24px !important;
    font-size: 1rem !important;
    padding: 0 2px !important;
  }
  .chat-history {
    max-height: 600px !important;
    height: auto !important;
    min-height: 0 !important;
    overflow-y: auto;
  }
}

.chat-history {
  flex: 1 1 auto;
  min-height: 0;
  max-height: 50vh;
  overflow-y: auto;
  padding: 18px 18px 8px 18px;
  background-color: #f9f9f9;
  border-bottom: 1px solid #e0e0e0;
}

.chat-message {
  margin: 5px 0;
  padding: 10px 14px;
  border-radius: var(--radius);
  max-width: 80%;
  font-size: 1rem;
  word-break: break-word;
}

.user-message  {
  background-color: var(--background-gray, #e5e5ea);
  color: black;
  align-self: flex-end;
  display: flex;
  justify-content: flex-end; /* align text to right horizontally */
  align-items: center; /* align text vertically center */
  text-align: right;
  margin: 0;
  margin-left: auto;
  margin-right: 0;
  max-width: 60%;
  border-radius: 16px 16px 4px 16px;
  font-weight: bold;
  padding: 10px 14px;
  word-wrap: break-word;
  white-space: pre-wrap;
}

/*p adds a margine I dont what in the user message*/
  .user-message p {
    margin: 0;
  }



.bot-message {
  background-color: #836fa9;
  color: var(--white);
  align-self: flex-start;
  text-align: left;
  border-radius: 16px 16px 16px 4px;
}

/* Ensure chat-input is positioned for overlay */
.chat-input {
  flex-shrink: 0;
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 12px 10px 12px 10px;
  border-top: 1px solid #e0e0e0;
  background-color: var(--white);
  position: relative; /* Required for spinner overlay */
  min-height: 54px;
}

.spinner-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: rgba(255, 255, 255, 0.8);
  z-index: 100;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #ccc;
  border-top: 4px solid #0078d4;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  background: transparent;
  z-index: 101;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.input-box {
  flex: 1 1 auto;
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 6px;
  resize: none;
  font-size: 1rem;
  min-height: 38px;
  max-height: 80px;
  box-sizing: border-box;
  margin-right: 0;
}

.send-button {
  flex-shrink: 0;
  height: 38px;
  padding: 0 18px;
  background-color: var(--primary-purple);
  color: var(--white);
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  transition: background 0.2s;
  margin-left: 4px;
  margin-bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.send-button:hover {
  background-color: var(--primary-purple-dark);
}

/* Ensure minimized state still works */
.chat-container.minimized {
  min-height: 0 !important;
  max-height: 600px !important;
  overflow: hidden;
  transition: height 0.3s, max-height 0.3s;
}

/* Always show input box if not minimized */
.chat-container:not(.minimized) .chat-input {
  display: flex !important;
}

/* Prevent input box from being hidden at high zoom */
@media (max-width: 400px), (max-height: 400px) {
  .empowered-sales-agent-window {
    min-width: 80px;
    max-width: 100vw;
    min-height: 60px;
    max-height: 80vw;
  }
  .chat-history {
    max-height: 20vw;
  }
}

@media (max-width: 768px) {
  #SalesBot {
    display: none !important;
  }
  .empowered-sales-agent-window {
    width: 100vw;
    min-width: 120px;
    max-width: 100vw;
    right: 0;
    bottom: 0;
    min-height: 80px;
    max-height: 50vh;
    border-radius: 0;
  }
}

@media (max-width: 768px) {
  #narrow-salesagent {
    display: block;
  }
}

@media (min-width: 769px) {
  #narrow-salesagent {
    display: none;
  }
}

/* Blazor error UI */
.blazor-error-ui {
  color-scheme: light only;
  background: lightyellow;
  bottom: 0;
  box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
  box-sizing: border-box;
  display: none;
  left: 0;
  padding: 0.6rem 1.25rem 0.7rem 1.25rem;
  position: fixed;
  width: 100%;
  z-index: 1000;
}

.blazor-error-ui .dismiss {
  cursor: pointer;
  position: absolute;
  right: 0.75rem;
  top: 0.5rem;
}

/* --- Custom List Layout for About & Learn Sections --- */
.about ul, .learn ul {
  list-style: disc inside;
  padding-left: 0;
  margin: 1.5rem 0 1rem 0;
}

.about li, .learn li {
  display: flex;
  align-items: flex-start;
  text-align: left;
  margin-bottom: 1.2rem;
  color: inherit;
  position: relative;
}

/* Add custom bullet for flex items */
.about ul, .learn ul {
  list-style: none;
  padding-left: 0;
}
.about li::before, .learn li::before {
  content: '\2022'; /* Unicode for bullet */
  color: var(--accent-green);
  font-size: 1.3em;
  margin-right: 0.7em;
  line-height: 1.2;
  flex-shrink: 0;
  display: inline-block;
}

.about li > strong, .learn li > strong {
  min-width: 220px;
  color: var(--primary-purple);
  font-weight: 700;
  margin-right: 0.5rem;
  text-align: left;
  flex-shrink: 0;
  display: inline-block;
}

.about li > p, .learn li > span {
  color: #222;
  font-weight: 400;
  margin: 0;
  text-align: left;
  display: block;
  flex: 1 1 0%;
  margin-left: 0;
}

.about li > p {
  margin-top: 0.1rem;
}

@media (max-width: 600px) {
  .about li, .learn li {
    flex-direction: column;
    align-items: flex-start;
  }
  .about li > strong, .learn li > strong {
    min-width: 0;
    margin-bottom: 0.2rem;
  }
}

/* Chat Header Close Button */
.chat-header {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #6a1b9a;
  color: var(--white);
  padding: 10px 40px 10px 10px;
  text-align: center;
  font-size: 0.75rem;
  font-weight: bold;
}

.chat-header h3 {
  flex: 1;
  margin: 0;
  font-size: 1.1rem;
}

.chat-close {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.3rem;
  cursor: pointer;
  padding: 0 6px;
  line-height: 1;
  transition: color 0.2s;
}

.chat-close:hover {
  color: #ff3131;
}

/* Minimized Chat */
.chat-container.minimized {
  min-height: 0 !important;
  max-height: 600px !important;
  overflow: hidden;
  transition: height 0.3s, max-height 0.3s;
}

.chat-container.minimized .chat-header {
  border-radius: var(--radius);
}

.chat-container.minimized .chat-history,
.chat-container.minimized .chat-input {
  display: none !important;
}

.empowered-sales-agent-window:has(.chat-container.minimized) {
  min-height: 0;
  max-height: none;
}

/* Chat Header Buttons */
/* Chat Header Buttons */
.chat-header-buttons {
  display: flex;
  flex-direction: row;
  gap: 8px;
  align-items: center;
  background: transparent;
  /* Remove position: absolute, right, top, and transform */
  margin-left: 4px; /* Small gap from the title */
  min-width: 0;
}

/* Ensure header uses flex row and allows shrinking */
.chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 10px;
}

/* Allow title to shrink and ellipsis */
.chat-header-title {
  flex: 1 1 0%;
  min-width: 0;
  padding: 0;
  margin: 0;
  display: flex;
  align-items: center;
}
.chat-header-title h3 {
  font-size: 1.1rem;
  margin: 0;
  padding: 0;
  min-width: 0;
  flex: 1 1 0%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Responsive: shrink padding, font, and gap on small screens */
@media (max-width: 600px) {
  .chat-header {
    padding: 4px 4px;
    gap: 4px;
  }
  .chat-header-title h3 {
    font-size: 0.9rem;
  }
  .chat-header-buttons {
    gap: 2px;
    margin-left: 4px;
  }
  .chat-header-btn {
    min-width: 24px;
    min-height: 24px;
    font-size: 1rem;
    padding: 0 2px;
  }
}

.chat-header-btn {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.3rem;
  cursor: pointer;
  padding: 0 6px;
  line-height: 1;
  transition: color 0.2s, background 0.2s;
  text-align: center;
  border-radius: 4px;
}

.chat-header-btn:hover {
  background: rgba(255,255,255,0.12);
  color: #ff3131;
}


.about p {
  text-align: justify;
}

.learn ul {
  list-style-position: inside;
}

.learn li {
  display: list-item;
}

  .learn li > div {
    display: inline;
  }

.electronic-couponing-purple .border-primary {
  border-color: var(--primary-purple) !important;
}
.electronic-couponing-purple .text-primary {
  color: var(--primary-purple) !important;
}
.electronic-couponing-purple .btn-primary {
  background-color: var(--primary-purple) !important;
  border-color: var(--primary-purple) !important;
}
.electronic-couponing-purple .btn-primary:hover,
.electronic-couponing-purple .btn-primary:focus {
  background-color: var(--primary-purple-dark) !important;
  border-color: var(--primary-purple-dark) !important;
}

@media (max-width: 600px) {
  .chat-container {
    max-width: 100vw !important;
    min-width: 120px !important;
    border-radius: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    top: auto !important;
  }
  .chat-header {
    font-size: 0.95rem;
    padding: 0.5rem 1rem;
  }
  .chat-header-buttons {
    flex-direction: row !important;
    gap: 2px !important;
    padding: 0 !important;
    margin-left: 0 !important;
  }
  .chat-header-buttons .chat-header-btn {
    min-width: 24px !important;
    min-height: 24px !important;
    font-size: 1rem !important;
    padding: 0 2px !important;
  }
}

@media (max-width: 600px) {
  .d-flex.justify-content-center {
    flex-direction: column !important;
  }

    .d-flex.justify-content-center > .button {
      margin-left: 0 !important;
      margin-right: 0 !important;
    }
}

.d-flex.justify-content-center {
  flex-direction: row !important;
  align-items: flex-start !important;
}

.d-flex.justify-content-center > .button {
  margin-left: 0 !important;
  margin-right: 0 !important;
  gap: 0.5rem !important;
}

@media (max-width: 600px) {
  .d-flex.justify-content-center > .button {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}

@media (max-width: 600px) {
  /* Make the NavMenu row stack vertically and center content */
  .navbar > .row.justify-content-center {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    width: 100% !important;
    margin: 0 auto !important;
    padding: 0 !important;
  }
  /* Ensure homepageTitle stacks and centers its children */
  .homepage-title {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    text-align: center !important;
    margin-bottom: 1.5rem !important;
  }
  .homepage-title .d-flex.justify-content-center {
    flex-direction: column !important;
    align-items: center !important;
    width: 100% !important;
    margin-top: 0.5rem !important;
  }
  .homepage-title .button {
    width: 90vw !important;
    max-width: 350px !important;
    margin: 0.3rem 0 !important;
    justify-content: center !important;
  }
  #bookTitle {
    margin-bottom: 0.7rem !important;
    font-size: 1.3rem !important;
    width: 100% !important;
    text-align: center !important;
    white-space: normal !important;
    overflow-wrap: break-word !important;
  }
}

#bookTitle {
  white-space: normal;
  overflow-wrap: break-word;
  word-break: keep-all;
}

/* Add spacing and min-width for NavMenu Home/News buttons */
.homepage-title .d-flex.justify-content-center > .button {
  min-width: 197px !important;
  margin-left: 12px !important;
  margin-right: 12px !important;
}

@media (max-width: 600px) {
  .homepage-title .d-flex.justify-content-center > .button {
    min-width: 90vw !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}

/* ContentTraker SDK Q&A */
.empowered-sales-agent-window:has(.snapchingiq-qna) {
  right: 1rem;
  bottom: 1rem;
  width: min(22.5rem, calc(100vw - 2rem));
  min-width: 16rem;
  max-width: none;
  min-height: 0;
  max-height: none;
  border: none;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
  z-index: 1100;
}

.snapchingiq-qna {
  --phx-chat-accent: #6c2eb9;
  --phx-chat-accent-hover: #4b167e;
  --phx-chat-input-focus-ring: rgba(108, 46, 185, 0.2);
  --phx-chat-title-color: #35105a;
  --phx-chat-subtitle-color: #607080;
  --phx-chat-header-bg: #f8f5ff;
  --phx-chat-user-bubble-bg: #6c2eb9;
  --phx-chat-chip-hover-bg: #f2eaff;
  --phx-chat-chip-hover-border: #b88af0;
  --phx-chat-chip-hover-color: #4b167e;
}

.snapchingiq-qna-open {
  width: 100%;
  border: 0;
  padding: 0.95rem 1.1rem;
  background: #6c2eb9;
  color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 18px 48px rgba(53, 16, 90, 0.18);
  cursor: pointer;
  font: inherit;
  font-size: 1rem;
  font-weight: 800;
  transition: background 0.15s ease, transform 0.15s ease;
}

.snapchingiq-qna-open:hover {
  background: #4b167e;
  transform: translateY(-1px);
}

.snapchingiq-qna-open:focus-visible {
  outline: 3px solid rgba(108, 46, 185, 0.32);
  outline-offset: 2px;
}

.phx-chat-popup-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.24);
  z-index: 1050;
}

.phx-chat-popup-dialog {
  --phx-chat-popup-width: 34rem;
  --phx-chat-popup-height: 42rem;
  position: fixed;
  right: 1.5rem;
  bottom: 1.5rem;
  width: min(var(--phx-chat-popup-width), calc(100vw - 2rem));
  height: min(var(--phx-chat-popup-height), calc(100vh - 2rem));
  border-radius: 1rem;
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);
}

.phx-chat-popup-dialog .phx-chat {
  height: 100%;
  border-radius: inherit;
}

.phx-chat-popup-close {
  border: 1px solid #d1d5db;
  border-radius: 999px;
  width: 2rem;
  height: 2rem;
  background: #ffffff;
  color: #475569;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
}

.phx-chat-popup-close:hover {
  background: #f8fafc;
  border-color: #94a3b8;
  color: #0f172a;
}

.snapchingiq-qna-popup-dialog {
  --phx-chat-popup-width: 42rem;
  --phx-chat-popup-height: 44rem;
}

.snapchingiq-qna-chat {
  border-radius: 8px;
  overflow: hidden;
}

.snapchingiq-qna-chat-title {
  color: #35105a;
}

.snapchingiq-qna-chat-send-btn {
  background: #00747a;
}

.snapchingiq-qna-chat-send-btn:hover:not(:disabled) {
  background: #005d62;
}

@media (max-width: 700px) {
  .empowered-sales-agent-window:has(.snapchingiq-qna) {
    right: 0.75rem;
    bottom: 0.75rem;
    width: calc(100vw - 1.5rem);
    min-width: 0;
  }

  .snapchingiq-qna-popup-dialog {
    --phx-chat-popup-width: calc(100vw - 1rem);
    --phx-chat-popup-height: calc(100vh - 1rem);
  }
}

/* --- Vibrant SnapChingIQ redesign --- */
:root {
  --brand-purple: #5d248b;
  --brand-purple-dark: #35124f;
  --brand-red: #ff3131;
  --brand-green: #4f8520;
  --brand-gold: #ffbc42;
  --brand-teal: #006d77;
  --brand-ink: #1f2233;
  --brand-muted: #5e6472;
  --brand-paper: #ffffff;
  --brand-surface: #f6f8f3;
  --brand-surface-cool: #eef7fb;
  --brand-line: rgba(31, 34, 51, 0.14);
  --brand-shadow: 0 14px 40px rgba(31, 34, 51, 0.12);
}

html {
  scroll-behavior: smooth;
}

body {
  padding: 0;
  color: var(--brand-ink);
  background: var(--brand-surface);
  font-size: 1rem;
  letter-spacing: 0;
}

.site-main {
  width: 100%;
  overflow-x: hidden;
}

.site-main > main {
  max-width: none;
  margin: 0;
  padding: 0;
}

.home-page,
.model-page,
.resource-page,
.waitlist-page,
.content-admin-page,
.content-page {
  width: 100%;
  max-width: none;
  margin: 0;
}

.navbar {
  width: min(1120px, calc(100% - 32px));
  margin: 16px auto 0 auto !important;
  padding: 16px 20px;
  border: 1px solid var(--brand-line) !important;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 8px 24px rgba(31, 34, 51, 0.08);
}

.navbar-brand-themed {
  color: var(--brand-purple);
  letter-spacing: 0;
  text-transform: none;
  border-bottom: 3px solid var(--brand-gold);
  background: none;
  -webkit-text-fill-color: currentColor;
  text-shadow: none;
}

.button,
.navbutton,
.nav .button,
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  min-width: 0;
  padding: 0.72rem 1.1rem;
  border: 1px solid transparent;
  border-radius: 8px;
  background: var(--brand-purple);
  color: var(--brand-paper) !important;
  font-weight: 750;
  line-height: 1.15;
  letter-spacing: 0;
  text-decoration: none;
  box-shadow: none;
  transition: transform 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

.button:hover,
.navbutton:hover,
.nav .button:hover,
.button:focus,
.btn-primary:hover,
.btn-primary:focus {
  transform: translateY(-1px);
  background: var(--brand-purple-dark);
  color: var(--brand-paper) !important;
}

.button-hot {
  background: var(--brand-red);
}

.button-hot:hover,
.button-hot:focus {
  background: #d62424;
}

.button-cool {
  background: var(--brand-teal);
}

.button-cool:hover,
.button-cool:focus {
  background: #004f57;
}

.button-quiet {
  background: transparent;
  color: var(--brand-purple) !important;
  border-color: rgba(93, 36, 139, 0.35);
}

.button-quiet:hover,
.button-quiet:focus {
  background: rgba(93, 36, 139, 0.08);
  color: var(--brand-purple-dark) !important;
}

.eyebrow {
  margin: 0 0 0.75rem 0;
  color: var(--brand-teal);
  font-size: 0.85rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

.book-hero,
.model-hero,
.resource-hero,
.form-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.95fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 4rem);
  width: 100%;
  padding: clamp(3rem, 8vw, 6rem) max(24px, calc((100vw - 1120px) / 2));
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(246, 248, 243, 0.96) 45%, rgba(238, 247, 251, 0.98) 100%);
  border-bottom: 1px solid var(--brand-line);
}

.book-hero h1,
.model-hero h1,
.resource-hero h1,
.form-hero h1 {
  max-width: 100%;
  margin: 0;
  color: var(--brand-purple-dark);
  font-size: clamp(2.4rem, 4.8vw, 4.3rem);
  line-height: 1;
  font-weight: 900;
  letter-spacing: 0;
  overflow-wrap: break-word;
}

.model-hero h1,
.resource-hero h1,
.form-hero h1 {
  font-size: clamp(2.25rem, 4vw, 3.75rem);
}

.book-hero__copy,
.model-hero > div,
.resource-hero > div,
.form-hero > div {
  min-width: 0;
}

.hero-subtitle,
.book-hero p,
.model-hero p,
.resource-hero p,
.form-hero p {
  max-width: 680px;
  margin-top: 1.2rem;
  color: var(--brand-muted);
  font-size: clamp(1.08rem, 2.2vw, 1.35rem);
  line-height: 1.55;
}

.book-hero__media {
  display: flex;
  justify-content: center;
  min-width: 0;
}

.book-cover,
.book-hero__media img {
  width: min(390px, 100%);
  max-height: 620px;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: var(--brand-shadow);
}

.model-hero img {
  width: min(540px, 100%);
  aspect-ratio: 2 / 1;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--brand-line);
}

.hero-actions,
.form-actions,
.resource-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1.6rem;
}

.value-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  width: min(1120px, calc(100% - 32px));
  margin: -32px auto 64px auto;
  overflow: hidden;
  border: 1px solid var(--brand-line);
  border-radius: 8px;
  background: var(--brand-line);
  box-shadow: 0 12px 34px rgba(31, 34, 51, 0.1);
  position: relative;
  z-index: 1;
}

.value-strip div {
  padding: 1.3rem;
  background: var(--brand-paper);
}

.value-strip strong,
.value-strip span {
  display: block;
}

.value-strip strong {
  color: var(--brand-purple);
  font-size: 1.05rem;
}

.value-strip span {
  margin-top: 0.35rem;
  color: var(--brand-muted);
}

.section-band,
.model-flow,
.audience-section,
.problem-solution-grid,
.resource-groups,
.content-page {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: clamp(2.4rem, 6vw, 4.5rem) 0;
}

.section-band {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

.section-band-light {
  border-top: 1px solid var(--brand-line);
  border-bottom: 1px solid var(--brand-line);
}

.section-band-deep {
  width: 100%;
  max-width: none;
  padding: clamp(2.7rem, 6vw, 5rem) max(24px, calc((100vw - 1120px) / 2));
  background:
    linear-gradient(135deg, rgba(53, 18, 79, 0.96), rgba(93, 36, 139, 0.92)),
    var(--brand-purple-dark);
  color: var(--brand-paper);
}

.section-band-deep .eyebrow,
.section-band-deep h2,
.section-band-deep h3,
.section-band-deep p {
  color: var(--brand-paper);
}

.section-copy h2,
.model-flow h2,
.audience-section h2,
.problem-solution-grid h2,
.resource-callout h2,
.reader-proof h2,
.content-page h1 {
  margin: 0;
  color: var(--brand-purple-dark);
  font-size: clamp(2rem, 4vw, 3.3rem);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: 0;
}

.section-copy p,
.content-page p,
.content-page li {
  margin-top: 1rem;
  color: var(--brand-muted);
  font-size: 1.05rem;
  line-height: 1.7;
}

.section-band-deep .section-copy h2,
.section-band-deep .section-copy p {
  color: var(--brand-paper);
}

.section-copy-centered {
  max-width: 760px;
  margin: 0 auto 2rem auto;
  text-align: center;
}

.proof-list,
.learn-grid,
.audience-grid,
.flow-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.audience-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.proof-list article,
.learn-grid article,
.audience-grid article,
.flow-grid article,
.resource-item,
.problem-solution-grid article {
  padding: 1.25rem;
  border: 1px solid var(--brand-line);
  border-radius: 8px;
  background: var(--brand-paper);
}

.section-band-deep .learn-grid article {
  background: rgba(255, 255, 255, 0.96);
  border-color: rgba(255, 255, 255, 0.78);
  box-shadow: 0 18px 44px rgba(23, 8, 39, 0.28);
}

.section-band-deep .learn-grid h3 {
  color: var(--brand-purple-dark);
}

.section-band-deep .learn-grid p {
  color: #3f4a5b;
}

.proof-list h3,
.learn-grid h3,
.audience-grid h3,
.flow-grid h3,
.resource-item h3,
.problem-solution-grid h2 {
  margin: 0;
  color: var(--brand-purple);
  font-size: 1.18rem;
  line-height: 1.25;
  font-weight: 850;
  letter-spacing: 0;
}

.proof-list p,
.learn-grid p,
.audience-grid p,
.flow-grid p,
.resource-item p {
  margin: 0.65rem 0 0 0;
  color: var(--brand-muted);
  line-height: 1.6;
}

.flow-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 32px;
  margin-bottom: 1rem;
  border-radius: 8px;
  background: rgba(255, 188, 66, 0.28);
  color: var(--brand-purple-dark);
  font-weight: 900;
}

.problem-solution-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.2rem;
}

.signal-list {
  display: grid;
  gap: 0.8rem;
  margin: 1.2rem 0 0 0;
  padding: 0;
  list-style: none;
}

.signal-list li {
  padding-left: 1rem;
  border-left: 4px solid var(--brand-gold);
  color: var(--brand-muted);
}

.resource-callout {
  display: grid;
  grid-template-columns: minmax(260px, 0.8fr) minmax(0, 1.2fr);
  gap: 1.5rem;
  align-items: start;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: clamp(2rem, 5vw, 3.5rem) 0;
  border-top: 1px solid var(--brand-line);
}

.resource-callout .navbar {
  width: 100%;
  margin: 0 !important;
  border: none !important;
  background: transparent;
  box-shadow: none;
  padding: 0;
}

.reader-proof {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto clamp(2.5rem, 6vw, 4rem) auto;
  padding: clamp(2rem, 5vw, 3.5rem) 0;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}

.quote-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.2rem;
}

.reader-proof blockquote {
  margin: 0;
  padding: 1.3rem;
  border-left: 5px solid var(--brand-red);
  border-radius: 8px;
  background: var(--brand-paper);
  box-shadow: none;
}

.reader-proof cite {
  color: var(--brand-purple);
  font-weight: 800;
}

.resource-hero {
  grid-template-columns: minmax(0, 1fr) auto;
}

.resource-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  width: min(1120px, calc(100% - 32px));
  margin: 2rem auto 0 auto;
}

.filter-button {
  min-height: 40px;
  padding: 0.55rem 0.9rem;
  border: 1px solid rgba(93, 36, 139, 0.25);
  border-radius: 8px;
  background: var(--brand-paper);
  color: var(--brand-purple);
  font-weight: 800;
}

.filter-button-active,
.filter-button:hover,
.filter-button:focus {
  background: var(--brand-purple);
  color: var(--brand-paper);
}

.resource-group {
  margin-bottom: 2rem;
}

.resource-group > header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--brand-line);
}

.resource-group h2 {
  margin: 0;
  color: var(--brand-purple-dark);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  line-height: 1.1;
  letter-spacing: 0;
}

.resource-list {
  display: grid;
  gap: 0.85rem;
  margin-top: 1rem;
}

.resource-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
}

.resource-platform,
.resource-date {
  color: var(--brand-teal) !important;
  font-size: 0.88rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0.25rem 0.65rem;
  border-radius: 8px;
  background: rgba(255, 188, 66, 0.3);
  color: var(--brand-purple-dark);
  font-size: 0.86rem;
  font-weight: 850;
}

.empty-state,
.content-form,
.alert {
  width: min(820px, calc(100% - 32px));
  margin: 2rem auto;
}

.empty-state {
  padding: 2rem;
  border: 1px solid var(--brand-line);
  border-radius: 8px;
  background: var(--brand-paper);
}

.content-form {
  padding: clamp(1.2rem, 4vw, 2rem);
  border: 1px solid var(--brand-line);
  border-radius: 8px;
  background: var(--brand-paper);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.form-field {
  min-width: 0;
}

.form-field-full {
  grid-column: 1 / -1;
}

.form-field label,
.form-field legend {
  display: block;
  margin-bottom: 0.35rem;
  color: var(--brand-purple-dark);
  font-weight: 850;
}

.form-control {
  min-height: 44px;
  border: 1px solid rgba(31, 34, 51, 0.25);
  border-radius: 8px;
}

.form-control:focus {
  border-color: var(--brand-teal);
  box-shadow: 0 0 0 0.2rem rgba(0, 109, 119, 0.16);
}

.radio-option,
.checkbox-option {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 36px;
  color: var(--brand-muted);
  font-weight: 700;
}

.content-page {
  max-width: 860px;
  padding-top: 3rem;
  padding-bottom: 4rem;
}

.content-page h2 {
  margin-top: 2rem;
  color: var(--brand-purple);
  font-size: 1.45rem;
  letter-spacing: 0;
}

.footer {
  margin-top: 0;
  border-radius: 0;
  background: var(--brand-purple-dark);
}

@media (max-width: 900px) {
  .book-hero,
  .model-hero,
  .resource-hero,
  .form-hero,
  .section-band,
  .resource-callout,
  .problem-solution-grid {
    grid-template-columns: 1fr;
  }

  .value-strip,
  .audience-grid,
  .proof-list,
  .learn-grid,
  .flow-grid,
  .quote-grid {
    grid-template-columns: 1fr;
  }

  .value-strip {
    margin-top: 0;
  }

  .resource-item {
    grid-template-columns: 1fr;
  }

  .resource-actions {
    margin-top: 0;
  }
}

@media (max-width: 600px) {
  .book-hero,
  .model-hero,
  .resource-hero,
  .form-hero {
    padding: 2.2rem 16px;
  }

  .book-hero h1,
  .model-hero h1,
  .resource-hero h1,
  .form-hero h1 {
    font-size: clamp(2.15rem, 12vw, 3.35rem);
  }

  .hero-actions,
  .form-actions,
  .resource-actions {
    align-items: stretch;
  }

  .hero-actions .button,
  .form-actions .button,
  .resource-actions .button {
    width: 100%;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .homepage-title .d-flex.justify-content-center > .button,
  .button,
  .nav .button {
    width: 100%;
    max-width: 100%;
    min-width: 0 !important;
  }
}
