@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600;700;800&display=swap');

/* Общие настройки и сброс стилей */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'JetBrains Mono', "Fira Code", monospace;
    background: #020b06;
    color: #e2e8f0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    overflow-x: hidden;
    position: relative;
    padding: 130px 20px 40px;
}

.container {
    width: 100%;
    max-width: 750px; 
    position: relative;
    z-index: 2;
}

.profile-card, .grid-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%);
    backdrop-filter: blur(10px) saturate(120%);
    -webkit-backdrop-filter: blur(10px) saturate(120%);
    border: 1px solid rgba(16, 185, 129, 0.15);
    border-radius: 20px;
    box-shadow: 0 15px 35px 0 rgba(0, 0, 0, 0.6);
}

.profile-card {
    text-align: center;
    padding: 50px 30px;
    margin-bottom: 25px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.01) 100%);
    border: 1px solid rgba(16, 185, 129, 0.25);
}

.avatar-placeholder {
    width: 85px;
    height: 85px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 50%;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
    border: 2px solid #10b981;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.3);
}

.terminal-prompt {
    font-size: 26px;
    color: #10b981;
    font-weight: bold;
    position: relative;
}
.terminal-prompt::after {
    content: "";
    display: inline-block;
    width: 10px;
    height: 24px;
    background: #10b981;
    margin-left: 4px;
    animation: blink 1s step-end infinite;
    vertical-align: middle;
}

@keyframes blink {
    50% { opacity: 0; }
}

.profile-card h1 {
    font-size: 30px;
    font-weight: 700;
    margin-bottom: 10px;
    color: #ffffff;
    letter-spacing: -0.5px;
}

.subtitle {
    font-size: 14px;
    color: #34d399; 
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 20px;
}

.comment {
    color: #4fa175;
    font-style: italic;
    opacity: 0.85;
}

.welcome-text {
    font-size: 14px;
    color: #cbd5e1;
    line-height: 1.6;
    max-width: 500px;
    margin: 0 auto;
}

.grid-container {
    display: block;
}

.grid-card {
    display: block;
    text-decoration: none;
    color: inherit;
    padding: 30px;
    margin-bottom: 20px;
    transition: transform 0.25s ease, background-color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

@media (min-width: 600px) {
    .grid-container {
        font-size: 0;
    }
    .grid-card {
        display: inline-block;
        vertical-align: top;
        width: calc(50% - 10px);
        font-size: 15px;
        margin-bottom: 0;
    }
    .grid-card:nth-child(odd) {
        margin-right: 20px;
    }
}

.grid-card:hover {
    transform: translateY(-4px);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(255, 255, 255, 0.02) 100%);
    border-color: #34d399;
    box-shadow: 0 0 25px rgba(52, 211, 153, 0.25);
}

.card-icon {
    font-size: 28px;
    margin-bottom: 15px;
    color: #10b981;
}

.grid-card h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 12px;
    color: #ffffff;
}

.grid-card:hover h3 {
    color: #34d399; 
}

.grid-card p {
    font-size: 13px;
    color: #94a3b8;
    line-height: 1.6;
    margin-bottom: 20px;
}

.card-link {
    font-size: 13px;
    font-weight: 600;
    color: #10b981;
    background: rgba(16, 185, 129, 0.1);
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid rgba(16, 185, 129, 0.2);
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    line-height: 1.2;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.card-link:hover,
.card-link:focus-visible {
    color: #ffffff;
    background: #10b981;
    box-shadow: 0 0 12px rgba(16, 185, 129, 0.35);
    transform: translateY(-1px);
    text-decoration: none;
}

.back-navigation .card-link {
    padding: 10px 16px;
    margin-bottom: 4px;
}

.grid-card:hover .card-link {
    color: #ffffff;
    background: #10b981;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.4);
}



.back-navigation {
    margin-bottom: 30px;
    text-align: left;
}

.projects-section {
    margin-bottom: 40px;
}

.section-title {
    font-size: 20px;
    color: #34d399;
    margin-bottom: 20px;
    font-weight: 700;
}

.project-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.project-list-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%);
    backdrop-filter: blur(10px) saturate(120%);
    -webkit-backdrop-filter: blur(10px) saturate(120%);
    border: 1px solid rgba(16, 185, 129, 0.15);
    border-radius: 16px;
    padding: 25px;
    transition: transform 0.25s ease, background-color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
    text-decoration: none; 
    display: block;
}

.project-list-card:hover {
    transform: translateX(5px); 
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.06) 0%, rgba(255, 255, 255, 0.02) 100%);
    border-color: #34d399;
    box-shadow: 0 0 20px rgba(52, 211, 153, 0.15);
}

.project-list-card.archive {
    border-color: rgba(16, 185, 129, 0.08);
}
.project-list-card.archive h3 {
    opacity: 0.85;
}

.project-header {
    display: flex;
    align-items: center; 
    justify-content: flex-start; 
    gap: 12px;
    margin-bottom: 12px;
    flex-wrap: wrap; /
}

.project-list-card h3 {
    font-size: 20px;
    font-weight: 700;
    color: #ffffff;
    margin-right: auto; 
}

.tech-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    color: #e2e8f0;
    font-weight: 600;
    white-space: nowrap; 
}

.tech-badge i {
    font-size: 16px;
}

.project-list-card p {
    font-size: 13.5px;
    color: #94a3b8;
    line-height: 1.6;
    margin-bottom: 18px;
}



.project-page-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.01) 100%);
    backdrop-filter: blur(10px) saturate(120%);
    -webkit-backdrop-filter: blur(10px) saturate(120%);
    border: 1px solid rgba(16, 185, 129, 0.15);
    border-radius: 20px;
    padding: 40px;
    text-align: left;
    margin-bottom: 20px;
}

.project-page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
    border-bottom: 1px solid rgba(16, 185, 129, 0.1);
    padding-bottom: 20px;
}

.project-title-group h1 {
    font-size: 32px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 8px;
}

.project-tagline {
    font-size: 15px;
    color: #94a3b8;
}

.project-tech-stack {
    display: flex;
    gap: 10px;
}

.project-preview-box {
    width: 100%;
    height: 300px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px dashed rgba(16, 185, 129, 0.3);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 35px;
    color: #475569;
    font-family: 'JetBrains Mono', monospace;
}

/* Текстовые секции */
.project-page-card section {
    margin-bottom: 30px;
}

.project-page-card h2 {
    font-size: 16px;
    color: #34d399;
    font-weight: bold;
    margin-bottom: 12px;
    font-family: 'JetBrains Mono', monospace;
}

.project-page-card p {
    font-size: 14.5px;
    color: #cbd5e1;
    line-height: 1.7;
    margin-bottom: 10px;
}

.features-list {
    list-style: none;
    padding: 0;
}

.features-list li {
    font-size: 14.5px;
    color: #cbd5e1;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.features-list span {
    font-size: 16px;
}

.specs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    background: rgba(0, 0, 0, 0.15);
    padding: 20px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.spec-item {
    font-size: 13.5px;
    color: #94a3b8;
}
.spec-item strong {
    color: #e2e8f0;
}

.project-actions {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-top: 40px;
    border-top: 1px solid rgba(16, 185, 129, 0.1);
    padding-top: 30px;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 24px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
}

.primary-btn {
    background: #10b981;
    color: #ffffff;
}
.primary-btn:hover {
    background: #059669;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.4);
}

.secondary-btn {
    background: rgba(255, 255, 255, 0.05);
    color: #e2e8f0;
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.secondary-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(16, 185, 129, 0.4);
}

.site-footer {
    margin-top: 30px;
    font-size: 13px;
    color: #475569;
    text-align: center;
}
.footer-link {
    color: #64748b;
    text-decoration: none;
}
.footer-link:hover {
    color: #10b981;
}

.project-screenshot {
    width: 100%;
    height: auto;
    object-fit: contain;  
    display: block;
}

.project-preview-box {
    width: 100%;
    height: auto;
    background: transparent;
    overflow: hidden;
    border: 1px solid rgba(16, 185, 129, 0.15); 
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 35px;
}



/* Performance tuning */
@media (max-width: 768px) {
    .profile-card, .grid-card, .project-list-card, .project-page-card {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
    }

    .profile-card, .grid-card, .project-list-card, .project-page-card {
        box-shadow: 0 8px 22px rgba(0, 0, 0, 0.34);
    }

    .grid-card:hover, .project-list-card:hover {
        transform: none;
    }
}

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

/* =========================================
   Эффекты фонового свечения
   ========================================= */
.bg-glow {
    position: fixed;
    width: 50vw;
    height: 50vw;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    filter: blur(100px);
    opacity: 0.4;
}

.glow-top-left {
    top: -20vw;
    left: -20vw;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.2) 0%, transparent 70%);
}

.glow-bottom-right {
    bottom: -20vw;
    right: -20vw;
    background: radial-gradient(circle, rgba(6, 95, 70, 0.2) 0%, transparent 70%);
}

/* =========================================
   Плавающая панель навигации (Liquid Glass)
   ========================================= */
.top-navbar {
    position: fixed;
    top: 25px; /* Отступ от верхнего края */
    left: 50%;
    transform: translateX(-50%); /* Идеальное центрирование */
    width: 90%;
    max-width: 800px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 30px;
    
    /* Эффект Liquid Glass */
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.02) 100%);
    backdrop-filter: blur(25px) saturate(120%);
    -webkit-backdrop-filter: blur(25px) saturate(120%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-top: 1px solid rgba(255, 255, 255, 0.2); /* Блик по верхней кромке */
    border-left: 1px solid rgba(255, 255, 255, 0.15); /* Блик слева */
    border-radius: 20px; /* Скругление бокса */
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4), inset 0 0 10px rgba(255, 255, 255, 0.05);
    
    z-index: 1000;
}

.nav-brand a {
    font-size: 22px;
    font-weight: 700;
    color: #10b981;
    text-decoration: none;
    letter-spacing: -0.5px;
    text-shadow: 0 0 10px rgba(16, 185, 129, 0.4);
    transition: text-shadow 0.3s;
}

.nav-brand a:hover {
    text-shadow: 0 0 20px rgba(16, 185, 129, 0.8);
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-links a {
    color: #94a3b8;
    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: #10b981;
    transition: width 0.3s ease;
    box-shadow: 0 0 8px #10b981;
}

.nav-links a:hover {
    color: #ffffff;
}

.nav-links a:hover::after {
    width: 100%;
}

@media (max-width: 768px) {
    .nav-links {
        display: none; /* Скрываем на мобильных для аккуратности */
    }
    .top-navbar {
        padding: 14px 25px;
        justify-content: center; /* Центрируем лого на мобилках */
    }
}

/* =========================================
   Cookie плашка
   ========================================= */
.cookie-banner {
    position: fixed;
    bottom: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(6, 32, 19, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(16, 185, 129, 0.4);
    border-radius: 16px;
    padding: 20px 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    z-index: 9999;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8), 0 0 20px rgba(16, 185, 129, 0.2);
    color: #cbd5e1;
    font-size: 14px;
    width: max-content;
    max-width: 90%;
    transition: bottom 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.cookie-banner.show {
    bottom: 30px;
}

.cookie-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cookie-btn {
    background: #10b981;
    color: #ffffff;
    border: none;
    padding: 10px 24px;
    border-radius: 10px;
    cursor: pointer;
    font-family: inherit;
    font-weight: 700;
    transition: all 0.2s ease;
    font-size: 14px;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.cookie-btn:hover {
    background: #059669;
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
    transform: translateY(-2px);
}

@media (max-width: 650px) {
    .cookie-banner {
        flex-direction: column;
        text-align: center;
        gap: 20px;
        padding: 20px;
    }
    .cookie-btn {
        width: 100%;
    }
}
