/*mobile first min-width sets base and content is adapted to computers.*/
@media (min-width: 100px) {
    #library-container {
        display: none;
        flex-direction: column;
        padding: 10px;
        border-radius: 10px;
        max-width: 800px;
        margin: 0 auto;
        height: 100%;
        overflow-y: auto;
    }

    #library-container.open {
        display: flex;
    }

    #library-btn {
        background: var(--background-accent-1-color);

    }
    #close-library-icon {
        position: absolute;
        top: 20px;
        right: 20px;
        cursor: pointer;
        width: 35px;
        /*bottom: auto;*/
    }

    #library-container h2 {
        text-align: center;
        margin-top: 0;
        margin-bottom: 30px;
        color: var(--title-color);
    }

    .recordings-container {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        grid-gap: 20px;
        justify-content: center;
        align-items: center;
        padding: 0 20px;
        gap: 15px;
        width: 100%;
    }

    .recording-item {
        display: flex;
        flex-direction: column;
        background-color: var(--background-accent-1-color);
        border-radius: 8px;
        padding: 15px;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
        transition: transform 0.2s ease;
        cursor: pointer;
        position: relative;
    }

    .recording-item:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    }

    .recording-name {
        font-size: 16px;
        font-weight: bold;
        margin-bottom: 10px;
    }

    .recording-controls {
        display: flex;
        gap: 10px;
    }

    .recording-controls button {
        background-color: var(--background-accent-5-color);
        border: none;
        border-radius: 50%;
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: background-color 0.2s ease;
    }

    .recording-controls button:hover {
        background-color: var(--background-accent-6-color);
    }

    .recording-audio {
        display: none;
    }

    /* Pagination styles */
    .pagination-container {
        display: flex;
        justify-content: center;
        align-items: center;
        margin-top: 20px;
        gap: 15px;
    }

    .pagination-button {
        background-color: #1e4f4f;
        color: white;
        border: none;
        border-radius: 4px;
        padding: 8px 16px;
        cursor: pointer;
        transition: background-color 0.2s ease;
    }

    .pagination-button:hover:not(:disabled) {
        background-color: #0c7878;
    }

    .pagination-button:disabled {
        background-color: #959595;
        cursor: not-allowed;
    }

    .page-info {
        font-size: 14px;
    }
        /* Loader styles */
    .loader-container {
        display: flex;
        justify-content: center;
        align-items: center;
        width: 100%;
        padding: 40px 0;
    }

    .loader {
        border: 10px solid var(--subdued-text-color);
        border-top: 10px solid #1e4f4f;
        border-radius: 50%;
        width: 50px;
        height: 50px;
        animation: spin 1s linear infinite;
    }

    @keyframes spin {
        0% { transform: rotate(0deg); }
        100% { transform: rotate(360deg); }
    }

    /* Audio loader styles */
    .audio-loader {
        position: absolute;
        display: flex;
        justify-content: center;
        align-items: center;
        width: 100%;
        height: 100%;
        top: 0;
        left: 0;
        background-color: rgba(0, 0, 0, 0.1);
        border-radius: 50%;
    }

    .recording-controls button {
        position: relative;
    }

    .recording-controls button:disabled {
        opacity: 0.7;
        cursor: not-allowed;
    }

}

/*portrait tablets, portrait iPad, landscape e-readers, landscape 800x480 or 854x480 phones*/
@media (min-width: 641px) {
    #library-icon {
        /*top: 20px;*/
        /*bottom: auto;*/
    }
    #library-container {
        padding: 20px;
    }
}

/*tablet, landscape iPad, lo-res laptops ands desktops*/
@media (min-width: 961px) {

}

/*big landscape tablets, laptops, and desktops*/
@media (min-width: 1025px) {

}
