/* ============================================================
   Rosario IT Group — AI Solutions & Automation styles
   Extends styles.css design tokens (navy/orange, pill buttons,
   14px radius, 1120px container). No token overrides.
   ============================================================ */

/* ---------- Hero AI link ---------- */
.hero-ai-link {
  display: inline-block;
  margin-top: 18px;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--orange-soft, #FFD9C7);
  color: var(--navy, #242E53);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 0.2s ease, transform 0.2s ease;
}
.hero-ai-link:hover,
.hero-ai-link:focus-visible {
  background: var(--orange, #F7652D);
  color: #fff;
  transform: translateY(-2px);
}

/* ---------- Featured AI service card ---------- */
.ai-feature {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 28px;
  padding: 28px 32px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--navy, #242E53) 0%, var(--navy-soft, #2E3A66) 100%);
  color: #fff;
  text-decoration: none;
  box-shadow: 0 10px 30px rgba(36, 46, 83, 0.18);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.ai-feature:hover,
.ai-feature:focus-visible {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(36, 46, 83, 0.28);
  color: #fff;
}
.ai-feature__icon {
  flex: 0 0 auto;
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(247, 101, 45, 0.18);
  color: var(--orange, #F7652D);
}
.ai-feature__icon svg {
  width: 34px;
  height: 34px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}
.ai-feature__body { flex: 1 1 auto; }
.ai-feature__eyebrow {
  margin: 0 0 4px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--orange, #F7652D);
}
.ai-feature__title {
  margin: 0 0 6px;
  font-size: 1.35rem;
  line-height: 1.25;
  color: #FFFFFF;
}
.ai-feature__text {
  margin: 0;
  max-width: 60ch;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.98rem;
  line-height: 1.55;
}
.ai-feature__cta {
  flex: 0 0 auto;
  font-weight: 700;
  color: var(--orange, #F7652D);
  white-space: nowrap;
}

/* ---------- AI savings showcase ---------- */
.ai-savings .savings-rotator {
  max-width: 760px;
  margin: 0 auto;
}
.savings-viewport {
  overflow: hidden;
  border-radius: 14px;
}
.savings-track {
  display: flex;
  transition: transform 0.6s ease;
}
.savings-slide {
  flex: 0 0 100%;
  padding: 36px 40px;
  background: #fff;
  border: 1px solid var(--line, #E3E7F0);
  border-radius: 14px;
  box-shadow: 0 10px 30px rgba(36, 46, 83, 0.08);
  text-align: center;
}
.savings-slide__tag {
  display: inline-block;
  margin-bottom: 12px;
  padding: 5px 14px;
  border-radius: 999px;
  background: var(--orange-soft, #FFD9C7);
  color: var(--navy, #242E53);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.savings-slide__title {
  margin: 0 0 10px;
  font-size: 1.4rem;
  color: var(--navy, #242E53);
}
.savings-slide__text {
  margin: 0 auto 16px;
  max-width: 52ch;
  color: var(--muted, #5C6478);
  line-height: 1.6;
}
.savings-slide__figure {
  margin: 0;
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--orange, #F7652D);
}
.savings-slide__figure span {
  font-size: 1rem;
  font-weight: 600;
  color: var(--muted, #5C6478);
  margin-left: 6px;
}
.savings-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 18px;
}
.savings-nav {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid var(--line, #E3E7F0);
  background: #fff;
  color: var(--navy, #242E53);
  font-size: 1.1rem;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}
.savings-nav:hover,
.savings-nav:focus-visible {
  background: var(--navy, #242E53);
  color: #fff;
}
.savings-dots {
  display: flex;
  gap: 8px;
}
.savings-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: var(--line, #E3E7F0);
  cursor: pointer;
  transition: background 0.2s ease, width 0.2s ease;
}
.savings-dot.is-active {
  width: 26px;
  background: var(--orange, #F7652D);
}
.savings-disclaimer {
  margin: 16px auto 0;
  max-width: 56ch;
  font-size: 0.8rem;
  color: var(--muted, #5C6478);
  text-align: center;
  font-style: italic;
}
.savings-cta {
  display: block;
  width: fit-content;
  margin: 22px auto 0;
}

/* No-JS fallback: show all slides stacked */
.savings-rotator.no-js .savings-track {
  flex-direction: column;
  gap: 16px;
}
.savings-rotator.no-js .savings-controls {
  display: none;
}

/* ---------- Multi-step AI discovery form ---------- */
.ai-page-hero {
  padding: 72px 0 40px;
  background: linear-gradient(135deg, var(--navy, #242E53) 0%, var(--navy-deep, #1B2340) 100%);
  color: #fff;
  text-align: center;
}
.ai-page-hero .eyebrow {
  color: var(--orange, #F7652D);
}
.ai-page-hero h1 {
  margin: 10px 0 12px;
  font-size: 2.4rem;
  line-height: 1.2;
  color: #FFFFFF;
}
.ai-page-hero p {
  max-width: 60ch;
  margin: 0 auto;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.6;
}

.ai-form-wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 48px 20px 72px;
}
.ai-form-card {
  background: #fff;
  border: 1px solid var(--line, #E3E7F0);
  border-radius: 14px;
  box-shadow: 0 10px 30px rgba(36, 46, 83, 0.08);
  padding: 36px 40px;
}

/* Progress */
.ai-progress {
  display: flex;
  align-items: center;
  gap: 0;
  margin-bottom: 32px;
}
.ai-progress__step {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  position: relative;
}
.ai-progress__step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 15px;
  left: calc(50% + 20px);
  width: calc(100% - 40px);
  height: 2px;
  background: var(--line, #E3E7F0);
}
.ai-progress__step.is-done:not(:last-child)::after {
  background: var(--orange, #F7652D);
}
.ai-progress__num {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--bg-soft, #F4F6FB);
  border: 2px solid var(--line, #E3E7F0);
  color: var(--muted, #5C6478);
  font-weight: 700;
  font-size: 0.9rem;
  z-index: 1;
}
.ai-progress__step.is-active .ai-progress__num {
  background: var(--orange, #F7652D);
  border-color: var(--orange, #F7652D);
  color: #fff;
}
.ai-progress__step.is-done .ai-progress__num {
  background: var(--navy, #242E53);
  border-color: var(--navy, #242E53);
  color: #fff;
}
.ai-progress__label {
  font-size: 0.75rem;
  color: var(--muted, #5C6478);
  text-align: center;
}
.ai-progress__step.is-active .ai-progress__label {
  color: var(--navy, #242E53);
  font-weight: 600;
}

/* Steps */
.ai-step {
  display: none;
}
.ai-step.is-active {
  display: block;
  animation: aiStepIn 0.35s ease;
}
@keyframes aiStepIn {
  from { opacity: 0; transform: translateX(12px); }
  to { opacity: 1; transform: translateX(0); }
}
.ai-step h2 {
  margin: 0 0 6px;
  font-size: 1.5rem;
  color: var(--navy, #242E53);
}
.ai-step__hint {
  margin: 0 0 24px;
  color: var(--muted, #5C6478);
  font-size: 0.95rem;
}
.ai-step .form-field {
  margin-bottom: 18px;
}
.ai-step .optional-tag {
  font-size: 0.75rem;
  color: var(--muted, #5C6478);
  font-weight: 400;
  margin-left: 4px;
}
.ai-checks {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.ai-checks label {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--line, #E3E7F0);
  border-radius: 10px;
  cursor: pointer;
  font-size: 0.95rem;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.ai-checks label:has(input:checked) {
  border-color: var(--orange, #F7652D);
  background: var(--orange-soft, #FFD9C7);
}
.ai-checks input {
  accent-color: var(--orange, #F7652D);
  width: 16px;
  height: 16px;
}

/* Nav buttons */
.ai-form-nav {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--line, #E3E7F0);
}
.ai-form-nav .btn { min-width: 140px; }

/* Privacy note */
.ai-privacy-note {
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: 10px;
  background: var(--bg-soft, #F4F6FB);
  font-size: 0.85rem;
  color: var(--muted, #5C6478);
  line-height: 1.5;
}

/* Submit states */
.ai-form-status {
  display: none;
  text-align: center;
  padding: 40px 20px;
}
.ai-form-status.is-visible { display: block; }
.ai-form-status h2 {
  color: var(--navy, #242E53);
  margin: 0 0 10px;
  font-size: 1.6rem;
}
.ai-form-status p {
  color: var(--muted, #5C6478);
  line-height: 1.6;
  max-width: 48ch;
  margin: 0 auto 20px;
}
.ai-form-status .status-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 18px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--orange-soft, #FFD9C7);
  color: var(--orange, #F7652D);
  font-size: 1.8rem;
}
.ai-form-status .status-icon--error {
  background: #FDE3D8;
  color: #C0392B;
}
.ai-error-text {
  color: #C0392B;
  font-size: 0.9rem;
  margin-top: 12px;
}

/* ---------- AI Solutions page content ---------- */
.ai-solutions-section {
  padding: 56px 0;
}
.ai-solutions-section:nth-of-type(even) {
  background: var(--bg-soft, #F4F6FB);
}
.ai-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin-top: 32px;
}
.ai-detail-card {
  background: #fff;
  border: 1px solid var(--line, #E3E7F0);
  border-radius: 14px;
  padding: 28px;
  box-shadow: 0 10px 30px rgba(36, 46, 83, 0.06);
}
.ai-detail-card h3 {
  margin: 0 0 10px;
  color: var(--navy, #242E53);
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  gap: 10px;
}
.ai-detail-card h3 svg {
  width: 26px;
  height: 26px;
  stroke: var(--orange, #F7652D);
  stroke-width: 2;
  fill: none;
  flex: 0 0 auto;
}
.ai-detail-card p {
  margin: 0;
  color: var(--muted, #5C6478);
  line-height: 1.6;
  font-size: 0.97rem;
}
.ai-cta-band {
  margin-top: 48px;
  padding: 40px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--navy, #242E53), var(--navy-soft, #2E3A66));
  color: #fff;
  text-align: center;
}
.ai-cta-band h2 {
  margin: 0 0 10px;
  font-size: 1.7rem;
}
.ai-cta-band p {
  margin: 0 auto 22px;
  max-width: 52ch;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.6;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .ai-feature {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .ai-feature__cta { align-self: flex-start; }
  .ai-detail-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .ai-form-card { padding: 26px 20px; }
  .savings-slide { padding: 28px 20px; }
  .savings-slide__figure { font-size: 1.8rem; }
  .ai-checks { grid-template-columns: 1fr; }
  .ai-progress__label { display: none; }
  .ai-page-hero h1 { font-size: 1.8rem; }
  .ai-form-nav { flex-direction: column-reverse; }
  .ai-form-nav .btn { width: 100%; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .savings-track { transition: none; }
  .ai-step.is-active { animation: none; }
  .ai-feature, .hero-ai-link, .savings-nav {
    transition: none;
  }
}
