/* The public postnummer pages (/postnumre): the index, kommuner and postnumre. A copy of AU's postcodes.css; brand
   colours come from the brand stylesheet's variables (docs/BRANDING.md), the rest follows the content pages in main.css. */

.pc-mast {
    padding-top: 7.5rem;
    padding-bottom: 2rem;
    background-color: #f6f6f9;
}

@media (max-width: 575.98px) {
    .pc-mast { padding-top: 6.5rem; }
}

.pc-crumbs {
    display: flex;
    flex-wrap: wrap;
    gap: .35rem;
    margin: 0 0 .75rem;
    padding: 0;
    list-style: none;
    font-size: .9rem;
    color: #6f7189;
}

.pc-crumbs li + li::before {
    content: "›";
    margin-right: .35rem;
    color: #9397ad;
}

.pc-mast h1 {
    margin-bottom: .5rem;
    text-wrap: balance;
}

.pc-mast h1 .pc-code { color: var(--brand-primary); }

.pc-lede {
    max-width: 44rem;
    margin: 0;
    color: #4a4b65;
    font-size: 1.1rem;
}

.pc-body {
    padding-top: 2.5rem;
    padding-bottom: 4rem;
    display: grid;
    /* minmax(0, 1fr), not auto: the code block is wider than a phone and would stretch the column with it. */
    grid-template-columns: minmax(0, 1fr);
    gap: 2.5rem;
}

.pc-body h2 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
}

.pc-grid2 {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    gap: 1.5rem;
}

@media (max-width: 767.98px) {
    .pc-grid2 { grid-template-columns: minmax(0, 1fr); }
}

.pc-facts {
    margin: 0;
    padding: .25rem 1.25rem;
    border: 1px solid #e2e5f1;
    border-radius: .75rem;
    background: #fff;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
}

.pc-facts dt,
.pc-facts dd {
    margin: 0;
    padding: .7rem 0;
    border-bottom: 1px solid #eff2fc;
}

.pc-facts dt {
    padding-right: 1rem;
    color: #6f7189;
    font-weight: normal;
    font-size: .92rem;
}

.pc-facts dd {
    text-align: right;
    font-weight: 600;
    color: #33354d;
    overflow-wrap: anywhere;
}

.pc-facts dt:last-of-type,
.pc-facts dd:last-of-type { border-bottom: 0; }

.pc-mono {
    font-family: SFMono-Regular, Menlo, Consolas, monospace;
    font-variant-numeric: tabular-nums;
}

.pc-map {
    min-height: 280px;
    /* A fixed height that stays in view, not the height of a long list beside it (København has 397 postnumre). */
    align-self: start;
    height: clamp(280px, 60vh, 520px);
    position: sticky;
    top: 6rem;
    border: 1px solid #e2e5f1;
    border-radius: .75rem;
    overflow: hidden;
    background: var(--brand-tint, #eef6f1);
}

/* Outranks MapLibre's own .maplibregl-map { position: relative }, as the homepage's location demo does. */
#place-map.pc-map-canvas {
    position: absolute;
    inset: 0;
}

.pc-panel {
    padding: 1.5rem;
    border: 1px solid #e2e5f1;
    border-radius: .75rem;
    background: #fff;
}

.pc-panel-head {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: .5rem 1rem;
    margin-bottom: 1rem;
}

.pc-panel-head h2 { margin-bottom: 0; }

.pc-muted {
    color: #6f7189;
    font-size: .92rem;
}

.pc-az {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr));
    gap: 1.25rem 1.75rem;
}

.pc-az h3 {
    margin: 0 0 .4rem;
    padding-bottom: .25rem;
    border-bottom: 1px solid #eff2fc;
    color: var(--brand-primary);
    font-size: .8rem;
    letter-spacing: .08em;
}

.pc-az ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: .2rem;
}

.pc-az li {
    display: flex;
    justify-content: space-between;
    gap: .5rem;
    color: #33354d;
}

.pc-az li span {
    color: #9397ad;
    font-size: .85rem;
    font-variant-numeric: tabular-nums;
}

.pc-try {
    padding: 1.5rem;
    border-radius: .75rem;
    background: var(--brand-tint, #eef6f1);
    display: grid;
    gap: .75rem;
}

.pc-try h2 { margin-bottom: 0; }

.pc-try-result {
    min-height: 1.5rem;
    color: #4a4b65;
}

.pc-snippet {
    margin: 0;
    padding: 1rem 1.25rem;
    border-radius: .75rem;
    background: #2b2c3e;
    color: #e7e9f3;
    font-size: .85rem;
    line-height: 1.6;
    overflow-x: auto;
}

.pc-chips {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}

.pc-chips a {
    display: inline-block;
    padding: .35rem .8rem;
    border: 1px solid #e2e5f1;
    border-radius: 999px;
    background: #fff;
    color: #33354d;
    font-size: .95rem;
}

.pc-chips a:hover {
    border-color: var(--brand-primary);
    color: var(--brand-primary);
    text-decoration: none;
}

.pc-chips .pc-mono {
    margin-left: .3rem;
    color: #9397ad;
    font-size: .85rem;
}

/* A postnummer is written number first: "2100 København Ø". */
.pc-chips .pc-mono:first-child {
    margin-left: 0;
    margin-right: .3rem;
}

.pc-states {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
    gap: 1rem;
}

.pc-state {
    display: block;
    padding: 1.1rem 1.25rem;
    border: 1px solid #e2e5f1;
    border-radius: .75rem;
    background: #fff;
    color: #33354d;
}

.pc-state:hover {
    border-color: var(--brand-primary);
    text-decoration: none;
}

.pc-state strong {
    display: block;
    font-size: 1.1rem;
}

.pc-postcodes {
    margin: 0;
    padding: 0;
    list-style: none;
    columns: 2 22rem;
    column-gap: 2rem;
}

.pc-postcodes li {
    break-inside: avoid;
    padding: .45rem 0;
    border-bottom: 1px solid #eff2fc;
    color: #4a4b65;
}

.pc-postcodes .pc-mono {
    display: inline-block;
    min-width: 3.5rem;
    font-weight: 700;
}

.pc-cta {
    padding: 1.5rem;
    border: 1px solid #e2e5f1;
    border-radius: .75rem;
    background: #fff;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.pc-cta h2 { margin-bottom: .25rem; }
.pc-cta p { margin: 0; color: #6f7189; }

.pc-find {
    max-width: 32rem;
    margin-top: 1.25rem;
}
