:root{                          /*Motyw się nie zmieniał na jasny<ciemny dlatgo uzyłam roota bo tylko w body reagował na tło*/
    --background:#1e1e1e;
    --card:#2d2d2d;
    --text:white;
    --accent:#53d8fb;
}

.light-theme{
    --background:#f3f3f3;
    --card:white;
    --text:#222;
    --accent:#4db8ff;
}


html {
    scroll-behavior: smooth;        /*Płynniejsze scrollowanie*/
}

body {
    background-color: #1a1a1a;
    color: white;
    font-family: Arial, sans-serif;
    margin: 0;
}

header {
    top: 0;
    z-index: 1000;
    background: rgba(26,26,26,0.95);
    backdrop-filter: blur(10px);
    text-align: center;             /*26.06.2026 dodałam sticky Navbar! - Przewijanie*/ 
    padding: 20px;
    transition: 0.5s;
}



section {
    margin: 20px;
    padding: 20px;
    background-color: #2d2d2d;
    border-radius: 10px;
}

nav {
    margin-top: 15px;
}

nav a {
    color: rgb(255, 255, 255);
    text-decoration: none;
    margin: 10px;
    padding: 5px 10px;
    border-radius: 10px;
    background-color:#2d2d2d;
    border-radius: 5px;
    transition: 0.3s;
}

nav a:hover {
    background-color: rgb(24, 31, 34);
}

header {
    text-align: center;
    padding: 30px;
}

section {
    margin: 30px;
    padding: 20px;
   
    border: 1px solid hsl(180, 37%, 32%);
    border-radius: 10px;
}

footer {
   text-align: center;
   margin-top: 50px;
}

.skills {
   display: flex;
   gap: 15px;
   flex-wrap: wrap;

  background-color:#2d2d2d;
  padding: 15px;
  border-radius: 10px;
  font-weight: bold;
}

.skill {
    background-color: #3d3d3d;
    padding: 15px;
    border-radius: 10px;
    font-weight: bold;
}

.projects {
   display: grid;
   grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
   gap: 20px;
}

.project-card {
   background-color: #2d2d2d;
   padding: 20px;
   border-radius: 10px;
   border: 1px solid #444;
}

.hero {
    text-align: center;
    padding: 100px 20px;
}

.hero-button {               /*kolor zmień*/
    display: inline-block;
    margin-top: 20px;
    padding: 15px 30px;
    background-color:#53d8fb;
    color: black;
    text-decoration: none;
    border-radius: 10px;
    font-weight: bold;
}

.hero-button:hover {
    transform: scale(1.05);
}

footer {
    text-align: center;
    margin-top: 50px;
    padding: 20px;
}

.avatar {           /*Może zmienię tą potem świnkę*/
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid #53d8fb;
    margin: 0 auto 20px;
}

#themeButton {
    margin-top: 15px;
    padding: 10px 20px;
    border: none;                 /*kolor przycisku*/
    background-color: #c3ce98;
    cursor: pointer;
    font-weight: bold;
}

.light-mode {   
    background-color: white;
    color: rgb(0, 0, 0);
}

.project-card {
    transition: 0.3s;
}
.project-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 20px rgba(83,216,251,0.25);
}

.skill {
    transition: 0.3s;
}

.skill:hover {
    transform: scale(1.1);
}

.skill-box {
    margin: 25px 0;
}  

.skill-box p {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    font-weight: bold;
}

.bar {
    width: 100%;
    height: 18px;
    background: rgba(255,255,255,0.15);
    border-radius: 20px;
    overflow: hidden;
}


.fill {
    height: 100%;
    border-radius: 20px;
    background: linear-gradient(90deg, #53d8fb, #8b5cf6);
    --target-width: 0;
}

.fill.animate {                     /*Dodałam animacje pasków*/
  animation: fillBar 1.8s ease forwards;
}

.html{
    --target-width: 90%;
}

.css{
     --target-width: 95%;
}

.js{
     --target-width: 80%;
}

.php{
     --target-width: 70%;
}

.sql{
     --target-width: 60%;
}

.cloud{
     --target-width: 55%;
}

@keyframes fillBar {
    from {
        width: 0;
    }
    to {
        width: var(--target-width);
    }
}

.container-flex{
    display: flex;
}

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

.about-text{
    flex:1;
}

.hidden {   /*animacje*/
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s ease;
}

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

nav a.active {
    background:#53d8fb;
    color: black;
}

.project-button {             /*Wygląd przycisku (odnośnik to strony Cavia Os)*/
    display: inline-block;
    margin-top: 15px;
    padding: 10px 18px;

    background-color: #53d8fb;
    color: black;
    text-decoration: none;
    border-radius: 8px;
    font-weight: bold;
    transition: 0.3s;
}

.project-button:hover {
    transform: scale(1.05);
    background-color: orange;
}
   

.socials {                          /*Moje media społecznościowe*/
   display: flex;
   justify-content: center;
   gap: 20px;
   margin-top: 20px;
}

.socials a {
    width:60px;
    height:60px;
    display:flex;
    justify-content:center;
    align-items:center;

    border-radius:50%;
    background:#303030;

    color:white;
    text-decoration:none;

    font-size:26px;
    transition:.35s;
}


.socials a:hover {
   
    transform:translateY(-8px) scale(1.1);
    background:#53d8fb;
    color:black;
    box-shadow:0 0 20px rgba(83,216,251,.6);

}

body.light-mode {                        /*tryb jasny*/
    background-color: #f2f2f2;
    color: #222
}

body.light-mode header {                  /*tryb jasny w header*/
    background-color: #ffffff;
    color: #222;

}
body.light-mode section {              /*tryb jasny w sekcji*/
    background-color: #ffffff;
    color: #222;
    border-color: #53d8fb;
}

body.light-mode .skills {              
    background-color: white;
    color: #222
}
     
body.light-mode nav a {
    background-color: #dddddd;    
    color:#222                    /*czarny-szary*/
}

body.light-mode footer {
    background-color: #ffffff;
    color:#222
}

body.light-mode .project-card {            
    background-color: #ffffff;
    color: #222;
    border: 1px solid #cccccc;
}

body.light-mode .project-card p,
body.light-mode .project-card h3 {
    color: #222;
}

body.light-mode .socials a {
    background-color: #dddddd;
    color: #222;
}

body.light-mode .bar {
    background-color: #dddddd;
}

body.light-mode header {
    background-color: #f5f5f5;
}

footer {                     /*by ładnie zakończenie strony wyglądało*/
    text-align: center;
    padding: 30px;
    margin-top: 40px;
    opacity: 0.8;
}

footer p {                /*perfect*/
    margin: 30px;
}

.avatar {
    transition: 0.3s;
}

.avatar:hover {
    transform: scale(1.05);
    box-shadow: 0 0 25px rgba(83,216,251,0.6);
}

.skills-layout {
    display: flex;
    justify-content: space-between;
    gap: 50px;
    align-items: flex-start;
}

.skill-bars {
    width: 60%;
}

.skills-note {
    width: 40%;
    padding: 25px;
    border-radius: 15px;
    background-color: #303030;
    border: 1px solid #53d8fb;
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 15px 0 0;

    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
}

nav li {
    list-style-type: none;
}


.project-logo {
    display: flex;
    justify-content: center;
    margin: 20px 0;

}

.project-logo img {
    width: 100px;
    height: 100px;
    object-fit: contain;
    border-radius: 20px;
    box-shadow: 0 0 25px rgba(83,216,151,.45);
    transition: .35s;
}

.project-logo img:hover {
    transform: scale(1.08) rotate(5deg);
}

.project-progress {
    margin: 20px 0;
}

.project-progress p {                     /*kod nie należy do mnie użyłam gotowego szablonu*/
    display: flex;
    justify-content: space-between;
    font-weight: bold;
    margin-bottom: 8px;
}

.progress-bar {
    width: 100%;
    height: 14px;
    background: rgba(255,255,255,0.15);
    border-radius: 999px;
    overflow: hidden;
}

.progress-fill {
    width: 75%;
    height: 100%;
    background: linear-gradient(90deg, #53d8fb, #8b5cf6);
    border-radius: 999px;
}

body.light-mode .skills-note {
    background-color: #ffffff;
    color: #222;
    border: 1px solid #53d8fb;
}


@media (max-width: 768px) {
  
    body {
        overflow-x: hidden;
    }

    header {
        padding: 20px 12px;
    }

    header h1 {
        font-size: 26px;
        line-height: 1.2;
    }

    nav ul {
        flex-direction: column;
        gap: 10px;
    }

    nav a {
        display: block;
        margin: 0;
        width: 180px;
        text-align: center;
    }

    #themeButton {
        margin-top: 15px;
        width: 180px;
    }

    section {
        margin: 14px;
        padding: 18px;
    }

    .hero {
        padding: 35px 15px;
    }

    .about {
        flex-direction: column;
        text-align: center;
        gap: 25px;
    }

    .avatar {
        width: 145px;
        height: 145px;
    }

    .about-text h2 {
        font-size: 24px;
    }

    .skills-layout {
    display: flex;
    flex-direction: column;
    gap: 25px;
    align-items: stretch;
    }

  .skill-bars,
  .skills-note {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    }

    .bar {
        max-width: none;
    }

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

    .project-card {
        padding: 20px;
    }

    .project-logo img {
        width: 85px;
        height: 85px;
    }

    .socials {
        flex-wrap: wrap;
        gap: 15px;
    }

    .socials a {
        width: 55px;
        height: 55px;
        font-size: 24px;
    }

    footer p {
        margin: 10px;
    }
}
