/**
 * Theme Name:        Evolutio Avocats
 * Template:          twentytwentyfour
 * Description:       A cool child theme for the Evolutio Avocats lawfirm website.
 * Requires at least: 6.7
 * Requires PHP:      7.0
 * Version:           1.0.0
 * Author:            Arthur Blaise
 * License:           GPL-2.0-or-later
 * License URI:       https://www.gnu.org/licenses/gpl-2.0.html
 * Text Domain:       evolutio
 */

/* ----- PAGE LAYOUT ----- */

body.page-template-pages,
body.post-template-default,
body.page-template-contact {
    background-color: var(--wp--preset--color--base-2);
}

@media (max-width: 782px) {
    .no-mobile {
        display: none;
    }
}

@media (prefers-contrast: more) {
    :root {
        --wp--preset--color--accent-2: var(--wp--preset--color--accent-3);
    }
}

/* ----- PRIVACY POLICY ----- */

body.privacy-policy .entry-content a {
    color: var(--wp--preset--color--contrast-2);
    text-decoration: underline;
}

body.privacy-policy .entry-content a:hover {
    color: var(--wp--preset--color--accent-2);
}

/* ----- BLOG POST ----- */

body.post-template-default .blog-main-group {
    width: 92%;
    max-width: 70rem;
    padding: 5rem 0;
}

.blog-main-group a {
    color: var(--wp--preset--color--contrast-2);
    word-break: break-word;
}

body.post-template-default .post-navigation-link-next {
    text-align: end;
}

@media (max-width: 782px) {
    body.post-template-default .blog-main-group {
        padding: 3rem 0;
    }
}

/* ----- ANCHOR LINKS ----- */

a {
    text-decoration: none;
}

a:hover:not(.evolutio-no-hover) {
    color: var(--wp--preset--color--accent-2);
}

:focus {
    outline: none;
}

:focus-visible {
    outline: 2px solid #007acc;
    outline-offset: 4px;
    border-radius: 4px;
}

@media (prefers-contrast: more) {
    a:not(.evolutio-no-hover) {
        text-decoration: underline;
    }

    a:hover:not(.evolutio-no-hover) {
        text-decoration: underline;
        text-decoration-thickness: 2px;
    }
}

.evolutio-link,
.evolutio-link-reverse {
    display: inline-flex;
    align-items: center;
    font-weight: 600;
    color: var(--wp--preset--color--accent);
    transition: all 0.2s;
}

.evolutio-link::after {
    transform: translateX(0);
}

.evolutio-link-reverse::before {
    transform: rotate(180deg) translateX(0);
}

.evolutio-link::after,
.evolutio-link-reverse::before {
    content: "";
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 25 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M9.41016 19.9201L15.9302 13.4001C16.7002 12.6301 16.7002 11.3701 15.9302 10.6001L9.41016 4.08008' stroke='black' stroke-width='2' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round' /%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 25 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M9.41016 19.9201L15.9302 13.4001C16.7002 12.6301 16.7002 11.3701 15.9302 10.6001L9.41016 4.08008' stroke='black' stroke-width='2' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round' /%3E%3C/svg%3E");
    width: 1.5rem;
    height: 1.5rem;
    background-color: currentColor;
    transition: transform 0.2s ease-in-out;
}

.evolutio-link:hover,
.evolutio-link-reverse:hover {
    color: var(--wp--preset--color--accent-2);
}

.evolutio-link:hover::after {
    transform: translateX(4px);
}

.evolutio-link-reverse:hover::before {
    transform: rotate(180deg) translateX(4px);
}

@media (prefers-reduced-motion) {

    .evolutio-link,
    .evolutio-link-reverse {
        transition: none;
    }

    .evolutio-link::after,
    .evolutio-link-reverse::before {
        transition: transform 0.5s;
    }
}

/* ----- DIALOGS ----- */

.evolutio-dialog {
    border: none;
    padding: 3rem;
    border-radius: 10px;
    box-sizing: border-box;
    max-width: 800px;
    width: 90vw;
    max-height: 90vh;
    overflow: auto;
    text-align: left;
    box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.2);
}

.evolutio-dialog__close {
    cursor: pointer;
    position: absolute;
    top: 2rem;
    right: 2rem;
    font-size: 3rem;
    font-weight: 100;
    line-height: 1.5rem;
    color: gray;
}

.evolutio-dialog__close:hover {
    color: var(--wp--preset--color--accent-2);
}

@media (min-width: 1300px) {
    .evolutio-dialog {
        padding: 4rem;
    }

    .evolutio-dialog__close {
        top: 3rem;
        right: 3rem;
    }
}

@media (max-width: 782px) {
    .evolutio-dialog {
        padding: 1.5rem;
    }

    .evolutio-dialog__close {
        top: 1.1rem;
        right: 1.5rem;
    }
}

/* ----- CONTACT FORM ----- */

.wpcf7-form .wpcf7-form-control-wrap input,
.wpcf7-form .wpcf7-form-control-wrap textarea {
    width: 100%;
    box-sizing: border-box;
    font-size: 1.125rem;
    font-weight: 500;
    font-family: var(--wp--preset--font-family--raleway);
    color: var(--wp--preset--color--contrast);
    padding: 0.5rem 1.125rem;
    border-radius: 15px;
    border: solid 1px #E0E0E0;
}

.wpcf7-form .wpcf7-form-control-wrap textarea {
    padding: 1rem 1.125rem;
}

.wpcf7-form .wpcf7-form-control-wrap span {
    margin: 0 1rem;
}

.wpcf7-form input[type="submit"] {
    padding: 0.7rem 1.75rem;
    background-color: var(--wp--preset--color--accent);
    font-size: 1rem;
    font-weight: 500;
    color: #F4EDE5;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.wpcf7-form input[type="submit"]:hover {
    background-color: var(--wp--preset--color--accent-2);
}