/*
 * Stylesheet for the rebuilt BionicPartner.AI website.
 *
 * The design takes inspiration from the original WordPress site but is
 * optimised for performance and responsiveness. Colours and typography
 * are drawn from the existing palette (dark backgrounds with bright
 * teal accents). The layout uses flexbox and CSS grid to adapt to
 * different screen sizes without relying on heavy frameworks. Feel free
 * to extend or modify these rules when evolving the site.
 */

/* Root variables for easy theming */
:root {
  /*
   * Colour palette inspired by the original site but tuned for a modern,
   * glassmorphic aesthetic. These variables can be tweaked to quickly
   * update the look and feel without hunting through the stylesheet.
   */
  --color-primary: #00bcd4;         /* teal accent from original site */
  --color-secondary: #00e5ff;       /* lighter accent for hover/focus */
  --color-background: #010a1b;      /* deep navy underlying background */
  --color-surface: rgba(255,255,255,0.08); /* translucent panels */
  --color-text-primary: #ffffff;    /* primary text */
  --color-text-secondary: #cbd5e1;  /* secondary text */
  /* Increased the opacity of glass backgrounds and borders to enhance
   * the iOS glassmorphic feel. A slightly higher alpha level adds more
   * luminosity while retaining the translucent look. The blur amount
   * has been intensified to soften edges and create a more polished
   * depth effect reminiscent of Apple's UI. */
  --glass-bg: rgba(255,255,255,0.12);
  --glass-border: rgba(255,255,255,0.3);
  --blur-amount: 30px;
  --max-width: 1200px;
  --header-height: 60px;
  font-family: 'Poppins', sans-serif;
}

html,
body {
  margin: 0;
  padding: 0;
  /*
   * Use a simple colour gradient for the overall page background rather than
   * an image. This keeps the focus on the hero artwork and ensures the
   * remainder of the page feels cohesive without distracting visuals.
   */
  background: linear-gradient(180deg, #01121f 0%, #010a1b 50%, #010613 100%);
  color: var(--color-text-primary);
  font-size: 16px;
  line-height: 1.6;
  scroll-behavior: smooth;
}

/* Typography helpers */
h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  color: var(--color-text-primary);
  font-weight: 600;
}

h1 { font-size: 2.25rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
p { color: var(--color-text-secondary); margin: 0.5rem 0 1rem; }

/* Apply rounded corners to all images used throughout the site. This
 * subtle detail ties together the glass panels and cards, creating a
 * cohesive feel. Small icons within buttons or illustrations will be
 * unaffected by the border radius due to their size. */
img {
  border-radius: 1rem;
}

/* Ensure videos in persona cards adopt the same sizing and rounded corners as images */
video {
  width: 100%;
  height: auto;
  border-radius: 1rem;
  /* Use cover to ensure the video fills the available width. This may crop
   * a bit of the top/bottom but removes unsightly grey bars at the sides. */
  object-fit: cover;
  /* Constrain the height so the video doesn’t dominate the card while
   * still maintaining enough vertical space for a balanced composition. */
  max-height: 300px;
}

/* Global container to constrain content */
.container {
  width: 90%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem 0;
}

/* Header and navigation */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  /* Glass effect for the header */
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur-amount));
  border-bottom: 1px solid var(--glass-border);
}
.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
  width: 90%;
  max-width: var(--max-width);
  margin: 0 auto;
}
.logo a {
  text-decoration: none;
  color: var(--color-primary);
  font-weight: 700;
  font-size: 1.5rem;
}
nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.5rem;
}
nav a {
  text-decoration: none;
  color: var(--color-text-secondary);
  font-weight: 500;
  transition: color 0.3s ease;
}
nav a:hover,
nav a:focus {
  color: var(--color-primary);
}

/* Responsive menu toggle for small screens */
.menu-toggle {
  display: none;
  flex-direction: column;
  cursor: pointer;
}
.menu-toggle span {
  height: 3px;
  width: 25px;
  background: var(--color-primary);
  margin-bottom: 5px;
  border-radius: 2px;
  transition: transform 0.3s ease;
}
@media (max-width: 768px) {
  nav ul {
    position: absolute;
    top: var(--header-height);
    right: 0;
    /* Use glass effect for the mobile drawer menu */
    background: var(--glass-bg);
    backdrop-filter: blur(var(--blur-amount));
    flex-direction: column;
    width: 200px;
    padding: 1rem;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transform: translateX(100%);
    transition: transform 0.3s ease;
  }
  nav ul.active {
    transform: translateX(0);
  }
  .menu-toggle { display: flex; }
}

/* Hero section */
/*
 * Hero section is transformed into a full‑width, parallax section with
 * background imagery. The content sits within a semi‑transparent card
 * to maintain legibility. On small screens the layout stacks.
 */
.hero {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  /* minimum height to create an immersive landing experience */
  min-height: 75vh;
  padding: 4rem 0;
  /* Background image for the hero – separate from body for layering. */
  /*
   * Use the final provided artwork which features two AI sisters spaced far
   * apart with ample void in the centre. We adjust the vertical offset
   * slightly so their faces are centred and fully visible on most
   * viewports. The `contain` sizing ensures the entire image fits within
   * the hero without cropping; the dark gradient overlay is kept very
   * light so the artwork remains clear.
   */
  background:
    linear-gradient(rgba(1, 10, 27, 0.05), rgba(1, 10, 27, 0.05)),
    /* Replace with the enhanced AI sisters image provided by the user */
    url('../images/AI-Sisters-enhanced5.webp') center 15% / contain no-repeat;
}
.hero-text {
  /*
   * Centre the hero copy within the available space. Without a flex
   * basis it will size itself to its content and the max‑width.
   */
  margin: 0 auto;
  /* Constrain the width so the card sits neatly in the central void between the two faces. */
  width: 65%;
  max-width: 700px;
  /* Centre the text consistently across all breakpoints */
  text-align: center;
  /* Reduce padding to shorten the card height so it sits neatly between the two faces */
  padding: 1.5rem 2rem;
  /* Glass panel for the hero copy: increase opacity a bit for readability */
  /* Lighten the hero card backdrop slightly to achieve a cleaner,
   * glass‑like look. Increasing transparency allows the background art
   * to subtly show through without sacrificing legibility. */
  background: rgba(1, 10, 27, 0.35);
  backdrop-filter: blur(var(--blur-amount));
  border: 1px solid var(--glass-border);
  border-radius: 1rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}
.hero-text h1 {
  font-size: 3rem;
  margin-bottom: 0.5rem;
}
.hero-text h2 {
  font-size: 1.75rem;
  color: var(--color-primary);
  margin-bottom: 1rem;
}
/* Hide the separate hero image container because the image is now set as a background */
.hero-img {
  display: none;
}
@media (min-width: 768px) {
  .hero-text {
    /* On larger screens, widen the card slightly but ensure it never
     * extends beyond the central void created by the artwork. The
     * max‑width prevents the panel from growing taller than the faces.
     */
    width: 50%;
    max-width: 700px;
    /* Keep the text centred even on larger screens */
    text-align: center;
    /* Further reduce vertical padding on desktop to keep the card from
     * extending below the hero image region. */
    padding: 1.5rem 2rem;
  }
}
/* Buttons */
.btn {
  display: inline-block;
  background: var(--color-primary);
  color: var(--color-background);
  padding: 0.75rem 1.5rem;
  margin-top: 1rem;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 188, 212, 0.4);
}
.btn:hover,
.btn:focus {
  background: var(--color-secondary);
  color: var(--color-background);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 229, 255, 0.4);
}

/* Section styling */
section {
  padding: 4rem 0;
  position: relative;
}

/*
 * Apply a glass panel effect to primary content sections that use the
 * `.container` class. This wraps content in a subtle translucent card
 * reminiscent of iOS and modern design systems. Individual sections
 * can opt out by adding the `no-glass` class.
 */
section.container {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur-amount));
  border: 1px solid var(--glass-border);
  border-radius: 1rem;
  padding: 4rem 2rem;
  margin-bottom: 3rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}
section.container.no-glass {
  background: transparent;
  backdrop-filter: none;
  border: none;
  box-shadow: none;
  padding: 0;
  margin-bottom: 0;
}
.section-title {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 2rem;
}
.two-column {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  /* Align items vertically so images and text sit on a common baseline.
   * This prevents tall images from overpowering short text blocks and
   * creates a more balanced composition across the row. */
  align-items: center;
}
.two-column .col {
  flex: 1 1 45%;
}
.two-column img {
  width: 100%;
  height: auto;
  border-radius: 0.5rem;
  /* Limit the maximum height of images in two‑column layouts so that
   * they remain visually proportional to the accompanying text. Using
   * object-fit: contain preserves the original aspect ratio without
   * cropping important details. */
  max-height: 320px;
  object-fit: contain;
}

/* Card grid */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}
.card {
  position: relative;
  padding: 2rem;
  border-radius: 1rem;
  text-align: center;
  /* Glass styling for cards */
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur-amount));
  border: 1px solid var(--glass-border);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}
.card img {
  height: 80px;
  width: 80px;
  margin-bottom: 1rem;
}
.card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}

/* Objective subcards layout used on the core objectives page */
.objective-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.subcard {
  padding: 1.5rem;
  border-radius: 1rem;
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur-amount));
  border: 1px solid var(--glass-border);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.subcard:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4);
}
.subcard h4 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
}
.subcard p {
  margin-bottom: 0;
}

/* Persona cards */
.persona-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}
.persona {
  overflow: hidden;
  border-radius: 1rem;
  display: flex;
  flex-direction: column;
  /* Glass styling for personas */
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur-amount));
  border: 1px solid var(--glass-border);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}
.persona img {
  width: 100%;
  /* Allow portraits to scale naturally to show the full figure without cropping. */
  height: auto;
  object-fit: contain;
}
.persona-content {
  padding: 1.5rem;
  flex: 1;
}
.persona-content h3 {
  margin-top: 0;
  font-size: 1.5rem;
}

/* Benefits list */
.benefits {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.benefit {
  position: relative;
  padding: 1.5rem;
  border-radius: 1rem;
  text-align: center;
  /* Glass styling for benefit cards */
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur-amount));
  border: 1px solid var(--glass-border);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

/* Footer */
footer {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur-amount));
  border-top: 1px solid var(--glass-border);
  padding: 3rem 0;
  font-size: 0.875rem;
}
footer .footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}
footer h4 {
  margin-top: 0;
  font-size: 1.25rem;
  color: var(--color-primary);
}
footer ul {
  list-style: none;
  padding: 0;
}
footer ul li {
  margin-bottom: 0.5rem;
}
footer ul a {
  color: var(--color-text-secondary);
  text-decoration: none;
  transition: color 0.3s ease;
}
footer ul a:hover {
  color: var(--color-primary);
}

/* ElevenLabs widget container styling (optional) */
.eleven-widget {
  position: fixed;
  bottom: 1rem;
  right: 1rem;
  z-index: 200;
}

/* Utility classes */
.text-center { text-align: center; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mt-4 { margin-top: 1rem; }

/* Emphasised summary line on the Personas page */
.together-text {
  /* Increase vertical spacing above the line to separate it from the persona cards */
  margin-top: 2rem;
  /* Boost the font size slightly for better readability */
  font-size: 1.25rem;
}

/*
 * Responsive adjustments
 * On small screens, stack two‑column layouts vertically and reduce the
 * height of videos so they don't overwhelm the viewport.
 */
@media (max-width: 768px) {
  /* Stack columns on mobile for better readability */
  .two-column .col {
    flex-basis: 100%;
  }
  /* Limit video height on smaller screens */
  video {
    max-height: 200px;
  }
}
