@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

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

body {
    font-family: 'Inter', sans-serif;
    background: #0f0f13;
    color: #e4e4e7;
}

textarea:focus, input:focus { outline: none; }

.site-header {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border-bottom: 1px solid rgba(255,255,255,0.06);
    padding: 1rem 0;
}

.site-header .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: #fff;
    font-weight: 800;
    font-size: 1.25rem;
}

.logo-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #06b6d4, #3b82f6);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    color: #fff;
}

nav a {
    color: #a1a1aa;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: color 0.2s;
    margin-left: 1.5rem;
}
nav a:hover { color: #fff; }

.hero {
    text-align: center;
    padding: 3rem 1.5rem 1rem;
}

.hero h1 {
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #22d3ee, #3b82f6, #6366f1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.75rem;
}

.hero p {
    color: #a1a1aa;
    font-size: 1.1rem;
    max-width: 500px;
    margin: 0 auto;
}

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

.card {
    background: #1a1a2e;
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.input-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.input-col label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.input-col label span {
    font-weight: 600;
    color: #e4e4e7;
}

.btn-paste-sm {
    background: none;
    border: none;
    color: #6366f1;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
}
.btn-paste-sm:hover { color: #818cf8; }

textarea {
    width: 100%;
    background: #0f0f13;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 0.75rem;
    padding: 1rem;
    color: #e4e4e7;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    line-height: 1.6;
    resize: vertical;
    transition: border-color 0.2s;
}

textarea:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.15);
}

textarea::placeholder { color: #52525b; }

.controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.25rem;
    align-items: center;
}

.btn-primary {
    background: linear-gradient(135deg, #3b82f6, #6366f1);
    color: #fff;
    border: none;
    padding: 0.75rem 1.75rem;
    border-radius: 0.75rem;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
    font-family: 'Inter', sans-serif;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(59,130,246,0.4);
}

.btn-secondary {
    background: rgba(255,255,255,0.06);
    color: #a1a1aa;
    border: 1px solid rgba(255,255,255,0.08);
    padding: 0.75rem 1.25rem;
    border-radius: 0.75rem;
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    font-family: 'Inter', sans-serif;
}
.btn-secondary:hover { background: rgba(255,255,255,0.1); color: #e4e4e7; }

.check-label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    color: #71717a;
    cursor: pointer;
}

.check-label input {
    accent-color: #6366f1;
}

.spacer { flex: 1; }

.stats-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1.25rem 0;
}

.stat-pill {
    padding: 0.4rem 1rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
}

.stat-added { background: rgba(34,197,94,0.12); color: #4ade80; border: 1px solid rgba(34,197,94,0.2); }
.stat-removed { background: rgba(239,68,68,0.12); color: #f87171; border: 1px solid rgba(239,68,68,0.2); }
.stat-unchanged { background: rgba(255,255,255,0.04); color: #a1a1aa; border: 1px solid rgba(255,255,255,0.08); }

.diff-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.diff-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #e4e4e7;
}

.view-btns { display: flex; gap: 0.35rem; }

.view-btn {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.08);
    color: #71717a;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.35rem 0.85rem;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.view-btn.active {
    background: rgba(59,130,246,0.15);
    border-color: rgba(59,130,246,0.3);
    color: #60a5fa;
}

.diff-panel {
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 0.75rem;
    overflow: hidden;
}

.diff-side {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.diff-col {
    overflow-x: auto;
    max-height: 600px;
    overflow-y: auto;
}

.diff-col-left {
    border-right: 1px solid rgba(255,255,255,0.06);
}

.diff-line {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    line-height: 1.7;
    padding: 1px 10px;
    white-space: pre-wrap;
    word-break: break-all;
}

.diff-line-num {
    display: inline-block;
    width: 35px;
    text-align: right;
    color: #52525b;
    margin-right: 10px;
    user-select: none;
    font-size: 0.7rem;
}

.diff-added { background: rgba(34,197,94,0.08); }
.diff-removed { background: rgba(239,68,68,0.08); }
.diff-empty { background: rgba(255,255,255,0.02); }
.diff-word-added { background: rgba(34,197,94,0.3); border-radius: 3px; padding: 0 2px; }
.diff-word-removed { background: rgba(239,68,68,0.3); border-radius: 3px; padding: 0 2px; }

.ad-slot {
    min-height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.02);
    border: 1px dashed rgba(255,255,255,0.08);
    border-radius: 0.75rem;
    color: #3f3f46;
    font-size: 0.75rem;
    margin: 1.5rem 0;
}
.ad-slot:empty::after { content: "Ad Space"; }

.content-section { margin-top: 2rem; }
.content-section h2 { font-size: 1.5rem; font-weight: 800; color: #e4e4e7; margin-bottom: 1rem; }
.content-section h3 { font-size: 1.1rem; font-weight: 700; color: #c4c4cc; margin-top: 1.5rem; margin-bottom: 0.5rem; }
.content-section p, .content-section li { color: #a1a1aa; line-height: 1.7; margin-bottom: 0.5rem; }
.content-section ul { padding-left: 1.5rem; }
.content-section details { margin-bottom: 0.5rem; }
.content-section summary { cursor: pointer; font-weight: 600; color: #c4c4cc; padding: 0.5rem 0; }
.content-section details p { margin-left: 1rem; margin-top: 0.25rem; }

.site-footer {
    border-top: 1px solid rgba(255,255,255,0.06);
    padding: 2rem 0;
    margin-top: 3rem;
}

.site-footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.site-footer p { color: #52525b; font-size: 0.8rem; }
.site-footer nav a { color: #52525b; font-size: 0.8rem; margin-left: 1.25rem; }
.site-footer nav a:hover { color: #a1a1aa; }

.hidden { display: none !important; }

@media (max-width: 768px) {
    .hero h1 { font-size: 1.75rem; }
    .card { padding: 1.25rem; }
    .input-grid { grid-template-columns: 1fr; }
    .diff-side { grid-template-columns: 1fr; }
    .diff-col-left { border-right: none; border-bottom: 1px solid rgba(255,255,255,0.06); }
    nav { display: none; }
    .site-footer .container { flex-direction: column; text-align: center; }
    .site-footer nav a { margin-left: 0; margin-right: 1rem; }
}
