/* Krypton Wolf — terminal-inspired, zero external dependencies
 * No Google Fonts. No CDN. No tracking. Just CSS.
 * System fonts only: monospace for headings, sans-serif for body.
 */

:root {
    --bg: #0a0a0a;
    --bg-alt: #141414;
    --bg-hover: #1a1a1a;
    --text: #d0d0d0;
    --text-dim: #888888;
    --text-bright: #e0e0e0;
    --accent: #00ff41;
    --accent-dim: #008f24;
    --accent-bg: rgba(0, 255, 65, 0.08);
    --border: #2a2a2a;
    --border-bright: #3a3a3a;
    --link: #00ff41;
    --link-hover: #00cc33;
    --max-width: 800px;
    --mono: "DejaVu Sans Mono", "Liberation Mono", "Menlo", "Consolas", "Courier New", monospace;
    --sans: "DejaVu Sans", "Liberation Sans", "Helvetica", "Arial", sans-serif;
    --glow: 0 0 4px rgba(0, 255, 65, 0.5);
    --glow-strong: 0 0 8px rgba(0, 255, 65, 0.6), 0 0 16px rgba(0, 255, 65, 0.2);
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--sans);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Header / Nav */
header {
    border-bottom: 1px solid var(--border);
    background: var(--bg);
    position: sticky;
    top: 0;
    z-index: 100;
    animation: fadeInDown 0.4s ease-out;
}

nav {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--mono);
    font-weight: bold;
    color: var(--accent);
    text-decoration: none;
    font-size: 1.1rem;
    border-bottom: none;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    text-shadow: var(--glow);
}

.nav-logo {
    display: inline-block;
    width: 20px;
    height: 20px;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.logo:hover .nav-logo {
    opacity: 1;
}

.logo-bracket {
    color: var(--text-dim);
}

.logo-dim {
    color: var(--text-dim);
}

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

.nav-links a {
    font-family: var(--mono);
    color: var(--accent);
    text-decoration: none;
    font-size: 0.9rem;
    border-bottom: none;
    transition: all 0.2s;
    opacity: 0.6;
}

.nav-links a:hover {
    color: var(--accent);
    opacity: 1;
    border-bottom: 1px solid var(--accent);
    text-shadow: var(--glow);
}

/* Mobile nav toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.nav-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--accent);
    transition: 0.2s;
}

.nav-toggle.open span:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}
.nav-toggle.open span:nth-child(2) {
    opacity: 0;
}
.nav-toggle.open span:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
}

/* Main content */
main {
    flex: 1;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 2rem 1rem;
    width: 100%;
    animation: fadeIn 0.4s ease-out 0.15s both;
}

/* Hero */
.hero {
    text-align: center;
    padding: 2rem 0;
    animation: fadeInUp 0.5s ease-out 0.1s both;
}

.hero-prompt {
    font-family: var(--mono);
    color: var(--text-dim);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    text-align: left;
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent);
    padding: 0.75rem 1rem;
    border-radius: 0;
    overflow-x: auto;
}

.prompt-user {
    color: var(--accent);
    text-shadow: var(--glow);
}

.prompt-path {
    color: var(--text-dim);
}

.prompt-cursor {
    color: var(--text);
}

/* Blinking terminal cursor */
.cursor {
    display: inline-block;
    width: 0.6em;
    height: 1.1em;
    background: var(--accent);
    box-shadow: var(--glow);
    vertical-align: text-bottom;
    margin-left: 2px;
    animation: blink 1s steps(1) infinite;
}

.hero h1 {
    font-family: var(--mono);
    color: var(--accent);
    font-size: 2rem;
    margin-bottom: 1rem;
    font-weight: normal;
    text-shadow: var(--glow-strong);
}

.tagline {
    color: var(--text-bright);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto 2rem;
    line-height: 1.7;
}

.cta {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 0.5s ease-out 0.3s both;
}

.btn {
    font-family: var(--mono);
    background: var(--accent);
    color: var(--bg);
    padding: 0.6rem 1.5rem;
    text-decoration: none;
    border: 1px solid var(--accent);
    font-size: 0.9rem;
    transition: all 0.2s;
    border-bottom: 1px solid var(--accent);
    box-shadow: 0 0 6px rgba(0, 255, 65, 0.3);
}

.btn:hover {
    background: transparent;
    color: var(--accent);
    box-shadow: 0 0 12px rgba(0, 255, 65, 0.5), 0 0 24px rgba(0, 255, 65, 0.15);
    text-shadow: var(--glow);
}

.btn-outline {
    background: transparent;
    color: var(--accent);
}

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

/* Sections */
section {
    margin-bottom: 3rem;
}

/* Alternate section backgrounds for visual rhythm */
.values {
    padding: 1.5rem;
    background: var(--bg);
}

.proof {
    padding: 1.5rem;
}

.who-for {
    padding: 1.5rem;
    background: var(--bg-alt);
    border: 1px solid var(--border);
}

.stack {
    padding: 1.5rem;
}

h2 {
    font-family: var(--mono);
    color: var(--accent);
    font-size: 1.3rem;
    margin-bottom: 1rem;
    font-weight: normal;
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.5rem;
    text-shadow: var(--glow);
}

h3 {
    font-family: var(--mono);
    color: var(--accent);
    font-size: 1rem;
    margin-bottom: 0.5rem;
    font-weight: normal;
    text-shadow: var(--glow);
}

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

a {
    color: var(--link);
    text-decoration: none;
    border-bottom: 1px dotted var(--accent-dim);
}

a:hover {
    color: var(--link-hover);
    border-bottom: 1px solid var(--accent);
}

/* Values grid */
.value-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.value {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.value:hover {
    border-color: var(--accent-dim);
    box-shadow: 0 0 12px rgba(0, 255, 65, 0.1);
}

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

/* Proof section */
.proof {
    background: var(--bg-alt);
    border-left: 3px solid var(--accent);
    padding: 1.5rem;
    margin-bottom: 3rem;
}

/* Stack section — slightly different bg to break visual monotony */
.stack {
    background: var(--bg-alt);
    padding: 1.5rem;
    border: 1px solid var(--border);
}

/* Who-for list */
.who-for ul {
    list-style: none;
    padding-left: 0;
}

.who-for li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text);
}

.who-for li::before {
    content: "$";
    color: var(--accent);
    position: absolute;
    left: 0;
    font-family: var(--mono);
}

/* Stack grid */
.stack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.stack-item {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    padding: 1.5rem;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.stack-item:hover {
    border-color: var(--accent-dim);
    box-shadow: 0 0 12px rgba(0, 255, 65, 0.1);
}

.stack-item p {
    color: var(--text);
    font-size: 0.95rem;
}

/* Page template (services, about, contact) */
.page-prompt {
    font-family: var(--mono);
    color: var(--text-dim);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    text-align: left;
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent);
    padding: 0.75rem 1rem;
    border-radius: 0;
    overflow-x: auto;
    animation: fadeInUp 0.4s ease-out 0.1s both;
}

.page-prompt .prompt-user {
    color: var(--accent);
    text-shadow: var(--glow);
}

.page h1 {
    font-family: var(--mono);
    color: var(--accent);
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    font-weight: normal;
}

.lead {
    font-size: 1.1rem;
    color: var(--text-bright);
    margin-bottom: 2rem;
    line-height: 1.7;
}

/* Service list */
.service-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.service {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.service:hover {
    border-color: var(--accent-dim);
    box-shadow: 0 0 12px rgba(0, 255, 65, 0.1);
}

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

/* Principles */
.principles {
    margin-top: 2rem;
}

.principles ul {
    list-style: none;
    padding-left: 0;
}

.principles li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text);
}

.principles li::before {
    content: ">";
    color: var(--accent);
    position: absolute;
    left: 0;
    font-family: var(--mono);
}

/* About page */
.people {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.person {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    padding: 1.5rem;
}

.person .role {
    font-family: var(--mono);
    color: var(--text-dim);
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
}

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

.values-list {
    list-style: none;
    padding-left: 0;
}

.values-list li {
    padding: 0.4rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text);
}

.values-list li::before {
    content: "##";
    color: var(--accent);
    position: absolute;
    left: 0;
    font-family: var(--mono);
}

/* Contact */
.contact-methods {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.contact-method {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    padding: 1.5rem;
}

.contact-method .hint {
    font-family: var(--mono);
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-top: 0.5rem;
}

.contact-note {
    background: var(--bg-alt);
    border-left: 3px solid var(--accent);
    padding: 1.5rem;
}

/* Footer */
footer {
    border-top: 1px solid var(--border);
    padding: 2rem 1rem;
    text-align: center;
    animation: fadeIn 0.5s ease-out 0.3s both;
}

.footer-content {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.footer-logo {
    width: 32px;
    height: 32px;
    opacity: 0.6;
    transition: opacity 0.2s;
}

.footer-logo:hover {
    opacity: 1;
}

footer p {
    font-family: var(--mono);
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-bottom: 0.5rem;
}

footer a {
    color: var(--text-dim);
    border-bottom: 1px dotted var(--accent-dim);
}

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

.footer-tag {
    color: var(--text) !important;
}

.footer-meta {
    font-size: 0.7rem !important;
    color: var(--text-dim) !important;
    opacity: 0.6;
}

/* Responsive */
@media (max-width: 600px) {
    .hero h1 {
        font-size: 1.5rem;
    }

    .tagline {
        font-size: 1rem;
    }

    nav {
        flex-direction: row;
        gap: 0.5rem;
        padding: 0.75rem 1rem;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        padding: 1rem;
        gap: 1rem;
    }

    .nav-links.open {
        display: flex;
    }

    .value-grid,
    .service-list,
    .people,
    .contact-methods,
    .stack-grid {
        grid-template-columns: 1fr;
    }

    .hero-prompt {
        font-size: 0.75rem;
    }
}

/* Article (blog) styles */
.article {
    max-width: 760px;
    margin: 0 auto;
}

.article-header {
    margin-bottom: 2rem;
}

.article-prompt {
    font-family: var(--mono);
    color: var(--text-dim);
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
    text-align: left;
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent);
    padding: 0.75rem 1rem;
    overflow-x: auto;
}

.article h1 {
    font-family: var(--mono);
    color: var(--accent);
    font-size: 1.6rem;
    margin-bottom: 0.5rem;
    font-weight: normal;
    line-height: 1.3;
}

.article-date {
    font-family: var(--mono);
    color: var(--text-dim);
    font-size: 0.85rem;
}

.article-body {
    color: var(--text);
    line-height: 1.7;
}

.article-body h2 {
    font-family: var(--mono);
    color: var(--accent);
    font-size: 1.2rem;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    font-weight: normal;
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.4rem;
}

.article-body h3 {
    font-family: var(--mono);
    color: var(--accent);
    font-size: 1rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    font-weight: normal;
}

.article-body p {
    margin-bottom: 1.25rem;
    font-size: 0.95rem;
    line-height: 1.7;
}

.article-body ul,
.article-body ol {
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
}

.article-body li {
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    line-height: 1.6;
}

.article-body blockquote {
    border-left: 3px solid var(--accent-dim);
    padding: 0.5rem 1.25rem;
    margin: 1.5rem 0;
    background: var(--bg-alt);
    color: var(--text-bright);
    font-size: 0.95rem;
}

.article-body code {
    font-family: var(--mono);
    background: var(--bg-alt);
    color: var(--accent);
    padding: 0.1rem 0.35rem;
    font-size: 0.88em;
}

.article-body pre {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent);
    padding: 1rem;
    overflow-x: auto;
    margin: 1.5rem 0;
}

.article-body pre code {
    background: none;
    color: var(--text);
    padding: 0;
    font-size: 0.88rem;
}

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

.article-body a {
    color: var(--link);
    border-bottom: 1px dotted var(--accent-dim);
}

.article-body a:hover {
    color: var(--link-hover);
    border-bottom: 1px solid var(--accent);
}

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

.article-footer a {
    font-family: var(--mono);
    color: var(--accent);
    text-decoration: none;
    font-size: 0.9rem;
    border-bottom: none;
}

.article-footer a:hover {
    border-bottom: 1px solid var(--accent);
}

/* Article list (writing page) */
.article-list {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-top: 2rem;
}

.article-entry {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent-dim);
    padding: 1.25rem 1.5rem;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.article-entry:hover {
    border-left-color: var(--accent);
    box-shadow: 0 0 12px rgba(0, 255, 65, 0.08);
}

.article-entry a {
    text-decoration: none;
    border-bottom: none;
}

.article-entry h2 {
    font-family: var(--mono);
    color: var(--accent);
    font-size: 1.15rem;
    margin-bottom: 0.4rem;
    font-weight: normal;
    border-bottom: none;
    padding-bottom: 0;
}

.article-entry p {
    color: var(--text);
    font-size: 0.9rem;
    margin-bottom: 0;
    line-height: 1.5;
}

.article-entry-date {
    font-family: var(--mono);
    color: var(--text-dim);
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
    display: block;
}

.article-entry:hover h2 {
    color: var(--link-hover);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    * {
        transition: none !important;
        animation: none !important;
    }
}

/* Keyframe animations */
@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Toys page */
.toy-card {
    display: flex;
    gap: 1.5rem;
    padding: 1.5rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 1.5rem;
    background: var(--bg-card, rgba(255,255,255,0.02));
}

.toy-card:hover {
    border-color: var(--link, #6c9);
    box-shadow: 0 0 12px rgba(0, 255, 65, 0.1);
}

.toy-icon {
    font-size: 2.5rem;
    line-height: 1;
    flex-shrink: 0;
    width: 60px;
    text-align: center;
    color: var(--accent, #6c9);
}

.toy-content h2 {
    margin-bottom: 0.5rem;
}

.toy-content h2 a {
    color: var(--text);
    text-decoration: none;
}

.toy-content h2 a:hover {
    color: var(--link-hover, #9cf);
}

.toy-details {
    list-style: none;
    padding-left: 0;
    margin: 0.75rem 0;
}

.toy-details li {
    color: var(--text-dim, #999);
    font-size: 0.85rem;
    padding-left: 1rem;
    position: relative;
    margin-bottom: 0.25rem;
}

.toy-details li::before {
    content: "›";
    position: absolute;
    left: 0;
    color: var(--accent, #6c9);
}

.toy-links {
    margin-top: 1rem;
    display: flex;
    gap: 1.5rem;
}

.toy-play {
    font-family: var(--mono, monospace);
    font-size: 0.9rem;
    color: var(--link, #6c9);
    text-decoration: none;
    border-bottom: 1px solid transparent;
}

.toy-play:hover {
    border-bottom-color: var(--link, #6c9);
}

.toy-source {
    font-family: var(--mono, monospace);
    font-size: 0.8rem;
    color: var(--text-dim, #999);
    text-decoration: none;
}

.toy-source:hover {
    color: var(--link, #6c9);
}

.toy-coming-soon {
    opacity: 0.5;
    border-style: dashed;
}