/* regular font */
@font-face {
    font-family: 'deluxe220';
    src: url('/fonts/deluxe220regular.otf') format('opentype');
    font-weight: 400;
    font-style: normal;
}

/* bold font */
@font-face {
    font-family: 'deluxe220';
    src: url('/fonts/deluxe220bold.otf') format('opentype');
    font-weight: 700;
    font-style: normal;
}


body {
    max-width: 1400px;
}

main {
    gap: 6rem;
}

h3 {
    margin: 2rem 0 0rem 0;
}

h4,
h5,
h6 {
    margin: 0;
}

.showcase-image {
    display: block;
    margin: 2rem 0 0rem 0;
}

.font-example-container {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.example-item-container {
    display: flex;
    flex-direction: column;
}

.font-example-title {
    font-size: 1.8rem;
    margin: 1rem 0 0 0;
}

.font-example-text {
    word-break: break-all;
    font-size: 1.8rem;
    margin: 1rem 0;
}

#large-text-showcase {
    font-size: 11rem;
    line-height: 1.5;
    overflow: hidden;
    margin: 0;
}

.project-footer-container {
    display: flex;
    flex-direction: row;
    gap: 7rem;
    justify-content: center;
    align-items: center;
    margin: 3rem 0rem 1rem 0rem;
    font-size: 1rem;
}


.font-images {
    display: flex;
    flex-direction: column;
    gap: 0rem;
    /* Large gaps make the scattering feel more intentional */
    width: 100%;
    margin: 4rem 0;
}

.font-images img {
    max-width: 50%;
    /* Prevents them from being too overwhelming */
    height: auto;
    display: block;
}

/* 1st Image: Anchored to the far right */
.font-images img:nth-child(1) {
    align-self: flex-end;
}

/* 2nd Image: Anchored to the left, but indented slightly */
.font-images img:nth-child(2) {
    align-self: flex-start;
    margin-left: 5%;
}

/* 3rd Image: Centered */
.font-images img:nth-child(3) {
    align-self: center;
}

/* 4th Image: Anchored to the left edge */
.font-images img:nth-child(4) {
    align-self: flex-end;
}


.info-p {
    max-width: 450px;
    margin-top: 5rem;
}

.styles-text {
    margin-left: 40rem;
}

.deluxe220-text {
    font-family: 'deluxe220', monospace;
    line-height: 1.4;
}

.deluxe220-small {
    font-size: 2rem;
    max-width: 300px;
    align-self: flex-end;
}

.deluxe220-large {
    max-width: 100%;
    font-size: 12rem;
    overflow: hidden;
}


.font-playground {
    margin-top: 3rem;
    border: 1px solid #111;
    border-top-left-radius: 37px 140px;
    border-top-right-radius: 23px 130px;
    border-bottom-left-radius: 110px 19px;
    border-bottom-right-radius: 120px 24px;
    padding: 2rem;
    width: 75%;
}

.playground-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 2rem;
    font-size: 0.8rem;
}

.control-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.weight-buttons {
    display: flex;
    border: 1px solid #111;
    border-radius: 2px;
    overflow: hidden;
}

.weight-btn {
    background: none;
    border: none;
    padding: 4px 12px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.75rem;
    cursor: pointer;
    color: #111;
    transition: background 0.2s, color 0.2s;
}

.input-wrapper {
    display: flex;
    align-items: center;
    gap: 4px;
}

#sizeValue {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.8rem;
    color: #111;
    min-width: 25px;
    display: inline-block;
    text-align: right;
}

.unit {
    font-size: 0.8rem;
    color: #111;
}





/* The active/selected state */
.weight-btn.active {
    background-color: #111;
    color: #fefefe;
}

.weight-btn:hover:not(.active) {
    background-color: rgba(0, 0, 0, 0.05);
}

.weight-btn:first-child {
    border-right: 1px solid #111;
}

/* Style the editable area */
#testerText {
    font-family: 'deluxe220', sans-serif;
    /* Your custom font */
    font-weight: 400;
    font-size: 24px;
    color: #111;
    outline: none;
    /* Removes the focus border */
    height: fit-content;
    width: fit-content;
    word-break: break-word;
    display: block;
}


#testerText:empty::before {
    content: attr(data-placeholder);
    color: #888; /* Dimmed color for placeholder */
    cursor: text;
}


/* Minimalist styling for the slider */
input[type=range] {
    cursor: pointer;
    accent-color: #111;
}

select {
    border: 1px solid #111;
    background: none;
    font-family: inherit;
    cursor: pointer;
}

@media (max-width: 600px) {
    .font-example-text {
        font-size: 1.4rem;
    }

    .font-example-container {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .project-footer-container {
        justify-content: space-between;
        gap: 0;
        margin: 1.5rem 0rem 1rem 0rem;
    }

    .playground-controls {
        gap: 1rem;
    }


}

@media (max-width: 800px) {

    .styles-text {
        margin-left: 5rem;
    }

    .deluxe220-large {
        font-size: 6rem;
    }

    .deluxe220-small {
        font-size: 1.5rem;
    }

    .font-images {
        gap: 2rem;
        /* Reduce the vertical gap for mobile screens */
    }

    .font-images img {
        /* 1. Make the images larger so the font is readable on phones */
        max-width: 100%;

        /* 2. Reset the scattering to keep everything in the center */
        align-self: center !important;

        /* 3. Remove the specific left margin from the 2nd image */
        margin-left: 0 !important;
    }

    .font-playground {
        width: 100%;
    }
}