:root {
  --primary: #79b0cc;
  --primary-light: #a8d4e8;
  --bg-dark: #0b0f1a;
  --bg-card: #121826;
  --bg-light: #1e2533;
  --text-main: #ffffff;
  --text-muted: #c9d1db;
  --border-color: #2b3545;
  --accent: #91da9b;
}

/* { outline: 1px solid red !important; } for debugging; remove in actual use */

body {
  font-family: 'Inter', sans-serif;
  margin: 0;
  color: var(--text-main);
  background-color: none;
  background: radial-gradient(ellipse at 50% 200%, #0c1b33 0%, #0a1a2f 30%, #040913 60%, #000000 100%);
  background-attachment: fixed;
}

#starfield {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1; /* Behind content */
  background: #0A0A10; /* fallback dark background */
}

.stars {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: transparent;
  pointer-events: none;
  z-index: 0;
}
.stars::after {
  content: '';
  position: absolute;
  width: 2px;
  height: 2px;
  background: white;
  opacity: 0.9;
  animation: twinkle 2.5s infinite ease-in-out;
  box-shadow:
    100px 120px #ffffff,
    250px 80px #ccc,
    400px 300px #bbb,
    600px 200px #fff,
    800px 450px #aaa,
    1000px 120px #eee,
    1200px 350px #999;
}
@keyframes twinkle {
  0% { opacity: 0.3; transform: scale(0.8); }
  100% { opacity: 1; transform: scale(1.25); }
}

main {
  background: radial-gradient(ellipse at center, #050d1a 0%, #000000 100%);
  position: relative;
  padding: none;
}

h1 {
  color: var(--primary);
}

p {
  font-family: 'Inter', sans-serif;
  color: var(--text-muted);
}

a {
  color: rgb(181, 225, 229);
}


header {
  background: linear-gradient(to bottom, rgba(1, 8, 18, 0) 95%, #030b1e 100%);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  padding: 1rem clamp(1rem, 5vw, 3rem);
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  position: fixed;
  width: 100%;
  z-index: 1000;
}

.logo {
  font-size: 2rem;
  font-family: 'Inter';
  font-weight: 800;
  color: rgb(243, 249, 242);
  margin-right: 1rem;
  align-items: center;
  display: flex;
  gap: 0rem;
  padding: 0;
}

nav {
  display: flex;
  gap: 2rem;
  margin-right: 1.5rem;
}

nav a {
  text-decoration: none;
  color: white;
  font-weight: 600;
  transition: color 0.2s ease;
}

nav a:hover {
  color: var(--primary);
}

.header-buttons {
  display: flex;
  gap: 1rem;
  font-family: 'Inter', cursive;
  margin-right: 5rem;
}
.header-buttons a {
  text-decoration: none;
  color: var(--text-main);
  font-weight: 600;
  font-size: 0.95rem;
  transition: background 0.2s ease, color 0.2s ease;
}

.btn {
  padding: 0.5rem 1.25rem;
  border-radius: 7.5px;
  text-decoration: none;
  font-weight: 600;
  cursor: pointer;
  font-size: 0.95rem;
  transition: background 0.2s ease;
  border: none;
}


.sign-in {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
}

.get-demo {
  background: var(--primary);
  color: white;
}

.get-demo:hover {
  background: rgb(34, 48, 120);
}


.hero {
  position: relative;
  height: 70vh;
  color: var(--text-main);
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2rem;
  overflow: hidden;
  z-index: 1;
}
.hero-fade {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 120px;
  margin-top: -100px; /* pulls fade up into the black zone */
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, #000 100%);
}

.hero h1 {
  font-size: 2.7rem;
  margin-top: 10rem;
  font-weight: 600;
  color: rgb(255, 255, 255);
}

.hero p {
  font-size: 1.3rem;
  color: var(--text-muted);
}

@media (max-width: 600px) {
  .hero h1 {
    font-size: 2rem;
    margin-top: 6rem;
  }
  .hero p {
    font-size: 1.25rem;
  }
}

.buttons {
  margin-top: 2rem;
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.buttons a {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  margin: 0.5rem;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  transition: background 0.2s ease;
}

.primary-btn {
  background: var(--primary);
  color: white;
  border: none;
  cursor: pointer;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  border-radius: 6px;
  font-weight: 600;
  transition: all 0.2s ease;
}
.primary-btn:hover {
  background: rgb(34, 48, 120);
}

.secondary-btn {
  background-color: #f4f4f8;
  color: #1e1e52;
  border: 1px solid #d4d4e4;
  padding: 8px 16px;
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}
.secondary-btn:hover {
  background-color: #e6e6f5;
  border-color: #bdbde0;
}
.secondary-btn:active {
  transform: scale(0.98);
}

section {
  padding: 4rem 2rem;
  max-width: 1100px;
  margin: 0 auto;
}

section h2 {
  font-family: 'Inter', cursive;
  font-weight: 600;
  font-size: 2.1rem;
  color: var(--text-main);
  margin-bottom: 1rem;
  text-align: center;
}

.grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  justify-content: center;
  margin-top: 2rem;
}

.grid > div {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.03);
  transition: transform 0.2s ease;
}

.grid > div:hover {
  transform: translateY(-4px);
}

.grid > div img {
  border-radius: 12px;
  width: 100%;
  margin-bottom: 0.5rem;
}

@media (min-width: 900px) {
  /* On wider screens, show roughly 4 per row */
  .grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

footer {
  background: rgb(5, 6, 35);
  color: #888;
  text-align: center;
  padding: 2rem;
  font-size: 0.9rem;
}

/* demo button modal */
.modal {
  display: none;
  position: fixed;
  z-index: 999;
  left: 0; top: 0;
  width: 100%; 
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
}
.modal-content {
  background: #1b1e2e;
  padding: 2rem;
  width: 480px;           /* Default width */
  max-width: 90vw;        /* Max width for smaller screens */          /* Fixed height */
  max-height: 90vh;       /* Max height for very short screens */
  border-radius: 12px;
  position: fixed;        /* Fix to viewport */
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: 'Inter', cursive;
  box-sizing: border-box;
  overflow-y: auto;       /* Scroll if content exceeds height */
}
.modal-content input,
.modal-content textarea {
  padding: .5rem 1rem;  /* bigger padding for taller rows */
  font-size: .9rem;
  border: 1px solid #ddd;
  border-radius: 10px;
  font-family: 'Inter', cursive;
  resize: vertical; /* allow vertical resize for textarea */
}
.close-button {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 2rem;
  cursor: pointer;
  color: #999;
}

/* Responsive navigation - hide links on small screens */
@media (max-width: 768px) {
  nav {
    display: none;
  }
}

/* Popup menu for 'Learn More' */
.popup-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.1);
  padding: 1rem;
  z-index: 1000;
  text-align: left;
}
.popup-menu a {
  display: block;
  color: var(--text-main);
  text-decoration: none;
  margin: 0.25rem 0;
  font-weight: 500;
}
.popup-menu a:hover {
  color: var(--primary);
}

#examples .grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  justify-content: center;
}
@media (min-width: 1024px) {
  #examples .grid {
    grid-template-columns: repeat(3, 1fr); /* Only 3 columns on large screens */
  }
}

.product-grid {
  display: grid;
  gap: 2rem;
  padding: 1rem;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1024px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}


#products {
  padding: 2rem 1rem;
  max-width: 1100px;
  margin: 2rem auto;
}

.product-card {
  background-color: #0c0c1b;
  border: none;
  border-radius: 10px;
  padding: 2rem;
  box-shadow: 0 8px 24px rgba(90, 85, 93, 0.06);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex; /* put text to the right of image */
  align-items: center;
  gap: 50px; /* spacing between image and text */
}
.product-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(90, 85, 93, 0.1);
  border: 1px solid #c7cee4; /* 6379b7 */
}
.product-card img {
  max-width: 300px;
  height: auto;
  object-fit: cover;
}
.product-info {
  flex: 1 1 300px;
  min-width: 300px;
  max-width: 100%;
}
@media (max-width: 768px) {
  .product-card {
    flex-direction: column;
    align-items: left;
    text-align: center;
  }
}
.product-card h3 {
  color: #000000; /* #369765 */
  margin-bottom: 1rem;
  font-size: 1.25rem;
}
.product-card p {
  color: #4a4a4a;
  line-height: 1.6;
  font-size: 1rem;
}
.product-scroll {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 1rem;
  padding: 2rem 0;
  -webkit-overflow-scrolling: touch;
}
.product-scroll::-webkit-scrollbar {
  height: 8px;
}
.product-scroll::-webkit-scrollbar-thumb {
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 4px;
}
.product-scroll img {
  flex: 0 0 auto;
  width: 300px;
  height: auto;
  scroll-snap-align: start;
  border-radius: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}


#pricing {
  padding: 4rem 1rem;
  background-color: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, #000 100%);
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

#pricing h2 {
  font-size: 2.5rem;
  font-weight: 600;
  margin-bottom: 3rem;
  color: #1f372b;
  text-align: center;
}

.pricing-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  max-width: 80rem;
  margin: 0 auto;
}


.plan {
  background-color: #03071d;
  border: 1px solid rgb(173, 209, 220);
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: box-shadow 0.3s ease;
  text-align: left;
  display: flex;
  flex-direction: column;
  justify-content: top;
}
.plan:hover {
  box-shadow: 0 10px 15px rgba(0, 0, 0, 0.15);
}

/*
- the individual plan should be under all three plans when full screen
- the individual plan should appear to the right of enterprise of the same row when the screen is squeezed (another row being standard and premium)
- the individual plan should be below all plans when the screen is further narrowed 
*/

/* Default: Full screen */
@media (min-width: 1200px) {
  .pricing-grid {
    grid-template-columns: repeat(3, 1fr);
    grid-template-areas:
      "starter premium enterprise"
      "individual individual individual";
  }

  .plan.starter { grid-area: starter; }
  .plan.premium { grid-area: premium; }
  .plan.enterprise { grid-area: enterprise; }
  .plan.individual { grid-area: individual; }
}
/* Medium screen: Tablet view */
@media (min-width: 768px) and (max-width: 1199px) {
  .pricing-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-template-areas:
      "starter premium"
      "enterprise individual";
  }

  .plan.starter { grid-area: starter; }
  .plan.premium { grid-area: premium; }
  .plan.enterprise { grid-area: enterprise; }
  .plan.individual { grid-area: individual; }
}
/* Small screen: Mobile */
@media (max-width: 767px) {
  .pricing-grid {
    grid-template-columns: 1fr;
    grid-template-areas:
      "starter"
      "premium"
      "enterprise"
      "individual";
  }

  .plan.starter,
  .plan.premium,
  .plan.enterprise,
  .plan.individual {
    grid-area: auto;
  }
}


.plan h3 {
  font-size: 1.5rem;
  color: rgb(38, 43, 41);
  font-weight: 600;
  margin-top: 0.5rem;
  margin-bottom: 1rem;
}
.plan p {
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent); /*111827*/ 
  margin-bottom: 1rem;
}
#priceDisplay {
  font-size: inherit;
  font-weight: bold;
} 
.plan p span {
  font-size: 1rem;
  font-weight: 400;
}
.plan ul {
  color: #374151;
  font-size: 0.85rem;
  margin-bottom: 0rem;
  padding-left: 0;
  list-style-type: none;
}
.plan ul li {
  margin-bottom: 0.5rem;
}
.plan button {
  padding: 0.7rem 1rem;
  width: 30%;
  font-weight: 600;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
}
.plan .primary-btn {
  background-color: #2b265d;
  color: #ffffff;
  border: none;
}
.plan .primary-btn:hover {
  background-color: #4338ca;
}
.plan .dark-btn {
  background-color: #e4e9ee;
  color: #0b0d1d;
  border: none;
  width: 100%;
  padding: 1rem 0.7rem;
  font-size: 1rem;
}
.plan .dark-btn:hover {
  background-color: #a8b0eb;
}
.plan a {
  color: #1e1e52;
  text-decoration: none;
  font-weight: 600;
}

.individual {
  grid-column: 1 / -1; /* spans all columns */
}


/* Upload box*/
.upload-input-group {
  display: flex;
  gap: 6px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

/* Paste URL: Layout */
.upload-input {
  flex: 1;
  padding: 12px 16px;
  max-width: 35%;
  font-size: 1rem;
  border: 1px solid #d1d1e0;
  border-radius: 6px;
  outline: none;
  background-color: #fff;
  color: #1e1e52;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.upload-input::placeholder {
  color: #a0a0b0;
  font-size: 1rem;
}
.upload-input:focus {
  border-color: #1e1e52;
  box-shadow: 0 0 0 2px rgba(30, 30, 82, 0.15);
}

/* Upload local files: Layout */
.button-row {
  display: flex;
  gap: 12px;
  margin-top: 10px;
  justify-content: center;
}
.supported-formats {
  font-size: 0.8rem;
  color: #6e6e8d;
  text-align: center;
  margin-top: 8px;
}

/* select ad_spend */
.custom-select {
  padding: 0.5rem 0.75rem;
  border: 1px solid #ddd;
  border-radius: 10px;
  font-size: 0.9rem;
  background-color: black;
  color: #888; /* default (placeholder) color */
}

.custom-select:valid {
  color: #000; /* change to black when a valid option is selected */
}


/* competitor plot */

.caption {
  color: #666;
  max-width: 700px;
  margin: 0 auto 2rem;
  font-size: 1rem;
}

.chart-container {
  position: relative;
  width: 800px;
  height: 500px;
  background: #ffffff;
  border: 1px solid #ffffff;
  overflow: hidden;
  margin: 0 auto;
  margin-top: 20px;
}

/* Axis Labels */
.axis-label {
  position: absolute;
  font-weight: bold;
  font-size: 20px;
  color: #333;
}

.x-label {
  position: absolute;
  bottom: -30px;
  left: 50%;
  transform: translateX(-50%);
}

.y-label {
  position: absolute;
  left: -40px;
  top: 50%;
  transform: translateY(-50%) rotate(-90deg);
  font-weight: bold;
  white-space: nowrap;
}


/* Markers (points) */
.marker {
  position: absolute;
  border-radius: 50%;
  background-color: rgba(59, 130, 246, 0.8);
  color: #fff;
  font-size: 12px;
  text-align: center;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s;
}

.marker:hover {
  transform: scale(1.1);
  z-index: 2;
}
/* Tooltip */
.marker::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 110%;
  left: 50%;
  transform: translateX(-50%);
  background: #333;
  color: #fff;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 12px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
  white-space: nowrap;
}
.marker:hover::after {
  opacity: 1;
}

/* Custom Colors */
.motion { background: #5b6dfb; }
.creatify { background: #7c3aed; }
.icon { background: #facc15; }
.openai { background: #111213; }
.atria { background: #ef4444; }
.opusclip { background: #4b5563; }
.arcads { background: #0ea5e9; }
.neuroad { background: #348245; }


#plot {
  width: 100%;
  height: 700px;
}

@media (max-width: 600px) {
  .y-label {
    left: -60px;
    font-size: 12px;
  }
  .x-label {
    font-size: 12px;
  }
  .marker {
    font-size: 10px;
  }
}
/*pricing sliding bar*/

input[type="range"] {  
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  height: 28px;
  border-radius: 15px;
  background: linear-gradient(90deg, #a97bdd 0%, #91dad3 100%); /* color of sliding bar */
  box-shadow: inset 0 0 8px rgba(0, 0, 0, 0.15);
  outline: none;
  cursor: pointer;
  transition: background 0.3s ease;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  border: 3px solid #07210a;
  box-shadow: none;
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
  margin-top: 0px; /* vertically center thumb on track */
}

input[type="range"]:hover::-webkit-slider-thumb {
  background: rgba(255, 255, 255, 1);
  box-shadow:
    0 4px 12px rgba(28, 63, 90, 0.8),
    0 0 10px rgba(136, 223, 236, 0.9);
}

input[type="range"]::-moz-range-thumb {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  border: 3px solid #447b40;
  box-shadow:
    0 2px 8px rgba(79, 70, 229, 0.6),
    0 0 6px rgba(188, 151, 233, 0.7);
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}

input[type="range"]:hover::-moz-range-thumb {
  background: rgba(255, 255, 255, 1);
  box-shadow:
    0 4px 12px rgba(79, 70, 229, 0.8),
    0 0 10px rgba(94, 213, 231, 0.9);
}

/* DARK */
/* Switch to dark background */
/* remove the entire section if not needed *//* === Dark backgrounds for pricing and product sections === */
/* #pricing,
.plan,
.product-card */

/* === Text colors inside cards and plans === */
.plan h3,
.plan p,
.plan ul li,
.product-card h3,
.product-card p,
#pricing h2,
#pricing p,
.product-info p,
.product-info h3 {
  color: var(--text-main) !important;
}

/* === Adjust pricing slider label and features === */
#priceDisplay,
#creditDisplay,
#teamSeats,
.plan ul,
.plan ul li {
  color: var(--text-main) !important;
}

/* === Modal and form inputs === */
.modal-content input,
.modal-content textarea,
.custom-select {
  background-color: #e6e6e6 !important;
  color: var(--text-main) !important;
  border: 1px solid #444444 !important;
}
.custom-select:valid {
  color: var(--text-main) !important;
}

/* === Optional: Footer text contrast === */
footer {
  color: #888888 !important;
}
/* DARK (END) */

