:root {
    color-scheme: light;
    color: #192138;
    background: #f9f9f3;
    font: 16px "Helvetica Neue", Arial, sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
}

.sheet {
    max-width: 480px;
    margin-inline: auto;
}

.catalog-header {
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    padding: 8px 16px;
    border-bottom: 1px solid #e1e0d5;
}

.brand, .notebook-link, .puzzle-card {
    color: inherit;
    text-decoration: none;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    font-weight: 800;
    letter-spacing: -.5px;
}

.notebook-link {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding-inline: 9px;
    border: 1px solid #e1e0d5;
    border-radius: 9px;
    font-size: .75rem;
    font-weight: 750;
}

.catalog-intro {
    padding: 18px 16px 15px;
}

.catalog-intro h1 {
    margin: 0;
    font-size: 1.9375rem;
    line-height: 1;
    font-weight: 800;
    letter-spacing: -1.25px;
}

.catalog-intro p {
    margin: 8px 0 0;
    color: #515469;
    font-size: .8125rem;
}

.puzzles {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 0;
    padding: 0 16px 24px;
    list-style: none;
}

.puzzle-card {
    display: block;
    height: 100%;
    padding: 7px 7px 10px;
    background: #fffefa;
    border: 1px solid #e1e0d5;
    border-radius: 15px;
    box-shadow: 0 2px 2px #201c4309;
}

.puzzle-card:hover, .notebook-link:hover {
    border-color: #8d80b3;
}

a:focus-visible {
    outline: 2px solid #514494;
    outline-offset: 3px;
}

.puzzle-card img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 1.12;
    object-fit: cover;
    background: #ebe8f2;
    border-radius: 10px;
}

.puzzle-title {
    display: flex;
    justify-content: space-between;
    gap: 4px;
    margin: 8px 3px 4px;
    font-size: .9375rem;
    line-height: 1.1;
    letter-spacing: -.34px;
    font-weight: 750;
}

.puzzle-arrow {
    color: #615295;
    font-size: .8125rem;
}

.puzzle-goal {
    display: block;
    margin-inline: 3px;
    color: #515469;
    font-size: .6875rem;
    line-height: 1.25;
}

.guide, .notebook, .faq, footer {
    margin-inline: 16px;
    padding-block: 18px;
    border-top: 1px solid #e1e0d5;
}

main section:not(.catalog-intro) h2 {
    margin: 0 0 12px;
    font-size: 1.25rem;
    letter-spacing: -.35px;
}

.faq h3 {
    margin: 0 0 4px;
    font-size: .9375rem;
}

.guide p, .notebook p, .faq p {
    margin: 0 0 12px;
    color: #515469;
    font-size: .875rem;
    line-height: 1.55;
}

.guide p:last-child, .notebook p:last-child, .faq-item:last-child p {
    margin-bottom: 0;
}

.guide a, footer a {
    color: #514494;
}

footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 8px 16px;
    font-size: .8125rem;
}

@media (max-width: 299px) {
    .puzzles {
        grid-template-columns: 1fr;
    }
}
