/* Shared Tools category pages. Scoped so the catalog and tool pages stay as they are. */
.tools-main:has(.tc-page) {
  --tc-cobalt: var(--wf-primary, #2459e0);
  --tc-hover: var(--wf-primary-hover, #1d47b8);
  --tc-navy: #182b49;
  --tc-bg: #f5f7fb;
  --tc-text: #182b49;
  --tc-muted: #5c6b82;
  --tc-line: rgba(24, 43, 73, 0.12);
  --tc-card: #fff;
  --tc-soft: #eef2f8;
  --tc-accent: #2459e0;
  background: var(--tc-bg);
  color: var(--tc-text);
  font-family: "Plus Jakarta Sans", sans-serif;
}
[data-theme="dark"] .tools-main:has(.tc-page) {
  --tc-bg: #070d18;
  --tc-text: #e8eef8;
  --tc-muted: #9aa8c0;
  --tc-line: rgba(232, 238, 248, 0.14);
  --tc-card: #10192b;
  --tc-soft: #182338;
  --tc-accent: #7c9fff;
}
.tc-page { color: var(--tc-text); }
.tc-wrap {
  width: min(1240px, calc(100% - 40px));
  margin: 0 auto;
  padding: 28px 0 56px;
}
.tc-page .breadcrumbs { margin: 0 0 18px; }
.tc-page .breadcrumb-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--tc-muted);
  font-size: 14px;
}
.tc-page .breadcrumb-item a { color: var(--tc-muted); text-decoration: none; }
.tc-page .breadcrumb-item a:hover { color: var(--tc-accent); }
.tc-page .breadcrumb-item.active { color: var(--tc-text); }
.tc-page .breadcrumb-item + .breadcrumb-item::before {
  content: "/";
  margin-right: 6px;
  color: var(--tc-muted);
}
.tc-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(240px, 0.9fr);
  gap: 28px;
  align-items: center;
  margin-bottom: 28px;
}
.tc-kicker {
  margin: 0 0 8px;
  color: var(--tc-accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.tc-hero h1,
.tc-catalog h2,
.tc-choose h2,
.tc-learn h2,
.tc-close h2 {
  margin: 0 0 10px;
  color: var(--tc-text);
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.08;
  letter-spacing: -0.03em;
}
.tc-lead,
.tc-sub,
.tc-learn-copy p,
.tc-card p,
.tc-situation p {
  margin: 0;
  color: var(--tc-muted);
  font-size: 16px;
  line-height: 1.5;
}
.tc-lead { max-width: 38ch; }
.tc-hero-art {
  display: flex;
  justify-content: flex-end;
  min-width: 0;
}
.tc-hero-img,
.tc-scene {
  width: min(100%, 460px);
  height: auto;
  background: transparent;
  filter: none;
  object-fit: contain;
}
.tc-scene { color: var(--tc-text); }
.tc-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 36px;
}
.tc-pill {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid var(--tc-line);
  border-radius: 999px;
  background: var(--tc-card);
  color: var(--tc-text);
  font-weight: 700;
  text-decoration: none;
}
.tc-pill:hover { text-decoration: none; border-color: rgba(36, 89, 224, 0.35); }
.tc-pill[aria-current="page"] {
  border-color: transparent;
  background: var(--tc-cobalt);
  color: #fff;
}
.tc-pill:focus-visible,
.tc-card:focus-visible,
.tc-situation:focus-visible,
.tc-btn:focus-visible,
.tc-text-link:focus-visible,
.tc-faq summary:focus-visible,
.tc-page a:focus-visible {
  outline: 2px solid var(--tc-cobalt);
  outline-offset: 2px;
}
.tc-catalog h2,
.tc-choose h2,
.tc-learn h2 { font-size: clamp(28px, 3vw, 36px); }
.tc-sub { margin-bottom: 18px; }
.tc-grid,
.tc-choose-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.tc-card,
.tc-situation {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  min-height: 100%;
  padding: 20px;
  border: 1px solid var(--tc-line);
  border-radius: 16px;
  background: var(--tc-card);
  color: inherit;
  text-decoration: none;
  box-shadow: 0 8px 24px rgba(24, 43, 73, 0.04);
}
.tc-card:hover,
.tc-situation:hover {
  text-decoration: none;
  border-color: rgba(36, 89, 224, 0.35);
}
.tc-card h3,
.tc-situation h3 {
  margin: 4px 0 0;
  font-size: 18px;
  letter-spacing: -0.02em;
}
.tc-card p,
.tc-situation p { flex: 1; }
.tc-open {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: auto;
  color: var(--tc-accent);
  font-weight: 700;
}
.tc-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--tc-soft);
  color: var(--tc-accent);
}
.tc-card.is-soon {
  position: relative;
  opacity: 0.72;
}
.tc-soon {
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--tc-soft);
  color: var(--tc-muted);
  font-size: 12px;
  font-weight: 700;
}
.tc-unavailable {
  margin-top: auto;
  color: var(--tc-muted);
  font-size: 14px;
  font-weight: 700;
}
.tc-choose {
  margin-top: 28px;
  padding: 28px;
  border-radius: 20px;
  background: var(--tc-soft);
}
.tc-choose-grid { margin-top: 8px; }
.tc-situation {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
  padding: 8px 12px 8px 0;
}
.tc-situation + .tc-situation { border-left: 1px solid var(--tc-line); padding-left: 20px; }
.tc-learn {
  display: grid;
  grid-template-columns: minmax(220px, 0.8fr) minmax(0, 1.2fr);
  gap: 36px;
  align-items: start;
  margin-top: 48px;
}
.tc-text-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-top: 12px;
  color: var(--tc-accent);
  font-weight: 700;
  text-decoration: none;
}
.tc-text-link:hover { text-decoration: none; }
.tc-faq {
  border-bottom: 1px solid var(--tc-line);
}
.tc-faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 52px;
  padding: 12px 0;
  cursor: pointer;
  font-weight: 700;
  list-style: none;
}
.tc-faq summary::-webkit-details-marker { display: none; }
.tc-faq summary::after {
  content: "+";
  flex: 0 0 auto;
  color: var(--tc-muted);
  font-size: 22px;
  font-weight: 500;
}
.tc-faq[open] summary::after { content: "–"; }
.tc-faq-body {
  padding: 0 0 16px;
  color: var(--tc-muted);
  line-height: 1.6;
}
.tc-faq-body p,
.tc-faq-body ul { margin: 0 0 10px; }
.tc-faq-body a { color: var(--tc-accent); }
.tc-close {
  background: var(--tc-navy);
  color: #fff;
}
.tc-close-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 36px;
  padding-bottom: 36px;
}
.tc-close h2 { color: #fff; font-size: clamp(28px, 3vw, 36px); }
.tc-close p { margin: 0; max-width: 46ch; color: rgba(255, 255, 255, 0.78); }
.tc-close-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.tc-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 10px;
  font-weight: 700;
  text-decoration: none;
}
.tc-btn:hover { text-decoration: none; }
.tc-btn-primary { background: var(--tc-cobalt); color: #fff; }
.tc-btn-primary:hover { background: var(--tc-hover); }
.tc-btn-secondary {
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: transparent;
  color: #fff;
}
.tc-btn-secondary:hover { border-color: #fff; }
.tc-close-decor {
  position: absolute;
  right: 0;
  bottom: 12px;
  pointer-events: none;
}
@media (max-width: 980px) {
  .tc-grid,
  .tc-choose-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tc-situation + .tc-situation { border-left: 0; padding-left: 0; }
  .tc-learn { grid-template-columns: 1fr; gap: 20px; }
}
@media (max-width: 699px) {
  .tc-wrap { width: min(1240px, calc(100% - 32px)); }
}
@media (max-width: 720px) {
  .tc-hero,
  .tc-grid,
  .tc-choose-grid,
  .tc-close-inner { grid-template-columns: 1fr; display: grid; }
  .tc-hero-art { justify-content: flex-start; }
  .tc-hero-img,
  .tc-scene { width: min(100%, 280px); }
  .tc-close-inner { display: grid; }
  .tc-choose { padding: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .tc-page *,
  .tc-page *::before,
  .tc-page *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
