@charset "utf-8";
/* CSS Document */
.tu-wrap { max-width: 900px; margin: 0 auto; padding: 0.5rem 0 3rem; }
.tu-wrap *, .tu-wrap *::before, .tu-wrap *::after { box-sizing: border-box; }
.hidden { display: none !important; }

.tu-header { text-align: center; margin: 1.5rem 0 2rem; }
.tu-icon { font-size: 2.6rem; display: block; margin-bottom: 0.5rem; }
.tu-header h1 { font-size: 2.2rem; font-weight: 700; color: var(--text-color, #1e293b); margin: 0 0 0.75rem; line-height: 1.2; }
.tu-header p { color: var(--text-light, #64748b); font-size: 1.05rem; line-height: 1.6; max-width: 680px; margin: 0 auto; }

.tu-card { background: var(--light-color, #ffffff); border: 1px solid var(--border-color, #e2e8f0); border-radius: var(--border-radius-lg, 16px); box-shadow: 0 10px 40px var(--shadow-color, rgba(15, 23, 42, 0.08)); padding: 1.5rem; margin-bottom: 2.5rem; }
.tu-card h2 { font-size: 1.15rem; margin: 1.5rem 0 0.75rem; color: var(--text-color, #1e293b); }

.tu-label, .tu-card label.tu-label { display: block; font-weight: 600; font-size: 0.9rem; color: var(--text-color, #1e293b); margin: 1rem 0 0.4rem; }
.tu-textarea, .tu-input, .tu-select { width: 100%; padding: 0.7rem 0.9rem; border: 1px solid var(--border-color, #cbd5e1); border-radius: 10px; font-size: 0.95rem; font-family: inherit; color: var(--text-color, #1e293b); background: #ffffff; transition: border-color 0.2s ease, box-shadow 0.2s ease; }
.tu-textarea { resize: vertical; line-height: 1.5; min-height: 110px; }
.tu-textarea:focus, .tu-input:focus, .tu-select:focus { outline: none; border-color: #667eea; box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2); }
.tu-textarea[readonly] { background: #f8fafc; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace; }

.tu-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.25rem; margin: 0.75rem 0; }
.tu-field { display: flex; flex-direction: column; flex: 1 1 200px; min-width: 0; }
.tu-field label { font-weight: 600; font-size: 0.85rem; color: var(--text-color, #1e293b); margin-bottom: 0.3rem; }
.tu-check { display: inline-flex; align-items: center; gap: 0.45rem; font-size: 0.9rem; color: var(--text-color, #1e293b); cursor: pointer; }
.tu-check input { width: 1.05rem; height: 1.05rem; accent-color: #667eea; }

.tu-tabs { display: flex; gap: 0.5rem; border-bottom: 2px solid var(--border-color, #e2e8f0); margin-bottom: 1rem; flex-wrap: wrap; }
.tu-tab { background: none; border: none; padding: 0.7rem 1.1rem; font-size: 0.95rem; font-weight: 600; color: var(--text-light, #64748b); cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -2px; }
.tu-tab:hover { color: var(--text-color, #1e293b); }
.tu-tab.active { color: #667eea; border-bottom-color: #667eea; }

.tu-segment { display: inline-flex; border: 1px solid var(--border-color, #cbd5e1); border-radius: 10px; overflow: hidden; }
.tu-seg { background: #ffffff; border: none; padding: 0.55rem 1.1rem; font-size: 0.9rem; font-weight: 600; color: var(--text-color, #1e293b); cursor: pointer; }
.tu-seg + .tu-seg { border-left: 1px solid var(--border-color, #cbd5e1); }
.tu-seg.active { background: linear-gradient(135deg, #667eea, #764ba2); color: #ffffff; }

.tu-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 0.75rem 0; }
.tu-btn, .tu-btn-primary { border-radius: 10px; padding: 0.6rem 1.1rem; font-size: 0.9rem; font-weight: 600; cursor: pointer; transition: transform 0.15s ease, box-shadow 0.15s ease; font-family: inherit; }
.tu-btn { background: #ffffff; color: var(--text-color, #1e293b); border: 1px solid var(--border-color, #cbd5e1); }
.tu-btn:hover { border-color: #667eea; color: #667eea; }
.tu-btn-primary { background: linear-gradient(135deg, #667eea, #764ba2); color: #ffffff; border: none; }
.tu-btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(102, 126, 234, 0.35); }
.tu-btn-primary.copied, .tu-btn.copied { background: #16a34a; border-color: #16a34a; color: #ffffff; }
.tu-btn-small { padding: 0.3rem 0.7rem; font-size: 0.8rem; }

.tu-status { font-size: 0.9rem; color: var(--text-light, #64748b); margin: 0.5rem 0; min-height: 1.4rem; }
.tu-status.error { color: #b91c1c; font-weight: 600; }
.tu-status.ok { color: #15803d; font-weight: 600; }
.tu-status.warn { color: #b45309; }

.tu-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0.75rem; margin: 1rem 0; }
.tu-stat { background: #f8fafc; border: 1px solid var(--border-color, #e2e8f0); border-radius: 12px; padding: 0.8rem 0.9rem; text-align: center; }
.tu-stat strong { display: block; font-size: 1.5rem; color: #667eea; line-height: 1.2; }
.tu-stat span { font-size: 0.8rem; color: var(--text-light, #64748b); }

.tu-table-wrap { overflow-x: auto; margin: 0.5rem 0 1rem; }
.tu-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.tu-table th, .tu-table td { text-align: left; padding: 0.55rem 0.7rem; border-bottom: 1px solid var(--border-color, #e2e8f0); vertical-align: top; }
.tu-table th { font-weight: 700; color: var(--text-color, #1e293b); background: #f8fafc; }
.tu-table code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: #f1f5f9; padding: 0.1rem 0.35rem; border-radius: 4px; font-size: 0.85rem; }

.tu-regex-line { display: flex; align-items: center; gap: 0.4rem; }
.tu-slash { font-size: 1.4rem; color: var(--text-light, #64748b); font-family: ui-monospace, Menlo, Consolas, monospace; }
.tu-flagsout { font-size: 1.1rem; color: #667eea; min-width: 1.5rem; }
.tu-highlight { white-space: pre-wrap; word-break: break-word; background: #f8fafc; border: 1px solid var(--border-color, #e2e8f0); border-radius: 10px; padding: 0.8rem 0.9rem; min-height: 3rem; font-size: 0.9rem; line-height: 1.6; max-height: 320px; overflow: auto; }
.tu-highlight mark { border-radius: 3px; padding: 0 1px; color: inherit; }
.tu-highlight mark.m0 { background: rgba(102, 126, 234, 0.35); }
.tu-highlight mark.m1 { background: rgba(6, 214, 160, 0.4); }
.tu-output-box { white-space: pre-wrap; word-break: break-word; background: #f8fafc; border: 1px solid var(--border-color, #e2e8f0); border-radius: 10px; padding: 0.8rem 0.9rem; font-size: 0.9rem; max-height: 240px; overflow: auto; }

.tu-code { background: #0f172a; color: #e2e8f0; border-radius: 12px; padding: 1rem 1.1rem; overflow: auto; font-size: 0.85rem; line-height: 1.55; max-height: 460px; white-space: pre; margin: 0.5rem 0; }

.tu-listrow { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 0.6rem; align-items: flex-start; }
.tu-listrow .tu-input, .tu-listrow .tu-textarea { flex: 1 1 220px; min-width: 0; }
.tu-listrow .tu-textarea { min-height: 70px; }
.tu-note { background: #fffbeb; border: 1px solid #fde68a; color: #78350f; border-radius: 10px; padding: 0.7rem 0.9rem; font-size: 0.88rem; line-height: 1.5; margin: 0.75rem 0; }
.tu-warnings { margin: 0.5rem 0; padding-left: 1.2rem; color: #b45309; font-size: 0.9rem; }

.tu-bars { display: grid; gap: 0.5rem; margin: 0.75rem 0; font-size: 0.88rem; }
.tu-bar-line { display: flex; justify-content: space-between; gap: 1rem; color: var(--text-color, #1e293b); }
.tu-bar-line b.ok { color: #15803d; }
.tu-bar-line b.over { color: #b45309; }

.tu-results { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 0.75rem; margin: 1rem 0; }
.tu-result { background: #f8fafc; border: 1px solid var(--border-color, #e2e8f0); border-radius: 12px; padding: 0.9rem; display: flex; flex-direction: column; gap: 0.4rem; }
.tu-result small { color: var(--text-light, #64748b); font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; font-size: 0.7rem; }
.tu-result code { font-size: 1.15rem; font-weight: 700; color: #667eea; word-break: break-all; }

.tu-info { margin-bottom: 2.5rem; }
.tu-info h2 { font-size: 1.5rem; color: var(--text-color, #1e293b); margin: 0 0 1rem; }
.tu-info p, .tu-info li { color: var(--text-light, #475569); line-height: 1.7; font-size: 1rem; }
.tu-info ol, .tu-info ul { padding-left: 1.4rem; margin: 0 0 1rem; }
.tu-info li { margin-bottom: 0.4rem; }
.tu-info code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: #f1f5f9; padding: 0.1rem 0.35rem; border-radius: 4px; font-size: 0.9rem; }
.tu-faq h3 { font-size: 1.05rem; color: var(--text-color, #1e293b); margin: 1.25rem 0 0.3rem; }
.tu-faq p { margin: 0; }
.tu-related { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0.75rem; list-style: none; padding: 0; }
.tu-related li { margin: 0; }
.tu-related a { display: block; padding: 0.9rem 1rem; border: 1px solid var(--border-color, #e2e8f0); border-radius: 12px; text-decoration: none; color: var(--text-color, #1e293b); font-weight: 600; transition: border-color 0.2s ease, transform 0.2s ease; }
.tu-related a:hover { border-color: #667eea; transform: translateY(-2px); }

@media (max-width: 640px) {
    .tu-header h1 { font-size: 1.7rem; }
    .tu-card { padding: 1rem; }
    .tu-tab { padding: 0.6rem 0.8rem; }
}
