website/styles/components/_search.scss
2024-04-13 15:26:52 +02:00

59 lines
998 B
SCSS

.c-search {
max-width: 52em;
margin: 0.5em auto;
padding: 0 1em;
@media (min-width: 40em) {
margin: 2em auto;
padding: 0 4em;
}
&__input {
width: 100%;
padding: 0.5em 1em;
margin-bottom: 0.5em;
box-sizing: border-box;
}
&__results {
display: grid;
row-gap: 0.5em;
}
&__result {
padding: 0.5em;
background-color: white;
box-shadow: rgba(0, 0, 0, 0.1) 0px 1px 3px 0px, rgba(0, 0, 0, 0.06) 0px 1px 2px 0px;
transition: box-shadow linear 100ms;
text-decoration: none;
color: var(--c-text);
&:focus-within,
&:hover {
box-shadow: rgba(0, 0, 0, 0.1) 0px 4px 6px -1px, rgba(0, 0, 0, 0.06) 0px 2px 4px -1px;
}
}
&__header {
display: flex;
}
&__title {
font-size: 1.3em;
margin: 0;
}
&__date {
margin-left: auto;
}
&__excerpt {
mark {
background-color: unset;
font-weight: 800;
text-decoration: underline;
color: var(--c-primary-d);
}
}
}