/* Загальні стилі */
body {
    font-family: 'Arial', sans-serif;
    background-color: #121212;
    color: #ffffff;
    margin: 0;
    padding: 0;
    line-height: 1.6;
}

h1, h2, h3 {
    color: #bb86fc;
}

a {
    color: #03dac6;
    text-decoration: none;
}

/* Навігація */
header {
    background: #1f1f1f;
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

nav ul {
    list-style: none;
    display: flex;
    justify-content: center;
    padding: 0;
    margin: 0;
}

nav ul li {
    margin: 0 15px;
}

nav ul li a {
    font-weight: bold;
    transition: color 0.3s;
}

nav ul li a:hover {
    color: #ffffff;
}

/* Головний контент */
main {
    padding-top: 60px; /* Відступ для фіксованої навігації */
}

section {
    padding: 40px 20px;
    text-align: center;
}

/* Hero Section */
#hero {
    /* Щоб змінити фонове зображення, замініть URL нижче */
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('https://images.unsplash.com/photo-1597733336794-12d05021d510?q=80&w=1974&auto=format&fit=crop') no-repeat center center/cover;
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

#hero h1 {
    font-size: 3rem;
}

/* Навички */
.skills-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.skill {
    background: #1f1f1f;
    padding: 20px;
    border-radius: 8px;
    width: 200px;
    transition: transform 0.3s;
}

.skill:hover {
    transform: translateY(-10px);
}

/* Проекти */
.projects-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.project-card {
    background: #1f1f1f;
    padding: 20px;
    border-radius: 8px;
    transition: transform 0.3s;
    overflow: hidden; /* Щоб зображення не виходило за межі картки */
}

.project-card img {
    width: 100%;
    height: auto;
    width: 400px;
    height: 300px;
    border-radius: 5px;
    margin-bottom: 15px;
    object-fit: contain;
}

.project-card:hover {
    transform: scale(1.05);
}

.project-link {
    color: inherit;
    text-decoration: none;
}

/* Контакти */
#contact form {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

#contact input, #contact textarea {
    padding: 10px;
    background: #1f1f1f;
    border: 1px solid #bb86fc;
    color: #ffffff;
    border-radius: 5px;
}

#contact button {
    padding: 10px 20px;
    background: #bb86fc;
    color: #121212;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s;
    border-radius: 5px;
    font-weight: bold;
}

#contact button:hover {
    background-color: #03dac6;
}

/* Футер */
footer {
    text-align: center;
    padding: 20px;
    background: #1f1f1f;
    margin-top: 40px;
}

.social-links {
    margin-bottom: 20px;
}

.social-links a {
    color: #ffffff;
    margin: 0 15px;
    font-size: 1.8rem;
    transition: color 0.3s ease-in-out;
}

.social-links a:hover {
    color: #bb86fc;
}

/* Terminal Section */
#terminal-section {
    padding: 60px 20px;
    background-color: #0d0d0d;
}

#terminal {
    width: 80%;
    max-width: 800px;
    margin: auto;
    background-color: #1e1e1e;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
    font-family: 'Courier New', Courier, monospace;
}

#terminal-header {
    background-color: #333;
    padding: 8px;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
    display: flex;
    align-items: center;
}

.terminal-button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 8px;
}

.terminal-button.red { background-color: #ff5f56; }
.terminal-button.yellow { background-color: #ffbd2e; }
.terminal-button.green { background-color: #27c93f; }

#terminal-body {
    padding: 20px;
    height: 400px;
    overflow-y: auto;
    text-align: left;
}

#terminal-output {
    white-space: pre-wrap;
    word-wrap: break-word;
}

.terminal-prompt {
    display: flex;
    align-items: center;
}

.prompt-user {
    color: #03dac6;
    font-weight: bold;
}

.prompt-symbol {
    color: #bb86fc;
    margin: 0 5px;
}

#terminal-input {
    background: transparent;
    border: none;
    color: #ffffff;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1em;
    flex-grow: 1;
    outline: none;
}

#terminal-input::after {
    content: '_';
    animation: blink 1s step-end infinite;
}

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

/* Project Details Page */
#project-details {
    max-width: 900px;
    margin: auto;
    padding: 60px 20px;
    text-align: left;
}

.project-header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.project-subtitle {
    font-size: 1.2rem;
    color: #03dac6;
    margin-bottom: 40px;
}

.project-gallery {
    margin-bottom: 40px;
}

.thumbnail-container {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.thumbnail {
    width: 150px;
    height: 100px;
    object-fit: cover;
    border-radius: 5px;
    cursor: pointer;
    transition: transform 0.2s, opacity 0.2s;
    background-color: #333; /* Placeholder color */
}

.thumbnail:hover {
    transform: scale(1.05);
    opacity: 0.8;
}

.project-description, .project-tech {
    margin-bottom: 40px;
}

.project-tech ul {
    list-style: none;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.project-tech li {
    background-color: #1f1f1f;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    color: #03dac6;
}

@media (max-width: 767px) {
    #terminal-section {
        display: none;
    }
}

.btn {
    display: inline-block;
    padding: 12px 25px;
    background: #bb86fc;
    color: #121212;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s;
    border-radius: 5px;
    font-weight: bold;
    text-align: center;
    text-decoration: none; /* To remove underline from <a> tag */
    margin-top: 20px; /* Add some space above the button */
}

.btn:hover {
    background-color: #03dac6;
}

.main-image-container {
    position: relative;
    width: 100%;
    max-width: 900px;
    height: 450px;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 20px;
}

.project-image-container {
    position: relative;
    width: 100%;
    max-width: 900px;
    height: 100%;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 20px;
}

/* розмите тло */
.main-image-blur {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(20px);
    transform: scale(3.5); /* трохи збільшуємо, щоб розмиття не обрізалось */
    z-index: 1;
}

/* справжнє фото зверху */
.main-image {
    position: relative;
    max-width: 100%;
    max-height: 100%;
    margin: auto;
    display: block;
    z-index: 2;
    object-fit: contain; /* щоб маленьке фото не обрізалось */
}