/* ===== FONTS ===== */
@import url('https://fonts.googleapis.com/css2?family=Fira+Code:wght@300;400;500;600;700&family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

/* ===== CSS VARIABLES ===== */
:root {
    --bg-primary: #0c0c0c;
    --bg-secondary: #111111;
    --bg-tertiary: #1a1a1a;
    --bg-card: #141414;
    --bg-card-hover: #1c1c1c;
    --border-dim: #222222;
    --border-active: #333333;
    --text-primary: #e0e0e0;
    --text-secondary: #888888;
    --text-muted: #555555;
    --green: #39ff14;
    --green-dim: rgba(57, 255, 20, 0.15);
    --green-glow: rgba(57, 255, 20, 0.3);
    --cyan: #00e5ff;
    --cyan-dim: rgba(0, 229, 255, 0.12);
    --amber: #ffab00;
    --amber-dim: rgba(255, 171, 0, 0.12);
    --red: #ff3d3d;
    --font-mono: 'Fira Code', 'Courier New', monospace;
    --font-sans: 'Space Grotesk', system-ui, sans-serif;
    --shadow-terminal: 0 0 30px rgba(57, 255, 20, 0.05);
    --radius: 6px;
    --transition: 0.25s ease;
}

/* ===== RESET ===== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: var(--green) var(--bg-primary);
}

html::-webkit-scrollbar {
    width: 5px;
}

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

html::-webkit-scrollbar-thumb {
    background: var(--green);
    border-radius: 3px;
}

body {
    font-family: var(--font-mono);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--green);
    text-decoration: none;
    transition: color var(--transition);
}

a:hover {
    color: var(--cyan);
}

/* ===== LAYOUT ===== */
.container {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 24px;
}

section {
    padding: 80px 0;
    position: relative;
}

/* ===== TERMINAL WINDOW CHROME ===== */
.terminal-window {
    background: var(--bg-card);
    border: 1px solid var(--border-dim);
    border-radius: var(--radius);
    overflow: hidden;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.terminal-window:hover {
    border-color: var(--border-active);
    box-shadow: var(--shadow-terminal);
}

.terminal-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-dim);
    user-select: none;
}

.terminal-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.terminal-dot.red {
    background: #ff5f57;
}

.terminal-dot.yellow {
    background: #febc2e;
}

.terminal-dot.green {
    background: #28c840;
}

.terminal-bar-title {
    flex: 1;
    text-align: center;
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 0.05em;
}

.terminal-body {
    padding: 24px;
}

/* ===== SECTION HEADERS ===== */
.section-comment {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 8px;
    letter-spacing: 0.02em;
}

.section-comment::before {
    content: '// ';
    color: var(--green);
    opacity: 0.5;
}

.section-title {
    font-family: var(--font-sans);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
    letter-spacing: -0.02em;
}

.section-title .prompt {
    color: var(--green);
    margin-right: 8px;
    font-family: var(--font-mono);
    font-weight: 400;
}

.section-subtitle {
    font-size: 0.85rem;
    color: var(--text-secondary);
    max-width: 500px;
}

/* ===== NAVBAR ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 12px 0;
    background: rgba(12, 12, 12, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-dim);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--green);
}

.nav-logo::before {
    content: '~/';
    color: var(--text-muted);
}

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

.nav-links a {
    font-size: 0.75rem;
    font-weight: 400;
    color: var(--text-secondary);
    padding: 6px 12px;
    border-radius: 4px;
    transition: all var(--transition);
    font-family: var(--font-mono);
}

.nav-links a:hover {
    color: var(--green);
    background: var(--green-dim);
}

.nav-settings-btn {
    background: transparent;
    border: 1px solid var(--border-dim);
    color: var(--text-muted);
    width: 34px;
    height: 34px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-family: var(--font-mono);
    transition: all var(--transition);
}

.nav-settings-btn:hover {
    border-color: var(--green);
    color: var(--green);
    background: var(--green-dim);
    box-shadow: 0 0 12px rgba(57, 255, 20, 0.15);
}

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

.nav-toggle span {
    width: 20px;
    height: 2px;
    background: var(--text-secondary);
    border-radius: 1px;
    transition: all var(--transition);
}

/* ===== HERO ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 60px;
    position: relative;
}

/* Scanline effect */
.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(0deg,
            transparent,
            transparent 2px,
            rgba(57, 255, 20, 0.008) 2px,
            rgba(57, 255, 20, 0.008) 4px);
    pointer-events: none;
    z-index: 0;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 220px;
    gap: 48px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-terminal {
    flex: 1;
}

.hero-output {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    line-height: 2;
}

.hero-output .line {
    display: block;
    opacity: 0;
    animation: typeLine 0.4s ease forwards;
}

.hero-output .line:nth-child(1) {
    animation-delay: 0.2s;
}

.hero-output .line:nth-child(2) {
    animation-delay: 0.5s;
}

.hero-output .line:nth-child(3) {
    animation-delay: 0.8s;
}

.hero-output .line:nth-child(4) {
    animation-delay: 1.1s;
}

.hero-output .line:nth-child(5) {
    animation-delay: 1.4s;
}

.hero-output .line:nth-child(6) {
    animation-delay: 1.7s;
}

@keyframes typeLine {
    from {
        opacity: 0;
        transform: translateX(-8px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.hero-output .key {
    color: var(--cyan);
}

.hero-output .val {
    color: var(--text-primary);
}

.hero-output .val-name {
    color: var(--green);
    font-size: 2rem;
    font-family: var(--font-sans);
    font-weight: 700;
    letter-spacing: -0.03em;
}

.hero-output .val-headline {
    color: var(--amber);
}

.hero-output .prompt-symbol {
    color: var(--green);
    margin-right: 4px;
}

.hero-cta {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    opacity: 0;
    animation: typeLine 0.4s ease forwards 2s;
}

.btn-terminal {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all var(--transition);
    text-decoration: none;
    font-weight: 500;
}

.btn-green {
    background: var(--green);
    color: #000;
    border: 1px solid var(--green);
}

.btn-green:hover {
    box-shadow: 0 0 20px var(--green-glow);
    transform: translateY(-2px);
    color: #000;
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-active);
}

.btn-ghost:hover {
    border-color: var(--cyan);
    color: var(--cyan);
    background: var(--cyan-dim);
    transform: translateY(-2px);
}

/* Avatar */
.hero-avatar-wrap {
    position: relative;
    opacity: 0;
    animation: avatarIn 0.6s ease forwards 1s;
}

@keyframes avatarIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.hero-avatar-frame {
    width: 200px;
    height: 200px;
    border-radius: 6px;
    border: 2px solid var(--border-dim);
    overflow: hidden;
    position: relative;
}

.hero-avatar-frame::after {
    content: '';
    position: absolute;
    inset: 0;
    border: 2px solid var(--green);
    border-radius: 4px;
    opacity: 0;
    transition: opacity var(--transition);
}

.hero-avatar-wrap:hover .hero-avatar-frame::after {
    opacity: 1;
    box-shadow: 0 0 20px var(--green-glow);
}

.hero-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(30%) contrast(1.1);
    transition: filter var(--transition);
}

.hero-avatar-wrap:hover .hero-avatar {
    filter: grayscale(0%) contrast(1);
}

.hero-avatar-label {
    font-size: 0.65rem;
    color: var(--text-muted);
    text-align: center;
    margin-top: 8px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

/* ===== CURSOR BLINK ===== */
.cursor {
    display: inline-block;
    width: 8px;
    height: 1.1em;
    background: var(--green);
    vertical-align: text-bottom;
    animation: blink 1s step-end infinite;
    margin-left: 2px;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* ===== ABOUT ===== */
.about {
    border-top: 1px solid var(--border-dim);
}

.about-text {
    font-family: var(--font-sans);
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.9;
    margin-top: 24px;
    padding-left: 20px;
    border-left: 2px solid var(--border-dim);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-top: 32px;
}

.stats-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.stat-block {
    padding: 16px;
    border: 1px solid var(--border-dim);
    border-radius: var(--radius);
    text-align: center;
    transition: all var(--transition);
}

.stat-block:hover {
    border-color: var(--green);
    box-shadow: 0 0 15px rgba(57, 255, 20, 0.08);
}

.stat-val {
    font-family: var(--font-sans);
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--green);
}

.stat-key {
    font-size: 0.65rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    margin-top: 2px;
}

/* ===== SKILLS ===== */
.skills {
    border-top: 1px solid var(--border-dim);
}

.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 32px;
}

.skill-tag {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    padding: 8px 16px;
    color: var(--green);
    border: 1px solid var(--border-dim);
    border-radius: 4px;
    background: var(--bg-card);
    transition: all var(--transition);
    cursor: default;
    position: relative;
}

.skill-tag::before {
    content: '#';
    color: var(--text-muted);
    margin-right: 4px;
}

.skill-tag:hover {
    border-color: var(--green);
    background: var(--green-dim);
    box-shadow: 0 0 12px rgba(57, 255, 20, 0.1);
    transform: translateY(-2px);
}

/* ===== PROJECTS ===== */
.projects {
    border-top: 1px solid var(--border-dim);
}

.projects-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 32px;
}

.project-item {
    border: 1px solid var(--border-dim);
    border-radius: var(--radius);
    overflow: hidden;
    transition: all var(--transition);
    background: var(--bg-card);
}

.project-item:hover {
    border-color: var(--border-active);
    box-shadow: var(--shadow-terminal);
}

.project-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-dim);
}

.project-header .dot {
    color: var(--green);
    font-size: 0.7rem;
}

.project-header .filename {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.project-content {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 0;
}

.project-thumb {
    width: 100%;
    height: 100%;
    min-height: 180px;
    object-fit: cover;
    border-right: 1px solid var(--border-dim);
    background: var(--bg-tertiary);
    filter: grayscale(20%);
    transition: filter var(--transition);
}

.project-item:hover .project-thumb {
    filter: grayscale(0%);
}

.project-body {
    padding: 20px 24px;
    display: flex;
    flex-direction: column;
}

.project-name {
    font-family: var(--font-sans);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.project-desc {
    font-family: var(--font-sans);
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.7;
    flex: 1;
    margin-bottom: 14px;
}

.project-tech-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
}

.project-tech-item {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    padding: 3px 10px;
    color: var(--cyan);
    background: var(--cyan-dim);
    border-radius: 3px;
}

.project-actions {
    display: flex;
    gap: 16px;
    padding-top: 12px;
    border-top: 1px solid var(--border-dim);
}

.project-action {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--text-muted);
    transition: color var(--transition);
}

.project-action:hover {
    color: var(--green);
}

.project-action svg {
    width: 14px;
    height: 14px;
}

/* No thumb fallback */
.project-content.no-thumb {
    grid-template-columns: 1fr;
}

/* ===== PUBLICATIONS ===== */
.publications {
    border-top: 1px solid var(--border-dim);
}

.pubs-list {
    margin-top: 32px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.pub-row {
    display: grid;
    grid-template-columns: 60px 1fr auto;
    gap: 20px;
    align-items: center;
    padding: 16px 20px;
    border: 1px solid transparent;
    border-radius: var(--radius);
    transition: all var(--transition);
}

.pub-row:hover {
    background: var(--bg-card);
    border-color: var(--border-dim);
}

.pub-year {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--amber);
    font-weight: 500;
}

.pub-info {}

.pub-name {
    font-family: var(--font-sans);
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.pub-venue {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-style: italic;
}

.pub-link-btn {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--text-muted);
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border: 1px solid var(--border-dim);
    border-radius: 3px;
    transition: all var(--transition);
    white-space: nowrap;
}

.pub-link-btn:hover {
    color: var(--green);
    border-color: var(--green);
    background: var(--green-dim);
}

.pub-link-btn svg {
    width: 12px;
    height: 12px;
}

/* ===== CONTACT ===== */
.contact {
    border-top: 1px solid var(--border-dim);
}

.contact-section {
    text-align: center;
}

.contact-row {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 32px;
    margin-bottom: 32px;
}

.contact-chip {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    border: 1px solid var(--border-dim);
    border-radius: var(--radius);
    background: var(--bg-card);
    transition: all var(--transition);
    text-decoration: none;
    color: var(--text-primary);
}

.contact-chip:hover {
    border-color: var(--green);
    background: var(--green-dim);
    color: var(--green);
}

.contact-chip-icon {
    color: var(--green);
    display: flex;
    align-items: center;
}

.contact-chip-icon svg {
    width: 18px;
    height: 18px;
}

.contact-chip-text {
    font-family: var(--font-sans);
    font-size: 0.85rem;
}

.social-row {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.social-btn {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-dim);
    border-radius: 4px;
    color: var(--text-muted);
    background: var(--bg-card);
    transition: all var(--transition);
}

.social-btn:hover {
    border-color: var(--green);
    color: var(--green);
    background: var(--green-dim);
    box-shadow: 0 0 15px rgba(57, 255, 20, 0.12);
    transform: translateY(-3px);
}

.social-btn svg {
    width: 18px;
    height: 18px;
}

/* ===== FOOTER ===== */
.footer {
    padding: 24px 0;
    border-top: 1px solid var(--border-dim);
    text-align: center;
}

.footer p {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.footer span.green {
    color: var(--green);
}

/* ===== SETTINGS PANEL ===== */
.settings-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition);
}

.settings-overlay.active {
    opacity: 1;
    visibility: visible;
}

.settings-panel {
    position: fixed;
    top: 0;
    right: -520px;
    width: 500px;
    max-width: 92vw;
    height: 100vh;
    background: var(--bg-secondary);
    border-left: 1px solid var(--border-dim);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    transition: right var(--transition);
}

.settings-panel.active {
    right: 0;
}

.settings-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-dim);
}

.settings-bar h2 {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--green);
}

.settings-bar h2::before {
    content: '> ';
    color: var(--text-muted);
}

.settings-x {
    background: transparent;
    border: 1px solid var(--border-dim);
    color: var(--text-muted);
    width: 30px;
    height: 30px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    transition: all var(--transition);
}

.settings-x:hover {
    border-color: var(--red);
    color: var(--red);
    background: rgba(255, 61, 61, 0.08);
}

.settings-body {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.settings-hint {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--text-muted);
    line-height: 1.7;
    padding: 12px 14px;
    border: 1px dashed var(--border-dim);
    border-radius: var(--radius);
}

.settings-hint strong {
    color: var(--green);
    font-weight: 500;
}

.settings-hint code {
    padding: 1px 5px;
    background: var(--bg-tertiary);
    border-radius: 3px;
    color: var(--cyan);
    font-size: 0.7rem;
}

.settings-textarea {
    flex: 1;
    min-height: 280px;
    width: 100%;
    background: var(--bg-primary);
    border: 1px solid var(--border-dim);
    border-radius: var(--radius);
    color: var(--green);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    padding: 14px;
    resize: none;
    line-height: 1.6;
    transition: border-color var(--transition);
}

.settings-textarea:focus {
    outline: none;
    border-color: var(--green);
    box-shadow: 0 0 0 2px rgba(57, 255, 20, 0.08);
}

.settings-textarea::placeholder {
    color: var(--text-muted);
}

.settings-msg {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    padding: 8px 12px;
    border-radius: var(--radius);
    display: none;
}

.settings-msg.error {
    color: var(--red);
    background: rgba(255, 61, 61, 0.06);
    border: 1px solid rgba(255, 61, 61, 0.15);
}

.settings-msg.success {
    color: var(--green);
    background: var(--green-dim);
    border: 1px solid rgba(57, 255, 20, 0.15);
}

.settings-msg.visible {
    display: block;
}

.settings-actions {
    padding: 16px 20px;
    border-top: 1px solid var(--border-dim);
    display: flex;
    gap: 10px;
}

.settings-actions .btn-terminal {
    flex: 1;
    justify-content: center;
}

/* ===== FADE IN ===== */
.fade-in {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        background: rgba(12, 12, 12, 0.97);
        padding: 16px 24px;
        gap: 4px;
        border-bottom: 1px solid var(--border-dim);
    }

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

    .nav-toggle {
        display: flex;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-avatar-wrap {
        justify-self: center;
        order: -1;
    }

    .hero-avatar-frame {
        width: 160px;
        height: 160px;
    }

    .hero-cta {
        justify-content: center;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }

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

    .project-thumb {
        height: 160px;
        border-right: none;
        border-bottom: 1px solid var(--border-dim);
    }

    .section-title {
        font-size: 1.5rem;
    }

    section {
        padding: 60px 0;
    }
}

@media (max-width: 480px) {
    .hero-avatar-frame {
        width: 130px;
        height: 130px;
    }

    .stats-row {
        grid-template-columns: 1fr 1fr;
    }

    .settings-panel {
        width: 100vw;
    }

    .contact-row {
        flex-direction: column;
        align-items: center;
    }
}

/* ===== PIN AUTH MODAL ===== */
.pin-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s ease;
}

.pin-overlay.active {
    opacity: 1;
    visibility: visible;
}

.pin-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    z-index: 2001;
    background: var(--bg-card);
    border: 1px solid var(--border-dim);
    border-radius: var(--radius);
    width: 340px;
    max-width: 90vw;
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s ease;
    box-shadow: 0 0 40px rgba(57, 255, 20, 0.05);
}

.pin-modal.active {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

.pin-modal-header {
    padding: 18px 20px 0;
    text-align: center;
}

.pin-modal-header h3 {
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 600;
    color: var(--green);
}

.pin-modal-body {
    padding: 18px 20px;
    text-align: center;
}

.pin-subtitle {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 18px;
}

.pin-input {
    width: 170px;
    text-align: center;
    font-family: var(--font-mono);
    font-size: 1.6rem;
    letter-spacing: 0.6em;
    padding: 10px 14px;
    background: var(--bg-primary);
    border: 1px solid var(--border-active);
    border-radius: 4px;
    color: var(--green);
    outline: none;
    transition: border-color 0.2s ease;
}

.pin-input:focus {
    border-color: var(--green);
    box-shadow: 0 0 15px rgba(57, 255, 20, 0.15);
}

.pin-error {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--red);
    margin-top: 10px;
    min-height: 18px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.pin-error.visible {
    opacity: 1;
}

.pin-lockout {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    color: var(--amber);
    margin-top: 4px;
    min-height: 16px;
}

.pin-modal-footer {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 0 20px 20px;
}

.pin-modal-footer .btn-terminal {
    padding: 8px 20px;
    font-size: 0.78rem;
}