/* NovaTrans — static site styles */

@font-face {
    font-family: 'antoniobold';
    src: url('../fonts/antonio-bold-pw.woff2') format('woff2');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'antoniolight';
    src: url('../fonts/antonio-light-pw.woff2') format('woff2');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'open_sanscondensed_light';
    src: url('../fonts/opensans-condlight-pw.woff2') format('woff2');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

:root {
    --orange: #fe5b10;
    --blue: #5189ba;
    --page: #f8f8f8;
    --text: #333;
    --muted: #555;
    --heading: #4d4d4d;
    --form-bg: #e6f4ff;
    --form-header: #fee183;
    --link: #337ab7;
    --link-hover: #23527c;
    --body-font: open_sanscondensed_light, 'Arial Narrow', sans-serif;
}

*, *::before, *::after {
    box-sizing: border-box;
}

[hidden] {
    display: none !important;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--page);
    color: var(--text);
    font: 14pt/1.42857 var(--body-font);
}

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

a:hover, a:focus {
    color: var(--link-hover);
    text-decoration: underline;
}

h1, h2, h3 {
    font-weight: 500;
    line-height: 1.1;
}

h2 {
    font-size: 24px;
    margin: 20px 0 10px;
}

h3 {
    font-size: 20px;
    margin: 20px 0 10px;
}

p {
    margin: 0 0 10px;
}

ul {
    margin: 0 0 10px;
}

.wrap {
    max-width: 1000px;
    margin: 0 auto;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

/* ---------- Header ---------- */

.site-header {
    background: var(--orange);
    padding: 15px 10px;
    min-height: 130px;
    border-bottom: 1px solid var(--page);
}

.site-header .wrap {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}

.site-header h1 {
    margin: 0;
    padding: 20px 0 0 120px;
    min-height: 100px;
    background: url('../img/logo_website.gif') no-repeat left center;
    color: var(--page);
    font-family: antoniobold, 'Arial Narrow', sans-serif;
    font-size: 2.1em;
    font-weight: normal;
}

.site-header h1 small {
    display: block;
    color: var(--page);
    font-family: antoniolight, 'Arial Narrow', sans-serif;
    font-size: 0.48em;
}

.header-nav {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
    margin-top: 3px;
}

.header-nav .btn {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 160px;
    padding: 6px 12px;
    border-radius: 4px;
    background: var(--page);
    color: var(--text);
    font-size: 14pt;
    line-height: 1.42857;
    cursor: pointer;
}

.header-nav .btn:hover, .header-nav .btn:focus {
    background: #e6e6e6;
    color: var(--text);
    text-decoration: none;
}

.header-nav .btn svg {
    width: 0.9em;
    height: 0.9em;
    flex: none;
    fill: currentColor;
}

.language {
    position: relative;
}

.language summary {
    list-style: none;
}

.language summary::-webkit-details-marker {
    display: none;
}

.language .caret {
    margin-left: auto;
    border-top: 4px solid;
    border-right: 4px solid transparent;
    border-left: 4px solid transparent;
}

.language ul {
    position: absolute;
    top: 100%;
    right: 0;
    z-index: 1000;
    min-width: 160px;
    margin: 2px 0 0;
    padding: 5px 0;
    list-style: none;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: 4px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175);
}

.language li a {
    display: block;
    padding: 3px 20px;
    color: var(--text);
    white-space: nowrap;
}

.language li a:hover, .language li a:focus {
    background: #f5f5f5;
    color: #262626;
    text-decoration: none;
}

.language li a[aria-current="page"] {
    background: #e8e8e8;
}

/* ---------- Services slider ---------- */

main {
    border-top: 10px solid var(--blue);
    padding-bottom: 40px;
}

.services {
    position: relative;
    padding: 15px;
    margin-bottom: 10px;
}

/* The radio buttons drive the slider; they stay focusable for keyboard users. */
.services > input, .contact > input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.pager {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 150px;
    padding: 5px 0 15px;
}

.pager label {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 10%;
    min-height: 116px;
    cursor: pointer;
}

.pager img {
    width: 80%;
    height: auto;
    border: 5px solid transparent;
    border-radius: 3px;
    transition: width 0.5s;
}

/* Tooltip with the service name */
.pager label::after {
    content: attr(data-tip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 3px 8px;
    border-radius: 4px;
    background: #000;
    color: #fff;
    font: 12px/1.42857 'Helvetica Neue', Helvetica, Arial, sans-serif;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s;
}

.pager label:hover::after {
    opacity: 0.9;
}

#service-0:checked ~ .pager [for="service-0"] img,
#service-1:checked ~ .pager [for="service-1"] img,
#service-2:checked ~ .pager [for="service-2"] img,
#service-3:checked ~ .pager [for="service-3"] img,
#service-4:checked ~ .pager [for="service-4"] img,
#service-5:checked ~ .pager [for="service-5"] img,
#service-6:checked ~ .pager [for="service-6"] img {
    width: 100%;
}

#service-0:focus-visible ~ .pager [for="service-0"] img,
#service-1:focus-visible ~ .pager [for="service-1"] img,
#service-2:focus-visible ~ .pager [for="service-2"] img,
#service-3:focus-visible ~ .pager [for="service-3"] img,
#service-4:focus-visible ~ .pager [for="service-4"] img,
#service-5:focus-visible ~ .pager [for="service-5"] img,
#service-6:focus-visible ~ .pager [for="service-6"] img {
    border-color: var(--blue);
}

/* All slides share one grid cell, so the box keeps the height of the tallest one. */
.slides {
    display: grid;
}

.slide {
    grid-area: 1 / 1;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.5s, visibility 0.5s;
}

#service-0:checked ~ .slides .slide:nth-child(1),
#service-1:checked ~ .slides .slide:nth-child(2),
#service-2:checked ~ .slides .slide:nth-child(3),
#service-3:checked ~ .slides .slide:nth-child(4),
#service-4:checked ~ .slides .slide:nth-child(5),
#service-5:checked ~ .slides .slide:nth-child(6),
#service-6:checked ~ .slides .slide:nth-child(7) {
    display: block;
    visibility: visible;
    opacity: 1;
}

/* ---------- Contact forms ---------- */

.contact {
    position: relative;
    max-width: 1010px;
    margin: 0 auto;
    padding: 5px;
    background:
        url('../img/contact_form_border_v.gif') left top repeat-y,
        url('../img/contact_form_border_v.gif') right top repeat-y,
        url('../img/contact_form_border.gif') left top repeat-x,
        url('../img/contact_form_border.gif') left bottom repeat-x,
        var(--form-bg);
}

.form-header {
    padding: 20px 10px 0;
    background: var(--form-header);
    color: var(--heading);
    text-shadow: 1px 1px 0 #fff;
}

.form-header .wrap {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-end;
}

.form-header h2 {
    margin: 0;
    padding: 4px 0 20px 10px;
    font-size: 1.5em;
    font-weight: bold;
}

.tabs {
    display: flex;
    gap: 2px;
    margin-top: 10px;
    font-size: 1.15em;
}

.tabs label {
    padding: 10px 15px;
    border-radius: 4px 4px 0 0;
    cursor: pointer;
}

.tabs label:hover,
#tab-rate:checked ~ .form-header [for="tab-rate"],
#tab-information:checked ~ .form-header [for="tab-information"] {
    background: var(--form-bg);
}

#tab-rate:focus-visible ~ .form-header [for="tab-rate"],
#tab-information:focus-visible ~ .form-header [for="tab-information"] {
    outline: 2px solid var(--blue);
    outline-offset: -2px;
}

.tab-content {
    min-height: 250px;
    padding: 25px 15px 0;
    color: var(--muted);
    text-shadow: 1px 1px 0 rgba(255, 255, 255, 0.8);
    font-style: italic;
}

.tab-content form {
    display: none;
}

#tab-rate:checked ~ .tab-content #rate,
#tab-information:checked ~ .tab-content #information {
    display: block;
}

.fields {
    display: grid;
    grid-template-columns: 1fr 2fr 1fr 2fr;
    column-gap: 30px;
    align-items: start;
}

.fields > *, .other-field > * {
    margin-bottom: 15px;
}

.fields .span-3 {
    grid-column: span 3;
}

.fields .span-all {
    grid-column: 1 / -1;
}

.other-field {
    display: contents;
}

.trap {
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 0;
    overflow: hidden;
    opacity: 0;
    z-index: -1;
}

.field {
    display: block;
    width: 100%;
    height: 34px;
    padding: 6px 12px;
    color: var(--muted);
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
    font: inherit;
    font-style: normal;
    line-height: 1.42857;
    transition: border-color 0.15s, box-shadow 0.15s;
}

textarea.field {
    height: auto;
    resize: vertical;
}

.field:focus {
    border-color: #66afe9;
    outline: 0;
    box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(102, 175, 233, 0.6);
}

.options {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 20px;
    font-style: normal;
}

.options label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
}

.options input {
    margin: 0;
}

.file {
    position: relative;
    display: flex;
    cursor: pointer;
    font-style: normal;
}

.file input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.file-button {
    flex: none;
    width: 50px;
    min-height: 34px;
    background: var(--blue) url('../img/folder.png') center no-repeat;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 4px 0 0 4px;
}

.file:hover .file-button {
    opacity: 0.8;
}

.file input:focus-visible + .file-button {
    outline: 2px solid #66afe9;
}

.file-name {
    flex: 1;
    min-width: 0;
    height: 34px;
    padding: 6px 12px;
    overflow: hidden;
    color: var(--muted);
    background: #fff;
    border: 1px solid #ccc;
    border-left: 0;
    border-radius: 0 4px 4px 0;
    line-height: 20px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
    gap: 10px 20px;
}

.button {
    padding: 5px 25px;
    color: #000;
    background: var(--blue);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 4px;
    box-shadow: 1px 1px 0 var(--blue);
    text-shadow: 1px 1px 0 rgba(255, 255, 255, 0.3);
    font: inherit;
    font-size: 1.2em;
    font-style: normal;
    line-height: 1.42857;
    cursor: pointer;
}

.button:hover, .button:focus-visible {
    color: #fff;
    text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.3);
}

.button:active {
    box-shadow: 1px 1px 0 #fff;
}

.button:disabled {
    opacity: 0.65;
    cursor: progress;
}

.status {
    margin: 0;
    padding: 35px 0;
    font-size: 1.2em;
}

.status-error {
    color: #a94442;
    text-align: right;
}

/* ---------- Contact info ---------- */

.contact-info {
    max-width: 1000px;
    margin: 0 auto;
    padding: 15px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 35px;
    margin: 30px 0 30px 16.667%;
    font-size: 1.1em;
}

.contact-item address {
    font-style: normal;
}

.contact-item svg {
    flex: none;
    width: 56px;
    height: 56px;
    fill: var(--text);
}

/* ---------- Smaller screens ---------- */

@media (max-width: 991px) {
    .pager {
        flex-wrap: wrap;
        min-height: 0;
    }

    .pager label {
        width: 14%;
        min-height: 0;
    }

    .slide {
        display: none;
    }

    .slides h2 {
        text-align: center;
    }

    .contact {
        margin: 0 10px;
    }

    .fields {
        grid-template-columns: 1fr 2fr;
    }

    .fields .span-3 {
        grid-column: auto;
    }

    .file {
        display: none;
    }
}

@media (max-width: 600px) {
    body {
        font-size: 13pt;
    }

    .site-header {
        min-height: 0;
    }

    .site-header h1 {
        min-height: 64px;
        padding: 10px 0 0 76px;
        background-size: 64px 64px;
        font-size: 1.6em;
    }

    .header-nav {
        flex-direction: row;
        margin-top: 12px;
    }

    .header-nav .btn {
        width: auto;
    }

    .header-nav .title, .language .caret {
        display: none;
    }

    .header-nav .btn svg {
        width: 1.2em;
        height: 1.2em;
    }

    .pager label {
        width: 25%;
    }

    .pager label::after {
        display: none;
    }

    .form-header h2 {
        width: 100%;
        padding: 0 0 10px;
    }

    .tabs {
        font-size: 1em;
    }

    .tab-content {
        padding: 20px 10px 0;
    }

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

    .fields > label, .other-field > label {
        margin-bottom: 5px;
    }

    .contact-item {
        flex-direction: column;
        gap: 10px;
        margin-left: 0;
        text-align: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .pager img, .slide {
        transition: none;
    }
}
