/* Chemistry AI page-specific layout */

.chemistry-ai-page {
  --chem-ai-panel: rgba(7, 18, 36, 0.78);
  --chem-ai-panel-strong: rgba(10, 26, 49, 0.94);
  --chem-ai-border: rgba(132, 204, 221, 0.26);
  --chem-ai-muted: rgba(226, 238, 246, 0.78);
  --chem-ai-accent: #2dd4bf;
  --chem-ai-accent-2: #38bdf8;
  color: var(--color-text);
}

.chemistry-ai-page a:not(.btn):not(.logo):not(.chemistry-ai-jump-nav a) {
  color: #67e8f9;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(103, 232, 249, 0.42);
  text-underline-offset: 3px;
}

.chemistry-ai-page a:not(.btn):not(.logo):not(.chemistry-ai-jump-nav a):visited {
  color: #7dd3fc;
}

.chemistry-ai-page a:not(.btn):not(.logo):not(.chemistry-ai-jump-nav a):hover,
.chemistry-ai-page a:not(.btn):not(.logo):not(.chemistry-ai-jump-nav a):focus-visible {
  color: #cffafe;
  text-decoration-color: currentColor;
}

.chemistry-ai-page .container {
  width: min(1160px, calc(100% - 32px));
}

.chemistry-ai-hero {
  min-height: auto;
  padding: clamp(96px, 10vw, 128px) 0 clamp(40px, 6vw, 64px);
  background:
    radial-gradient(circle at 15% 18%, rgba(45, 212, 191, 0.2), transparent 31%),
    radial-gradient(circle at 82% 24%, rgba(56, 189, 248, 0.2), transparent 28%),
    linear-gradient(135deg, rgba(3, 10, 24, 0.96), rgba(9, 24, 45, 0.9));
  border-bottom: 1px solid var(--chem-ai-border);
  overflow: hidden;
}

.chemistry-ai-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
  gap: clamp(24px, 4vw, 52px);
  align-items: center;
}

.chemistry-ai-hero__copy {
  text-align: left;
}

.chemistry-ai-eyebrow {
  width: fit-content;
  margin: 0 0 18px;
  padding: 8px 12px;
  border: 1px solid rgba(45, 212, 191, 0.36);
  border-radius: 999px;
  background: rgba(45, 212, 191, 0.1);
  color: #bffbf2;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.chemistry-ai-hero h1 {
  max-width: 940px;
  margin: 0;
  color: #f8fbff;
  font-size: clamp(2.3rem, 3.55vw, 3.45rem);
  line-height: 1.04;
  letter-spacing: 0;
  text-align: left;
}

.chemistry-ai-hero .lead {
  max-width: 68ch;
  margin: 24px 0 0;
  color: var(--chem-ai-muted);
  font-size: clamp(1.02rem, 1.6vw, 1.2rem);
  line-height: 1.75;
}

.chemistry-ai-hero__copy > p[style] {
  margin: 18px 0 0 !important;
  color: rgba(226, 238, 246, 0.68) !important;
  font-size: 0.94rem;
}

.chemistry-ai-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.chemistry-ai-actions .btn {
  min-height: 46px;
  border-radius: 8px;
  padding: 0 20px;
}

.chemistry-ai-actions .btn-secondary {
  border: 1px solid rgba(226, 238, 246, 0.22);
  background: rgba(255, 255, 255, 0.07);
  color: #f8fbff;
}

.chemistry-ai-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: 560px;
  margin-top: 28px;
}

.chemistry-ai-metrics span {
  display: grid;
  gap: 2px;
  min-height: 70px;
  padding: 13px 14px;
  border: 1px solid rgba(226, 238, 246, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(226, 238, 246, 0.78);
  font-size: 0.86rem;
}

.chemistry-ai-metrics strong {
  color: #ffffff;
  font-size: 1.45rem;
  line-height: 1;
}

.chemistry-ai-hero__panel {
  position: relative;
  display: grid;
  gap: 14px;
  min-height: 390px;
  padding: clamp(22px, 3vw, 34px);
  border: 1px solid var(--chem-ai-border);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03)),
    var(--chem-ai-panel);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.32);
  overflow: hidden;
}

.chemistry-ai-orbit {
  position: relative;
  min-height: 160px;
  margin-bottom: 6px;
}

.chemistry-ai-orbit::before,
.chemistry-ai-orbit::after {
  content: "";
  position: absolute;
  inset: 14px 18%;
  border: 1px solid rgba(56, 189, 248, 0.34);
  border-radius: 50%;
  transform: rotate(-18deg);
}

.chemistry-ai-orbit::after {
  transform: rotate(54deg);
  border-color: rgba(45, 212, 191, 0.32);
}

.chemistry-ai-orbit span {
  position: absolute;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--chem-ai-accent);
  box-shadow: 0 0 28px rgba(45, 212, 191, 0.65);
}

.chemistry-ai-orbit span:nth-child(1) {
  left: 48%;
  top: 44%;
  width: 34px;
  height: 34px;
  background: #f8fbff;
}

.chemistry-ai-orbit span:nth-child(2) {
  left: 20%;
  top: 32%;
}

.chemistry-ai-orbit span:nth-child(3) {
  right: 18%;
  bottom: 24%;
  background: var(--chem-ai-accent-2);
}

.chemistry-ai-workflow {
  position: relative;
  display: grid;
  gap: 6px;
  padding: 16px;
  border: 1px solid rgba(226, 238, 246, 0.12);
  border-radius: 8px;
  background: rgba(5, 14, 29, 0.72);
}

.chemistry-ai-workflow span {
  color: rgba(226, 238, 246, 0.62);
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
}

.chemistry-ai-workflow strong {
  color: #f8fbff;
  font-size: clamp(0.98rem, 1.3vw, 1.08rem);
  line-height: 1.35;
}

.chemistry-ai-workflow sub {
  font-size: 0.68em;
  line-height: 0;
  vertical-align: -0.32em;
}

.chemistry-ai-workflow--result {
  border-color: rgba(45, 212, 191, 0.38);
  background: rgba(45, 212, 191, 0.1);
}

.chemistry-ai-jump-nav {
  position: relative;
  z-index: 2;
  margin: -24px 0 14px;
  background: transparent;
}

.chemistry-ai-jump-nav .container {
  display: flex;
  gap: 10px;
  justify-content: center;
  overflow-x: auto;
  padding: 12px;
  border: 1px solid rgba(226, 238, 246, 0.1);
  border-radius: 8px;
  background: rgba(9, 20, 38, 0.72);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.2);
  scrollbar-width: none;
}

.chemistry-ai-jump-nav .container::-webkit-scrollbar {
  display: none;
}

.chemistry-ai-jump-nav a {
  flex: 0 0 auto;
  padding: 9px 14px;
  border: 1px solid rgba(103, 232, 249, 0.16);
  border-radius: 8px;
  color: rgba(226, 238, 246, 0.9);
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.035);
}

.chemistry-ai-jump-nav a:hover,
.chemistry-ai-jump-nav a:focus-visible {
  border-color: rgba(103, 232, 249, 0.48);
  color: #ffffff;
  background: rgba(103, 232, 249, 0.12);
}

.chemistry-ai-page > .services-section,
.chemistry-ai-page > .faq {
  padding: clamp(44px, 7vw, 76px) 0;
}

.chemistry-ai-page > .services-section:nth-of-type(even) {
  background: rgba(4, 14, 28, 0.28);
}

.chemistry-ai-page .services-section h2,
.chemistry-ai-page .faq h2 {
  max-width: 820px;
  margin: 0 auto 14px;
  text-align: center;
  color: var(--color-text);
  font-size: clamp(1.8rem, 3vw, 2.7rem);
  line-height: 1.1;
  letter-spacing: 0;
}

.chemistry-ai-page .services-section .container > p,
.chemistry-ai-page .faq .container > p {
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
  color: var(--color-text-muted);
  text-align: center;
  line-height: 1.75;
}

.chemistry-ai-page .services-section h3:not(.service-card h3) {
  max-width: 760px;
  margin: 32px auto 14px;
  color: var(--color-text);
  text-align: center;
}

.chemistry-ai-page .services-section ul,
.chemistry-ai-page .services-section ol {
  max-width: 900px;
  margin: 24px auto 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 12px;
}

.chemistry-ai-page .services-section li {
  padding: 16px 18px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background: var(--color-surface);
  color: var(--color-text-muted);
  line-height: 1.65;
}

.chemistry-ai-page .services-section li::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 10px;
  border-radius: 50%;
  background: var(--chem-ai-accent);
  box-shadow: 0 0 16px rgba(45, 212, 191, 0.45);
}

.chemistry-ai-page .services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
  margin-top: 30px;
}

.chemistry-ai-page .service-card {
  min-height: 100%;
  padding: 22px;
  border-radius: 8px;
  text-align: left;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.015)),
    var(--color-surface);
}

.chemistry-ai-page .service-card h3 {
  margin-bottom: 12px;
  font-size: 1.08rem;
}

.chemistry-ai-page .service-card p {
  margin-bottom: 20px;
  font-size: 0.96rem;
}

.chemistry-ai-page .service-card .btn {
  align-self: flex-start;
  order: 10;
  min-height: 40px;
  padding: 0 15px;
  border-radius: 8px;
  font-size: 0.9rem;
}

.chemistry-ai-page .faq {
  background: rgba(4, 14, 28, 0.34);
}

.chemistry-ai-page .faq details {
  max-width: 900px;
  margin: 12px auto;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background: var(--color-surface);
  overflow: hidden;
}

.chemistry-ai-page .faq summary {
  cursor: pointer;
  padding: 18px 20px;
  color: var(--color-text);
  font-weight: 800;
  line-height: 1.35;
}

.chemistry-ai-page .faq details[open] summary {
  border-bottom: 1px solid var(--color-border);
}

.chemistry-ai-page .faq details p {
  margin: 0;
  padding: 18px 20px 20px;
  color: var(--color-text-muted);
  line-height: 1.7;
}

@media (max-width: 900px) {
  .chemistry-ai-hero__grid {
    grid-template-columns: 1fr;
  }

  .chemistry-ai-hero h1 {
    max-width: 760px;
  }

  .chemistry-ai-hero__panel {
    min-height: auto;
  }

}

@media (max-width: 620px) {
  .chemistry-ai-page .container {
    width: min(100% - 24px, 1160px);
  }

  .chemistry-ai-hero {
    padding-top: 92px;
  }

  .chemistry-ai-hero h1 {
    max-width: 100%;
    font-size: 2.2rem;
    line-height: 1.08;
  }

  .chemistry-ai-actions .btn {
    width: 100%;
  }

  .chemistry-ai-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
  }

  .chemistry-ai-metrics span {
    min-height: 64px;
    padding: 11px 10px;
    font-size: 0.78rem;
  }

  .chemistry-ai-metrics strong {
    font-size: 1.22rem;
  }

  .chemistry-ai-hero__panel {
    display: none;
  }

  .chemistry-ai-page .services-grid {
    grid-template-columns: 1fr;
  }

  .chemistry-ai-jump-nav {
    margin: -8px 0 8px;
  }

  .chemistry-ai-jump-nav .container {
    justify-content: flex-start;
    width: 100%;
    border-right: 0;
    border-left: 0;
    border-radius: 0;
    box-shadow: none;
  }
}
