/* =========================
   TOABAI CARD SYSTEM
   Single source for shared card surfaces.
========================= */

.tm-card,
.tm-card-soft,
.tm-card-dark,
.tm-card-glass {
  padding: var(--tm-card-padding);
  border-radius: var(--tm-card-radius);
}

.tm-card {
  border: var(--tm-card-border);
  background: var(--tm-color-surface);
  box-shadow: var(--tm-card-shadow);
}

.tm-card-soft {
  border: 1px solid var(--tm-color-border);
  background: var(--tm-color-surface-soft);
  box-shadow: none;
}

.tm-card-dark {
  border: 1px solid rgba(255, 255, 255, .10);
  background: var(--tm-color-surface-dark);
  color: var(--tm-color-white);
  box-shadow: none;
}

.tm-card-glass {
  border: 1px solid rgba(255, 255, 255, .85);
  background: rgba(255, 255, 255, .90);
  color: var(--tm-color-text);
  box-shadow: var(--tm-shadow-sm);
  backdrop-filter: blur(12px);
}

.tm-card h3 {
  margin-top: 0;
  margin-bottom: .75rem;
  color: inherit;
  font-size: var(--tm-font-size-h3);
  line-height: var(--tm-line-heading);
  letter-spacing: -.025em;
}

.tm-card p {
  color: var(--tm-color-muted);
  line-height: var(--tm-line-body);
}

.tm-card-dark p {
  color: rgba(255, 255, 255, .74);
}

.tm-card-number {
  display: inline-flex;
  margin-bottom: var(--tm-space-5);
  color: var(--tm-color-primary);
  font-size: .78rem;
  font-weight: 850;
  letter-spacing: .14em;
}

.tm-card-list {
  display: grid;
  gap: var(--tm-space-3);
  margin: var(--tm-space-5) 0;
  padding: 0;
  list-style: none;
}

.tm-card-list li {
  position: relative;
  padding-left: 22px;
}

.tm-card-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: #60a5fa;
  font-weight: var(--tm-weight-bold);
}

/* =========================
   CARD EXTENSIONS
========================= */

.tm-card>*:last-child {
  margin-bottom: 0;
}

/* =========================
   REPORT / STATUS CARDS
========================= */

.tm-status-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.tm-status-warning {
  color: #ea580c;
}

.tm-status-danger {
  color: #dc2626;
}

/* =========================
   PRICING
========================= */

.tm-pricing-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.tm-pricing-card-featured {
  border-color: rgba(37, 99, 235, 0.35);
  box-shadow: 0 28px 80px rgba(37, 99, 235, 0.16);
}

.tm-price {
  color: #0f172a;
  font-size: clamp(2.8rem, 5vw, 4rem);
  font-weight: 850;
  line-height: 1;
  letter-spacing: -0.06em;
}

.tm-price span {
  color: #64748b;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0;
}

/* =========================
   FAQ
   Shared accordion system for production pages and the component library.
========================= */

.tm-faq {
  display: grid;
  gap: 14px;
}

.tm-faq details {
  overflow: clip;
  padding: 0;
  border: 1px solid var(--tm-color-border);
  border-radius: var(--tm-card-radius);
  background: var(--tm-color-surface);
  box-shadow: var(--tm-card-shadow);
  transition:
    border-color var(--tm-transition-fast),
    box-shadow var(--tm-transition-fast),
    transform var(--tm-transition-fast);
}

.tm-faq details:hover {
  border-color: rgba(37, 99, 235, .28);
  box-shadow: var(--tm-shadow-sm);
}

.tm-faq details[open] {
  border-color: rgba(37, 99, 235, .34);
  box-shadow: 0 16px 42px rgba(15, 23, 42, .07);
}

.tm-faq summary {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 72px;
  padding: 20px 64px 20px 24px;
  cursor: pointer;
  list-style: none;
  color: var(--tm-color-navy);
  font-size: clamp(1.02rem, 1.3vw, 1.16rem);
  font-weight: 800;
  line-height: 1.4;
  letter-spacing: -.025em;
}

.tm-faq summary::-webkit-details-marker {
  display: none;
}

.tm-faq summary::after {
  content: "+";
  position: absolute;
  top: 50%;
  right: 22px;
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  transform: translateY(-50%);
  border-radius: 10px;
  background: var(--tm-color-info-soft);
  color: var(--tm-color-primary);
  font-size: 1.35rem;
  font-weight: 600;
  line-height: 1;
  transition:
    background-color var(--tm-transition-fast),
    color var(--tm-transition-fast),
    transform var(--tm-transition-fast);
}

.tm-faq details[open] summary::after {
  content: "−";
  background: var(--tm-color-primary);
  color: var(--tm-color-white);
}

.tm-faq summary:focus-visible {
  outline: 0;
  box-shadow: inset var(--tm-focus-ring);
}

.tm-faq details > p {
  margin: 0;
  padding: 0 24px 22px;
  color: var(--tm-color-muted);
  line-height: var(--tm-line-body);
}

@media (max-width: 640px) {
  .tm-faq {
    gap: 12px;
  }

  .tm-faq details {
    border-radius: 18px;
  }

  .tm-faq summary {
    min-height: 66px;
    padding: 18px 56px 18px 19px;
    font-size: 1rem;
  }

  .tm-faq summary::after {
    right: 17px;
    width: 28px;
    height: 28px;
    border-radius: 9px;
  }

  .tm-faq details > p {
    padding: 0 19px 19px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tm-faq details,
  .tm-faq summary::after {
    transition: none;
  }
}

/* =========================
   SERVICE CARD SYSTEM
========================= */

.tm-service-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

/* =========================
   CARD
========================= */

.tm-service-card {
  position: relative;

  display: flex;
  flex-direction: column;

  min-height: 100%;

  padding: 34px;

  overflow: hidden;

  border: var(--tm-card-border);
  border-radius: var(--tm-card-radius);

  background:
    radial-gradient(circle at 100% 0%,
      rgba(37, 99, 235, 0.05),
      transparent 36%),
    #ffffff;

  box-shadow: var(--tm-card-shadow);

  transition:
    transform 220ms ease,
    border-color 220ms ease,
    box-shadow 220ms ease;
}

.tm-service-card:hover {
  transform: translateY(-4px);

  border-color: rgba(37, 99, 235, 0.16);

  box-shadow: var(--tm-card-shadow-hover);
}

/* =========================
   TOP
========================= */

.tm-service-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;

  margin-bottom: 26px;
}

/* =========================
   ICON
========================= */

.tm-service-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: 58px;
  height: 58px;

  border: 1px solid rgba(37, 99, 235, 0.12);
  border-radius: 18px;

  background: rgba(37, 99, 235, 0.06);

  color: #2563eb;
}

.tm-service-icon svg {
  width: 24px;
  height: 24px;
}

/* =========================
   BADGE
========================= */

.tm-service-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  min-height: 34px;
  padding: 0 14px;

  border-radius: 999px;

  background: rgba(37, 99, 235, 0.08);

  color: #2563eb;

  font-size: 0.74rem;
  font-weight: 800;

  letter-spacing: 0.04em;
}

.tm-service-badge-success {
  background: rgba(22, 163, 74, 0.10);
  color: #15803d;
}

/* =========================
   CONTENT
========================= */

.tm-service-card h3 {
  margin: 0 0 14px;

  color: #0f172a;

  font-size: 1.5rem;
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.tm-service-card p {
  margin: 0 0 28px;

  color: #64748b;

  line-height: 1.8;
}

/* =========================
   FEATURES
========================= */

.tm-service-features {
  display: flex;
  flex-direction: column;
  gap: 12px;

  margin-bottom: 30px;
}

.tm-service-features span {
  display: inline-flex;
  align-items: center;
  gap: 10px;

  color: #475569;

  font-size: 0.92rem;
  font-weight: 700;
}

.tm-service-features span::before {
  content: "";

  width: 7px;
  height: 7px;

  flex: 0 0 auto;

  border-radius: 999px;

  background: #2563eb;
}

/* =========================
   KPI ROW
========================= */

.tm-service-kpis {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;

  margin-top: auto;
  margin-bottom: 26px;
}

.tm-service-kpi {
  padding: 16px;

  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 18px;

  background: #f8fafc;
}

.tm-service-kpi strong {
  display: block;
  margin-bottom: 4px;

  color: #0f172a;

  font-size: 1.2rem;
  line-height: 1;
}

.tm-service-kpi span {
  color: #64748b;

  font-size: 0.78rem;
  font-weight: 700;
}

.tm-service-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;

  color: #2563eb;

  font-size: 0.92rem;
  font-weight: 800;

  text-decoration: none;

  transition:
    gap 180ms ease,
    opacity 180ms ease;
}

.tm-service-link:hover {
  gap: 14px;
  opacity: 0.9;
}

.tm-service-link svg {
  width: 16px;
  height: 16px;
}

/* =========================
   DARK VERSION
========================= */

.tm-service-card-dark {
  border-color: rgba(255, 255, 255, 0.08);

  background:
    radial-gradient(circle at 100% 0%,
      rgba(37, 99, 235, 0.18),
      transparent 34%),
    linear-gradient(180deg, #071225 0%, #0f172a 100%);
}

.tm-service-card-dark h3,
.tm-service-card-dark strong {
  color: #ffffff;
}

.tm-service-card-dark p,
.tm-service-card-dark .tm-service-features span,
.tm-service-card-dark .tm-service-kpi span {
  color: rgba(255, 255, 255, 0.72);
}

.tm-service-card-dark .tm-service-kpi {
  border-color: rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}

.tm-service-card-dark .tm-service-icon {
  border-color: rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.06);

  color: #ffffff;
}

/* =========================
   MOBILE
========================= */

@media (max-width: 980px) {

  .tm-service-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

}

@media (max-width: 760px) {

  .tm-service-grid {
    grid-template-columns: 1fr;
  }

  .tm-service-card {
    padding: 28px;
  }

  .tm-service-kpis {
    grid-template-columns: 1fr;
  }

}

.tm-maint-card,
.tm-maint-process article,
.tm-maint-mini-grid div,
.tm-web-card,
.tm-web-reference-card,
.tm-web-info-box,
.tm-web-testimonials,
.tm-web-quote-card {
  background: #ffffff;
  border: 1px solid rgba(226,232,240,.92);
  box-shadow:
    0 12px 36px rgba(15,23,42,.045),
    inset 0 1px 0 rgba(255,255,255,.85);
}

.tm-home-solution-point,
.tm-home-trust-item {
  padding: 22px;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid rgba(226,232,240,.92);
  box-shadow: 0 10px 28px rgba(15,23,42,.04);
}

.tm-home-solution-point strong,
.tm-home-trust-item strong {
  display: block;
  margin-bottom: 7px;
  color: #0f172a;
}

.tm-home-solution-point span,
.tm-home-trust-item span {
  color: #64748b;
  line-height: 1.65;
}

@media (max-width: 540px) {
  .tm-home-problem-card,
  .tm-home-solution-point,
  .tm-home-trust-item {
    padding: 22px;
    border-radius: 22px;
  }
}

/* =========================
   PRICE / FIT CARD
========================= */

.tm-price-card {
  padding: 38px;
  border-radius: 32px;
}

.tm-price-card h3 {
  font-size: 1.5rem;
  line-height: 1.15;
}

.tm-price-card ul {
  display: grid;
  gap: 12px;
  margin: 24px 0;
  padding: 0;
  list-style: none;
}

.tm-price-card li {
  color: #0f172a;
  font-weight: 760;
}

.tm-price-card small {
  display: block;
  margin-top: 18px;
  color: #64748b;
  line-height: 1.6;
}

@media (max-width: 760px) {
  .tm-price-card {
    padding: 26px;
  }
}
