.page-ai .site-header-cta {
  display: inline-flex;
  align-items: center;
  padding: 0.48rem 0.95rem;
  font-size: 0.8125rem;
}

.page-ai main {
  position: relative;
  z-index: 1;
}

.ai-privacy-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.9rem;
  padding: 0;
  font-size: 0.74rem;
  font-weight: 550;
  color: #6b7a64;
  background: transparent;
  border: 0;
  border-radius: 0;
}

.ai-lab {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 1.75rem;
  border-top: 1px solid rgba(58, 52, 47, 0.14);
}

@media (min-width: 860px) {
  .ai-lab {
    display: grid;
    grid-template-columns: 15.5rem minmax(0, 1fr);
    align-items: stretch;
  }
}

.ai-score-panel {
  padding: 1.45rem 0 1.4rem;
  border-radius: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}

@media (min-width: 860px) {
  .ai-score-panel {
    padding-right: 1.4rem;
    border-right: 1px solid rgba(58, 52, 47, 0.14);
  }
}

.ai-score-ring-wrap {
  position: relative;
  width: 132px;
  height: 132px;
  margin-bottom: 0.85rem;
}

.ai-score-ring {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.ai-score-ring-bg {
  fill: none;
  stroke: rgba(166, 124, 120, 0.16);
  stroke-width: 8;
}

.ai-score-ring-fill {
  fill: none;
  stroke: #a67c78;
  stroke-width: 8;
  stroke-linecap: square;
  stroke-dasharray: 377;
  stroke-dashoffset: 377;
  transition: stroke-dashoffset 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.ai-score-value {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.ai-score-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.5rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: #3a342f;
}

.ai-score-label {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #8a8178;
  margin-top: 0.3rem;
}

.ai-score-grade {
  font-size: 0.9rem;
  font-weight: 600;
  color: #3a342f;
}

.ai-score-hint {
  font-size: 0.75rem;
  color: #8a8178;
  line-height: 1.5;
  max-width: 14rem;
}

.ai-dimensions {
  padding: 1.25rem 0 1.15rem;
  border-radius: 0;
  background: transparent;
  backdrop-filter: none;
  border: 0;
  box-shadow: none;
  display: flex;
  flex-direction: column;
  gap: 1.05rem;
}

@media (min-width: 860px) {
  .ai-dimensions {
    padding-left: 1.6rem;
  }
}

.ai-dimensions-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.ai-dimensions-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.25rem;
  font-weight: 600;
  color: #3a342f;
}

.ai-dimensions-updated {
  font-size: 0.7rem;
  color: #8a8178;
}

.ai-dim-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.75rem;
  align-items: center;
}

.ai-dim-icon {
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  background: transparent;
  border: 1px solid rgba(166, 124, 120, 0.28);
  color: #8c645f;
}

.ai-dim-icon--layout {
  background: transparent;
  color: #6b7a64;
  border-color: rgba(139, 154, 130, 0.35);
}

.ai-dim-icon--metrics {
  background: transparent;
  color: #6d7786;
  border-color: rgba(139, 150, 163, 0.35);
}

.ai-dim-icon--ats {
  background: transparent;
  color: #7a6c74;
  border-color: rgba(163, 148, 156, 0.35);
}

.ai-dim-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: #3a342f;
  margin-bottom: 0.35rem;
}

.ai-dim-bar {
  height: 3px;
  background: rgba(90, 70, 62, 0.1);
  border-radius: 0;
  overflow: hidden;
}

.ai-dim-bar-fill {
  height: 100%;
  border-radius: 0;
  width: 0;
  transition: width 1s cubic-bezier(0.4, 0, 0.2, 1);
  background: #a67c78;
}

.ai-dim-bar-fill--good {
  background: #8b9a82;
}

.ai-dim-bar-fill--info {
  background: #8b96a3;
}

.ai-dim-bar-fill--brand {
  background: #a3949c;
}

.ai-dim-pct {
  font-size: 0.8rem;
  font-weight: 650;
  color: #3a342f;
  min-width: 2.5rem;
  text-align: right;
}

.ai-insights {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 1.6rem;
  border-top: 1px solid rgba(58, 52, 47, 0.14);
}

@media (min-width: 768px) {
  .ai-insights {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.ai-insight-card {
  padding: 1.15rem 0 1.1rem;
  border-radius: 0;
  background: transparent;
  backdrop-filter: none;
  border: 0;
  border-bottom: 1px solid rgba(58, 52, 47, 0.14);
  box-shadow: none;
}

@media (min-width: 768px) {
  .ai-insight-card {
    padding-right: 1.2rem;
    border-bottom: 0;
    border-right: 1px solid rgba(58, 52, 47, 0.14);
  }

  .ai-insight-card:last-child {
    border-right: 0;
    padding-right: 0;
    padding-left: 1.2rem;
  }

  .ai-insight-card:nth-child(2) {
    padding-left: 1.2rem;
  }
}

.ai-insight-card--warn,
.ai-insight-card--good,
.ai-insight-card--info {
  border-left: 0;
}

.ai-insight-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.45rem;
}

.ai-insight-icon {
  width: auto;
  height: auto;
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  background: transparent;
  color: #8c645f;
}

.ai-insight-title {
  font-size: 0.95rem;
  font-weight: 650;
  color: #3a342f;
}

.ai-insight-text {
  font-size: 0.8125rem;
  color: #5c544c;
  line-height: 1.7;
  margin: 0;
}

.ai-insight-action {
  margin-top: 0.75rem;
  font-size: 0.75rem;
  font-weight: 650;
  color: #8c645f;
  background: transparent;
  border: 0;
  border-bottom: 1px solid #8c645f;
  padding: 0.1rem 0;
  border-radius: 0;
  cursor: pointer;
}

.ai-insight-action:hover {
  background: transparent;
  color: #73524e;
}

.ai-keywords-section {
  padding: 1.35rem 0 1.4rem;
  border-radius: 0;
  background: transparent;
  backdrop-filter: none;
  border: 0;
  border-top: 1px solid rgba(58, 52, 47, 0.14);
  margin-bottom: 1.5rem;
}

.ai-keywords-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.15rem;
}

.ai-keywords-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  font-weight: 600;
  color: #3a342f;
}

.ai-keywords-desc {
  font-size: 0.8125rem;
  color: #8a8178;
  margin-top: 0.25rem;
}

.ai-keywords-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #fff8f5;
  background: #a67c78;
  padding: 0.48rem 0.95rem;
  border-radius: 0;
  border: none;
  cursor: pointer;
}

.ai-keywords-btn:hover {
  background: #8c645f;
}

.ai-keywords-btn:disabled {
  opacity: 0.6;
  cursor: default;
}

.ai-keywords-groups {
  display: grid;
  gap: 1.15rem;
}

@media (min-width: 640px) {
  .ai-keywords-groups {
    grid-template-columns: 1fr 1fr;
    gap: 0 2rem;
  }
}

.ai-kw-group-label {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #8a8178;
  margin-bottom: 0.5rem;
}

.ai-kw-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.7rem;
}

.ai-kw-chip {
  font-size: 0.78rem;
  font-weight: 550;
  padding: 0.15rem 0;
  border-radius: 0;
  border: 0;
  border-bottom: 1px solid transparent;
}

.ai-kw-chip--missing {
  color: #8c645f;
  background: transparent;
  border-color: rgba(166, 124, 120, 0.45);
}

.ai-kw-chip--found,
.ai-kw-chip.is-filled {
  color: #6b7a64;
  background: transparent;
  border-color: rgba(139, 154, 130, 0.45);
}

.ai-kw-chip.is-filled {
  animation: ai-chip-pop 0.35s ease;
}

@keyframes ai-chip-pop {
  0% { transform: scale(0.92); }
  60% { transform: scale(1.06); }
  100% { transform: scale(1); }
}

.ai-actions {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 1.5rem;
  border-top: 1px solid rgba(58, 52, 47, 0.14);
}

@media (min-width: 768px) {
  .ai-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
}

.ai-action-card {
  padding: 1.35rem 0;
  border-radius: 0;
  background: transparent;
  backdrop-filter: none;
  border: 0;
  border-bottom: 1px solid rgba(58, 52, 47, 0.14);
  display: flex;
  flex-direction: column;
}

@media (min-width: 768px) {
  .ai-action-card {
    padding-right: 1.5rem;
    border-bottom: 0;
    border-right: 1px solid rgba(58, 52, 47, 0.14);
  }

  .ai-action-card:last-child {
    border-right: 0;
    padding-right: 0;
    padding-left: 1.5rem;
  }
}

.ai-action-card--highlight {
  background: transparent;
}

.ai-action-icon {
  width: auto;
  height: auto;
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  font-size: 0.9rem;
  margin-bottom: 0.65rem;
  background: transparent;
  color: #8c645f;
}

.ai-action-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  font-weight: 600;
  color: #3a342f;
}

.ai-action-desc {
  font-size: 0.8125rem;
  color: #5c544c;
  margin-top: 0.35rem;
  line-height: 1.65;
  flex: 1;
}

.ai-action-btn {
  margin-top: 1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.52rem 1.05rem;
  border-radius: 0;
  border: none;
  cursor: pointer;
  align-self: flex-start;
}

.ai-action-btn--primary {
  color: #fff8f5;
  background: #a67c78;
}

.ai-action-btn--primary:hover {
  background: #8c645f;
}

.ai-action-btn--secondary {
  color: #3a342f;
  background: transparent;
  border: 1px solid #3a342f;
}

.ai-action-btn.is-loading {
  opacity: 0.7;
  pointer-events: none;
}

.ai-action-btn.is-loading i {
  animation: ai-spin 0.8s linear infinite;
}

@keyframes ai-spin {
  to { transform: rotate(360deg); }
}

.ai-intro-output {
  margin-top: 1rem;
  padding: 0.85rem 0 0;
  background: transparent;
  border: 0;
  border-top: 1px dashed rgba(166, 124, 120, 0.35);
  border-radius: 0;
  position: relative;
}

.ai-intro-output.is-visible {
  animation: ai-fade-in 0.35s ease;
}

@keyframes ai-fade-in {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.ai-intro-text {
  font-size: 0.8125rem;
  color: #5c544c;
  line-height: 1.75;
  margin: 0;
  padding-right: 3.5rem;
}

.ai-intro-copy {
  position: absolute;
  top: 0.75rem;
  right: 0;
  font-size: 0.7rem;
  font-weight: 600;
  color: #8c645f;
  background: transparent;
  border: 0;
  border-bottom: 1px solid #8c645f;
  padding: 0.1rem 0;
  border-radius: 0;
  cursor: pointer;
}

.ai-intro-copy.is-copied {
  color: #6b7a64;
  border-color: #6b7a64;
}

.ai-bottom-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: flex-start;
  padding-top: 0.15rem;
}

.ai-bottom-cta a {
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.65rem 1.15rem;
}
