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

:root {
    --bg-primary: #0f1026;
    --bg-secondary: #1a1b3a;
    --bg-card: #252740;
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --accent: #6366f1;
    --accent-hover: #4f46e5;
    --border: #2a2b4a;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
        'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
        sans-serif;
    background: linear-gradient(180deg, var(--bg-primary) 0%, #050610 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

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

.header {
    background: rgba(15, 16, 38, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
    background: linear-gradient(135deg, #6366f1 0%, #06b6d4 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav {
    display: flex;
    gap: 1.5rem;
}

.nav a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.nav a:hover {
    color: var(--text-primary);
}

.hero {
    padding: 4rem 0 3rem;
    text-align: center;
}

.hero h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    background: linear-gradient(135deg, #ffffff 0%, #a1a1aa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero p {
    font-size: 1.125rem;
    color: var(--text-secondary);
}

.tools {
    padding: 2rem 0 3rem;
}

.tools h2 {
    font-size: 1.875rem;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.tool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
}

.tool-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.25rem;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.2s;
    display: block;
}

.tool-card:hover {
    border-color: var(--accent);
    background: #2d2f52;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.tool-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.375rem;
    color: var(--text-primary);
}

.tool-card p {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.monetize {
    padding: 2rem 0 4rem;
}

.monetize h2 {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.monetize p {
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.monetize ul {
    color: var(--text-secondary);
    margin-left: 1.5rem;
}

.monetize li {
    margin-bottom: 0.5rem;
}

.monetize strong {
    color: var(--text-primary);
}

.footer {
    border-top: 1px solid var(--border);
    padding: 1.5rem 0;
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* Tool page styles */
.tool-page {
    min-height: calc(100vh - 140px);
    padding: 2rem 0 3rem;
}

.tool-page h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.tool-page .description {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.input-group {
    margin-bottom: 1rem;
}

.input-group label {
    display: block;
    margin-bottom: 0.375rem;
    color: var(--text-secondary);
    font-weight: 500;
}

textarea {
    width: 100%;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.75rem;
    color: var(--text-primary);
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    font-size: 0.875rem;
    resize: vertical;
    min-height: 200px;
}

textarea:focus {
    outline: none;
    border-color: var(--accent);
}

textarea::placeholder {
    color: var(--text-secondary);
}

.button-group {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.btn {
    background: var(--accent);
    color: var(--text-primary);
    border: none;
    padding: 0.625rem 1.25rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
    font-family: 'Inter', sans-serif;
}

.btn:hover {
    background: var(--accent-hover);
}

.btn-secondary {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--bg-card);
}

.output {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.75rem;
    min-height: 200px;
    white-space: pre-wrap;
    word-break: break-word;
    color: var(--text-primary);
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    font-size: 0.875rem;
    overflow-x: auto;
}

.error {
    color: #f87171;
    border-color: #dc2626;
    background: rgba(220, 38, 38, 0.1);
}

.success {
    color: #34d399;
    border-color: #059669;
    background: rgba(5, 150, 105, 0.1);
}

/* Comparison / guide page styles */
.guide {
    padding: 2.5rem 0 3rem;
}

.guide h1 {
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    line-height: 1.25;
}

.guide h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 2.5rem 0 1rem;
}

.guide h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.guide p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.guide ul {
    color: var(--text-secondary);
    margin: 0 0 1rem 1.25rem;
}

.guide li {
    margin-bottom: 0.4rem;
}

.guide strong {
    color: var(--text-primary);
}

.guide a {
    color: #8b8cf8;
}

.updated {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin-bottom: 1.25rem;
}

.disclosure {
    background: rgba(99, 102, 241, 0.08);
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent);
    border-radius: 6px;
    padding: 0.75rem 1rem;
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.tldr {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1rem;
}

.tldr h2 {
    margin-top: 0;
    font-size: 1.125rem;
}

.tldr ul {
    margin-bottom: 0;
}

.table-wrap {
    overflow-x: auto;
    margin-bottom: 1rem;
    border: 1px solid var(--border);
    border-radius: 8px;
}

.compare-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
    min-width: 720px;
}

.compare-table th,
.compare-table td {
    text-align: left;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}

.compare-table th {
    background: var(--bg-secondary);
    font-weight: 600;
    white-space: nowrap;
}

.compare-table td {
    color: var(--text-secondary);
}

.compare-table tr:last-child td {
    border-bottom: none;
}

.compare-table .tool-name {
    color: var(--text-primary);
    font-weight: 600;
    white-space: nowrap;
}

.pick {
    display: inline-block;
    background: rgba(99, 102, 241, 0.15);
    color: #a5a6fb;
    border-radius: 4px;
    padding: 0.1rem 0.45rem;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.review-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1rem;
}

.review-card.featured {
    border-color: var(--accent);
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.15);
}

.review-card .meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.25rem;
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.review-card .meta strong {
    color: var(--text-primary);
    font-weight: 600;
}

.verdict {
    border-top: 1px solid var(--border);
    padding-top: 0.75rem;
    margin-top: 0.75rem;
    font-size: 0.875rem;
}

.cta-button {
    display: inline-block;
    background: var(--accent);
    color: #ffffff;
    text-decoration: none;
    padding: 0.625rem 1.25rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-top: 0.5rem;
    transition: background 0.2s;
}

.cta-button:hover {
    background: var(--accent-hover);
    color: #ffffff;
}

.cta-button.secondary {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    color: var(--text-primary);
    font-weight: 500;
}

.cta-button.secondary:hover {
    background: var(--bg-card);
}

.cta-note {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
}

.big-cta {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.18) 0%, rgba(6, 182, 212, 0.12) 100%);
    border: 1px solid var(--accent);
    border-radius: 8px;
    padding: 1.75rem;
    text-align: center;
    margin: 2.5rem 0 1rem;
}

.big-cta h2 {
    margin-top: 0;
}

.faq dt {
    color: var(--text-primary);
    font-weight: 600;
    margin-bottom: 0.375rem;
}

.faq dd {
    color: var(--text-secondary);
    margin: 0 0 1.25rem;
}

.fine-print {
    border-top: 1px solid var(--border);
    margin-top: 2.5rem;
    padding-top: 1rem;
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.related {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 0.75rem;
    margin-top: 1rem;
}

.crumb {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

@media (max-width: 640px) {
    .guide h1 {
        font-size: 1.75rem;
    }

    .guide h2 {
        font-size: 1.25rem;
    }
}
