/*
listed-id.css
*/

h1 {
    font-size: clamp(1.22rem, 3.1vw, 1.4rem);
    margin: .8rem 0 .6rem;
    min-width: 37.5rem;
}

main a[itemprop="url"] {
    display: inline;
    margin-top: 0;
}

main a[itemprop="url"]::before {
    content: "";
    display: block;
    margin-top: 1.1rem;
}

h1 > span:first-of-type {
    color: var(--blue);
    margin-right: 0.3rem;
}

h2,
h3 {
    font-weight: 600;
    font-size: 1rem;
    max-width: 90%;
}

h3 {
    display: inline;
}

li h3 {
    margin-top: 0;
    padding: 0;
}

p[itemprop="description"] {
    margin-right: 1.6rem;
    white-space: pre-line;
}

.rec-type,
span[itemprop="award"] {
    font-weight: 600;
}

div:has([itemprop="brand"]),
div:has([itemprop="countryOfOrigin"]),
div:has([itemprop="foundingLocation"]),
div:has([itemprop="contentLocation"]) {
    margin-top: 0.26rem;
}

.info-list {
    margin-top: 3.2rem;
    padding: 0;
    list-style: none;
    width: 35rem;
    text-align: left;
}

.info-list li {
    margin: 0.3rem 0;
}

.info-list .label {
    display: inline-block;
    width: 10rem;
    vertical-align: top;
}

.info-list .value {
    display: inline-block;
    width: 24rem;
    font-weight: 600;
}

main .item-grid {
    display: grid;
    grid-template-columns: 3fr 1fr;
    align-items: stretch;
    gap: 0;
}

.item-content {
    padding-right: 2rem;
}

.item-sidebar {
    border-left: 1px solid rgba(0,0,0,.16);
    padding-left: 2rem;
    display: flex;
    flex-direction: column;
    min-height: 58vh;
}

.item-sidebar::before {
    content: "";
    position: absolute;
    top: 2rem;
    bottom: 2rem;
    left: 0;
    width: 1px;
    background: rgba(0,0,0,.16);
}

.item-sidebar .side-section h4 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.8rem 0;
}

aside {
    padding-top: 1.1rem;
}

.side-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1.2rem 0;
}

.side-list li {
    margin: 0.4rem 0;
    opacity: .8;
    font-size: var(--font-size-sm);
}

.side-list a {
    text-decoration: none;
}

.side-list a:hover {
    text-decoration: underline;
}

.side-archive {
    margin-top: 1.6rem;
}

/*  =============================
    MEDIA
    ============================= */

/* ≤1300px */
@media (max-width: 1300px) {

    main .item-grid {
        grid-template-columns: 2fr 1fr;
        gap: 1.5rem;
    }

    header nav a {
        margin: 0 0.8rem;
        padding: 0.8rem 0.2rem;
        text-align: center;
    }

    h1,
    .item-content h2 {
        min-width: 0;
        width: auto;
    }

    p[itemprop="description"] {
        margin-right: 0;
        width: auto;
    }

    .info-list {
        width: 100%;
        max-width: 100%;
    }

    .info-list .label {
        width: 9rem;
    }

    .info-list .value {
        width: calc(100% - 9rem);
    }

    .item-sidebar {
        position: relative;
        padding-left: 1.5rem;
        border-left: none;
    }

    .item-sidebar::before {
        left: 0;
        top: 1.25rem;
        bottom: 1.25rem;
    }

    .item-content {
        padding-right: 1.5rem;
    }
}

/* ≤900px */
@media (max-width: 900px) {
    main .item-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .item-content {
        padding-right: 0;
    }

    .item-sidebar {
        border-left: 0;
        border-top: 1px solid #e3e3e3;
        padding-left: 0;
        padding-top: 1.5rem;
        position: static;
    }

    .item-sidebar::before {
        content: none;
        display: none;
    }

    h1,
    .item-content h2,
    p[itemprop="description"] {
        min-width: 0;
        width: 100%;
        padding-right: 0;
        margin-right: 0;
        overflow-wrap: anywhere;
    }

    .info-list {
        width: 96%;
        max-width: 96%;
    }

    .info-list .label {
        width: 8.2rem;
    }

    .info-list .value {
        width: calc(100% - 9rem);
    }
}

/* ≤600px */
@media (max-width: 600px) {

    main .item-grid::before {
        display: none;
    }

    h1,
    .item-content h2 {
        min-width: 0;
        width: min(560px, calc(100vw - 1rem));
        padding-right: 1.6rem;
        box-sizing: border-box;
        overflow-wrap: anywhere;
        display: block;
    }

    main p[itemprop="description"] {
        width: min(560px, calc(100vw - 1rem));
        padding-right: 1.6rem;
        margin-right: 0;
        box-sizing: border-box;
        overflow-wrap: anywhere;
        display: block;
    }

    .info-list .value {
        width: 14rem;
    }

    .item-content {
        grid-column: 1 / -1;
        padding-right: 0;
    }

    .item-sidebar {
        grid-column: 1 / -1;
        border-left: 0;
        border-top: 1px solid #e3e3e3;
        margin-top: 1.5rem;
        padding-top: 1.5rem;
        padding-left: 0;
    }

    .info-list {
        display: grid;
        grid-template-columns: 6.4rem 1fr; /* label | value */
        column-gap: .4rem;
        row-gap: .4rem;
        width: 97%;
        max-width: 97%;
        padding-right: .4rem;
        font-size: 98%;
    }

    .info-list h3,
    .info-list .label,
    .info-list .value,
    .info-list time,
    .info-list span,
    .info-list a,
    .info-list strong {
        font-size: inherit;
    }

    .info-list * {
        font-size: inherit !important;
    }

    .info-list li {
        display: contents;
    }

    .info-list .label,
    .info-list .value {
        display: block;
        width: auto !important;
    }

    .item-sidebar::before {
        content: none !important;
        display: none !important;
    }

    /* Two-column info list */
    .info-list {
        display: grid;
        grid-template-columns: max-content 1fr;
        column-gap: 6px;
        row-gap: 9px;
        align-items: baseline;           /* key: align value's text baseline with label */
    }

    .info-list li { display: contents; }

    .info-list .label,
    .info-list .value {
        display: block;
        margin: 0;
    }

    #canonicalText {
        align-self: baseline;            /* safe redundant */
        margin: 0;
        line-height: 1.25;
        word-break: break-all;           /* wrap long URLs */
        overflow-wrap: anywhere;         /* better wrapping on narrow widths */
    }
}
