/**
 * Variables
 */

:root {
    --icon-count: 16;
    --icon-height: 32px;
    --icon-width: 45px;
}

/**
 * Fonts
 */

@font-face {
    font-display: swap;
    font-family: 'Assistant';
    font-style: normal;
    font-weight: 400;
    src: url('/fonts/assistant.woff2') format('woff2'),
    url('/fonts/assistant.woff') format('woff'),
    url('/fonts/assistant.ttf')  format('truetype');
}

@font-face {
    font-display: swap;
    font-family: 'Assistant';
    font-style: normal;
    font-weight: 600;
    src: url('/fonts/assistant-semibold.woff2') format('woff2'),
    url('/fonts/assistant-semibold.woff') format('woff'),
    url('/fonts/assistant-semibold.ttf')  format('truetype');
}

/**
 * Skeleton
 */

html {
    background-color: #1a1a1a;
    overflow-y: scroll;
}

.home {
    background-color: #0a0a0a;
}

body {
    box-sizing: border-box;
    color: #fff;
    font-family: 'Assistant', sans-serif;
    font-size: 18px;
    font-weight: 400;
    margin: 0;
}

.body-home::before {
    background-image: url('/images/background.jpg');
    background-size: cover;
    content: '';
    filter: blur(36px);
    height: 100%;
    left: 0;
    opacity: .2;
    overflow: hidden;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: -1;
}

header {
    line-height: 0;
}

.wrapper {
    box-sizing: border-box;
    margin: 0 auto;
    max-width: 1200px;
}

.page {
    padding: 56px;
}

.page-home {
    background-image: url('/images/background.jpg');
    background-repeat: no-repeat;
    background-size: cover;
    height: 668px;
    position: relative;
}

main {
    box-sizing: border-box;
    margin-top: 70px;
    text-shadow: 1px 1px #555;
}

.page-home main {
    max-width: 450px;
}

footer {
    color: #5e5e5e;
    font-size: 1rem;
    font-weight: 600;
    padding: 24px 24px 64px;
    text-align: center;
    text-shadow: 1px 1px #050505;
}

/**
 * Header
 */

.container-logo {
    display: inline-block;
}

/**
 * Page
 */

h2 {
    font-size: 1.6rem;
    font-weight: 600;
    margin: 26px 0;
    text-align: left;
}

.title {
    font-size: 1.45rem;
    text-align: center;
}

/**
 * Hyperlinks
 */

a {
    color: #00efa1;
    font-weight: 600;
}

a:hover {
    color: #fff;
}

footer a {
    color: #5e5e5e;
    font-weight: 400;
}

footer a:hover {
    color: #b7b7b7;
}

/**
 * Carousel
 */

.carousel {
    anchor-name: --carousel;
    height: var(--icon-height);
    mask-image: linear-gradient(90deg, transparent 0%, black 15%, black 85%, transparent 100%);
    overflow: hidden;
    position: relative;
    width: calc(var(--icon-width) * var(--icon-count) / 2);
}

.icon-strip {
    animation: slide 20s linear infinite;
    display: flex;
    overflow: hidden;
    position: absolute;
}

.icon-strip:nth-child(0) {
    margin-left: calc(var(--icon-width) * var(--icon-count));
    mask-image: linear-gradient(90deg, transparent 0%, black 5%, black 100%);
}

.icon-strip:nth-child(1) {
    margin-left: calc(var(--icon-width) * var(--icon-count));
    mask-image: linear-gradient(90deg, black 0%, black 95%, transparent 100%);
}

.carousel:hover .icon-strip {
    animation-play-state: paused;
}

.popover {
    /* Compatibility */
    display: none;
    left: 50%;

    background: rgba(0, 0, 0, .5);
    border-radius: .7rem;
    border: none;
    color: #fff;
    cursor: default;
    left: calc(anchor(right) - anchor-size(width) / 2.5);
    margin: 6px 0 0;
    padding: 6px 11px;
    position-anchor: --carousel;
    text-shadow: none;
    top: anchor(--carousel bottom);
    translate: -50%;
    user-select: none;
    white-space: nowrap;
}

/* Compatibility */
.popover:popover-open {
    display: block;
}

.icon {
    align-items: center;
    background: none;
    border-radius: .5rem;
    border: none;
    box-sizing: border-box;
    color: inherit;
    cursor: pointer;
    display: flex;
    flex-shrink: 0;
    font: inherit;
    height: var(--icon-height);
    justify-content: center;
    padding: 4px;
    width: var(--icon-width);
}

/* Compatibility */
.icon::-moz-focus-inner {
    border: none;
}

.icon svg {
    display: block;
}

.icon-holder {
    display: none;
}

.icon-etc:hover {
    background-color: rgba(0, 0, 0, .25);
}

.icon-architecture:hover {
    background-color: #226eaf;
}

.icon-c-sharp:hover {
    background-color: #7058d7;
}

.icon-docker:hover {
    background-color: #1d63ed;
}

.icon-inertia:hover {
    background-color: #165efc;
}

.icon-infrastructure:hover {
    background-color: #d3f0ff;
    color: #244d60;
}

.icon-laravel:hover {
    background-color: #f53003;
}

.icon-livewire:hover {
    background-color: #162130;
    color: #e24ca6;
}

.icon-data-modeling:hover {
    background-color: #005883;
}

.icon-nodejs:hover {
    background-color: #0d121c;
    color: #5a984b;
}

.icon-python:hover {
    background-color: #ffd343;
    color: #29577e;
}

.icon-react:hover {
    background-color: #23272f;
    color: #58c4dc;
}

.icon-rust:hover {
    background-color: #fff;
    color: #000;
}

.icon-terminal:hover {
    background-color: #141414;
}

.icon-vite:hover {
    background-color: #30333d;
    color: #fdc71f;
}

.icon-vue:hover {
    background-color: #42b883;
}

/**
 * Controls
 */

.alert,
.form {
    background: linear-gradient(135deg, #202020, #141414);
    box-shadow: 0 0 2rem #141414;
    font-size: 1rem;
    margin: 0 auto;
    max-width: 500px;
    padding: 16px 48px 48px 48px;
    text-align: left;
    text-shadow: 1px 1px #111;
}

.form {
    border-radius: 2rem;
}

label {
    font-size: 1.1rem;
    font-weight: 600;
}

.input-submit {
    border: none;
    cursor: pointer;
    text-align: right;
}

.input-text,
.input-email,
.input-date,
.input-number {
    background-color: #252525;
    border-radius: .5rem;
    border: none;
    box-sizing: border-box;
    color: #00efa1;
    font-family: 'Assistant', sans-serif;
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 8px;
    outline: none;
    padding: 9px 11px;
    width: 100%;
}

.input-text:focus-visible,
.input-email:focus-visible,
.input-date:focus-visible,
.input-number:focus-visible {
    outline: 2px solid #3c3c3c;
}

.input-text:user-invalid,
.input-email:user-invalid,
.input-date:user-invalid,
.input-number:user-invalid {
    background-color: #190a0a;
    outline: 2px solid #5f141a;
}

.select {
    color: #746a63;
    padding: 3px 0;
    width: 100%;
}

.textarea {
    background-color: #252525;
    border-radius: .75rem;
    border: none;
    box-sizing: border-box;
    color: #00efa1;
    font-family: 'Assistant', sans-serif;
    font-weight: 600;
    margin-top: 8px;
    outline: none;
    padding: 9px 11px;
    resize: none;
    width: 100%;
}

.textarea:focus-visible {
    outline: 2px solid #3c3c3c;
}

.textarea:user-invalid {
    background-color: #190a0a;
    outline: 2px solid #5f141a;
}

.button-bar {
    display: flex;
    margin-top: 50px;
}

.action-button-bar {
    justify-content: flex-end;
}

.button-accent {
    animation: shimmer 5s ease infinite;
    background: linear-gradient(45deg, #fff0, #008c5e) center / 300% 300%;
    border-radius: 100px;
    display: inline-block;
    padding: 4px;
}

.button {
    display: inline-block;
    font-family: 'Assistant', sans-serif;
    outline: 0;
    text-decoration: none;
}

.button-important {
    animation: pulse 2.5s ease infinite;
    background-color: #00a770;
    border-radius: 100px;
    color: #fff;
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1;
    padding: 18px 20px 19px;
    text-shadow: none;
}

.button-important:hover,
.button-important:focus-visible {
    background-color: #00efa1;
    color: #00472f;
    text-shadow: none;
}

.description-input {
    color: #d2d2d2;
    font-size: 1.1rem;
    font-style: italic;
}

/**
 * Alerts
 */

.alert {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 24px;
    padding-bottom: 16px;
    padding-top: 16px;
}

.alert-success {
    background: #00b076;
    text-shadow: 1px 1px #005d3f;
}

.alert-error {
    background: #9a1d1d;
    text-shadow: 1px 1px #651212;
}

/**
 * Notices
 */

.notice-license {
    margin: 12px auto 0 auto;
    max-width: 500px;
}

/**
 * Miscellaneous
 */

.challenge {
    animation: fade-in 300ms ease forwards 250ms;
    opacity: 0;
}

.form-element {
    margin-top: 8px;
}

.muted {
    color: #d2d2d2;
}

/**
 * Animations
 */

@keyframes fade-in {
    to {
        opacity: 1;
    }
}

@keyframes pulse {
    0%, to {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.1);
    }
}

@keyframes shimmer {
    0%, to {
        background-position:0 50%
    }
    50% {
        background-position:175% 50%
    }
}

@keyframes slide {

    from {
        transform: translateX(0);
    }

    100% {
        transform: translateX(calc((-1 * var(--icon-width)) * var(--icon-count)));
    }
}

/**
 * Media Queries
 */

@media (max-width: 575px) {

    .page {
        padding: 56px 32px;
    }

    main {
        margin-top: 48px;
        max-width: unset;
        text-align: justify;
        text-shadow: 1px 1px #000;
    }

    .alert,
    .form {
        max-width: unset;
        margin: 0 -32px -48px -32px;
    }

    .form {
        border-radius: 0;
    }

    .alert {
        text-align: center;
        padding: 12px 24px;
    }

    .form {
        padding: 32px 24px 64px 24px;
    }

    .button-bar {
        justify-content: center;
    }

    header {
        margin: -56px -32px 0;
        padding: 24px;
    }

    footer {
        padding: 56px 24px;
    }

    .page-home {
        background: rgba(255, 255, 255, .025);
        height: auto;
    }

    .page-home header {
        background-image: url('/images/background.jpg');
        background-repeat: no-repeat;
        background-size: 100%;
        height: 238px;
        margin-bottom: 48px;
    }

    .carousel {
        margin: 0 auto;
    }

    .popover {
        background: rgba(0, 0, 0, .35);
    }
}

@media (max-width: 505px) {

    .page-home header {
        height: 202px;
    }
}

@media (max-width: 450px) {

    .page-home header {
        height: 172px;
    }

    :root {
        --icon-width: 42px;
    }
}

@media (max-width: 400px) {

    :root {
        --icon-width: 40px;
    }
}

@media (max-width: 380px) {

    .page-home header {
        background-size: 110%;
    }

    :root {
        --icon-width: 38px;
    }
}

@media (max-width: 350px) {

    .page-home header {
        background-size: 130%;
    }
}
