:root {
    --primary: #F59E0B;
    --primary-hover: #D97706;
    --secondary: #FBBF24;
    --accent: #8B5CF6;
    --bg-dark: #0F0D0A;
    --bg-panel: rgba(25, 22, 18, 0.7);
    --text-main: #F3F4F6;
    --text-muted: #9CA3AF;
    --border-color: rgba(245, 158, 11, 0.2);
    --radius: 12px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
    background-image:
        radial-gradient(circle at 15% 50%, rgba(245, 158, 11, 0.05), transparent 25%),
        radial-gradient(circle at 85% 30%, rgba(139, 92, 246, 0.05), transparent 25%);
}

.app-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

header {
    margin-bottom: 2rem;
    text-align: center;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
    color: var(--primary);
}

.logo h1 {
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    color: var(--text-muted);
    font-size: 1.1rem;
}

.glass-panel {
    background: var(--bg-panel);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1.5rem;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    margin-bottom: 1.5rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.glass-panel:hover {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(245, 158, 11, 0.3);
}

h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--secondary);
    display: flex;
    align-items: center;
}

.hint {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
}

textarea,
select {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-main);
    padding: 0.75rem;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: all 0.2s;
}

textarea {
    resize: vertical;
    margin-bottom: 1rem;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.9rem;
}

textarea:focus,
select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.2);
}

.options-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.option-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.primary-btn {
    width: 100%;
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.875rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(245, 158, 11, 0.4);
}

.primary-btn:active {
    transform: translateY(0);
}

.results-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.result-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 400px;
    overflow-y: auto;
    padding-right: 0.5rem;
}

.result-list::-webkit-scrollbar {
    width: 6px;
}

.result-list::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
}

.result-list::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 10px;
}

.url-item {
    background: rgba(0, 0, 0, 0.4);
    padding: 0.75rem;
    border-radius: 8px;
    border-left: 3px solid var(--primary);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    animation: fadeIn 0.3s ease;
}

.url-text {
    font-family: ui-monospace, SFMono-Regular, monospace;
    font-size: 0.85rem;
    word-break: break-all;
    flex: 1;
}

.copy-icon-btn {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    border-radius: 4px;
    padding: 0.4rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.copy-icon-btn:hover {
    color: var(--primary);
    border-color: var(--primary);
    background: rgba(245, 158, 11, 0.1);
}

.tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 0.5rem;
}

.tab-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s;
}

.tab-btn:hover {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
}

.tab-btn.active {
    color: var(--primary);
    background: rgba(245, 158, 11, 0.1);
    font-weight: 500;
}

.code-panel {
    display: none;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.code-panel.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    font-size: 0.85rem;
    color: var(--text-muted);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.copy-btn {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: var(--text-main);
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: background 0.2s;
}

.copy-btn:hover {
    background: var(--primary);
    color: #fff;
}

pre {
    padding: 1rem;
    overflow-x: auto;
    font-size: 0.85rem;
    font-family: ui-monospace, SFMono-Regular, monospace;
    color: #A78BFA;
    margin: 0;
}

pre code {
    white-space: pre-wrap;
}

.header-items {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.header-item {
    background: rgba(0, 0, 0, 0.4);
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid rgba(139, 92, 246, 0.3);
}

.header-key {
    font-size: 0.8rem;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
    font-weight: 600;
}

.header-value {
    font-family: ui-monospace, SFMono-Regular, monospace;
    font-size: 0.9rem;
}

.empty-state {
    color: var(--text-muted);
    font-style: italic;
    font-size: 0.9rem;
    text-align: center;
    padding: 2rem 0;
}

footer {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 2rem;
    opacity: 0.7;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .options-grid {
        grid-template-columns: 1fr;
    }

    .results-layout {
        grid-template-columns: 1fr;
    }
}