/* Tool-specific styles only - base styles are in tool-layout.css */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: #0a0a0a;
    color: #e5e7eb;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background-color: #141414;
    border-bottom: 1px solid #374151;
    z-index: 100;
}

    max-width: 1200px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
}

    margin-top: 60px;
    padding: 48px 24px;
    text-align: center;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

    max-width: 720px;
    margin: 0 auto;
}

.tool-main {
    flex: 1;
    padding: 32px 24px 120px;
}

.tool-container {
    max-width: 720px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.input-section {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.section-title {
    font-size: 16px;
    font-weight: 600;
    color: #e5e7eb;
    display: flex;
    align-items: center;
    gap: 8px;
}

.template-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.template-btn {
    background-color: #1a1a1a;
    border: 1px solid #374151;
    color: #e5e7eb;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: all 150ms ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.template-btn:hover {
    background-color: #374151;
}

.template-btn.active {
    background-color: #667eea;
    border-color: #667eea;
    color: #ffffff;
}

.count-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.count-btn {
    background-color: #1a1a1a;
    border: 1px solid #374151;
    color: #e5e7eb;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: all 150ms ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.count-btn:hover {
    background-color: #374151;
}

.count-btn.active {
    background-color: #667eea;
    border-color: #667eea;
    color: #ffffff;
}

.pro-badge {
    color: #0a0a0a;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    padding: 1px 5px;
    border-radius: 3px;
    flex-shrink: 0;
    letter-spacing: 0.3px;
}

.text-input {
    background-color: #141414;
    border: 1px solid #374151;
    color: #e5e7eb;
    padding: 12px 16px;
    border-radius: 6px;
    font-size: 15px;
    font-family: inherit;
    outline: none;
    width: 100%;
    transition: border-color 150ms ease, box-shadow 150ms ease;
}

.text-input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.15);
}

.text-input::placeholder {
    color: #6b7280;
}

textarea.text-input {
    resize: vertical;
    line-height: 1.5;
}

.select-input {
    background-color: #141414;
    border: 1px solid #374151;
    color: #e5e7eb;
    padding: 12px 16px;
    border-radius: 6px;
    font-size: 15px;
    font-family: inherit;
    cursor: pointer;
    outline: none;
    width: 100%;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%239ca3af' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
    transition: border-color 150ms ease, box-shadow 150ms ease;
}

.select-input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.15);
}

.select-input option {
    background-color: #1a1a1a;
}

input[type="range"].slider {
    width: 100%;
    height: 4px;
    background-color: #374151;
    border-radius: 2px;
    outline: none;
    -webkit-appearance: none;
    cursor: pointer;
    display: block;
}

input[type="range"].slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background-color: #667eea;
    border-radius: 50%;
    cursor: pointer;
}

input[type="range"].slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background-color: #667eea;
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

input[type="range"].slider:focus-visible::-webkit-slider-thumb {
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.3);
}

.testimonial-card {
    background-color: #141414;
    border: 1px solid #374151;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 12px;
}

.testimonial-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    cursor: pointer;
    transition: background-color 150ms ease;
}

.testimonial-header:hover {
    background-color: #1a1a1a;
}

.testimonial-number {
    font-size: 14px;
    font-weight: 600;
    color: #e5e7eb;
}

.testimonial-toggle {
    background: none;
    border: none;
    color: #6b7280;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 200ms ease, color 150ms ease;
}

.testimonial-toggle:hover {
    color: #e5e7eb;
}

.testimonial-card.collapsed .testimonial-toggle {
    transform: rotate(-90deg);
}

.testimonial-body {
    padding: 0 16px 16px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.testimonial-card.collapsed .testimonial-body {
    display: none;
}

.testimonial-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.testimonial-field > label {
    font-size: 13px;
    font-weight: 500;
    color: #9ca3af;
    display: flex;
    align-items: center;
    gap: 6px;
}

.char-hint {
    font-size: 12px;
    color: #6b7280;
}

.star-selector {
    display: flex;
    gap: 4px;
}

.star-btn {
    background: none;
    border: none;
    color: #374151;
    cursor: pointer;
    padding: 2px;
    transition: color 150ms ease, transform 100ms ease;
    display: flex;
    align-items: center;
}

.star-btn:hover {
    transform: scale(1.15);
}

.star-btn.filled {
    color: #f59e0b;
}

.star-btn.hovered {
    color: #f59e0b;
    opacity: 0.7;
}

.avatar-field {
    position: relative;
}

.avatar-upload-zone {
    display: flex;
    align-items: center;
    gap: 12px;
}

.avatar-preview-wrap {
    position: relative;
    width: 48px;
    height: 48px;
    flex-shrink: 0;
}

.avatar-preview {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #374151;
}

.avatar-remove {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 18px;
    height: 18px;
    background-color: #dc2626;
    color: #ffffff;
    border: none;
    border-radius: 50%;
    font-size: 10px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 150ms ease;
}

.avatar-remove:hover {
    background-color: #ef4444;
}

.avatar-upload-btn {
    padding: 8px 16px;
    font-size: 13px;
}

.setting-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.setting-item > label {
    font-size: 13px;
    font-weight: 500;
    color: #9ca3af;
    display: flex;
    align-items: center;
    gap: 6px;
}

.color-input-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.color-picker {
    width: 40px;
    height: 36px;
    border: 1px solid #374151;
    border-radius: 6px;
    background: none;
    cursor: pointer;
    padding: 2px;
    -webkit-appearance: none;
}

.color-picker::-webkit-color-swatch-wrapper {
    padding: 0;
}

.color-picker::-webkit-color-swatch {
    border: none;
    border-radius: 4px;
}

.color-picker::-moz-color-swatch {
    border: none;
    border-radius: 4px;
}

.hex-input {
    background-color: #141414;
    border: 1px solid #374151;
    color: #e5e7eb;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-family: 'SF Mono', 'Fira Code', 'Fira Mono', monospace;
    width: 100px;
    outline: none;
    transition: border-color 150ms ease, box-shadow 150ms ease;
}

.hex-input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.15);
}

.radio-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 14px;
    color: #e5e7eb;
    padding: 8px 12px;
    background-color: #1a1a1a;
    border: 1px solid #374151;
    border-radius: 6px;
    transition: background-color 150ms ease, border-color 150ms ease;
}

.radio-label:hover {
    background-color: #252525;
}

.radio-label input[type="radio"] {
    display: none;
}

.radio-custom {
    width: 18px;
    height: 18px;
    border: 2px solid #374151;
    border-radius: 50%;
    position: relative;
    flex-shrink: 0;
    transition: border-color 150ms ease;
}

.radio-label input[type="radio"]:checked ~ .radio-custom {
    border-color: #667eea;
}

.radio-label input[type="radio"]:checked ~ .radio-custom::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 8px;
    height: 8px;
    background-color: #667eea;
    border-radius: 50%;
}

.radio-label input[type="radio"]:checked ~ .pro-badge {
    opacity: 1;
}

.button-primary {
    background-color: #667eea;
    color: #ffffff;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    font-family: inherit;
    border: none;
    cursor: pointer;
    transition: background-color 150ms ease;
    text-align: center;
    width: 100%;
}

.button-secondary {
    background-color: #1a1a1a;
    color: #e5e7eb;
    border: 1px solid #374151;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: background-color 150ms ease;
    text-align: center;
}

.output-section {
    background-color: #141414;
    border: 1px solid #374151;
    border-radius: 8px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.output-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.preview-container {
    background-color: #0a0a0a;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    padding: 24px;
    min-height: 200px;
    overflow: auto;
}

.preview-container > * {
    all: initial;
}

.code-tabs {
    display: flex;
    gap: 0;
    border-bottom: 1px solid #374151;
}

.code-tab {
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: #6b7280;
    padding: 10px 16px;
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: color 150ms ease, border-color 150ms ease;
}

.code-tab:hover {
    color: #e5e7eb;
}

.code-tab.active {
    color: #667eea;
    border-bottom-color: #667eea;
}

.code-block {
    background-color: #0a0a0a;
    border: 1px solid #2a2a2a;
    border-radius: 6px;
    overflow: auto;
    max-height: 400px;
}

.code-block pre {
    margin: 0;
    padding: 16px;
    font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Consolas', monospace;
    font-size: 13px;
    line-height: 1.6;
    color: #e5e7eb;
    white-space: pre;
    overflow-x: auto;
}

.code-block code {
    font-family: inherit;
    font-size: inherit;
    color: inherit;
}

.code-block .syn-tag {
    color: #f472b6;
}

.code-block .syn-attr {
    color: #a78bfa;
}

.code-block .syn-val {
    color: #34d399;
}

.code-block .syn-prop {
    color: #60a5fa;
}

.code-block .syn-comment {
    color: #6b7280;
}

.code-block .syn-str {
    color: #fbbf24;
}

.code-actions {
    display: flex;
    gap: 12px;
}

.code-actions .button-primary {
    flex: 1;
}

.code-actions .button-secondary {
    flex: 1;
}

.code-stats {
    font-size: 13px;
    color: #6b7280;
    text-align: center;
}

.copy-success {
    background-color: #059669;
}

.pro-cta-content {
    max-width: 720px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    text-align: center;
}

.pro-cta-text {
    font-size: 14px;
    color: #d1d5db;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.8);
    align-items: center;
    justify-content: center;
    z-index: 200;
    padding: 24px;
}

.modal-overlay.modal-hidden {
    display: none;
}

.modal-overlay.modal-visible {
    display: flex;
}

.modal {
    background-color: #141414;
    border: 1px solid #374151;
    border-radius: 12px;
    padding: 0;
    max-width: 480px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-header {
    padding: 24px 24px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h3 {
    font-size: 22px;
    font-weight: 600;
    color: #ffffff;
}

.modal-close {
    background: none;
    border: none;
    color: #9ca3af;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 150ms ease;
}

.modal-close:hover {
    color: #e5e7eb;
}

.modal-content {
    padding: 24px;
}

.modal-feature-context {
    font-size: 14px;
    color: #9ca3af;
    margin-bottom: 16px;
}

.pro-features-list {
    margin-bottom: 24px;
}

.pro-feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
}

.feature-check {
    width: 20px;
    height: 20px;
    background-color: #059669;
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    flex-shrink: 0;
}

.feature-text {
    font-size: 15px;
    color: #e5e7eb;
}

.modal-cta {
    width: 100%;
    display: block;
}

.error-message {
    background-color: #7f1d1d;
    border: 1px solid #dc2626;
    color: #fca5a5;
    padding: 12px 16px;
    border-radius: 6px;
    font-size: 14px;
    margin-top: 8px;
}

.success-message {
    background-color: #064e3b;
    border: 1px solid #059669;
    color: #6ee7b7;
    padding: 12px 16px;
    border-radius: 6px;
    font-size: 14px;
    margin-top: 8px;
}

.footer {
    background-color: #0a0a0a;
    border-top: 1px solid #374151;
    padding: 32px 24px;
    text-align: center;
    margin-top: auto;
}

.footer p {
    font-size: 14px;
    color: #6b7280;
}

.modal-hidden {
    display: none;
}

@media (max-width: 768px) {
        padding: 32px 16px;
    }

        font-size: 28px;
        line-height: 36px;
    }

        font-size: 14px;
    }

    .tool-main {
        padding: 24px 16px 100px;
    }

    .tool-container {
        gap: 32px;
    }

    .output-section {
        padding: 16px;
    }

    .template-btn {
        padding: 6px 12px;
        font-size: 12px;
    }

    .count-btn {
        padding: 6px 10px;
        font-size: 12px;
    }

    .code-actions {
        flex-direction: column;
    }

    .pro-cta-content {
        flex-direction: column;
        gap: 10px;
    }

        padding: 0 16px;
    }

    .preview-container {
        padding: 16px;
    }

    .testimonial-body {
        padding: 0 12px 12px;
    }
}

@media (max-width: 480px) {
    .template-selector {
        gap: 6px;
    }

    .count-selector {
        gap: 6px;
    }

    .color-input-group {
        flex-wrap: wrap;
    }
}