.jwt-tool {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 15px;
}

.jwt-tool h1 {
    margin-top: 30px;
    margin-bottom: 20px;
    font-size: 28px;
}

.jwt-tool h2 {
    margin-top: 30px;
    margin-bottom: 15px;
    font-size: 22px;
}

.jwt-tool h3 {
    font-size: 18px;
    margin-top: 20px;
    margin-bottom: 10px;
}

.jwt-tool .privacy-note {
    color: #666;
    font-size: 13px;
    margin-bottom: 20px;
    padding: 8px 12px;
    background: #f0faf0;
    border-left: 3px solid #28a745;
    border-radius: 3px;
}

/* JWT Input */
.jwt-input-area {
    width: 100%;
    min-height: 120px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 14px;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 4px;
    resize: vertical;
    word-break: break-all;
    line-height: 1.5;
}

.jwt-input-area:focus {
    border-color: #337ab7;
    outline: none;
}

/* Color-coded JWT display */
.jwt-colored {
    font-family: 'Courier New', Courier, monospace;
    font-size: 14px;
    word-break: break-all;
    padding: 12px;
    background: #1e1e1e;
    border-radius: 4px;
    line-height: 1.6;
    min-height: 40px;
    margin-bottom: 15px;
}

.jwt-colored .jwt-header-part {
    color: #fb015b;
}

.jwt-colored .jwt-payload-part {
    color: #d63aff;
}

.jwt-colored .jwt-signature-part {
    color: #00b9f1;
}

.jwt-colored .jwt-dot {
    color: #fff;
}

/* Decoded panels */
.decoded-panels {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.decoded-panel {
    flex: 1;
    min-width: 0;
}

.decoded-panel .panel-label {
    font-weight: bold;
    font-size: 13px;
    text-transform: uppercase;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.panel-label-header {
    color: #fb015b;
}

.panel-label-payload {
    color: #d63aff;
}

.decoded-panel pre {
    font-family: 'Courier New', Courier, monospace;
    font-size: 13px;
    padding: 12px;
    background: #1e1e1e;
    color: #d4d4d4;
    border-radius: 4px;
    overflow-x: auto;
    margin: 0;
    min-height: 80px;
    white-space: pre-wrap;
    word-wrap: break-word;
    position: relative;
}

/* JSON syntax highlighting */
.json-key {
    color: #9cdcfe;
}

.json-string {
    color: #ce9178;
}

.json-number {
    color: #b5cea8;
}

.json-boolean {
    color: #569cd6;
}

.json-null {
    color: #569cd6;
}

.json-timestamp {
    color: #dcdcaa;
    font-style: italic;
}

/* Expiry badge */
.expiry-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 15px;
}

.expiry-valid {
    background: #d4edda;
    color: #155724;
}

.expiry-expired {
    background: #f8d7da;
    color: #721c24;
}

.expiry-none {
    background: #fff3cd;
    color: #856404;
}

/* Claims table */
.claims-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    font-size: 14px;
}

.claims-table th,
.claims-table td {
    padding: 8px 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.claims-table th {
    background: #f5f5f5;
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    color: #555;
}

.claims-table td:first-child {
    font-family: 'Courier New', Courier, monospace;
    font-weight: 600;
    white-space: nowrap;
    color: #333;
}

.claims-table td:nth-child(2) {
    font-family: 'Courier New', Courier, monospace;
    word-break: break-all;
}

.claims-table td:nth-child(3) {
    color: #666;
    font-size: 13px;
}

/* Signature verification */
.sig-verify {
    padding: 15px;
    background: #f9f9f9;
    border-radius: 4px;
    margin-bottom: 20px;
}

.sig-verify label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
    font-size: 13px;
}

.sig-verify input[type="text"],
.sig-verify textarea {
    width: 100%;
    font-family: 'Courier New', Courier, monospace;
    font-size: 13px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 3px;
    margin-bottom: 10px;
    box-sizing: border-box;
}

.sig-verify textarea {
    min-height: 80px;
    resize: vertical;
}

.sig-result {
    padding: 8px 12px;
    border-radius: 3px;
    font-weight: 600;
    font-size: 13px;
    margin-top: 8px;
}

.sig-result.valid {
    background: #d4edda;
    color: #155724;
}

.sig-result.invalid {
    background: #f8d7da;
    color: #721c24;
}

.sig-result.info {
    background: #e2e3e5;
    color: #383d41;
}

/* Encoder section */
.encoder-section {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid #eee;
}

.encoder-section textarea {
    width: 100%;
    font-family: 'Courier New', Courier, monospace;
    font-size: 13px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    resize: vertical;
    box-sizing: border-box;
}

.encoder-section label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
    margin-top: 10px;
}

.encoder-output {
    font-family: 'Courier New', Courier, monospace;
    font-size: 14px;
    word-break: break-all;
    padding: 12px;
    background: #1e1e1e;
    color: #d4d4d4;
    border-radius: 4px;
    min-height: 40px;
    margin-top: 10px;
}

/* Buttons */
.jwt-btn {
    display: inline-block;
    padding: 6px 14px;
    font-size: 13px;
    border: 1px solid #ddd;
    border-radius: 3px;
    background: #fff;
    color: #333;
    cursor: pointer;
    margin-right: 5px;
    margin-bottom: 5px;
}

.jwt-btn:hover {
    background: #f5f5f5;
}

.jwt-btn-primary {
    background: #337ab7;
    color: #fff;
    border-color: #337ab7;
}

.jwt-btn-primary:hover {
    background: #286090;
}

.jwt-btn-sm {
    padding: 3px 8px;
    font-size: 12px;
}

.copy-btn {
    position: absolute;
    top: 6px;
    right: 6px;
    padding: 2px 8px;
    font-size: 11px;
    background: #444;
    color: #ccc;
    border: 1px solid #555;
    border-radius: 3px;
    cursor: pointer;
}

.copy-btn:hover {
    background: #555;
    color: #fff;
}

.panel-wrapper {
    position: relative;
}

/* Toolbar */
.jwt-toolbar {
    display: flex;
    gap: 8px;
    margin: 10px 0;
    flex-wrap: wrap;
}

/* Algorithm selector for encoder */
.algo-select {
    padding: 6px 10px;
    font-size: 13px;
    border: 1px solid #ddd;
    border-radius: 3px;
}

/* Error display */
.jwt-error {
    color: #721c24;
    background: #f8d7da;
    padding: 8px 12px;
    border-radius: 3px;
    font-size: 13px;
    margin: 10px 0;
}

/* SEO content */
.seo-content {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid #eee;
    line-height: 1.7;
    color: #333;
}

.seo-content p {
    margin-bottom: 14px;
    font-size: 15px;
}

.seo-content code {
    background: #f4f4f4;
    padding: 2px 5px;
    border-radius: 3px;
    font-size: 13px;
    color: #c7254e;
}

.seo-content ul {
    margin-bottom: 16px;
    padding-left: 24px;
}

.seo-content ul li {
    margin-bottom: 8px;
    font-size: 15px;
}

.seo-content a {
    color: #337ab7;
}

.seo-content a:hover {
    color: #23527c;
    text-decoration: underline;
}

.claims-ref-table {
    margin-top: 10px;
}

/* FAQ */
.faq-section {
    margin-top: 10px;
}

.faq-item {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.faq-item:last-child {
    border-bottom: none;
}

.faq-item h3 {
    font-size: 16px;
    margin-top: 0;
    margin-bottom: 8px;
    color: #222;
}

.faq-item p {
    margin-bottom: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .decoded-panels {
        flex-direction: column;
    }
}
