Skip to content

Commit 454cbea

Browse files
author
molty3000
committed
Fix security card hover + install centering
1 parent c5333b2 commit 454cbea

1 file changed

Lines changed: 14 additions & 10 deletions

File tree

‎docs/index.html‎

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -70,12 +70,16 @@
7070
.perf-table .alloc { color: var(--green); }
7171

7272
/* Security card */
73+
.security-card { max-width: 720px; }
74+
.security-card.card:hover { transform: none; border-color: var(--border-card); }
7375
.security-row {
74-
display: flex; align-items: center; gap: 12px;
76+
display: grid; grid-template-columns: 56px 1fr 1fr; gap: 12px;
7577
padding: 12px 0; border-bottom: 1px solid var(--border-subtle);
76-
font-size: 14px;
78+
font-size: 14px; align-items: center;
7779
}
7880
.security-row:last-child { border-bottom: none; }
81+
.security-row .desc { color: var(--text-secondary); font-size: 13px; line-height: 1.5; }
82+
@media (max-width: 640px) { .security-row { grid-template-columns: 56px 1fr; } }
7983
.badge {
8084
display: inline-flex; align-items: center;
8185
font-family: var(--font-mono); font-size: 10px; font-weight: 600;
@@ -355,42 +359,42 @@ <h2>Zero-allocation distance<br>computation</h2>
355359
<h2>Minimal attack surface</h2>
356360
<p class="lead">Pure float32 math. No CGo, no syscalls, no I/O, no network. Every edge case returns zero/nil — the library never panics.</p>
357361

358-
<div class="card" style="max-width: 720px;">
362+
<div class="card security-card">
359363
<div class="security-row">
360364
<span class="badge g">SAFE</span>
361365
<span style="flex: 1;">Attack surface</span>
362-
<span style="color: var(--text-secondary);">Pure float32 operations — no injection, no deserialization, no file access</span>
366+
<span class="desc">Pure float32 operations — no injection, no deserialization, no file access</span>
363367
</div>
364368
<div class="security-row">
365369
<span class="badge g">SAFE</span>
366370
<span style="flex: 1;">Panic-free</span>
367-
<span style="color: var(--text-secondary);">All edge cases (mismatched lengths, zero vectors, empty stores) return zero/nil</span>
371+
<span class="desc">All edge cases (mismatched lengths, zero vectors, empty stores) return zero/nil</span>
368372
</div>
369373
<div class="security-row">
370374
<span class="badge g">SAFE</span>
371375
<span style="flex: 1;">Memory hygiene</span>
372-
<span style="color: var(--text-secondary);">Store outputs are always cloned. Internal state never leaks.</span>
376+
<span class="desc">Store outputs are always cloned. Internal state never leaks.</span>
373377
</div>
374378
<div class="security-row">
375379
<span class="badge y">AWARE</span>
376380
<span style="flex: 1;">Float32 overflow</span>
377-
<span style="color: var(--text-secondary);">Dot products of large vectors (>10⁵ dims with large magnitudes) can overflow. Normalize first.</span>
381+
<span class="desc">Dot products of large vectors (>10⁵ dims with large magnitudes) can overflow. Normalize first.</span>
378382
</div>
379383
<div class="security-row">
380384
<span class="badge y">AWARE</span>
381385
<span style="flex: 1;">Thread safety</span>
382-
<span style="color: var(--text-secondary);">Store is read-safe but not write-safe concurrently. Guard with <code>sync.Mutex</code>.</span>
386+
<span class="desc">Store is read-safe but not write-safe concurrently. Guard with <code>sync.Mutex</code>.</span>
383387
</div>
384388
</div>
385389
</div>
386390
</section>
387391

388392
<!-- Install -->
389393
<section class="section" id="install" style="padding-top: 0;">
390-
<div class="container">
394+
<div class="container" style="text-align: center;">
391395
<div class="section-label">Get Started</div>
392396
<h2>Install</h2>
393-
<p class="lead">One import. Zero dependencies.</p>
397+
<p class="lead" style="margin: 16px auto 0;">One import. Zero dependencies.</p>
394398

395399
<div class="install-box">
396400
<span class="prompt">$</span>

0 commit comments

Comments
 (0)