/* ShardKeep — how-it-works.css */

.page-hero {
    padding-block: clamp(var(--sp-8), 9vw, var(--sp-9));
    text-align: center;
}
.page-hero h1 {
    font-size: clamp(2.5rem, 1.8rem + 4vw, 5rem);
    max-width: 18ch;
    margin-inline: auto;
    margin-bottom: var(--sp-5);
}
.page-hero .lead {
    margin-inline: auto;
    margin-bottom: var(--sp-6);
}

/* ── How-step (alternating sections) ── */
.how-step {
    padding-block: clamp(var(--sp-7), 8vw, var(--sp-9));
    position: relative;
}
.how-step:nth-child(even) {
    background: linear-gradient(180deg, transparent, rgba(244, 63, 94, 0.03), transparent);
}
.how-step__grid {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: clamp(var(--sp-6), 6vw, var(--sp-8));
    align-items: center;
}
.how-step--reverse .how-step__grid {
    grid-template-columns: 1fr 1.05fr;
}
.how-step--reverse .how-step__copy { order: 1; }
.how-step--reverse .how-step__visual { order: 2; }
@media (max-width: 880px) {
    .how-step__grid,
    .how-step--reverse .how-step__grid { grid-template-columns: 1fr; }
    .how-step__visual, .how-step--reverse .how-step__visual { order: -1; }
}

.how-step__copy h2 {
    margin-top: var(--sp-3);
    margin-bottom: var(--sp-4);
}
.how-step__copy .lead { margin-bottom: var(--sp-5); }
.how-step__copy ul {
    list-style: none;
    padding: 0;
    display: grid;
    gap: var(--sp-3);
}
.how-step__copy ul li {
    padding-left: 2rem;
    position: relative;
    color: var(--text-2);
    line-height: 1.6;
}
.how-step__copy ul li::before {
    content: '';
    position: absolute; left: 0; top: 0.7em;
    width: 20px; height: 2px;
    background: var(--grad-brand);
    border-radius: 2px;
}

/* ── Visuals container ── */
.how-step__visual {
    position: relative;
    aspect-ratio: 1 / 1;
    width: 100%;
    max-width: 520px;
    margin-inline: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--sp-5);
    background:
        radial-gradient(ellipse at 50% 50%, rgba(139,92,246,0.1), transparent 65%),
        rgba(10, 10, 26, 0.4);
    border: 1px solid var(--line);
    border-radius: var(--r-4);
    backdrop-filter: blur(8px);
    box-shadow: var(--shadow-2);
    overflow: hidden;
}
.how-step__visual svg { width: 100%; height: 100%; overflow: visible; }

/* ── SVG nodes (shared) ── */
.hiw-node {
    fill: rgba(20, 18, 44, 0.8);
    stroke: var(--violet);
    stroke-width: 1.5;
}
.hiw-node-label {
    fill: var(--text-2);
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 500;
    text-anchor: middle;
    dominant-baseline: middle;
}
.hiw-edge {
    fill: none;
    stroke: rgba(139, 92, 246, 0.5);
    stroke-width: 1.2;
    stroke-dasharray: 4 4;
}
.hiw-core {
    fill: rgba(244, 63, 94, 0.2);
    stroke: var(--rose);
    stroke-width: 1.5;
}
.hiw-glow-rose { filter: drop-shadow(0 0 8px rgba(244,63,94,0.6)); }
.hiw-glow-violet { filter: drop-shadow(0 0 8px rgba(139,92,246,0.5)); }
.hiw-glow-cyan { filter: drop-shadow(0 0 8px rgba(6,182,212,0.5)); }

/* Keyframes for line-drawing effect */
@keyframes dashDraw {
    from { stroke-dashoffset: 200; }
    to   { stroke-dashoffset: 0; }
}
.hiw-edge-animated {
    stroke-dasharray: 200;
    stroke-dashoffset: 200;
    animation: dashDraw 2.5s var(--ease-out) infinite;
}
@keyframes nodePulse {
    0%, 100% { opacity: 0.6; }
    50%      { opacity: 1; transform: scale(1.08); }
}
.hiw-pulse {
    transform-origin: center;
    transform-box: fill-box;
    animation: nodePulse 2.6s ease-in-out infinite;
}

/* ── Threat-model callout ── */
.threat-callout {
    margin-top: var(--sp-6);
    padding: var(--sp-5);
    background:
        linear-gradient(135deg, rgba(244, 63, 94, 0.08), rgba(139, 92, 246, 0.04));
    border-left: 3px solid var(--rose);
    border-radius: var(--r-2);
}
.threat-callout__label {
    font-size: var(--fs-xs);
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--rose-soft);
    font-weight: 700;
    margin-bottom: var(--sp-2);
    display: flex;
    align-items: center;
    gap: 0.4em;
}
.threat-callout__label svg { width: 14px; height: 14px; }
.threat-callout p { color: var(--text-2); font-size: var(--fs-sm); margin: 0; }

/* ── Step chip ── */
.step-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.7em;
    padding: 0.35em 0.9em 0.35em 0.4em;
    border-radius: var(--r-pill);
    background: rgba(244, 63, 94, 0.1);
    border: 1px solid rgba(244, 63, 94, 0.25);
    font-size: var(--fs-xs);
    font-family: var(--font-mono);
    letter-spacing: 0.08em;
    color: var(--rose-soft);
    margin-bottom: var(--sp-3);
}
.step-chip__num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px; height: 24px;
    border-radius: 50%;
    background: var(--grad-brand);
    color: white;
    font-weight: 700;
    font-family: var(--font-display);
    font-size: 0.78rem;
}
