/* Research Page Styles - Expanded version */

/* Ensure main element has proper width */
main {
  width: 100%;
  max-width: 1200px;
  margin: 60px auto 0; /* Preserve top margin for fixed header */
  padding: 0 20px;
}

/* Adjust for mobile header height */
@media (max-width: 768px) {
  main {
    margin-top: 76px; /* Account for taller mobile header with touch targets */
  }
}

.jai-image {
  height: 160px;
  background-color: #f5f5f5;
  background-position: center;
  background-size: cover;
  position: relative;
}

/* Page-specific overrides removed - using global styles from apps-page.css */

.jai-card {
  max-width: 100%;
  width: 100%;
  min-height: 340px;
  height: 100%;
}

/* Real mode banner images - matches actual 6 research cards */
html.real-mode-html .jai-card:nth-child(1) .jai-image {
  background-image: url("../../images/backgrounds/jailab.png");
}

html.real-mode-html .jai-card:nth-child(2) .jai-image {
  background-image: url("../../images/app-banners/local-first-phone-banner.svg");
}

html.real-mode-html .jai-card:nth-child(3) .jai-image {
  background-image: url("../../images/app-banners/site-theming-banner.svg");
}

html.real-mode-html .jai-card:nth-child(4) .jai-image {
  background-image: url("../../images/app-banners/homelab-banner.svg");
}

html.real-mode-html .jai-card:nth-child(5) .jai-image {
  background-image: url("../../images/app-banners/chatgpt-analysis-banner.svg");
}

html.real-mode-html .jai-card:nth-child(6) .jai-image {
  background-image: url("../../images/app-banners/birthday-card-magic-banner.svg");
}

.jai-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  will-change: transform;
  transform: translateZ(0);
  font-size: 0; /* Hide alt text */
  color: transparent; /* Hide any text color */
  text-indent: -9999px; /* Move text off-screen */
}

/* Body styles removed - using global styles from reset.css and theme.css */

/* Theme toggle styles removed - using global styles from apps-page.css */

/* Button and theme mode styles removed - using global styles from apps-page.css */

.page-description {
  font-size: 16px;
  color: #666;
  max-width: 600px;
  margin: 0 auto;
}

/* Grid layout defined in components.css - ensure proper inheritance */
.jai-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  width: 100%;
  max-width: 1000px;
  margin: 0 auto;
}

@media (width >= 769px) and (width <= 1024px) {
  .jai-container {
    grid-template-columns: repeat(2, minmax(280px, 400px));
    justify-content: center;
  }
}

@media (width <= 768px) {
  .jai-container {
    grid-template-columns: 1fr;
    max-width: 400px;
  }
  
  .page-title {
    font-size: 26px;
  }
  
  .page-description {
    font-size: 14px;
  }
}

/* Local First Phone page styles */
.phone-mockup {
  text-align: center;
  margin-bottom: 30px;
}

.phone-mockup img {
  max-width: 400px;
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 5px 15px rgb(0 0 0 / 10%);
}

/* Project update banner */
.project-update-banner {
  background-color: rgb(66 153 225 / 10%);
  border-left: 4px solid #4299e1;
  padding: 16px;
  margin: 24px 0;
  border-radius: 4px;
}

.project-update-banner h3 {
  margin-top: 0;
  color: #2b6cb0;
  font-size: 18px;
}

.project-update-banner p {
  margin-bottom: 8px;
}

.project-update-banner p:last-child {
  margin-bottom: 0;
}

.project-update-banner a {
  color: #3182ce;
  font-weight: 500;
  text-decoration: none;
}