/* OTFeed — Design System */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --bg: #0f0f1a;
    --bg-elevated: #1a1a2e;
    --bg-card: #16213e;
    --primary: #0f3460;
    --accent: #e94560;
    --text: #f1f5f9;
    --text-muted: #94a3b8;
    --border: #1e293b;
    --critical: #dc2626;
    --high: #f59e0b;
    --medium: #3b82f6;
    --low: #64748b;
    --success: #22c55e;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

/* Header */
.header {
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
}

.logo span { color: var(--accent); }

.nav-links { display: flex; gap: 1.5rem; }
.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    padding: 0.5rem 0;
    transition: all 0.2s;
    cursor: pointer;
    position: relative;
}
.nav-links a:hover { color: var(--text); }
.nav-links a.active {
    color: var(--accent);
    font-weight: 600;
}
.nav-links a.active:after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--accent);
    border-radius: 3px;
}

/* Pages */
.page { display: none; min-height: 80vh; }
.page.active { display: block; }

/* Hero */
.hero {
    text-align: center;
    padding: 3rem 2rem 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.hero-visual {
    margin-bottom: 2.5rem;
}

.hero-image {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    display: block;
    margin: 0 auto;
}

.hero-placeholder {
    width: 100%;
    max-width: 700px;
    aspect-ratio: 16/9;
    margin: 0 auto 2rem;
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-elevated) 100%);
    border-radius: 12px;
    border: 1px solid var(--border);
    overflow: hidden;
    position: relative;
}

/* Abstract magnifying glass visualization */
.hero-placeholder::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 200px;
    height: 200px;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    border: 3px solid var(--accent);
    background: radial-gradient(circle, rgba(233, 69, 96, 0.1) 0%, transparent 70%);
    box-shadow: 0 0 60px rgba(233, 69, 96, 0.15);
}

.hero-placeholder::after {
    content: '';
    position: absolute;
    bottom: 25%;
    right: 30%;
    width: 60px;
    height: 8px;
    background: var(--accent);
    border-radius: 4px;
    transform: rotate(-45deg);
}

.hero h1 {
    font-size: 2.75rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.15;
}

.hero h1 span { color: var(--accent); }

.hero p {
    font-size: 1.3rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.hero-sub {
    font-size: 0.9rem !important;
    margin-top: 1rem !important;
    margin-bottom: 0 !important;
}

.cta-btn {
    display: inline-block;
    background: var(--accent);
    color: white;
    padding: 0.875rem 2rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: background 0.2s, transform 0.2s;
    border: none;
    cursor: pointer;
}

.cta-btn:hover {
    background: #d13a52;
    transform: translateY(-1px);
}

.cta-btn:disabled {
    background: #555;
    cursor: not-allowed;
    transform: none;
}

.cta-btn.full-width {
    width: 100%;
    text-align: center;
}

/* Value Props */
.value-props {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    padding: 2rem;
    max-width: 1100px;
    margin: 0 auto 4rem;
}

.value-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 2rem 1.5rem;
    text-align: center;
}

.value-card h3 {
    font-size: 1.25rem;
    margin: 0.75rem 0 0.5rem;
    color: var(--accent);
}

.value-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.value-card .step-num {
    display: inline-block;
    width: 36px;
    height: 36px;
    background: var(--accent);
    color: white;
    border-radius: 50%;
    line-height: 36px;
    font-weight: 700;
}

/* Registration Form */
.form-container {
    max-width: 480px;
    margin: 3rem auto;
    padding: 2.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
}

.form-container h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.form-container > p {
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.form-group {
    margin-bottom: 1.25rem;
}

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

.form-group input[type="text"],
.form-group input[type="email"],
.form-group select {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text);
    font-size: 1rem;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent);
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.checkbox-group label {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.checkbox-group a {
    color: var(--accent);
}

.status-msg {
    margin-top: 1rem;
    font-size: 0.9rem;
    text-align: center;
}

/* Asset Selection */
.select-header {
    text-align: center;
    padding: 2rem;
}

.select-header h2 { margin-bottom: 0.5rem; }
.select-header p { color: var(--text-muted); }

.search-bar {
    max-width: 600px;
    margin: 1rem auto;
    padding: 0 2rem;
}

.search-bar input {
    width: 100%;
    padding: 0.875rem 1rem 0.875rem 2.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text);
    font-size: 1rem;
}

.search-bar input:focus {
    outline: none;
    border-color: var(--accent);
}

/* Asset Selection Panels (3-Level) */
.asset-select-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
}

.asset-panel {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
}

.panel-title {
    padding: 1rem 1.25rem;
    margin: 0;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
    font-size: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.panel-count {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 400;
}

.panel-list {
    max-height: 400px;
    overflow-y: auto;
}

.asset-item {
    display: flex;
    align-items: center;
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: background 0.15s;
    gap: 0.75rem;
}

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

.asset-item:hover {
    background: var(--bg-elevated);
}

.asset-item.selected {
    background: rgba(34, 197, 94, 0.1);
}

.item-checkbox {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border);
    border-radius: 4px;
    flex-shrink: 0;
    transition: all 0.15s;
}

.item-checkbox.checked {
    background: var(--success);
    border-color: var(--success);
    position: relative;
}

.item-checkbox.checked::after {
    content: '✓';
    color: white;
    font-size: 12px;
    font-weight: bold;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.item-name {
    flex: 1;
    font-size: 0.9rem;
}

.item-type,
.item-sector {
    font-size: 0.75rem;
    padding: 0.15rem 0.5rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 4px;
    color: var(--text-muted);
    text-transform: capitalize;
}

.item-count {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.select-all-item {
    background: rgba(15, 52, 96, 0.3);
    border-bottom: 2px solid var(--border);
}

.select-all-item:hover {
    background: rgba(15, 52, 96, 0.5);
}

/* Selected Summary */
.selected-summary {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 2rem;
}

.selected-summary h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: var(--text-muted);
}

.summary-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.summary-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 0.85rem;
}

.summary-detail {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.remove-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0 0.25rem;
    font-size: 0.9rem;
}

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

.empty-summary {
    color: var(--text-muted);
    font-size: 0.85rem;
    padding: 1rem 0;
}

/* Feed */
.feed-header {
    padding: 1.25rem 2rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    background: var(--bg-elevated);
}

.feed-title { font-size: 1.25rem; margin-bottom: 0.25rem; }
.feed-subtitle { color: var(--text-muted); font-size: 0.85rem; }

.feed-actions { display: flex; gap: 0.75rem; }
.feed-actions a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: 4px;
    transition: border-color 0.2s;
}
.feed-actions a:hover { border-color: var(--accent); }

.feed-list {
    max-width: 900px;
    margin: 0 auto;
    padding: 1.5rem 1rem;
}

.empty-feed {
    text-align: center;
    color: var(--text-muted);
    padding: 3rem 1rem;
}

.feed-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 1.25rem;
    margin-bottom: 1rem;
    cursor: pointer;
    transition: border-color 0.2s;
}

.feed-item:hover { border-color: var(--primary); }

.feed-item-header {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.severity-badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    flex-shrink: 0;
    margin-top: 0.15rem;
}

.severity-critical { background: var(--critical); color: white; }
.severity-high { background: var(--high); color: black; }
.severity-medium { background: var(--medium); color: white; }
.severity-low { background: var(--low); color: white; }

.feed-item h3 { font-size: 1rem; margin: 0; line-height: 1.3; }

.feed-item-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.4rem;
}

.feed-item-preview {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-top: 0.6rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.matched-assets {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
    margin-top: 0.6rem;
}

.matched-asset {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 4px;
    color: var(--success);
}

.article-body {
    border-top: 1px solid var(--border);
    padding-top: 1rem;
    margin-top: 1rem;
}

.article-body p {
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.article-body strong {
    color: var(--accent);
}

/* Footer */
.footer {
    text-align: center;
    padding: 3rem 2rem;
    color: var(--text-muted);
    font-size: 0.85rem;
    border-top: 1px solid var(--border);
}

.footer a {
    color: var(--text-muted);
}

/* ─── Custom Asset Entry ───────────────────────────────────── */
.custom-asset-section {
    margin-top: 1.5rem;
    padding: 1.25rem;
    background: var(--bg-card);
    border-radius: 8px;
    border: 1px solid var(--border);
}
.custom-title {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    font-weight: 500;
}
.custom-form {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.custom-input {
    flex: 1;
    min-width: 180px;
    padding: 0.5rem 0.75rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text);
    font-size: 0.85rem;
}
.custom-input:focus {
    outline: none;
    border-color: var(--accent);
}
.custom-form .cta-btn {
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
}
.custom-status {
    width: 100%;
    font-size: 0.8rem;
    margin-top: 0.5rem;
}
.custom-status.success { color: var(--success); }
.custom-status.error { color: var(--accent); }

.footer a:hover {
    color: var(--accent);
}

/* Mobile */
@media (max-width: 768px) {
    .hero h1 { font-size: 1.75rem; }
    .hero { padding: 3rem 1.5rem 2rem; }
    .value-props { grid-template-columns: 1fr; padding: 1rem; }
    .vendor-grid { grid-template-columns: 1fr; padding: 1rem; }
    .feed-header { flex-direction: column; gap: 1rem; align-items: flex-start; }
    .form-container { margin: 1.5rem; padding: 1.5rem; }
    .selected-bar { flex-direction: column; gap: 0.75rem; text-align: center; }
}
