/* ===== CIP Health — Global Styles ===== */
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@300;400;500;600;700;800&display=swap');

/* --- Custom Properties --- */
:root {
  --bg: #080910;
  --surface: #111319;
  --border: #1E2230;
  --text: #FFFFFF;
  --text-secondary: #9E9E9E;
  --font: 'JetBrains Mono', monospace;
  --grade-a: #00E676;
  --grade-b: #66BB6A;
  --grade-c: #FFA726;
  --grade-d: #EF5350;
  --grade-e: #B71C1C;
  --accent-drink: #00E676;
  --accent-food: #FF6B35;
  --accent-cosmetics: #8B5CF6;
  --accent-plants: #14B8A6;
  --accent-gastro: #F59E0B;
  --accent-baby: #EC4899;
  --accent-diabetes: #3B82F6;
  --accent-supplements: #84CC16;
  --accent-vegan: #22C55E;
  --accent-allergen: #EF4444;
  --accent-water: #06B6D4;
  --accent-urine: #FDD835;
  --accent-womens: #F472B6;
  --accent-hemorrhoid: #DC2626;
  --accent: #00E676;
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --max-width: 1200px;
}

/* --- Reset --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  max-width: 100vw;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
button, input { font-family: var(--font); }

/* --- Bokeh Canvas --- */
.bokeh-canvas,
canvas[id$="-bokeh"] {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(8, 9, 16, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 16px 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.nav-inner,
.nav-container {
  max-width: var(--max-width);
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 15px;
}
.nav-logo-icon,
.logo-icon {
  width: 32px; height: 32px;
  background: var(--grade-a);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
  color: #000;
  flex-shrink: 0;
}
.nav-links { display: flex; gap: 32px; align-items: center; }
.nav-links a {
  font-size: 13px;
  color: var(--text-secondary);
  transition: color 0.2s;
  font-weight: 500;
}
.nav-links a:hover, .nav-links a.active, .nav-link.active { color: var(--text); }
.nav-hamburger,
.hamburger {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  font-size: 24px;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  margin: 4px 0;
  transition: all 0.3s;
}
.nav-mobile,
.nav .nav-mobile {
  display: none;
  position: fixed;
  top: 64px; left: 0; right: 0; bottom: 0;
  background: rgba(8, 9, 16, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  flex-direction: column;
  align-items: center;
  padding-top: 48px;
  gap: 24px;
  z-index: 999;
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  font-size: 18px;
  color: var(--text-secondary);
  font-weight: 500;
  transition: color 0.2s;
}
.nav-mobile a:hover { color: var(--text); }

/* --- Sections --- */
section {
  position: relative;
  padding: 80px 40px;
  max-width: 100vw;
  z-index: 1;
}
.section {
  padding: 80px 40px;
}
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}
.section-title {
  font-size: 36px;
  font-weight: 800;
  margin-bottom: 12px;
  text-align: center;
}
.section-subtitle {
  font-size: 15px;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 48px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* --- Hero --- */
.hero {
  min-height: 100vh;
  width: 100%;
  max-width: 100vw;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 40px 80px;
}
.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  margin: 0 auto;
}
.hero-badge,
.badge {
  display: inline-block;
  background: rgba(0, 230, 118, 0.1);
  border: 1px solid rgba(0, 230, 118, 0.3);
  color: var(--grade-a);
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 24px;
  letter-spacing: 0.5px;
}
.hero h1,
.hero-title {
  font-size: clamp(40px, 6vw, 80px);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 16px;
  background: linear-gradient(135deg, #00E676, #8B5CF6);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-tagline,
.hero-subtitle {
  font-size: clamp(16px, 2.5vw, 22px);
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--text);
}
.hero-desc,
.hero-description {
  font-size: 14px;
  color: var(--text-secondary);
  max-width: 700px;
  margin: 0 auto 40px;
  line-height: 1.8;
}
.hero-stats,
.stats {
  display: flex;
  justify-content: center;
  gap: 48px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}
.hero-stat,
.stat {
  text-align: center;
}
.hero-stat .num,
.stat .counter {
  font-size: 36px;
  font-weight: 800;
  color: var(--grade-a);
  display: block;
}
.stat-suffix {
  font-size: 36px;
  font-weight: 800;
  color: var(--grade-a);
}
.hero-stat .label,
.stat-label {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 500;
  display: block;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  font-family: var(--font);
}
.btn-primary {
  background: var(--accent);
  color: #000;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 230, 118, 0.3);
}
.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
}
.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* --- What is CIP --- */
.what-cip,
.what-is-cip {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.what-cip-text h2,
.what-is-cip-text h2 {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 20px;
}
.what-cip-text p,
.what-is-cip-text p {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 16px;
  line-height: 1.8;
}
.app-icon-grid,
.what-is-cip-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.app-icon-badge,
.app-icon-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 16px 8px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  transition: all 0.3s;
}
.app-icon-badge:hover,
.app-icon-cell:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 20px color-mix(in srgb, var(--icon-color, var(--accent)) 25%, transparent);
}
.app-icon-badge .emoji,
.app-icon-cell > span:first-child {
  font-size: 28px;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
}
.app-icon-badge .name,
.app-icon-label {
  font-size: 10px;
  font-weight: 600;
  text-align: center;
  color: var(--text-secondary);
}

/* --- Apps Grid --- */
.apps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.app-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}
.app-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: var(--card-accent, var(--accent));
}
.app-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
  border-color: var(--card-accent, var(--accent));
}
.app-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.app-card-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
  margin-bottom: 12px;
}
.app-card-content h3,
.app-card-info h3 {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 4px;
}
.app-card-content .app-card-category,
.app-card-info .category {
  font-size: 11px;
  color: var(--text-secondary);
  font-weight: 500;
  display: block;
  margin-bottom: 8px;
}
.app-card-content p,
.app-card-desc {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 12px;
  line-height: 1.6;
}
.app-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}
.app-card-stat {
  font-size: 12px;
  font-weight: 600;
  color: var(--card-accent, var(--accent));
}
.ai-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.3);
  color: #8B5CF6;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  animation: aiGlow 2s ease-in-out infinite;
}
@keyframes aiGlow {
  0%, 100% { box-shadow: 0 0 5px rgba(139, 92, 246, 0.2); }
  50% { box-shadow: 0 0 15px rgba(139, 92, 246, 0.4); }
}
.app-card-link {
  font-size: 12px;
  font-weight: 600;
  color: var(--card-accent, var(--accent));
  transition: opacity 0.2s;
}
.app-card-link:hover { opacity: 0.7; }

/* --- How It Works --- */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.step-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 24px;
  text-align: center;
  transition: all 0.3s;
}
.step-card:hover { transform: translateY(-4px); }
.step-num {
  font-size: 48px;
  font-weight: 800;
  color: var(--accent);
  opacity: 0.3;
  line-height: 1;
  margin-bottom: 12px;
}
.step-icon { font-size: 32px; margin-bottom: 12px; }
.step-card h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
}
.step-card p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* --- AI Section --- */
.ai-cards,
.ai-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.section-description {
  font-size: 14px;
  color: var(--text-secondary);
  text-align: center;
  max-width: 700px;
  margin: 0 auto 40px;
  line-height: 1.8;
}
.section-note {
  text-align: center;
  font-size: 13px;
  color: var(--text-secondary);
}
.ai-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: all 0.3s;
}
.ai-card::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 3px;
  background: var(--card-accent, var(--accent));
}
.ai-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 0 30px rgba(139, 92, 246, 0.15);
}
.ai-card .emoji,
.ai-card-icon { font-size: 36px; margin-bottom: 12px; }
.ai-card h3 { font-size: 14px; font-weight: 700; margin-bottom: 8px; }
.ai-card p { font-size: 12px; color: var(--text-secondary); line-height: 1.6; }

/* --- Grade System --- */
.grades-row {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}
.grade-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 20px;
  text-align: center;
  flex: 1;
  min-width: 180px;
  max-width: 220px;
  transition: all 0.3s;
}
.grade-card:hover { transform: translateY(-4px); }
.grade-letter {
  font-size: 48px;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 8px;
  color: var(--grade-color, var(--text));
}
.grade-label {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 8px;
}
.grade-card p {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* --- Languages --- */
.lang-row {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.lang-pill {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 8px 20px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  transition: all 0.3s;
}
.lang-pill:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.lang-note {
  text-align: center;
  font-size: 13px;
  color: var(--text-secondary);
}

/* --- Features Grid --- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: all 0.3s;
}
.feature-card:hover { transform: translateY(-4px); }
.feature-card .icon,
.feature-icon {
  font-size: 28px;
  margin-bottom: 12px;
}
.feature-card h3 {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 8px;
}
.feature-card p {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* --- Sources --- */
.sources-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.source-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 24px;
  text-align: center;
  transition: all 0.3s;
}
.source-card:hover { transform: translateY(-4px); }
.source-card .icon,
.source-icon { font-size: 36px; margin-bottom: 16px; }
.source-card h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
}
.source-card p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* --- CTA Banner --- */
.cta-banner {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 64px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-banner::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #00E676, #8B5CF6, #F59E0B, #EC4899);
}
.cta-banner h2 {
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 12px;
}
.cta-banner p {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

/* --- Footer --- */
.footer {
  border-top: 1px solid var(--border);
  padding: 64px 40px 32px;
  background: var(--surface);
  position: relative;
  z-index: 1;
}
.footer-grid {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1.5fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.footer-brand .logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 15px;
  margin-bottom: 12px;
}
.footer-brand .tagline,
.footer-tagline {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}
.footer-brand .copy,
.footer-copyright {
  font-size: 11px;
  color: var(--text-secondary);
}
.footer-column h4 {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text);
}
.footer-column ul li {
  margin-bottom: 8px;
}
.footer-column ul a {
  font-size: 12px;
  color: var(--text-secondary);
  transition: color 0.2s;
}
.footer-column ul a:hover { color: var(--text); }
.footer h4 {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text);
}
.footer ul li {
  margin-bottom: 8px;
}
.footer ul a {
  font-size: 12px;
  color: var(--text-secondary);
  transition: color 0.2s;
}
.footer ul a:hover { color: var(--text); }
.footer-bottom {
  max-width: var(--max-width);
  margin: 0 auto;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 11px;
  color: var(--text-secondary);
}

/* --- AI Chat --- */
#ai-chat-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 2000;
  background: var(--surface);
  border: 1px solid var(--grade-a);
  color: var(--grade-a);
  padding: 12px 20px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font);
  transition: all 0.3s;
  box-shadow: 0 0 20px rgba(0, 230, 118, 0.15);
}
#ai-chat-btn:hover {
  box-shadow: 0 0 30px rgba(0, 230, 118, 0.3);
  transform: translateY(-2px);
}
#ai-chat-btn.active { opacity: 0; pointer-events: none; }

#ai-chat-panel {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 2001;
  width: 380px;
  max-height: 500px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  transform: translateY(20px) scale(0.95);
  pointer-events: none;
  transition: all 0.3s;
}
#ai-chat-panel.open {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: all;
}
.ai-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
  font-weight: 700;
}
.ai-chat-header button {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 20px;
  cursor: pointer;
}
.ai-chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 360px;
}
.ai-msg {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  line-height: 1.6;
  max-width: 90%;
}
.ai-msg.bot {
  background: rgba(0, 230, 118, 0.08);
  border: 1px solid rgba(0, 230, 118, 0.15);
  align-self: flex-start;
  color: var(--text-secondary);
}
.ai-msg.user {
  background: var(--border);
  align-self: flex-end;
  color: var(--text);
}
.ai-chat-input {
  display: flex;
  border-top: 1px solid var(--border);
}
.ai-chat-input input {
  flex: 1;
  background: none;
  border: none;
  padding: 14px 20px;
  color: var(--text);
  font-size: 12px;
  outline: none;
}
.ai-chat-input input::placeholder { color: var(--text-secondary); }
.ai-chat-input button {
  background: none;
  border: none;
  color: var(--grade-a);
  font-size: 18px;
  padding: 14px 20px;
  cursor: pointer;
  transition: opacity 0.2s;
}
.ai-chat-input button:hover { opacity: 0.7; }

/* --- Scroll Animations --- */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- App Page Specific --- */
.app-hero {
  min-height: 60vh;
  display: flex;
  align-items: center;
  padding-top: 100px;
}
.app-hero-content {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}
.app-hero-icon {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  margin: 0 auto 20px;
}
.app-hero-content h1 {
  font-size: 40px;
  font-weight: 800;
  margin-bottom: 8px;
}
.app-hero-content .category-badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  padding: 4px 14px;
  border-radius: 999px;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}
.app-hero-content .tagline {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}
.app-hero-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}
.back-link {
  font-size: 13px;
  color: var(--text-secondary);
  transition: color 0.2s;
}
.back-link:hover { color: var(--text); }

/* --- Phone Mockup --- */
.phone-section {
  display: flex;
  justify-content: center;
  padding: 60px 24px;
}
.phone-mockup {
  width: 280px;
  background: #000;
  border-radius: 40px;
  border: 3px solid #333;
  padding: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  position: relative;
}
.phone-notch {
  width: 100px;
  height: 28px;
  background: #000;
  border-radius: 14px;
  margin: 0 auto 8px;
  position: relative;
  z-index: 2;
}
.phone-screen {
  background: var(--bg);
  border-radius: 28px;
  overflow: hidden;
  min-height: 500px;
  padding: 16px;
}
.phone-status {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 16px;
  padding: 0 4px;
}
.phone-header {
  font-size: 18px;
  font-weight: 800;
  margin-bottom: 20px;
  text-align: center;
}
.phone-scan-btn {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin: 0 auto 20px;
  color: #000;
  font-weight: 800;
}
.phone-result {
  background: var(--surface);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 12px;
}
.phone-result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.phone-result-name {
  font-size: 13px;
  font-weight: 700;
}
.phone-grade {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 800;
  color: #000;
}
.phone-bar {
  height: 6px;
  border-radius: 3px;
  margin-bottom: 8px;
  background: var(--border);
  overflow: hidden;
}
.phone-bar-fill {
  height: 100%;
  border-radius: 3px;
}
.phone-ingredient {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  font-size: 11px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border);
}
.phone-ingredient .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* --- App Detail Sections --- */
.app-detail-text {
  max-width: 800px;
  margin: 0 auto;
}
.app-detail-text p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 16px;
}
.app-features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.app-feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  transition: all 0.3s;
}
.app-feature-card:hover { transform: translateY(-4px); }
.app-feature-card .icon { font-size: 24px; margin-bottom: 10px; }
.app-feature-card h3 { font-size: 13px; font-weight: 700; margin-bottom: 6px; }
.app-feature-card p { font-size: 12px; color: var(--text-secondary); line-height: 1.5; }

/* --- Privacy & Support Pages --- */
.page-content {
  max-width: 800px;
  margin: 0 auto;
  padding-top: 120px;
  padding-bottom: 80px;
}
.page-content h1 {
  font-size: 36px;
  font-weight: 800;
  margin-bottom: 8px;
}
.page-content .subtitle {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 40px;
}
.page-content h2 {
  font-size: 20px;
  font-weight: 700;
  margin: 32px 0 12px;
}
.page-content p, .page-content li {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 12px;
}
.page-content a {
  color: var(--accent);
  transition: opacity 0.2s;
}
.page-content a:hover { opacity: 0.7; }
.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
}
.faq-q {
  padding: 16px 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: color 0.2s;
}
.faq-q:hover { color: var(--accent); }
.faq-q .arrow {
  transition: transform 0.3s;
  font-size: 18px;
  color: var(--text-secondary);
}
.faq-item.open .faq-q .arrow { transform: rotate(180deg); }
.faq-a {
  padding: 0 20px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}
.faq-item.open .faq-a {
  max-height: 300px;
  padding: 0 20px 16px;
}
.faq-a p { margin: 0; }

/* --- Responsive --- */
@media (max-width: 1024px) {
  .apps-grid { grid-template-columns: repeat(2, 1fr); }
  .steps-grid { grid-template-columns: repeat(2, 1fr); }
  .ai-cards, .ai-grid { grid-template-columns: repeat(2, 1fr); }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .app-features-grid { grid-template-columns: repeat(2, 1fr); }
  section, .section { padding: 60px 24px; }
  .hero { padding: 100px 24px 60px; }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-hamburger, .hamburger { display: block; }
  .nav { padding: 12px 20px; }
  .hero { padding: 100px 20px 60px; }
  .hero-stats, .stats { gap: 24px; }
  .what-cip, .what-is-cip { grid-template-columns: 1fr; }
  .app-icon-grid, .what-is-cip-grid { grid-template-columns: repeat(4, 1fr); }
  .apps-grid { grid-template-columns: 1fr; }
  .steps-grid { grid-template-columns: 1fr; }
  .ai-cards, .ai-grid { grid-template-columns: 1fr; }
  .features-grid { grid-template-columns: 1fr; }
  .sources-grid { grid-template-columns: 1fr; }
  .grades-row { flex-direction: column; align-items: center; }
  .grade-card { max-width: 100%; }
  .footer-grid { grid-template-columns: 1fr; }
  .app-features-grid { grid-template-columns: 1fr; }
  .section-title { font-size: 28px; }
  section, .section { padding: 40px 16px; }
  #ai-chat-panel { width: calc(100vw - 48px); right: 24px; bottom: 24px; }
  .app-hero-content h1 { font-size: 28px; }
}

/* --- Chat Messages --- */
.chat-message { margin-bottom: 12px; display: flex; }
.chat-message-user { justify-content: flex-end; }
.chat-message-assistant { justify-content: flex-start; }
.chat-message-user .chat-bubble { background: #EA580C; color: white; border-radius: 16px 16px 4px 16px; padding: 10px 14px; max-width: 80%; font-size: 13px; line-height: 1.6; }
.chat-message-assistant .chat-bubble { background: #F2EFE9; color: #1C1917; border-radius: 16px 16px 16px 4px; padding: 10px 14px; max-width: 80%; font-size: 13px; line-height: 1.6; }
.typing-dot { display: inline-block; width: 6px; height: 6px; background: #78716C; border-radius: 50%; margin: 0 2px; animation: typingBounce 1.2s infinite; }
.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingBounce { 0%, 60%, 100% { transform: translateY(0); } 30% { transform: translateY(-6px); } }
