/* Agency Models case study: additions on top of styles_ai_service.css (the shared Allstate case study styles). */

/* Three hero stats instead of four */
.agm-page .ask-hero-stats { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .agm-page .ask-hero-stats { grid-template-columns: 1fr; } }

/* Visual placeholder: delete once the real visual is in */
.agm-placeholder {
  width: 100%;
  box-sizing: border-box;
  aspect-ratio: 4 / 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 32px;
  text-align: center;
  border: 2px dashed var(--primary-color);
  border-radius: 24px 24px 0 0;
  background: repeating-linear-gradient(135deg, rgba(100,100,200,0.06) 0 14px, rgba(100,100,200,0.02) 14px 28px);
  color: var(--text-primary);
  font-size: .9rem;
  line-height: 1.5;
}
.agm-placeholder strong { font-size: 1.1rem; color: var(--text-headline); }
.agm-placeholder-tag {
  font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px; background: #f59e0b; color: #1a1a1a;
}

/* Two columns, no arrow, for the structured UI vs Ask Allstate split */
.agm-split { grid-template-columns: 1fr 1fr; }
@media (max-width: 700px) { .agm-split { grid-template-columns: 1fr; } }

/* The what-if exchange that shows why chat struggles with numbers */
.agm-chat {
  display: flex; flex-direction: column; align-items: flex-end; gap: 8px;
  margin: 20px 0 28px; padding: 20px; border-radius: 16px;
  border: 1px solid var(--border-color); background: var(--background-color_lighter);
}
.agm-chat-bubble {
  margin: 0; max-width: 80%; padding: 10px 14px; border-radius: 16px 16px 4px 16px;
  background: var(--primary-color); color: #fff; font-size: .9rem; line-height: 1.4;
}

/* "In the MVP" tag in captions */
.agm-mvp-tag {
  display: inline-block; margin-right: 8px; padding: 2px 8px; border-radius: 999px;
  font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  background: rgba(34,197,94,0.14); color: #15803d;
}
html.dark .agm-mvp-tag { color: #4ade80; }
.agm-mvp-tag--designed { background: rgba(100,116,139,0.16); color: #475569; }
html.dark .agm-mvp-tag--designed { background: rgba(148,163,184,0.18); color: #cbd5e1; }

/* Releases in the same destination */
.agm-phases { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 28px; }
.agm-phase {
  display: flex; flex-direction: column; gap: 4px; padding: 16px 18px; border-radius: 14px;
  border: 1px solid var(--border-color); background: var(--background-color_lighter);
  color: var(--text-primary); font-size: .85rem;
}
.agm-phase strong { color: var(--text-headline); font-size: .95rem; }
.agm-phase-num { font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; opacity: .7; }
.agm-phase--mvp { border: 2px solid var(--primary-color); }
@media (max-width: 700px) { .agm-phases { grid-template-columns: 1fr; } }

/* Place the assistant sparkle inside the tab in both 1440 × 2188 captures. */
.agm-tab-figure {
  --capture-background: #f3f6f9;
  position: relative;
}
.agm-tab-figure--muted { --capture-background: #f8fafb; }

/* Cover the displaced white sparkle baked into the capture below the tab. */
.agm-tab-figure::before,
.agm-tab-figure::after {
  content: "";
  position: absolute;
  pointer-events: none;
  left: 97.78%;
  width: 1.39%;
  height: .914%;
}
.agm-tab-figure::before {
  top: 22.3%;
  background: var(--capture-background);
}
.agm-tab-figure::after {
  top: 20.52%;
  background: center / contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M14 4c.5 5.6 4 9 9 9.5-5 .5-8.5 4-9 9-.5-5-4-8.5-9-9 5-.5 8.5-4 9-9.5ZM5 1c.2 2.4 1.6 4 4 4.2-2.4.2-3.8 1.8-4 4.2C4.8 7 3.4 5.4 1 5.2 3.4 5 4.8 3.4 5 1Z'/%3E%3C/svg%3E");
}

.agm-page .ask-hero h1 { max-width: 22ch; }
.agm-page .ask-hero-sub { max-width: 66ch; }
.agm-hero-screen { margin: 0; }
.agm-hero-crop { aspect-ratio: 1440 / 1140; overflow: hidden; }
.agm-page .ask-hero .ask-metadata-grid { grid-template-columns: auto 1fr auto; }
@media (max-width: 600px) { .agm-page .ask-hero .ask-metadata-grid { grid-template-columns: 1fr; } }
@media (min-width: 901px) {
  .agm-page .ask-hero h1 { max-width: none; }
}
@media (min-width: 1025px) {
  .agm-page .ask-hero-inner { grid-template-columns: 1.15fr 1fr; }
}
.agm-hero-screen img { display: block; width: 100%; height: auto; }
@media (max-width: 900px) { .agm-hero-screen { display: none; } }
.agm-byline { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin: 0; }
.agm-page .ask-exec-list a { color: var(--accent-text); text-decoration: underline; text-underline-offset: 3px; font-weight: 600; }
.agm-evidence { margin-block: 40px; }
.agm-evidence figure { margin: 0; }
.agm-comparison { display: block; width: 100%; height: auto; overflow: hidden; }
.agm-enlarge, .agm-viewer button {
  color: var(--text-headline);
  font: inherit;
  font-style: normal;
  padding: 8px 14px;
  background: var(--background-color);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  cursor: pointer;
}
.agm-enlarge { display: block; margin: 10px auto 0; }
.agm-enlarge:focus-visible, .agm-viewer :focus-visible { outline: 2px solid var(--accent-text); outline-offset: 2px; }
.agm-viewer {
  box-sizing: border-box;
  margin: auto;
  padding: 0;
  width: min(96vw, 1600px);
  max-width: 96vw;
  background: var(--background-color_lighter);
  color: var(--text-headline);
  border: 1px solid var(--border-color);
  border-radius: 12px;
}
.agm-viewer::backdrop { background: rgba(0,0,0,.8); }
.agm-viewer form { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0; padding: 12px 18px; }
.agm-viewer h2 { margin: 0; font-size: 1.1rem; }
.agm-viewer-scroll { max-height: 75vh; overflow: auto; overscroll-behavior: contain; }
.agm-viewer-scroll > * { display: block; width: 100%; min-width: 1250px; }
@media (min-width: 641px) {
  .agm-page .ask-hero-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
