@import url("https://styles.blocklycode.org/templatesettings.css");

#error {
    margin: 15vh auto;
    display: none;
    width: fit-content;
    grid-column: span 2;
    text-align: center;
    line-height: 1.5;
    font-weight: 100;
    color: var(--bc-clr-text-800);
}
#error::first-line {
    font-family: var(--bc-ff-heading);
    font-size: var(--bc-fs-700);
    font-weight: 800;
    color: var(--bc-clr-text-400);
}
#contentLoader {
    border-top: 3px solid var(--bc-clr-primary-400);
    border-right: 1px solid transparent;
    border-radius: 5rem;
    margin: 15vh auto;
    display: block;
    width: 10rem;
    aspect-ratio: 1 / 1;
    animation: templateLoader 1s infinite;
}
@keyframes templateLoader {
    from {rotate: 0deg}
    to {rotate: 360deg}
}

.search-wrapper {
    margin-bottom: 2rem;
}
.search-input {
    background: var(--bc-clr-dark-800);
    border: none;
    border-radius: .5rem;
    padding: 1rem;
    width: min(55rem, 50%);
}
.search-input:is(:focus, :focus-visible, :focus-within) {
    background: var(--bc-clr-dark-900);
}
.result-count {
    margin-right: 1rem;
    font-size: var(--bc-fs-300);
    font-weight: 300;
    color: var(--bc-clr-text-800);
}

.template-list {
    display: grid;
    gap: 2rem;
    grid-template-columns: repeat(auto-fit, minmax(45rem, 1fr));
}
.template {
    background: var(--bc-clr-dark-800);
    border: 1px solid var(--bc-clr-dark-400);
    border-radius: 1rem;
    /* padding: 1rem; */
}
.template-icon {
    border-radius: inherit;
    height: 10rem;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}
.template-text {
    flex-grow: 1;
}
.template-title {
    font-weight: 900;
    font-size: var(--bc-fs-700);
    color: var(--bc-clr-primary-400);
}
.template-desc {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    text-overflow: ellipsis;
    font-weight: 300;
    color: var(--bc-clr-text-200);
    overflow: hidden;
}
.template-tag {
    background: var(--bc-clr-primary-600);
    border-radius: .3rem;
    padding: .3rem;
    line-height: 1;
    font-size: var(--bc-fs-300);
    font-weight: 300;
    color: var(--bc-clr-text-100);
}
.template-button {
    margin-right: 1rem;
    font-size: var(--bc-fs-900);
    color: var(--bc-clr-primary-400);
}