/* MBTI A/T Variants Page Styles */

.tl-mbti-at-page {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1rem 3rem;
}

.tl-mbti-page-header {
  text-align: center;
  margin-bottom: 2.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--color-border);
}

.tl-mbti-page-header h1 {
  font-size: clamp(2rem, 5vw, 2.5rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  color: var(--color-text);
}

.tl-mbti-page-sub {
  display: block;
  font-size: clamp(1.125rem, 2.5vw, 1.375rem);
  font-weight: 400;
  color: var(--color-primary);
  margin-top: 0.25rem;
}

.tl-mbti-page-lead {
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--color-muted);
  max-width: 700px;
  margin: 0 auto;
}

.tl-mbti-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--color-muted);
  margin-bottom: 1.5rem;
  justify-content: center;
}

.tl-mbti-breadcrumb a {
  color: var(--color-muted);
  text-decoration: none;
  transition: color 0.2s;
}

.tl-mbti-breadcrumb a:hover {
  color: var(--color-primary);
}

.tl-mbti-breadcrumb span[aria-hidden="true"] {
  color: var(--color-border);
}

.tl-mbti-section {
  margin-bottom: 3rem;
}

.tl-mbti-section h2 {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--color-primary);
  display: inline-block;
}

.tl-mbti-table-wrap {
  overflow-x: auto;
  margin: 1rem 0;
  border-radius: 12px;
  border: 1px solid var(--color-border);
}

.tl-mbti-at-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

.tl-mbti-at-table th,
.tl-mbti-at-table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}

.tl-mbti-at-table th {
  background: var(--color-surface);
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
}

.tl-mbti-at-table tr:last-child td {
  border-bottom: none;
}

.tl-mbti-at-table tr:hover td {
  background: var(--color-surface-hover);
}

.tl-mbti-at-dim {
  font-weight: 500;
  color: var(--color-text);
  white-space: nowrap;
}

.tl-mbti-at-a {
  color: #166534;
  background: #f0fdf4;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
}

.tl-mbti-at-t {
  color: #92400e;
  background: #fffbeb;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
}

/* Per-Type A/T Grid */
.tl-mbti-at-type-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
}

.tl-mbti-at-type-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
}

.tl-mbti-at-type-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
}

.tl-mbti-at-type-card header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-surface-hover);
}

.tl-mbti-at-type-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.tl-mbti-at-type-code {
  font-family: monospace;
  font-size: 0.875rem;
  font-weight: 700;
  padding: 0.25rem 0.625rem;
  background: var(--color-primary);
  color: white;
  border-radius: 4px;
}

.tl-mbti-at-type-name {
  font-weight: 500;
  color: var(--color-text);
}

.tl-mbti-at-variant-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--color-border);
}

.tl-mbti-at-variant {
  padding: 1.25rem;
  background: var(--color-surface);
}

.tl-mbti-at-variant h3 {
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.tl-mbti-at-badge {
  font-size: 0.6875rem;
  font-weight: 700;
  padding: 0.1875rem 0.5rem;
  border-radius: 3px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.tl-mbti-at-assertive .tl-mbti-at-badge {
  background: #dcfce7;
  color: #166534;
}

.tl-mbti-at-turbulent .tl-mbti-at-badge {
  background: #fef3c7;
  color: #92400e;
}

.tl-mbti-at-variant p {
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--color-text);
}

/* FAQ */
.tl-mbti-faq-item {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  margin-bottom: 0.75rem;
  overflow: hidden;
}

.tl-mbti-faq-item summary {
  padding: 1rem 1.25rem;
  font-weight: 600;
  color: var(--color-text);
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.tl-mbti-faq-item summary::-webkit-details-marker {
  display: none;
}

.tl-mbti-faq-item summary::after {
  content: "+";
  font-size: 1.25rem;
  color: var(--color-primary);
  transition: transform 0.2s;
}

.tl-mbti-faq-item[open] summary::after {
  transform: rotate(45deg);
}

.tl-mbti-faq-item p {
  padding: 0 1.25rem 1rem;
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--color-muted);
}

.tl-mbti-nav-back {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--color-border);
  justify-content: center;
}

.tl-mbti-nav-back a {
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 500;
  transition: opacity 0.2s;
}

.tl-mbti-nav-back a:hover {
  opacity: 0.7;
  text-decoration: underline;
}

/* Mobile */
@media (max-width: 640px) {
  .tl-mbti-at-page {
    padding: 0 1rem 2rem;
  }

  .tl-mbti-at-type-grid {
    grid-template-columns: 1fr;
  }

  .tl-mbti-at-variant-pair {
    grid-template-columns: 1fr;
  }

  .tl-mbti-table-wrap {
    margin: 0.5rem -1rem;
    border-radius: 0;
    border-left: none;
    border-right: none;
  }
}