/*! HTML5 Boilerplate v9.0.1 | MIT License | https://html5boilerplate.com/ */

/* main.css 3.0.0 | MIT License | https://github.com/h5bp/main.css#readme */
/*
 * What follows is the result of much research on cross-browser styling.
 * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
 * Kroc Camen, and the H5BP dev community and team.
 */

/* ==========================================================================
   Base styles: opinionated defaults
   ========================================================================== */

html {
    color: #222;
    font-size: 1em;
    line-height: 1.4;
}

/*
 * Remove text-shadow in selection highlight:
 * https://twitter.com/miketaylr/status/12228805301
 *
 * Customize the background color to match your design.
 */

::-moz-selection {
    background: #b3d4fc;
    text-shadow: none;
}

::selection {
    background: #b3d4fc;
    text-shadow: none;
}

/*
 * A better looking default horizontal rule
 */

hr {
    display: block;
    height: 1px;
    border: 0;
    border-top: 1px solid #ccc;
    margin: 1em 0;
    padding: 0;
}

/*
 * Remove the gap between audio, canvas, iframes,
 * images, videos and the bottom of their containers:
 * https://github.com/h5bp/html5-boilerplate/issues/440
 */

audio,
canvas,
iframe,
img,
svg,
video {
    vertical-align: middle;
}

/*
 * Remove default fieldset styles.
 */

fieldset {
    border: 0;
    margin: 0;
    padding: 0;
}

/*
 * Allow only vertical resizing of textareas.
 */

textarea {
    resize: vertical;
}

/* ==========================================================================
   Author's custom styles
   ========================================================================== */

:root {
    color-scheme: dark;

    --bg: #0b1020;
    --surface: rgba(255, 255, 255, 0.06);
    --surface-strong: rgba(255, 255, 255, 0.1);
    --border: rgba(255, 255, 255, 0.12);
    --text: rgba(255, 255, 255, 0.92);
    --muted: rgba(255, 255, 255, 0.7);
    --brand: #7c5cff;
    --brand-2: #29d3c1;

    --shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
    --radius: 14px;

    --page-bg: radial-gradient(1200px 800px at 20% 10%, rgba(124, 92, 255, 0.25), transparent 55%),
    radial-gradient(900px 700px at 90% 20%, rgba(41, 211, 193, 0.18), transparent 55%),
    linear-gradient(180deg, #070a14 0%, var(--bg) 65%, #070a14 100%);
}

html {
    background: #070a14;
}

html,
body {
    height: 100%;
}

body {
    margin: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji",
    "Segoe UI Emoji";
    color: var(--text);
    position: relative;
    z-index: 0;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    background: var(--page-bg);
    background-repeat: no-repeat;
    z-index: -1;
    pointer-events: none;
}

h1,
h2,
h3,
p {
    margin: 0;
}

*:focus-visible {
    outline: 2px solid rgba(124, 92, 255, 0.9);
    outline-offset: 2px;
}

html {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

a {
    color: inherit;
    text-decoration-color: rgba(124, 92, 255, 0.7);
    text-underline-offset: 3px;
}

a:hover {
    text-decoration-color: rgba(41, 211, 193, 0.85);
}

.container {
    width: min(1100px, calc(100% - 48px));
    margin: 0 auto;
}

.skip-link {
    position: absolute;
    left: 12px;
    top: 12px;
    z-index: 999;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: var(--shadow);
    transform: translateY(-150%);
}

.skip-link:focus {
    transform: translateY(0);
    outline: 2px solid rgba(124, 92, 255, 0.9);
    outline-offset: 2px;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(10px);
    background: rgba(7, 10, 20, 0.62);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 14px 0;
}

.brand {
    font-weight: 650;
    letter-spacing: 0.2px;
    text-decoration: none;
}

.nav {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.nav a {
    text-decoration: none;
    color: var(--muted);
    padding: 8px 10px;
    border-radius: 10px;
}

.nav a:hover,
.nav a:focus-visible {
    color: var(--text);
    background: rgba(255, 255, 255, 0.06);
}

.hero {
    padding: 70px 0 34px;
}

.hero-inner {
    padding: 34px;
    border-radius: calc(var(--radius) + 6px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04));
    box-shadow: var(--shadow);
}

.eyebrow {
    margin: 0 0 10px;
    color: var(--muted);
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.16em;
}

.hero-title {
    margin: 0 0 14px;
    font-size: clamp(2rem, 4.2vw, 3.2rem);
    line-height: 1.05;
}

.lead {
    margin: 0;
    max-width: 68ch;
    color: var(--muted);
    font-size: 1.08rem;
}

.cta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 22px;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.06);
    text-decoration: none;
    color: var(--text);
}

.button.primary {
    border-color: rgba(124, 92, 255, 0.5);
    background: linear-gradient(135deg, rgba(124, 92, 255, 0.9), rgba(41, 211, 193, 0.55));
}

.button:hover,
.button:focus-visible {
    border-color: rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.1);
}

.button.primary:hover,
.button.primary:focus-visible {
    border-color: rgba(41, 211, 193, 0.75);
}

.section {
    padding: 44px 0;
}

.section-head {
    display: grid;
    gap: 10px;
    margin-bottom: 18px;
}

.section h2 {
    margin: 0;
    font-size: 1.6rem;
}

.muted {
    color: var(--muted);
}

.grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 16px;
}

.card {
    grid-column: span 12;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius);
    padding: 18px;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

.card h3 {
    margin: 0 0 8px;
    font-size: 1.05rem;
}

.card p {
    margin: 0;
    color: var(--muted);
}

.projects-grid .project {
    display: grid;
    gap: 12px;
}

.project-top {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
}

.card-actions {
    display: flex;
    gap: 10px;
}

.link {
    color: var(--text);
    text-decoration: none;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.04);
}

.link:hover,
.link:focus-visible {
    border-color: rgba(41, 211, 193, 0.6);
}

.tag-list {
    list-style: none;
    padding: 0;
    margin: 10px 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.04);
    border-radius: 999px;
    padding: 6px 10px;
    color: var(--muted);
    font-size: 0.92rem;
}

.mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.95em;
}

.contact-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 12px;
}

.contact-list li {
    display: grid;
    grid-template-columns: 110px 1fr;
    gap: 12px;
    align-items: baseline;
}

.contact-item-pgp {
    align-items: start;
}

.contact-label {
    color: rgba(255, 255, 255, 0.86);
    font-weight: 600;
}

.pgp-box {
    width: 100%;
    box-sizing: border-box;
    padding: 12px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    line-height: 1.35;
    min-height: 150px;
    max-height: 240px;
    overflow: auto;
}

.site-footer {
    padding: 26px 0 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    margin-top: 24px;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
}

@media only screen and (min-width: 48em) {
    .card {
        padding: 20px;
    }

    .grid > .card {
        grid-column: span 4;
    }

    .projects-grid > .project {
        grid-column: span 6;
    }

    #contact .card {
        grid-column: span 12;
    }
}

/* ==========================================================================
   Helper classes
   ========================================================================== */

/*
 * Hide visually and from screen readers
 */

.hidden,
[hidden] {
    display: none !important;
}

/*
 * Hide only visually, but have it available for screen readers:
 * https://snook.ca/archives/html_and_css/hiding-content-for-accessibility
 *
 * 1. For long content, line feeds are not interpreted as spaces and small width
 *    causes content to wrap 1 word per line:
 *    https://medium.com/@jessebeach/beware-smushed-off-screen-accessible-text-5952a4c2cbfe
 */

.visually-hidden {
    border: 0;
    clip: rect(0, 0, 0, 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    white-space: nowrap;
    width: 1px;
    /* 1 */
}

/*
 * Extends the .visually-hidden class to allow the element
 * to be focusable when navigated to via the keyboard:
 * https://www.drupal.org/node/897638
 */

.visually-hidden.focusable:active,
.visually-hidden.focusable:focus {
    clip: auto;
    height: auto;
    margin: 0;
    overflow: visible;
    position: static;
    white-space: inherit;
    width: auto;
}

/*
 * Hide visually and from screen readers, but maintain layout
 */

.invisible {
    visibility: hidden;
}

/*
 * Clearfix: contain floats
 *
 * The use of `table` rather than `block` is only necessary if using
 * `::before` to contain the top-margins of child elements.
 */

.clearfix::before,
.clearfix::after {
    content: "";
    display: table;
}

.clearfix::after {
    clear: both;
}

/* ==========================================================================
   EXAMPLE Media Queries for Responsive Design.
   These examples override the primary ('mobile first') styles.
   Modify as content requires.
   ========================================================================== */

@media only screen and (min-width: 35em) {
    /* Style adjustments for viewports that meet the condition */
}

@media print,
(-webkit-min-device-pixel-ratio: 1.25),
(min-resolution: 1.25dppx),
(min-resolution: 120dpi) {
    /* Style adjustments for high resolution devices */
}

/* ==========================================================================
   Print styles.
   Inlined to avoid the additional HTTP request:
   https://www.phpied.com/delay-loading-your-print-css/
   ========================================================================== */

@media print {
    *,
    *::before,
    *::after {
        background: #fff !important;
        color: #000 !important;
        /* Black prints faster */
        box-shadow: none !important;
        text-shadow: none !important;
    }

    a,
    a:visited {
        text-decoration: underline;
    }

    a[href]::after {
        content: " (" attr(href) ")";
    }

    abbr[title]::after {
        content: " (" attr(title) ")";
    }

    /*
     * Don't show links that are fragment identifiers,
     * or use the `javascript:` pseudo protocol
     */
    a[href^="#"]::after,
    a[href^="javascript:"]::after {
        content: "";
    }

    pre {
        white-space: pre-wrap !important;
    }

    pre,
    blockquote {
        border: 1px solid #999;
        page-break-inside: avoid;
    }

    tr,
    img {
        page-break-inside: avoid;
    }

    p,
    h2,
    h3 {
        orphans: 3;
        widows: 3;
    }

    h2,
    h3 {
        page-break-after: avoid;
    }
}

