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

:root {
    --font-family: 'Karla', sans-serif;
    --green-200: hsl(148, 38%, 91%);
    --green-600: hsl(169, 82%, 27%);
    --red: hsl(0, 66%, 54%);
    --white: hsl(0, 0%, 100%);
    --grey-500: hsl(186, 15%, 59%);
    --grey-900: hsl(187, 24%, 22%);
}


a {
    text-decoration: none;
    color: var(--green-600);
}

@font-face {
    font-family: 'Karla';
    src: url('./fonts/static/Karla-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: 'Karla';
    src: url('./fonts/static/Karla-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
}


body {
    background-color: var(--green-200);
    font-family: var(--font-family);
    font-size: 1rem;
    font-weight: 400;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 1.5rem;
}

h1 {
    font-family: var(--font-family);
    font-size: 1.70rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--grey-900);
}

main {
    width: 100%;
    max-width: 730px;
}

.container {
    background-color: var(--white);
    padding: 2.5rem;
    border-radius: 0.75rem;
    position: relative;
}

.name_form {
    display: flex;
    gap: 1rem;
    width: 100%;
    margin-bottom: 1rem;
}

.query-fieldset {
    border: none;
    margin-bottom: 1rem;
    margin-top: 1rem;

}

.query-fieldset legend {
    margin-bottom: 0.5rem;
    color: var(--grey-900);
}

.query-row {
    display: flex;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.query-type-options {
    display: flex;
    flex: 1;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border: 1px solid var(--grey-500);
    border-radius: 0.5rem;
    cursor: pointer;
}

.query-type-options label {
    margin-bottom: 0;
    cursor: pointer;
    display: inline;
    width: auto;
}

input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border: 1px solid var(--grey-500);
    border-radius: 50%;
    cursor: pointer;
    background-color: var(--white);
    flex-shrink: 0;
}

input[type="radio"]:checked {
    border: none;
    background-image: url('./images/icon-radio-selected.svg');
    background-repeat: no-repeat;
    background-position: center;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--grey-900);
    width: 100%;
}

textarea {
    resize: vertical;
    min-height: 100px;
}

input[type="text"],
input[type="email"],
textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--grey-500);
    border-radius: 0.5rem;
    font-family: var(--font-family);
}

.consent-field {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1rem;
}

input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border: 1px solid var(--grey-500);
    border-radius: 2px;
    cursor: pointer;
    background-color: var(--white);
    flex-shrink: 0;
}

input[type="checkbox"]:checked {
    border: none;
    background-image: url('./images/icon-checkbox-check.svg');
    background-repeat: no-repeat;
    background-position: center;
}

.consent-field label {
    margin-bottom: 0;
    cursor: pointer;
    display: inline;
    width: auto;
}

.error-message-name,
.error-message-email,
.error-message-consent,
.error-message-query-type,
.error-message {
    color: var(--red);
    font-size: 0.75rem;
    margin-bottom: 0.5rem;
    margin-top: 0.5rem;
}


button {
    background-color: var(--green-600);
    color: var(--white);
    border: none;
    cursor: pointer;
    margin-top: 1rem;
    padding: 1rem;
    border-radius: 0.5rem;
    font-family: var(--font-family);
    font-weight: 700;
    font-size: 1rem;
    width: 100%;
}

.submitted-message {
    background-color: var(--green-600);
    color: var(--white);
    top: 0%;
    left: 50%;
    transform: translate(-50%, -50%);
    position: absolute;
    padding: 1rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: max-content;
    display: none;
}


.footer {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 1rem;
    font-size: 0.875rem;
    color: var(--grey-900);
}