@font-face {
    font-family: "Work Sans";
    src: url("./assets/fonts/WorkSans-VariableFont_wght.ttf") format("truetype");
    font-weight: 100 900;
    font-style: normal;
}

:root {
    --primary-color: hsl(292, 42%, 14%);
    --secondary-color: hsl(275, 100%, 97%);
    --white: #ffffff;
    --gray-text: #6c757d;
}

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

body {
    font-family: 'Work Sans', sans-serif;
    background-color: var(--secondary-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.background-top {
    width: 100%;
    height: 320px;
    background-image: url('./assets/images/background-pattern-desktop.svg');
    background-size: cover;
    position: absolute;
    top: 0;
    z-index: -1;
}

@media (max-width: 600px) {
    .background-top {
        background-image: url('./assets/images/background-pattern-mobile.svg');
        height: 230px;
    }
}

.container {
    width: 90%;
    max-width: 600px;
    margin-top: 160px;
    margin-bottom: 2rem;
}

.faq-card {
    background-color: var(--white);
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0px 32px 56px rgba(80, 0, 118, 0.1);
}

.head {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 32px;
}

.head h1 {
    font-size: 42px;
    color: var(--primary-color);
}

.faq-item:not(:last-child) {
    border-bottom: 1px solid #f8eeff;
    padding-bottom: 20px;
    margin-bottom: 20px;
}

.faq-trigger {
    width: 100%;
    background: none;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: inherit;
    cursor: pointer;
    text-align: left;
    font-weight: 600;
    font-size: 18px;
    color: var(--primary-color);
    transition: color 0.3s ease;
}

.faq-trigger:focus-visible {
    outline: 1px solid #ad28eb;
    outline-offset: 3px;
}

.faq-trigger:hover {
    color: #ad28eb;
}

.icon {
    transition: transform 0.3s ease-in-out;
}

.icon.rotate {
    transform: rotate(180deg);
}

.faq-answer {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.3s ease-in-out;
}

.answer-content {
    overflow: hidden;
}

.faq-item.active .faq-answer {
    grid-template-rows: 1fr;
}

.answer-content p {
    padding-top: 24px;
    color: var(--gray-text);
    line-height: 1.5;
}

.attribution {
    font-size: 14px;
    text-align: center;
    margin-top: auto;
    padding: 20px;
    color: var(--gray-text);
}