/************************* == Fonts == *************************/

@font-face {
    font-family: Block;
    src: url(../assets/fonts/BabyBlocks-OGv8.ttf);
    font-weight: normal;
}

@font-face {
    font-family: Roboto;
    src: url(../assets/fonts/RobotoMono-Regular.ttf);
    font-weight: normal;
}

/************************* == CSS Reset == *************************/

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

li {
    list-style: none;
}

a {
    text-decoration: none;
}

/************************* == Global == *************************/

:root {

    /* dark mode */
    --black: #1b1a1d;
    --red: #ff5757;
    --grey: #9a9a9c;
    --white: #f6f5f8;
    --blue: #0270AD;
    --tooltipBlack: #000000D9;
    --tooltipWhite: #fff;

    /* light mode */    
    --darkWhite: #E4DCCF;
    --pYellow: #BD9D3D;
    --pblack: #504E70;
    --text-black-900: #302e4d;
    --text-black-700: #504e70;
    --bg-color: #faf7f0;
    --tooltipBlack: #000000D9;
    --tooltipWhite: #fff;
    
}

.light {
    --bg: var(--bg-color);
    --text: var(--text-black-900);
    --h2Header: var(--pYellow);
    --logo: var(--text-black-900);
    --ref: var(--blue);
    --shadow: var(--darkWhite);
    --navItem: var(--text-black-900);
    --hoverText: var(--pYellow);
    --hamburger: var(--pYellow);
    --border: var(--text-black-700);
    --logoSpan: var(--pYellow);
    --tooltipBackground: var(--tooltipBlack);
    --toolTipText: var(--tooltipWhite);
}

.dark {
    --bg: var(--black);
    --text: var(--grey);
    --h2Header: var(--red);
    --logo: var(--white);
    --ref: var(--blue);
    --shadow: var(--black);
    --navItem: var(--grey);
    --hoverText: var(--red);
    --hamburger: var(--red);
    --border: var(--grey);
    --logoSpan: var(--h2Header);
    --tooltipBackground: var(--tooltipBlack);
    --toolTipText: var(--tooltipWhite);
}

html {
    font-size: 60%;
    font-family: 'Roboto', 'Verdana';
    background: var(--bg);
    transition: background 500ms ease-in-out, color 700ms ease-in-out;
}

body {
    min-height: 100vh;
    padding-top: 70px;
    width: 70%;
    margin: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--bg);
    max-width: 1350px;
    transition: background 500ms ease-in-out, color 700ms ease-in-out;
}

/************************* == Navigation == *************************/

.application-header {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--bg);
    z-index: 10;
    transition: background 500ms ease-in-out, color 700ms ease-in-out;
}

.application-navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 70%;
    max-width: 1350px;
    margin: auto;
    height: 70px;
    background: var(--bg);
    transition: background 500ms ease-in-out, color 700ms ease-in-out;
}

.nav-logo {
    color: var(--logo);
    font-size: 1.4rem;
    transition: color 700ms ease-in-out;
}

.nav-logo h1 span {
    color: var(--logoSpan);
    transition: color 700ms ease-in-out;
}

.nav-menu {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-item {
    margin-left: 5rem;
}

.nav-link {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--navItem);
    transition: color 700ms;
}

.nav-link:hover {
    color: var(--hoverText);
    transition: color 700ms;
}

.bar-menu {
    display: none;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    -webkit-transition: all 0.3s ease-in-out, color 700ms ease-in-out;
    transition: all 0.3s ease-in-out, color 700ms ease-in-out;
    background: var(--hamburger);
    border-radius: 10px;
}

.lang-btn {
    font-family: 'Roboto', 'Verdana';
    background: none;
    border: none;
    font-weight: bold;
    cursor: pointer;
    padding: 0px 2px;
    font-size: 1.8rem;
    position: relative;
    z-index: 1;
    color: var(--navItem);
    transition: color 700ms;;
}

.lang-btn:hover,
.lang-btn:focus {
    color: var(--hoverText);
}

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

.lang-divider {
    font-family: 'Roboto', 'Verdana';
    font-size: 1.8rem;
    user-select: none;
    color: var(--navItem);
    transition: color 700ms;
}

/************************* == Footer == *************************/

.application-footer {
    margin-top: auto;
    text-align: center;
    height: 70px;
    color: var(--logo);
    width: 100%;
    padding: 30px 0 0 0;
    transition: color 700ms ease-in-out;
}

.application-footer p {
    font-size: 1.2rem;
}

/************************* == Index page == *************************/

/************************* == Index page header == *************************/

.index-header {
    display: flex;
    justify-content: center;
}

.index-header h2 {
    margin-top: 4rem;
    background-image: url(../assets/images/photo.webp);
    font-size: 7rem;
    background-size: cover;
    object-position: center;
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    font-family: 'Block', 'Verdana';
    width: fit-content;
    margin-bottom: 6rem;
}

/************************* == Index page section == *************************/

.index-section {
    border: 1px solid var(--border);
    border-radius: 2px;
    padding: 12px;
    box-shadow: 0 0 0 1px var(--border);
    transition: box-shadow 700ms ease-in-out, border 700ms ease-in-out;
}

.index-section h2 {
    font-family: 'Block', 'Verdana';
    font-size: 3rem;
    color: var(--h2Header);
    margin-bottom: 2rem;
    transition: color 700ms ease-in-out;
}

.index-section p {
    color: var(--text);
    font-size: 1.5rem;
    text-align: justify;
    line-height: 1.5;
    transition: color 700ms ease-in-out;
}

.profile p {
    padding: 0 10px;
}

/************************* == Index page skills == *************************/

.index-section .skills {
    display: flex;
    gap: 2.5rem;
    flex-wrap: wrap;
    align-items: center;
    flex-direction: column;
}

.index-section .skills .skill {
    display: flex;
    gap: 1.7rem;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
}

.loading {
    display: inline-block;
}

.loading p {
    color: var(--text);
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    animation: typing 5s steps(11) infinite;
    transition: color 700ms ease-in-out;
}

@keyframes typing {
    0% {
        width: 0
    }

    50% {
        width: 100%
    }
}

.tooltip {
  position: relative;
  display: inline-block;
  cursor: pointer;
  overflow: visible;
}

.tooltip-text {
  position: absolute;
  top: calc(100% + 3px);
  left: 50%;
  transform: translateX(-80%);
  background: var(--tooltipBackground);
  color: var(--toolTipText);
  padding: 4px 8px;
  border-radius: 4px;
  white-space: nowrap;
  font-size: 12px;
  z-index: 100;
  font-family: 'Roboto', 'Verdana';

  opacity: 0;
  pointer-events: none;
  transition: transform 0.5s ease, opacity 0.5s ease;
}

.tooltip:hover .tooltip-text {
  opacity: 1;
  transform: translateX(-50%) translateY(2px);
  pointer-events: auto;
}

.index-section .skill img {
    position: relative;
    cursor: pointer;
    width: 80%;
    transition: filter 0.7s ease-in-out;
}

.dark .index-section img {
    filter: grayscale(100%);
    transition: filter 0.7s ease-in-out;
}

.light .index-section img {
    filter: none;
    transition: filter 0.7s ease-in-out;
}

.index-section img:hover {
    filter: none;
}

/************************* == Index page accordion == *************************/

.index-section .accordion-content {
    margin: 10px 0;
    overflow: hidden;
}

.accordion-content.open {
    padding-bottom: 10px;
}

.accordion-content header {
    display: flex;
    align-items: center;
    min-height: 50px;
    justify-content: space-between;
    padding: 0 10px;
    font-size: 1.7rem;
    color: var(--text);
    cursor: pointer;
    transition: all 0.2s linear;
}

.accordion-content.open header {
    min-height: 50px;
    color: var(--h2Header);
}

.accordion-content .dot {
    transition: all 0.2s linear;
}

.accordion-content.open .dot {
    color: var(--h2Header);
}

.accordion-content .description {
    padding: 0 15px;
    height: 0;
    transition: all 0.2s linear;
}

.accordion-content header .plus {
    font-size: 2.1rem;
}

/************************* == Index page contact == *************************/

.contact a {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0 4px;
  cursor: default;
  color: var(--text);
  text-decoration: none;
  transition: color 700ms ease-in-out;
}

.contact a img {
    width: 4rem;
    transition: filter 0.7s ease-in-out;
}

.contact a img:hover,
.contact a span:hover {
  filter: brightness(1.2);
  color: var(--ref);
  cursor: pointer;
}

.index-section a {
    text-decoration: none;
    color: var(--text);
    transition: color 700ms ease-in-out;
}

/************************* == Portfolio page == *************************/

.article-portfolio {
    display: flex;
    justify-content: center;
    width: 100%;
    gap: 5rem;
    padding: 0 10px;
}

.section-portfolio {
    filter: contrast(1);
    width: 70%;
    border-radius: 2px;
    display: flex;
    flex-direction: column;
    border-radius: 10px;
}

.section-portfolio-img {
    width: 30%;
    height: fit-content;
    border-radius: 10px;
}

.project-preview-img {
  width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
  max-height: 100%;
  border-radius: 10px;
  transition: filter 0.7s ease-in-out;
}

.dark .project-preview-img {
  filter: grayscale(100%);
}

.light .project-preview-img {
  filter: none;
}

.project-preview-img:hover {
  filter: brightness(1.1);
}

.portfolio-buttons {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  margin-top: 1rem;
}

.tooltip {
  position: relative;
  display: inline-block;
  cursor: pointer;
}

.tooltip-text.right {
  position: absolute;
  top: 50%;
  left: 115%;
  transform: translateY(-50%) translateX(-10px);
  background: var(--tooltipBackground);
  color: var(--toolTipText);
  padding: 5px 10px;
  border-radius: 4px;
  white-space: nowrap;
  font-size: 12px;
  font-family: 'Roboto', 'Verdana';
  opacity: 0;
  pointer-events: none;
  transition: transform 0.5s ease, opacity 0.5s ease;
  z-index: 999;
}

.tooltip:hover .tooltip-text.right {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
  pointer-events: auto;
}

.section-portfolio h2 {
    font-size: 3rem;
    color: var(--h2Header);
    margin-bottom: 2rem;
}

.section-portfolio h3 {
    font-size: 2rem;
    color: var(--h2Header);
    margin-bottom: 2rem;
    transition: color 700ms ease-in-out;
}

.section-portfolio .portfolio-lang {
    width: 35px;
    margin-bottom: 1rem;
}

.section-portfolio p {
    font-size: 1.5rem;
    color: var(--text);
    margin-bottom: 2rem;
    line-height: 1.5;
    text-align: justify;
}

.section-portfolio a {
    background: var(--h2Header);
    padding: 8px;
    border-radius: 5px;
    font-size: 1.5rem;
    color: var(--white);
    transition: background 500ms ease-in-out, color 700ms ease-in-out;
}

.section-portfolio a:hover {
    filter: brightness(110%);
}

.article-portfolio .mobile-img {
    display: none;
}

.section-portfolio span {
    font-family: 'Roboto', 'Verdana';
    font-weight: 500;
    color: var(--text);
    font-size: 10px;
    transition: color 700ms ease-in-out;
}

.portfolio-separator {
    width: 100%;
    margin-bottom: 2rem;
    border: 1px solid var(--border);
    transition: border 700ms ease-in-out;
}

/************************* == Scroll to top button == *************************/

#arrow {
    display: none;
    position: fixed;
    bottom: 3%;
    right: 3%;
    width: 30px;
    height: 30px;
    border: 2px solid;
    border-radius: 4px;
    color: var(--h2Header);
    background: var(--bg);
    transition: left 0.4s ease;
    transition: background 500ms ease-in-out, color 700ms ease-in-out;
}
  
#arrow:hover {
    cursor: pointer;
}

#arrow::after,
#arrow::before {
    content: "";
    display: block;
    box-sizing: border-box;
    position: absolute;
    top: 8px;
    color: var(--h2Header);
    transition: background 500ms ease-in-out, color 700ms ease-in-out;
}

#arrow::after {
    width: 6px;
    height: 6px;
    border-top: 2px solid;
    border-left: 2px solid;
    transform: rotate(45deg);
    left: 10px;
    color: var(--h2Header);
    transition: background 500ms ease-in-out, color 700ms ease-in-out;
    }

#arrow::before {
    width: 2px;
    height: 10px;
    left: 12px;
    background-color: var(--h2Header);
    transition: background 500ms ease-in-out, color 700ms ease-in-out;
}

#arrow.open {
    left: 160px;
}

/************************* == Light Dark button == *************************/

label {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
}

input {
    position: absolute;
    opacity: 0;
}

.sun {
    position: absolute;
    font-size: 2.5rem;
    color: var(--pblack);
    filter: drop-shadow(0 0 2px rgba(0, 0, 0, .5));
    z-index: 5000;
    transform: scale(0);
    transition: 1s ease;
}

input:checked~.sun {
    transition-delay: .5s;
    transform: scale(1) rotate(360deg);
}

.moon {
    font-size: 2.5rem;
    color: var(--grey);
    filter: drop-shadow(0 0 2px rgba(0, 0, 0, .5));
    z-index: 5000;
    color: var(--pblack);
    transition: 1s ease;
    transition-delay: .5s;
}

input:checked~.moon {
    transition-delay: 0s;
    transform: rotate(360deg) scale(0);
}

.toggle {
    position: absolute;
    display: block;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    box-shadow: 
        inset 0 8px 60px rgba(0, 0, 0, .1),
        inset 0 8px 8px rgba(0, 0, 0, .1),
        inset 0 -4px 4px rgba(0, 0, 0, .1);
        z-index: 4999;
        transition: 1s;
}

input:checked~.toggle {
    background: #f8f8f8;
}

.light-dark-button {
    width: 100%;
    display: flex;
    justify-content: flex-end;
}

/************************* == Breakpoints == *************************/

@media all and (min-width: 2700px) {

    html {
        font-size: 80%;
    }

    body {
        width: 70%;
        max-width: 1800px;
    }
    
    .application-navbar {
        width: 70%;
        max-width: 1800px;
    }

    .index-section .skill img {
        width: 70px;
    }

    .contact img {
        width: 55px;
    }

    /************************* == Project page == *************************/

    .article-portfolio {
        width: 1800px;
    }

    .article-portfolio {
        display: flex;
        justify-content: center;
        width: 100%;
        gap: 1rem;
        padding: 0 10px;
    }

    .section-portfolio {
        filter: contrast(1);
        width: 70%;
        border-radius: 2px;
        display: flex;
        flex-direction: column;
        border-radius: 10px;
    }

    .section-portfolio-img {
        width: 30%;
        height: 100%;
        border-radius: 10px;
        display: flex;
        flex-direction: row-reverse;
    }

    .project-preview-img {
        width: 80%;
        height: auto;
        object-fit: contain;
        border-radius: 10px;
        transition: filter 0.7s ease-in-out;
    }
}


@media all and (min-width: 2100px) and (max-width: 2700px) {

    html {
        font-size: 70%;
    }

    body {
        width: 70%;
        max-width: 1500px;
    }
    
    .application-navbar {
        width: 70%;
        max-width: 1500px;
    }

    .index-section .skill img {
        width: 60px;
    }

    .contact img {
        width: 45px;
    }

    /************************* == Project page == *************************/

    .application-navbar {
        width: 1500px;
    }

    .article-portfolio {
        width: 1500px;
    }

    .article-portfolio {
        display: flex;
        justify-content: center;
        width: 100%;
        gap: 1rem;
        padding: 0 10px;
    }

    .section-portfolio {
        filter: contrast(1);
        width: 70%;
        border-radius: 2px;
        display: flex;
        flex-direction: column;
        border-radius: 10px;
    }

    .section-portfolio-img {
        width: 30%;
        height: 100%;
        border-radius: 10px;
        display: flex;
        flex-direction: row-reverse;
    }

    .project-preview-img {
        width: 80%;
        height: auto;
        object-fit: contain;
        border-radius: 10px;
        transition: filter 0.7s ease-in-out;
    }
}

@media all and (min-width: 1700px) and (max-width: 2099px) {

    /************************* == Project page == *************************/

    .application-navbar {
        width: 1350px;
    }

    .article-portfolio {
        width: 1350px;
    }

    .section-portfolio-img {
        width: 50%;
        height: fit-content;
    }

    .article-portfolio {
        display: flex;
        justify-content: center;
        width: 100%;
        gap: 1rem;
        padding: 0 10px;
    }

    .section-portfolio {
        filter: contrast(1);
        width: 70%;
        border-radius: 2px;
        display: flex;
        flex-direction: column;
        border-radius: 10px;
    }

    .section-portfolio-img {
        width: 30%;
        height: 100%;
        border-radius: 10px;
        display: flex;
        flex-direction: row-reverse;
    }

    .project-preview-img {
        width: 80%;
        height: auto;
        object-fit: contain;
        border-radius: 10px;
        transition: filter 0.7s ease-in-out;
    }
}


@media all and (max-width: 1450px) {

    /************************* == Project page == *************************/

    .application-navbar {
        width: 1000px;
    }

    .article-portfolio {
        width: 1000px;
        gap: 5rem;
    }

    .section-portfolio-img {
        width: 50%;
        height: fit-content;
    }
}

@media all and (max-width: 1205px) {

    .index-section .skills {
        flex-direction: column;
    }

    .index-section .skills .skill {
        justify-content: center;

    }
}

@media all and (max-width: 1060px) {

    .application-navbar {
        width: 830px;
    }

    .article-portfolio {
        width: 830px;
    }

    .section-portfolio-img {
        width: 50%;
        height: fit-content;
    }
}

@media all and (max-width: 885px) {

    .application-navbar {
        width: 70%;
    }

    .nav-menu {
        position: fixed;
        left: 100%;
        top: 8rem;
        flex-direction: column;
        background-color: var(--bg);
        border: 3px solid var(--h2Header);
        width: 29%;
        border-radius: 10px 0px 0px 10px;
        text-align: center;
        transition: 0.4s, background 500ms ease-in-out, color 700ms ease-in-out;
    }

    .nav-menu.active {
        left: 72%;
    }

    .nav-item {
        margin: 1.8rem 0;
    }

    .nav-link {
        color: var(--text);
    }

    .bar-menu {
        display: block;
        cursor: pointer;
    }

    /************************* == Icon menu navigation == *************************/

    .bar-menu.active .bar:nth-child(2) {
        opacity: 0;
    }

    .bar-menu.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .bar-menu.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .separator {
        width: 10%; /* šířka čárky */
        border-top: 1px solid var(--border); /* barva a styl čárky */
        margin: 5px 0; /* okraje nad a pod čárkou */
    }

    .index-header h2 {
        font-size: 6rem;
    }

    .index-section h2 {
        font-size: 2.6rem;
        margin-bottom: 1.8rem;
    }

    .index-section .skill img {
        width: 54px;
    }

    .index-section img {
        filter: grayscale(0%);
    }

    .section-portfolio-img {
        width: 100%;
        height: fit-content;
    }

    /************************* == Portfolio page == *************************/

    .article-portfolio {
        width: 100%;
        flex-direction: column;
        display: block;
        height: 100%;
    }

    .section-portfolio {
        width: 100%;
        padding: 0;
        margin-bottom: 2rem;
    }

    .section-portfolio h2 {
        font-size: 2.6rem;
        margin-bottom: 1.8rem;
    }
}

@media all and (max-width: 748px) {

    body {
        width: 90%;
    }

    .application-navbar {
        width: 90%;
    }  

    .nav-menu {
        border: 2px solid var(--h2Header);
        width: 50%;
    }

    .nav-menu.active {
        left: 51%;
    }

    .index-header h2 {
        font-size: 5rem;
        margin-top: 3rem;
        margin-bottom: 5rem;
    }

    .index-section .skill img {
        width: 35px;
    }

    .section-portfolio h3 {
        font-size: 1.7rem;
        margin-bottom: 1rem;
    }
}

@media all and (max-width: 608px) {

    .index-header h2 {
        font-size: 4rem;
        margin-top: 2rem;
        margin-bottom: 4rem;
    }

    .application-footer {
        margin-top: auto;
        height: 55px;
        padding: 18px 0 0 0;
    }

    .application-footer p {
        font-size: 1.2rem;
    }

    .index-section h2 {
        font-size: 2.3rem;
        margin-bottom: 1.4rem;
    }

    .index-section p {
        font-size: 1.3rem;
    }

    .accordion-content header {
        font-size: 1.6rem;
        min-height: 35px;
    }

    .accordion-content.open header {
        min-height: 35px;
    }

    /************************* == Project page == *************************/

    .section-portfolio h2 {
        font-size: 2.3rem;
        margin-bottom: 1.4rem;
    }

    .section-portfolio p {
        font-size: 1.5rem;
    }

    .section-portfolio a {
        padding: 6px;
        font-size: 1.5rem;
    }
}

@media all and (max-width: 450px) {
/*
    .nav-menu {
        display: block;
    }
*/
    .nav-logo {
        font-size: 1.3rem;
    }

    .nav-link {
        font-size: 1.6rem;
    }

    .application-footer {
        margin-top: auto;
        height: 40px;
        padding: 13px 0 0 0;
    }

    .application-footer p {
        font-size: 1.2rem;
    }

    .index-header h2 {
        font-size: 3rem;
        margin-top: 10px;
        margin-bottom: 3rem;
    }

    .index-section p {
        font-size: 1.4rem;
    }

    .profile p {
        padding: 0 5px;
    }

    .index-section .skill img {
        width: 35px;
    }

    .accordion-content header {
        padding: 0 5px;
        font-size: 1.5rem;
    }

    .accordion-content .description {
        padding: 0 10px;
    }

    .contact a {
        padding: 0 5px;
    }

    .contact a img {
        width: 3.5rem;
    }

    /************************* == Project page == *************************/

    .article-portfolio {
        margin-bottom: 0rem;
        padding: 0 5px;
    }

    .section-portfolio .portfolio-lang {
        width: 30px;
    }

    .section-portfolio p {
        font-size: 1.4rem;
    }

    .section-portfolio a {
        padding: 5px;
        font-size: 1.4rem;
    }
}

/********************************************/