/* Universal title bar */
.categoryTitleBar {
    text-align: center;
    padding: 10px;
    border: 4px ridge grey;
    color: #eeeeee;
}

/* Colour-coded title bars */
.forthcomingTitle { background-color: #BBBBBB; color: black; }
.childrenTitle    { background-color: #006600; }
.youngAdultTitle  { background-color: #990000; }
.fictionTitle     { background-color: #990066; }
.poetryTitle      { background-color: #003399; }
.memoirsTitle     { background-color: yellow; color: #111111 !important; }

/* Category heading */
.categoryTitle {
    text-align: center;
    font-size: 3em;
    margin: 20px 0;
    color: #eeeeee;
}

/* Unified grid */
.categoryGrid {
    display: grid;
    justify-content: center;
    grid-template-columns: repeat(auto-fit, minmax(160px, 240px));
    gap: 70px; /* 30 larger spacing */
    padding: 20px;
}

.categoryGrid a {
    display: block;
    text-align: center;
    text-decoration: none;
    color: #222;
    max-width: 240px; /* limit the width of each grid item */
}

.categoryGrid img {
    width: 65%; /* smaller images */
    height: auto;
    object-fit: contain;
    background: #ccc;
    border: 4px ridge grey;
    display: block;
    margin: 0 auto;   /* centres the image */
}

.categoryGrid span {
    display: block;
    margin-top: 8px;
    font-weight: bold;
    font-size: 1dvh;      /* normal text size */
    color: #eee;          /* optional, matches your aesthetic */
}

/* Sub-menu */
.catalogueSubMenu {
    width: 100%;
    text-align: center;
    margin: 10px 0 20px;
}

.catalogueSubMenu a {
    display: inline-block;
    padding: 8px 14px;
    margin: 4px;
    text-decoration: none;
    color: #eee;
    font-weight: bold;
    border: 4px ridge grey;
}

/* Colour-coded links */
.forthcomingLink { background-color: #444; }
.fictionLink     { background-color: #990066; }
.youngAdultLink  { background-color: #990000; }
.childrenLink    { background-color: #006600; }
.memoirLink      { background-color: yellow; }
.poetryLink      { background-color: #003399; }
