:root {
    --bg-color: #0d0d0d;
    --card-bg-color: rgba(255, 255, 255, 0.05);
    --card-border-color: rgba(255, 255, 255, 0.1);
    --text-primary: #f0f0f0;
    --text-secondary: #a0a0a0;
    --accent-blue: #00aaff;
    --accent-purple: #8A2BE2;
    --accent-pink: #FF007F;
    --accent-orange: #F28500;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: 'Poppins', sans-serif;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 100vh;
    padding: 2rem;
    overflow-y: auto;
    cursor: none; 
}

.custom-cursor {
    width: 25px;
    height: 25px;
    border: 2px solid var(--text-primary);
    border-radius: 50%;
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 9999;
    transition: width 0.3s ease, height 0.3s ease, background-color 0.3s ease;
    mix-blend-mode: difference;
}

.custom-cursor.hover {
    width: 40px;
    height: 40px;
    background-color: var(--text-primary);
}

.background-aurora {
    position: fixed;
    top: -10%;
    left: -10%;
    width: 120%;
    height: 120%;
    overflow: hidden;
    z-index: -1;
    transition: transform 0.5s ease-out;
}

.aurora-shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.4;
}

.shape1 {
    width: 400px;
    height: 400px;
    background: var(--accent-orange);
    top: -10%;
    left: -10%;
    animation: move 10s infinite alternate;
}

.shape2 {
    width: 500px;
    height: 500px;
    background: var(--accent-orange);
    bottom: -15%;
    right: -15%;
    animation: move 13s infinite alternate-reverse;
}

.shape3 {
    width: 300px;
    height: 300px;
    background: var(--accent-orange);
    bottom: 20%;
    left: 20%;
    animation: move 8s infinite alternate;
}

@keyframes move {
    from { transform: translate(0, 0) rotate(0deg) scale(1); }
    to { transform: translate(100px, 50px) rotate(180deg) scale(1.2); }
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(9, 1fr);
    grid-template-rows: 1fr;   
    column-gap: 1rem;
    row-gap: 0.5rem;    
    width: 100%;
    max-width: 1400px; 
    padding: 1rem;
}

.bento-item {
    background: var(--card-bg-color);
    border: 1px solid var(--card-border-color);
    border-radius: 1rem;
    padding: 1.5rem;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease-out, transform 0.5s ease-out, background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.bento-item.visible {
    opacity: 1;
    transform: translateY(0);
}

.bento-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-5px);
}

.bento-column.column-left {
    grid-column: 1 / 4;
    grid-row: 1; 
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

.bento-column.column-right {
    grid-column: 4 / 7;
    grid-row: 1; 
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

.bento-column.column-tools {
    grid-column: 7 / 10;
    grid-row: 1; 
    display: flex;
    flex-direction: column;
    gap: 1rem;
    overflow-y: auto;
    max-height: 90vh;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

.bento-column.column-tools::-webkit-scrollbar { 
    width: 8px; 
}

.bento-column.column-tools::-webkit-scrollbar-track { 
    background: transparent; 
}

.bento-column.column-tools::-webkit-scrollbar-thumb { 
    background-color: rgba(255, 255, 255, 0.2); 
    border-radius: 10px; 
    border: 2px solid transparent; 
    background-clip: content-box;
}

.bento-column.column-tools::-webkit-scrollbar-thumb:hover { 
    background-color: rgba(255, 255, 255, 0.4); 
}

.card-tool {
    padding: 1rem; 
    overflow: hidden; 
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.card-tool-image {
    width: 70px;
    height: 70px;
    flex-shrink: 0;
    overflow: hidden;
}

.card-tool-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    border-radius: 12px;
}

.card-tool:hover {
    border-color: var(--accent-orange);
    box-shadow: 0 0 4px 0px var(--accent-orange);
}

.card-tool-content {
    padding: 0;
    flex-grow: 1;
}

.card-tool-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
}

.card-tool-description {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 0;
    line-height: 1.5;
}

.card-tool-button {
    text-decoration: none;
    color: var(--text-primary);
    background: var(--accent-orange);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    text-align: center;
    font-weight: bold;
    transition: background-color 0.3s ease, transform 0.2s ease;
    font-size: 0.8rem;   
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.card-tool-button:hover {
    background: #0090d8;
    transform: scale(1.03);
}

.profile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.language-switcher {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 100;
}

.language-switcher-wrapper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.05);
    padding: 0.3rem 0.6rem;
    border-radius: 0.8rem;
    border: 1px solid var(--card-border-color);
}

.lang-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-family: inherit;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: color 0.3s ease;
    padding: 0.2rem;
}

.lang-btn:hover {
    color: var(--text-primary);
}

.lang-btn.active {
    color: var(--accent-orange);
}

.lang-divider {
    color: var(--card-border-color);
    font-size: 0.7rem;
}

.profile-main-info {    display: flex;
    align-items: center; 
    gap: 1rem;
}

.profile-picture { 
    width: 70px; 
    height: 70px; 
    border-radius: 50%; 
    border: 2px solid var(--text-primary); 
    object-fit: cover; 
    flex-shrink: 0; 
}

.profile-name { 
    font-size: 1.5rem; 
    font-weight: 600; 
}

.profile-handle { 
    color: var(--text-secondary); 
    font-size: 1rem; 
}

.profile-bio { 
    font-size: 0.9rem; 
    color: var(--text-secondary); 
    min-height: 54px; 
}

#typing-bio::after { 
    content: '|'; 
    animation: blink 1s infinite; 
}

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

.card-social-links { 
    display: grid; 
    grid-template-columns: repeat(4, 1fr); 
    gap: 1rem; 
    padding: 1rem; 
}

.social-link {
    color: var(--text-primary); 
    background-color: rgba(255,255,255,0.1); 
    text-decoration: none;
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    justify-content: center;
    padding: 0.75rem 0; 
    border-radius: 0.75rem; 
    transition: background-color 0.2s, transform 0.2s; 
    font-size: 0.8rem;
    min-width: 0;
}

.social-link:hover { 
    transform: scale(1.05); 
}

.social-link i { 
    font-size: 1.2rem; 
    margin-bottom: 0.5rem; 
}

.social-link.github:hover { 
    background-color: #333; 
}

.social-link.facebook:hover { 
    background-color: #1877F2; 
}

.social-link.linkedin:hover { 
    background-color: #0E76A8; 
}

.social-link.zalo:hover { 
    background-color: #0068ff; 
}

.social-link.telegram:hover { 
    background-color: #2AABEE; 
}

.social-link.phone:hover { 
    background-color: #4CAF50; 
}

.social-link.civitai:hover { 
    background-color: #1a73e8; 
}

.social-link.shakker:hover { 
    background-color: #e6007a; 
}

.social-link.email:hover { 
    background-color: #EA4335; 
}

.social-link.discord:hover { 
    background-color: #5865F2; 
}

.skills-header {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    gap: 0.5rem;
}

.lang-title, .now-title, .journey-title {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    flex-shrink: 0;
}

.skills-title {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    flex-shrink: 0;
}

.now-content { 
    font-size: 0.9rem; 
    color: var(--text-secondary); 
}

.now-content h4 { 
    font-size: 1rem; 
    margin-bottom: 0.5rem; 
    color: var(--text-primary);
}

.skills-tabs {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-start;
    flex-wrap: wrap;
}

.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    min-height: 80px;
    align-content: flex-start;
}

.skill-tab {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--card-border-color);
    color: var(--text-secondary);
    padding: 0.3rem 0.7rem;
    border-radius: 0.5rem;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.skill-tab:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.skill-tab.active {
    background: var(--accent-orange);
    color: white;
    border-color: var(--accent-orange);
}

.skills-list span {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.3rem 0.8rem;
    border-radius: 2rem;
    font-size: 0.8rem;
    animation: fadeInScale 0.3s ease forwards;
}

@keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.lang-list { 
    display: flex; 
    flex-wrap: wrap; 
    gap: 0.5rem;
}

.lang-list span { 
    background: rgba(255, 255, 255, 0.1); 
    padding: 0.3rem 0.8rem; 
    border-radius: 2rem; 
    font-size: 0.8rem;
}

.journey-title i, .now-title i, .skills-title i, .lang-title i  {
    margin-right: 0.5rem;
    color: var(--accent-orange);
}

.journey-steps {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.journey-step {
    display: flex;
    flex-direction: column;
    width: 100%; /* Ensure full width */
    padding: 0.75rem;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 0.75rem;
    border-left: 3px solid var(--accent-orange);
    transition: background-color 0.3s ease;
}

.journey-step:hover {
    background-color: rgba(0, 0, 0, 0.4);
}

.journey-date {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    background-color: rgba(255, 255, 255, 0.05);
    padding: 0.2rem 0.5rem;
    border-radius: 0.5rem;
    min-width: 80px;
    text-align: center;
    transition: color 0.3s ease, background-color 0.3s ease;
}

.journey-role {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-primary);
}

.journey-step.current {
    border-left-color: var(--accent-orange); 
}

.journey-step.current .journey-date {
    color: var(--text-primary);
    background-color: rgba(255, 140, 0, 0.2); 
}

.journey-step-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    cursor: pointer;
    padding-right: 0.5rem; /* Space for the arrow */
    gap: 0.5rem; /* Add gap here */
}

.journey-arrow {
    margin-left: auto;
    transition: transform 0.3s ease;
}

.journey-step.expanded .journey-arrow {
    transform: rotate(180deg);
}

.journey-description {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.5s ease-out, opacity 0.5s ease-out, padding-top 0.5s ease-out, margin-top 0.5s ease-out;
    font-size: 0.9rem;
    color: var(--text-secondary);
    padding-top: 0;
    margin-top: 0;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
}

.journey-step.expanded .journey-description {
    max-height: 1000px; /* Zwiększono, aby zapobiec przycinaniu */
    opacity: 1;
    padding-top: 0.5rem;
    margin-top: 0.5rem;
}

/* Styles for bullet points within journey descriptions */
.journey-description ul {
    list-style-type: disc; /* Ensure it's a dot */
    padding-left: 1.5rem; /* Add indentation for bullets */
    margin-bottom: 0.5rem; /* Space below the list */
    margin-top: 0.5rem; /* Space above the list */
}

.journey-description li {
    margin-bottom: 0.25rem; /* Space between list items */
}

.copy-feedback {
    font-size: 0.8rem;
    color: var(--accent-blue);
    text-align: center;
    margin-top: 0.75rem; 
    opacity: 0;
    transition: opacity 0.3s ease;
    height: 0; 
    overflow: hidden;
}

.copy-feedback.active {
    opacity: 1;
    height: auto; 
}

.profile-cta {
    background: rgba(255,255,255,0.9); 
    color: #000; 
    padding: 0.5rem 1.5rem; 
    border-radius: 2rem; 
    text-decoration: none; 
    font-weight: 600; 
    transition: transform 0.2s;
    flex-shrink: 0; 
    font-size: 0.9rem; 
}

.profile-cta:hover { 
    transform: scale(1.05); 
}

.modal-overlay {
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    background: rgba(0, 0, 0, 0.8);
    display: flex; 
    justify-content: center; 
    align-items: center; 
    z-index: 1000;
    opacity: 0; 
    visibility: hidden; 
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

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

.modal-content {
    max-width: 90%; max-height: 90%; width: 300px; border-radius: 1rem;
    transform: scale(0.9); transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.skills-wrap {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--card-border-color);
    padding: 0.5rem;
    border-radius: 0.75rem;
}

a:focus-visible,
button:focus-visible,
.social-link:focus-visible,
.profile-cta:focus-visible,
.project-link:focus-visible,
.social-link:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px var(--bg-color), 0 0 0 5px var(--accent-orange);
}

@media (max-width: 900px) {
    body {
        padding: 1rem;
        align-items: flex-start;
        overflow-y: auto;
    }

    .bento-grid {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
        row-gap: 0.25rem;
        padding-right: 0;
        padding-left: 0;
        padding-top: 0;
        padding-bottom: 0;
        height: auto;
        max-height: none;
        overflow-y: visible;
    }

    .bento-column.column-left,
    .bento-column.column-right,
    .bento-column.column-tools {
        grid-column: span 1 !important;
        grid-row: auto !important;
        height: auto;
        max-height: none;
        overflow-y: visible;
        padding: 0.4rem;
    }

    .bento-item,
    .card-profile, 
    .card-social-links, 
    .card-now, 
    .card-skills,
    .card-lang, 
    .card-journey, 
    .card-cta {
        grid-column: span 1 !important;
        grid-row: auto !important;
        height: auto;
        max-height: none;
        overflow-y: visible;
        padding: 1.2rem;
    }

    .card-profile { 
        flex-direction: column; 
        align-items: center; 
    }

    .profile-header { 
        flex-direction: column; 
        align-items: center; 
        text-align: center; 
        gap: 1rem; 
    }

    .profile-main-info {
        flex-direction: column; 
        align-items: center;
        text-align: center;
    }

    .profile-bio { 
        min-height: 80px; 
        text-align: center; 
    }
    
    .card-social-links { 
        grid-template-columns: 1fr 1fr 1fr 1fr; 
    } 
    
    .custom-cursor { 
        display: none; 
    }

    body {
        cursor: auto;
    }

    @media (max-width: 500px) {
        .journey-step {
            flex-direction: column;
            align-items: flex-start;
            gap: 0.5rem;
        }

        .journey-date {
            min-width: unset;
            width: fit-content;
        }
    }
}
