/* ========================================
   CODY MELNICK — PERSONAL DEV HUB
   Style: DIY futuristic / dark glass
======================================== */

:root {
    --bg: #0c0d12;
    --bg-soft: #12141c;
    --card: #171923;
    --card-hover: #1d202c;

    --text: #eeeeF4;
    --muted: #989baa;

    --accent: #b6a0ff;
    --accent-soft: rgba(182, 160, 255, 0.12);

    --border: rgba(255, 255, 255, 0.09);
    --radius: 12px;

    --max-width: 1120px;
}

/* RESET */

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: "Inter", "Segoe UI", Arial, sans-serif;
    line-height: 1.65;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font: inherit;
}

img {
    max-width: 100%;
    display: block;
}

::selection {
    background: var(--accent);
    color: #101014;
}

/* SUBTLE BACKGROUND */

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;

    background:
        radial-gradient(
            ellipse at 15% 0%,
            rgba(124, 103, 190, 0.12),
            transparent 45%
        ),
        radial-gradient(
            ellipse at 90% 40%,
            rgba(67, 90, 140, 0.08),
            transparent 40%
        );
}

/* LAYOUT */

.container {
    width: min(92%, var(--max-width));
    margin: 0 auto;
}

section {
    padding: 100px 0;
}

.section-title {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    font-weight: 700;
    letter-spacing: -1.5px;
    margin-bottom: 12px;
}

.section-subtitle {
    color: var(--muted);
    max-width: 620px;
    margin-bottom: 40px;
}

/* NAVIGATION */

header,
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;

    background: rgba(12, 13, 18, 0.88);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(14px);
}

.nav-container,
nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.nav-container {
    width: min(92%, var(--max-width));
    min-height: 72px;
    margin: 0 auto;
}

.logo {
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

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

nav ul,
.nav-links {
    display: flex;
    align-items: center;
    gap: 28px;
    list-style: none;
}

nav a,
.nav-links a {
    color: var(--muted);
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

nav a:hover,
.nav-links a:hover,
.nav-links a.active {
    color: var(--accent);
}

/* HERO */

.hero {
    min-height: 78vh;
    display: flex;
    align-items: center;
    padding: 100px 0 90px;
}

.hero-content {
    width: 100%;
}

.hero-label {
    display: inline-flex;
    align-items: center;
    gap: 10px;

    padding: 7px 12px;
    margin-bottom: 25px;

    border: 1px solid var(--border);
    border-radius: 6px;

    background: rgba(255, 255, 255, 0.025);
    color: var(--muted);

    font-size: 0.78rem;
    letter-spacing: 0.5px;
}

.hero-label::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #9fdfaa;
    box-shadow: 0 0 8px rgba(159, 223, 170, 0.4);
}

.hero h1 {
    max-width: 850px;
    font-size: clamp(2.8rem, 7vw, 5.7rem);
    line-height: 1.04;
    letter-spacing: -4px;
    font-weight: 800;
    margin-bottom: 24px;
}

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

.hero p {
    color: var(--muted);
    max-width: 640px;
    font-size: 1.05rem;
    margin-bottom: 32px;
}

/* BUTTONS */

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 12px 20px;
    border-radius: 7px;

    font-size: 0.9rem;
    font-weight: 600;

    border: 1px solid var(--border);
    transition:
        background 0.2s ease,
        border-color 0.2s ease,
        transform 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn-primary {
    background: var(--accent);
    color: #000000;
    border-color: var(--accent);
}

.btn-primary:hover {
    background: #c6b5ff;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.035);
    color: var(--text);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(182, 160, 255, 0.4);
}

/* CURRENT PAGE COMPONENTS */

.background-grid {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    opacity: 0.28;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
    background-size: 44px 44px;
    mask-image: linear-gradient(to bottom, black, transparent 85%);
}

.navbar {
    min-height: 72px;
    padding: 0 4%;
}

.navbar .logo {
    white-space: nowrap;
}

.logo small {
    color: var(--muted);
    font-size: 0.62em;
    letter-spacing: 0;
}

.nav-button,
.button-primary,
.button-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 11px 16px;
    border: 1px solid var(--border);
    border-radius: 7px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.4px;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.nav-button,
.button-primary {
    background: var(--accent);
    color: #000000;
    border-color: var(--accent);
}

.nav-button:hover,
.button-primary:hover {
    background: #c6b5ff;
    color: #000000;
    transform: translateY(-2px);
}

.button-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(182, 160, 255, 0.4);
    transform: translateY(-2px);
}

.status,
.hero-footer,
.section-heading,
.card-top,
.card-tags,
.mods-banner {
    display: flex;
    align-items: center;
}

.status {
    gap: 9px;
    margin-bottom: 25px;
    color: var(--muted);
    font-size: 0.75rem;
    letter-spacing: 0.6px;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #9fdfaa;
    box-shadow: 0 0 8px rgba(159, 223, 170, 0.5);
}

.hero {
    gap: 8%;
}

.hero-content,
.hero-visual {
    flex: 1 1 0;
}

.hero-visual {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: rgba(18, 20, 29, 0.75);
    overflow: hidden;
    font-family: Consolas, "Courier New", monospace;
}

.visual-top,
.visual-bottom {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 13px 16px;
    color: var(--muted);
    font-size: 0.72rem;
}

.visual-top {
    border-bottom: 1px solid var(--border);
}

.visual-bottom {
    border-top: 1px solid var(--border);
}

.terminal-content {
    min-height: 260px;
    padding: 24px;
    color: #c7c9d7;
}

.terminal-content p {
    margin-bottom: 8px;
    font-size: 0.84rem;
}

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

.yellow-text,
.terminal-logo span {
    color: var(--accent);
}

.terminal-logo {
    margin: 38px 0 6px;
    color: var(--text);
    font-family: "Orbitron", sans-serif;
    font-size: 3rem;
    font-weight: 800;
}

.hero-footer {
    flex-wrap: wrap;
    gap: 14px 24px;
    margin-top: 34px;
    color: var(--muted);
    font-size: 0.67rem;
    letter-spacing: 0.5px;
}

.section-heading {
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 38px;
}

.section-heading h2,
.mods-section h2,
.about-section h2 {
    margin-top: 8px;
    font-size: clamp(1.8rem, 4vw, 2.6rem);
}

.section-heading h2 span,
.mods-section h2 span,
.about-section h2 span {
    color: var(--accent);
}

.eyebrow,
.section-count,
.project-type,
.project-number,
.card-tags,
.mods-banner {
    color: var(--muted);
    font-size: 0.7rem;
    letter-spacing: 0.7px;
}

.project-card {
    display: flex;
    flex-direction: column;
}

.project-card .btn {
    align-self: flex-start;
    margin-top: auto;
}

.card-top,
.card-tags {
    justify-content: space-between;
    gap: 12px;
}

.project-icon {
    margin: 28px 0 18px;
    color: var(--accent);
    font-family: "Orbitron", sans-serif;
    font-size: 1.6rem;
    font-weight: 800;
}

.card-tags {
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 8px;
    margin: 4px 0 24px;
}

.card-tags span {
    padding: 4px 8px;
    border: 1px solid var(--border);
    border-radius: 4px;
}

.project-link {
    margin-top: auto;
}

.mods-section > p,
.about-section > p {
    max-width: 680px;
    color: var(--muted);
}

.mods-banner {
    justify-content: space-between;
    gap: 18px;
    margin-top: 34px;
    padding: 18px 20px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.025);
}

.about-section > p + p {
    margin-top: 18px;
}

/* TERMINAL / CODE PANEL */

.terminal,
.terminal-window {
    margin-top: 50px;
    max-width: 650px;

    background: rgba(18, 20, 29, 0.8);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.terminal-header {
    display: flex;
    align-items: center;
    gap: 7px;

    padding: 13px 16px;
    background: rgba(255, 255, 255, 0.025);
    border-bottom: 1px solid var(--border);
}

.terminal-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #484b59;
}

.terminal-title {
    margin-left: 8px;
    color: var(--muted);
    font-size: 0.75rem;
}

.terminal-body {
    padding: 20px;
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.85rem;
    color: #b9bbc9;
    overflow-x: auto;
}

.terminal-body p {
    margin-bottom: 8px;
}

.terminal-body .prompt {
    color: var(--accent);
}

/* PROJECTS */

.projects-grid,
.project-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.project-card {
    position: relative;
    padding: 25px;

    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);

    transition:
        transform 0.2s ease,
        background 0.2s ease,
        border-color 0.2s ease;
}

.project-card:hover {
    transform: translateY(-4px);
    background: var(--card-hover);
    border-color: rgba(182, 160, 255, 0.3);
}

.project-card h3 {
    font-size: 1.15rem;
    margin-bottom: 10px;
}

.project-card p {
    color: var(--muted);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.project-card .tag {
    display: inline-block;
    margin: 0 6px 6px 0;
    padding: 4px 9px;

    border: 1px solid var(--border);
    border-radius: 5px;

    color: #c4b6f3;
    font-size: 0.72rem;
}

.project-card a {
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 600;
}

.project-card a:hover {
    text-decoration: underline;
}

/* MODS SECTION */

.mods-section {
    background: rgba(255, 255, 255, 0.015);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.mods-list {
    display: grid;
    gap: 12px;
}

.mod-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;

    padding: 18px 20px;

    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 9px;

    transition: border-color 0.2s ease;
}

.mod-item:hover {
    border-color: rgba(182, 160, 255, 0.3);
}

.mod-item h3 {
    font-size: 1rem;
}

.mod-item p {
    color: var(--muted);
    font-size: 0.85rem;
}

/* ABOUT */

.about-content {
    max-width: 780px;
}

.about-content p {
    color: var(--muted);
    margin-bottom: 18px;
    font-size: 1rem;
}

.about-content strong {
    color: var(--text);
}

/* FOOTER */

footer {
    padding: 30px 0;
    border-top: 1px solid var(--border);
    color: var(--muted);
    font-size: 0.82rem;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

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

footer a:hover {
    text-decoration: underline;
}

/* REVEAL ANIMATIONS */

.reveal {
    opacity: 0;
    transform: translateY(18px);
    transition:
        opacity 0.55s ease,
        transform 0.55s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* TEXT UTILITIES */

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

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

.small {
    font-size: 0.82rem;
}

/* SCROLLBAR */

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg);
}

::-webkit-scrollbar-thumb {
    background: #30313e;
    border-radius: 8px;
}

::-webkit-scrollbar-thumb:hover {
    background: #55536b;
}

/* RESPONSIVE */

@media (max-width: 850px) {
    .projects-grid,
    .project-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .hero {
        align-items: stretch;
        flex-direction: column;
    }

    .hero-visual {
        width: 100%;
    }

    .hero h1 {
        letter-spacing: -2px;
    }

    section {
        padding: 75px 0;
    }
}

@media (max-width: 600px) {
    .navbar {
        align-items: flex-start;
        flex-wrap: wrap;
        padding-top: 15px;
        padding-bottom: 15px;
    }

    .navbar nav {
        order: 3;
        width: 100%;
        justify-content: flex-start;
    }

    .nav-button {
        margin-left: auto;
    }

    .nav-container {
        align-items: flex-start;
        flex-direction: column;
        padding: 15px 0;
        gap: 12px;
    }

    nav ul,
    .nav-links {
        flex-wrap: wrap;
        gap: 16px;
    }

    .hero {
        min-height: auto;
        padding: 75px 0;
    }

    .hero h1 {
        font-size: clamp(2.5rem, 12vw, 4rem);
        letter-spacing: -2px;
    }

    .hero p {
        font-size: 0.95rem;
    }

    .section-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
    }

    .section-count {
        font-size: 0.65rem;
    }

    .mods-banner {
        align-items: flex-start;
        flex-direction: column;
    }

    .projects-grid,
    .project-grid {
        grid-template-columns: 1fr;
    }

    .mod-item {
        align-items: flex-start;
        flex-direction: column;
    }

    .footer-content {
        align-items: flex-start;
        flex-direction: column;
    }

    section {
        padding: 60px 0;
    }
}

/* ACCESSIBILITY */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }
}
