/* semantic-renderer — default styles
   Import: import 'semantic-renderer/react/styles.css'
   All classes use .sem- prefix to avoid collisions. */

.sem-body { display: flex; flex-direction: column; gap: 16px; }

/* Verdict */
.sem-verdict { display: flex; gap: 14px; padding: 16px 18px; border-left: 4px solid var(--sem-accent, #6366f1); background: linear-gradient(135deg, rgba(99,102,241,0.04) 0%, rgba(109,40,217,0.03) 100%); border-radius: 0 10px 10px 0; }
.sem-verdict-icon { flex-shrink: 0; color: var(--sem-accent, #6366f1); margin-top: 2px; }
.sem-verdict-content { flex: 1; min-width: 0; }
.sem-verdict-content p { font-size: 1.02em; }
.sem-verdict-reasoning { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--sem-border, #e5e7eb); opacity: 0.75; font-size: 0.92em; }

/* Pros & Cons */
.sem-pros-cons { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.sem-pros-col, .sem-cons-col { border-radius: 10px; border: 1px solid var(--sem-border, #e5e7eb); overflow: hidden; }
.sem-pros-header, .sem-cons-header { display: flex; align-items: center; gap: 8px; padding: 10px 14px; font-weight: 600; font-size: 0.88em; text-transform: uppercase; letter-spacing: 0.04em; }
.sem-pros-header { background: rgba(22,163,74,0.08); color: #16a34a; border-bottom: 1px solid rgba(22,163,74,0.15); }
.sem-cons-header { background: rgba(220,38,38,0.08); color: #dc2626; border-bottom: 1px solid rgba(220,38,38,0.15); }
.sem-pros-list, .sem-cons-list { list-style: none; padding: 8px 14px; margin: 0; }
.sem-pros-item, .sem-cons-item { display: flex; align-items: flex-start; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--sem-border, #e5e7eb); font-size: 0.93em; line-height: 1.5; }
.sem-pros-item:last-child, .sem-cons-item:last-child { border-bottom: none; }
.sem-pros-icon { flex-shrink: 0; color: #16a34a; margin-top: 3px; }
.sem-cons-icon { flex-shrink: 0; color: #dc2626; margin-top: 3px; }

/* Steps */
.sem-steps { display: flex; flex-direction: column; }
.sem-step { display: flex; gap: 14px; min-height: 48px; }
.sem-step-rail { display: flex; flex-direction: column; align-items: center; flex-shrink: 0; width: 32px; }
.sem-step-circle { width: 28px; height: 28px; border-radius: 50%; background: var(--sem-accent, #6366f1); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 0.78em; font-weight: 700; flex-shrink: 0; }
.sem-step-line { width: 2px; flex: 1; background: var(--sem-border, #d1d5db); margin: 4px 0; min-height: 16px; }
.sem-step-last .sem-step-line { display: none; }
.sem-step-content { flex: 1; min-width: 0; padding-bottom: 16px; }
.sem-step-last .sem-step-content { padding-bottom: 0; }
.sem-step-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; background: none; border: none; cursor: pointer; font: inherit; font-weight: 600; font-size: 0.95em; color: inherit; padding: 4px 8px 4px 0; text-align: left; border-radius: 6px; transition: background 0.15s; }
.sem-step-title:hover { background: rgba(0,0,0,0.03); }
.sem-step-title svg { flex-shrink: 0; opacity: 0.5; }
.sem-step-body { overflow: hidden; padding-top: 6px; }
.sem-step-body p { font-size: 0.93em; }

/* Comparison */
.sem-comparison { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.sem-comparison-card { border-radius: 10px; border: 1px solid var(--sem-border, #e5e7eb); overflow: hidden; }
.sem-comparison-card-header { display: flex; align-items: center; gap: 8px; padding: 10px 14px; font-weight: 600; font-size: 0.95em; border-bottom: 2px solid var(--sem-accent, #6366f1); background: rgba(0,0,0,0.015); }
.sem-comparison-card-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.sem-comparison-card-points { list-style: none; padding: 8px 14px; margin: 0; }
.sem-comparison-card-point { padding: 6px 0; border-bottom: 1px solid var(--sem-border, #e5e7eb); font-size: 0.92em; line-height: 1.5; }
.sem-comparison-card-point:last-child { border-bottom: none; }

/* Data Table */
.sem-data-table { border-radius: 10px; border: 1px solid var(--sem-border, #e5e7eb); overflow: hidden; }
.sem-table-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 12px; background: rgba(0,0,0,0.015); border-bottom: 1px solid var(--sem-border, #e5e7eb); }
.sem-table-filter { display: flex; align-items: center; gap: 6px; color: #6b7280; }
.sem-table-filter input { border: 1px solid var(--sem-border, #d1d5db); border-radius: 6px; padding: 4px 8px; font-size: 0.82em; outline: none; width: 160px; }
.sem-table-filter input:focus { border-color: var(--sem-accent, #6366f1); }
.sem-table-count { font-size: 0.78em; color: #6b7280; white-space: nowrap; }
.sem-table-scroll { overflow-x: auto; }
.sem-sort-header { cursor: pointer; user-select: none; white-space: nowrap; }
.sem-sort-header > span { margin-right: 4px; }
.sem-sort-idle { opacity: 0.3; }
.sem-sort-header:hover .sem-sort-idle { opacity: 0.6; }

/* Code + Explanation */
.sem-code-explain { display: grid; grid-template-columns: 55% 45%; border-radius: 10px; border: 1px solid var(--sem-border, #e5e7eb); overflow: hidden; }
.sem-code-panel { border-right: 1px solid var(--sem-border, #e5e7eb); overflow: auto; max-height: 500px; }
.sem-code-panel-header { display: flex; align-items: center; gap: 6px; padding: 6px 12px; background: #1e1e1e; color: #9ca3af; font-size: 0.78em; font-weight: 500; text-transform: uppercase; letter-spacing: 0.04em; }
.sem-explain-panel { padding: 14px 16px; overflow: auto; max-height: 500px; }
.sem-explain-panel-header { font-weight: 600; font-size: 0.82em; text-transform: uppercase; letter-spacing: 0.04em; color: #6b7280; margin-bottom: 10px; padding-bottom: 6px; border-bottom: 1px solid var(--sem-border, #e5e7eb); }
.sem-explain-panel p { font-size: 0.92em; }

/* Email */
.sem-email { border-radius: 10px; border: 1px solid var(--sem-border, #e5e7eb); overflow: hidden; box-shadow: 0 1px 4px rgba(0,0,0,0.04); }
.sem-email-header { display: flex; align-items: center; gap: 8px; padding: 10px 16px; background: linear-gradient(135deg, rgba(99,102,241,0.08) 0%, rgba(139,92,246,0.06) 100%); border-bottom: 1px solid var(--sem-border, #e5e7eb); }
.sem-email-header-icon { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 6px; background: var(--sem-accent, #6366f1); color: #fff; flex-shrink: 0; }
.sem-email-header-label { font-weight: 600; font-size: 0.88em; flex: 1; }
.sem-email-copy { display: flex; align-items: center; gap: 4px; padding: 4px 10px; border: 1px solid var(--sem-border, #d1d5db); border-radius: 6px; background: transparent; color: #6b7280; font-size: 0.78em; font-family: inherit; cursor: pointer; transition: all 0.15s; }
.sem-email-copy:hover { border-color: var(--sem-accent, #6366f1); color: var(--sem-accent, #6366f1); }
.sem-email-fields { padding: 12px 16px; border-bottom: 1px solid var(--sem-border, #e5e7eb); display: flex; flex-direction: column; gap: 6px; background: rgba(0,0,0,0.01); }
.sem-email-field { display: flex; align-items: baseline; gap: 10px; font-size: 0.88em; line-height: 1.5; }
.sem-email-field-label { display: flex; align-items: center; gap: 4px; flex-shrink: 0; width: 60px; font-weight: 600; font-size: 0.85em; text-transform: uppercase; letter-spacing: 0.03em; color: #6b7280; }
.sem-email-field-value { word-break: break-word; }
.sem-email-field-value.sem-email-subject { font-weight: 600; }
.sem-email-body { padding: 20px 24px; }
.sem-email-greeting { font-size: 0.95em; margin-bottom: 12px; }
.sem-email-content { font-size: 0.94em; line-height: 1.7; }
.sem-email-content p { margin-bottom: 0.8em; }
.sem-email-signoff { margin-top: 20px; font-size: 0.94em; }
.sem-email-signature { margin-top: 4px; font-size: 0.88em; color: #6b7280; line-height: 1.6; padding-top: 8px; border-top: 1px solid var(--sem-border, #e5e7eb); max-width: 280px; }

/* Responsive */
@media (max-width: 700px) {
  .sem-pros-cons { grid-template-columns: 1fr; }
  .sem-comparison { grid-template-columns: 1fr; }
  .sem-code-explain { grid-template-columns: 1fr; }
  .sem-code-panel { border-right: none; border-bottom: 1px solid var(--sem-border, #e5e7eb); max-height: 300px; }
  .sem-explain-panel { max-height: none; }
  .sem-table-toolbar { flex-direction: column; align-items: flex-start; }
}
