@import url('https://fonts.googleapis.com/css2?family=PT+Sans:wght@400;700&display=swap');

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    width: 100vw;
    max-width: 100%;
    overflow-x: hidden; /* Убирает горизонтальный скролл */
}

body {
    height: 100%;
    max-width: 1200px;
    width: 100vw;
    margin: 0;
    min-height: 100vh; /* Минимальная высота равна высоте экрана */
    display: flex;
    flex-direction: column;
    justify-content: space-between;  /* Раздвигает main между header и footer */
    align-items: center;
    text-align: center;
    padding: 20px;
    box-sizing: border-box;
    background-color: #f4ecd8; /* old paper color */
    font-family: 'PT Sans';
    margin: 0 auto; /* Center the content */
    position: relative; /* Ensure positioned elements are relative to the body */
    flex: 1; /* Fill the available space */
}

main {
    flex: 1; /* Занимает всё доступное пространство между header и footer */
    display: flex;
    flex-direction: column;
    justify-content: center; /* Центрирует содержимое */
    align-items: center;
    width: 100%;
    margin-bottom: 80px;
}

header {
    top: 20px;
    left: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: calc(100% - 40px);  /* Adjust width to fit within body padding */
}

footer {
    margin-top: auto; /* Push to the bottom гпт предложил - нужно проверить */
    bottom: 20px;
    left: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: calc(100% - 40px); /* Adjust width to fit within body padding */
}

h1 {
    font-size: 28px;
    font-weight: 600;
    color: #333;
    margin: 20px 0;
}

h2 {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin: 18px 0;
    text-align: center;
}

h3 {
    font-size: 22px;
    font-weight: 600;
    color: #333;
    margin: 20px 0 10px 0;
}

h4 {
    font-size: 18px;
    font-weight: 500;
    color: #333;
    margin: 15px 0 8px 0;
}

.main-info {
    margin: 10px;
    font-size: 24px;
    color: #333333;
    font-weight: 400;
    text-align: justify;
    text-justify: inter-word; /* Равномерное распределение пробелов */
    max-width: 100%;
    word-wrap: break-word;
}

.task-button {
    padding: 15px 30px;
    margin: 10px;
    font-size: 18px;
    font-family: 'PT Sans', sans-serif;
    font-weight: 500;
    color: #333;
    background-color: #fff;
    border: 2px solid #333;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    max-width: 100%;
    word-wrap: break-word;
}

.task-button:hover {
    background-color: #f4ecd8;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

.task-button:active {
    transform: translateY(0);
    box-shadow: none;
}

.task-text {
    text-align: left;
    max-width: 800px;
    margin: 20px auto;
    padding: 20px;
    font-size: 20px;
    color: #333;
    line-height: 1.6;
}

.task-text h3 {
    font-family: 'PT Sans', sans-serif;
    text-align: left;
}

.task-text p {
    margin: 10px 0;
    text-align: justify;
    text-justify: inter-word;
}

.task-text img {
    width: 100%;
    height: auto;
    max-width: 800px;
    margin: 20px auto;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.requirements-list {
    padding-right: 20px;
    padding-left: 40px;
    margin: 10px 0;
}

.requirements-list li {
    margin-bottom: 8px;
    color: #333;
    font-size: 16px;
    line-height: 1.5;
}

.back-arrow {
    width: 100%;
    max-width: 800px;
    margin: 20px auto;
    padding: 10px 0;
    text-align: left;
    color: #333;
    font-family: 'PT Sans', sans-serif;
    font-size: 14px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.back-arrow:hover {
    color: #666;
}

.red-line {
    text-indent: 3em; /* red line */
}

.share-buttons {
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 30px 0;
    padding: 20px;
    width: 100%;
    max-width: 800px;
    justify-content: flex-end;
    font-family: 'PT Sans', sans-serif;
    font-size: 18px;
    color: #333;
    font-weight: 500;
}

.share-buttons .task-button {
    padding: 10px;
    width: 44px;
    height: 44px;
    background-color: #f4ecd8;
    border: 2px solid #333;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.share-buttons .task-button img {
    width: 16px;  /* 1/4 of the original size */
    height: 16px;
    object-fit: contain;
}

.share-buttons .task-button:hover {
    background-color: #e6f3ff;  /* light blue color */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

.share-buttons .task-button:active {
    transform: translateY(0);
    box-shadow: none;
}

.logo {
    width: 180px; /* 1.5 times bigger than the original 100px */
    height: auto; /* Maintain aspect ratio */
}

.about {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 24px;
    line-height: 1.6;
    color: #333;
}

.language-switcher {
    display: flex;
    gap: 16px;
}

.language-switcher a {
    text-decoration: none;
    color: #666;
    font-weight: 500;
    font-size: 15px;
    transition: color 0.2s ease;
}

.language-switcher a:hover {
    color: #333;
}

.footer-links a {
    text-decoration: none;
    color: #666;
    font-weight: 500;
    font-size: 15px;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: #333;
}

.error-page {
    text-align: center;
    padding: 40px 20px;
}

.error-page h2 {
    font-size: 120px; /* 5x bigger than default h2 (24px) */
    font-weight: 600;
    color: #333;
    margin-bottom: 20px;
}

.error-page p {
    font-size: 40px; /* 5x bigger than typical paragraph text */
    color: #333;
    line-height: 1.4;
}



                                                                    /*Form container styling */
#expeditionForm {
    width: 100%;
    max-width: 800px;
    margin: 20px auto;
    padding: 30px;
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* Individual form groups styling */
.form-group {
    text-align: left;
    margin-bottom: 20px;
    padding: 20px;
    background-color: #f4ecd8;
    border-radius: 8px;
}

/* Labels styling */
.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

/* Input fields styling */
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="date"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 2px solid #333;
    border-radius: 4px;
    font-family: 'PT Sans', sans-serif;
    font-size: 16px;
}

/* Range input styling */
.form-group input[type="range"] {
    /* width: 400px; */
    width: 100%;
    max-width: 100%;
    margin: 10px 0;
}

/* Checkbox and radio groups */
.form-group input[type="checkbox"],
.form-group input[type="radio"] {
    margin-right: 8px;
}

.form-group input[type="checkbox"] + label,
.form-group input[type="radio"] + label {
    display: inline-block;
    margin-bottom: 8px;
}

/* Submit and reset buttons */
button[type="submit"],
button[type="reset"] {
    padding: 12px 24px;
    margin: 10px;
    font-size: 16px;
    font-family: 'PT Sans', sans-serif;
    font-weight: 500;
    color: #333;
    background-color: #fff;
    border: 2px solid #333;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

button[type="submit"]:hover,
button[type="reset"]:hover {
    background-color: #f4ecd8;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}



                                                                /* MOBILE ADOPTIONS */
@media screen and (max-width: 1200px) {
    body {
        padding: 15px;
    }
}

@media screen and (max-width: 768px) {
    body {
        padding: 10px;
    }

    main {
        margin-bottom: 30px;
    }
    
    h1 {
        font-size: 24px;
    }
    
    h2 {
        font-size: 22px;
    }
    
    h3 {
        font-size: 20px;
    }
    
    h4 {
        font-size: 16px;
    }
    
    .main-info {
        font-size: 20px;
    }

    .task-button {
        padding: 12px 24px;
        font-size: 16px;
    }

    .task-text {
        font-size: 18px;
        padding: 15px;
    }
    
    .task-text h3 {
        font-size: 20px;
        font-family: 'PT Sans', sans-serif;
    }

    .task-text img {
        margin: 15px auto;
    }

    .requirements-list {
        padding-right: 15px;
        padding-left: 30px;
    }
    
    .requirements-list li {
        font-size: 14px;
    }

    .back-arrow {
        font-size: 12px;
        margin: 15px auto;
    }

    .error-page h2 {
        font-size: 90px;
    }
    
    .error-page p {
        font-size: 30px;
    }

    .share-buttons {
        font-size: 16px;
        padding: 15px;
        gap: 12px;
    }
    
    .share-buttons .task-button {
        width: 40px;
        height: 40px;
    }
    
    .share-buttons .task-button img {
        width: 14px;
        height: 14px;
    }

    #expeditionForm {
        padding: 20px;
    }

    .form-group {
        padding: 15px;
    }

    .form-group input[type="range"] {
        /* width: 300px; */
        width: 100%;
    }

}

@media screen and (max-width: 480px) {
    body {
        padding: 5px;
    }

    main {
        margin-bottom: 20px;
    }
    
    h1 {
        font-size: 20px;
    }
    
    h2 {
        font-size: 18px;
    }
    
    h3 {
        font-size: 16px;
    }
    
    h4 {
        font-size: 14px;
    }

    .main-info {
        font-size: 18px;
    }

    .task-button {
        padding: 10px 20px;
        font-size: 14px;
    }

    .task-text {
        font-size: 16px;
        padding: 10px;
    }
    
    .task-text h3 {
        font-size: 18px;
    }

    .task-text img {
        margin: 10px auto;
        border-radius: 4px;
    }

    .requirements-list {
        padding-right: 10px;
        padding-left: 20px;
    }
    
    .requirements-list li {
        font-size: 13px;
    }

    .back-arrow {
        font-size: 10px;
        margin: 10px auto;
        padding: 8px 0;
    }

    .error-page h2 {
        font-size: 60px;
    }
    
    .error-page p {
        font-size: 24px;
    }

    .share-buttons {
        font-size: 14px;
        padding: 10px;
        gap: 10px;
    }
    
    .share-buttons .task-button {
        width: 36px;
        height: 36px;
    }
    
    .share-buttons .task-button img {
        width: 12px;
        height: 12px;
    }

    #expeditionForm {
        padding: 15px;
    }

    .form-group {
        padding: 10px;
    }

    .form-group input[type="range"] {
        width: 100%;
    }

}