/* JWT 디코더 스타일 - base64 / json-csv-converter 디자인 언어 차용 */
.jwt-tool {
    --tool-primary: #e11d48;
    --tool-bg: #fff1f2;
    --tool-gradient: linear-gradient(135deg, #e11d48 0%, #db2777 100%);
}

/* 히어로 */
.jwt-hero {
    background: var(--tool-gradient);
    border-radius: 16px;
    padding: 36px 32px;
    color: #fff;
    text-align: center;
    position: relative;
    overflow: hidden;
    margin-bottom: 28px;
}
.jwt-hero::before {
    content: '';
    position: absolute;
    top: -80px;
    right: -80px;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 50%;
}
.jwt-hero::after {
    content: '';
    position: absolute;
    bottom: -120px;
    left: -60px;
    width: 260px;
    height: 260px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 50%;
}
.jwt-hero h1 {
    font-size: 28px;
    font-weight: 800;
    position: relative;
    z-index: 1;
    margin: 10px 0 6px;
}
.jwt-hero p {
    opacity: 0.85;
    position: relative;
    z-index: 1;
    margin-bottom: 0;
}

/* 에디터 카드 */
.editor-card {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 14px;
    overflow: hidden;
}
.editor-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #f1f3f5;
}
.editor-title {
    font-weight: 700;
    font-size: 14px;
    color: #343a40;
}
.editor-title i {
    color: var(--tool-primary);
}
.size-badge {
    font-size: 12px;
    font-weight: 600;
    color: #868e96;
    background: #f1f3f5;
    padding: 3px 10px;
    border-radius: 20px;
}
.editor-body {
    padding: 16px;
}
.editor-textarea {
    width: 100%;
    min-height: 140px;
    resize: vertical;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    background: #f8f9fb;
    padding: 14px 16px;
    font-size: 13px;
    line-height: 1.6;
    color: #212529;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace;
}
.editor-textarea:focus {
    border-color: var(--tool-primary);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(225, 29, 72, 0.12);
}

/* 액션 버튼 영역 */
.action-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin: 0 0 18px;
}
.btn-action {
    display: inline-flex;
    align-items: center;
    padding: 9px 18px;
    border-radius: 10px;
    border: 1px solid #dee2e6;
    background: #fff;
    color: #495057;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
}
.btn-action:hover {
    border-color: var(--tool-primary);
    color: var(--tool-primary);
    background: var(--tool-bg);
}
.btn-action-sm {
    padding: 5px 12px;
    font-size: 12.5px;
    border-radius: 8px;
}
.btn-action-primary {
    background: var(--tool-gradient);
    border: none;
    color: #fff;
}
.btn-action-primary:hover {
    background: var(--tool-gradient);
    border: none;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(225, 29, 72, 0.3);
}

/* 토큰 구조 시각화 - jwt.io 스타일 색상 */
.jwt-token-structure {
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace;
    font-size: 13px;
    line-height: 1.8;
    word-break: break-all;
    background: #f8f9fb;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 14px 16px;
}
.jwt-part-header {
    color: #fb015b;
    font-weight: 600;
}
.jwt-part-payload {
    color: #d63aff;
    font-weight: 600;
}
.jwt-part-signature {
    color: #00b9f1;
    font-weight: 600;
}
.jwt-dot {
    color: #6c757d;
    font-weight: 700;
    font-size: 1.1em;
}

/* 세그먼트 라벨 태그 */
.seg-tag {
    font-size: 11px;
    font-weight: 700;
}
.seg-header { color: #fb015b; }
.seg-payload { color: #d63aff; }
.seg-signature { color: #00b9f1; }

/* JSON 신택스 하이라이팅 (다크 출력 영역) */
.json-highlight-output {
    background-color: #1e1e2e !important;
    color: #cdd6f4;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace;
    line-height: 1.6;
}
.json-highlight-output .json-key {
    color: #89b4fa;
}
.json-highlight-output .json-string {
    color: #a6e3a1;
}
.json-highlight-output .json-number {
    color: #fab387;
}
.json-highlight-output .json-boolean {
    color: #cba6f7;
}
.json-highlight-output .json-null {
    color: #f38ba8;
    font-style: italic;
}

/* 서명 출력 */
.signature-output {
    background: #f8f9fb;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 14px 16px;
    color: #868e96;
    word-break: break-all;
}

/* 클레임 테이블 */
.claims-table td {
    vertical-align: middle;
    padding: 0.5rem;
}
.claims-table th {
    padding: 0.5rem;
}

/* 서포트 카드 */
.support-card {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 14px;
    overflow: hidden;
}
.support-card .card-hd {
    padding: 14px 18px;
    font-weight: 700;
    font-size: 15px;
    border-bottom: 1px solid #f1f3f5;
}
.support-card .card-bd {
    padding: 18px;
}
.support-subtitle {
    font-size: 15px;
    font-weight: 700;
    color: #343a40;
    margin: 18px 0 10px;
}

/* 아코디언 */
.jwt-tool .accordion-button:not(.collapsed) {
    background-color: var(--tool-bg);
    color: var(--tool-primary);
    box-shadow: none;
}
.jwt-tool .accordion-button:focus {
    box-shadow: none;
}

/* 반응형 */
@media (max-width: 768px) {
    .jwt-hero { padding: 28px 20px; border-radius: 12px; }
    .jwt-hero h1 { font-size: 22px; }
    .btn-action { flex: 1 1 calc(50% - 8px); justify-content: center; }
}
