/* Deferred summary interaction plus the mobile second-screen presentation. */
@media (min-width: 621px) {
    .pmdh-summary__details { transition: background-color .18s ease; }
    .pmdh-summary__details:hover,
    .pmdh-summary__weather:hover {
        border: 0;
        background: rgba(255,255,255,.075);
        color: #fff;
        box-shadow: none;
        transform: none;
    }
    .pmdh-summary__details-arrow { transition: transform .18s ease; }
    .pmdh-summary__details:hover .pmdh-summary__details-arrow,
    .pmdh-summary__weather:hover .pmdh-summary__details-arrow { transform: translateX(3px); }
    .pmdh-summary__value a:hover,
    .pmdh-rating--link:hover .pmdh-rating__copy { text-decoration: underline; text-underline-offset: 2px; }
    .pmdh-summary[data-pmdh-section="place-summary"] .pmdh-type-chip:hover {
        border-color: rgba(255,255,255,.32);
        background: rgba(255,255,255,.15);
    }
}

@media (max-width: 620px) {
    /* Visual paint of the offscreen second slide is intentionally deferred. */
    .pmdh__hero-details,
    .pmdh--taxonomy .pmdh__hero-details {
        overflow-x: hidden;
        overflow-y: auto;
        padding: 28px var(--pmdh-gutter) 78px;
        background: linear-gradient(180deg, rgba(2,24,43,.38), rgba(2,24,43,.58));
        color: #fff;
        overscroll-behavior-y: auto;
    }
    .pmdh-mobile-details-slot { display: block; width: 100%; }

    /* Base summary presentation is only needed after JavaScript moves it into slide 2,
       or below the hero when JavaScript is disabled. */
    .pmdh-summary {
        position: relative;
        z-index: 5;
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        width: calc(100% - (var(--pmdh-gutter) * 2));
        margin: -30px var(--pmdh-gutter) 0;
        overflow: visible;
        border: 0;
        background: transparent;
        box-shadow: none;
    }
    .pmdh-summary__item {
        display: flex;
        align-items: center;
        gap: .9rem;
        min-width: 0;
        width: 100%;
        min-height: 72px;
        padding: 1rem 1.2rem;
        border: 1px solid var(--pmdh-line);
        border-radius: var(--pmdh-radius);
        background: #fff;
        box-shadow: 0 12px 32px rgba(9,42,70,.11);
    }
    .pmdh-summary__details {
        appearance: none;
        width: 100%;
        color: var(--pmdh-text);
        font: inherit;
        text-align: left;
        cursor: pointer;
    }
    .pmdh-summary__details-arrow {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        margin-left: auto;
        color: var(--pmdh-blue);
    }
    .pmdh-summary__icon {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 42px;
        height: 42px;
        flex: 0 0 42px;
        border-radius: var(--pmdh-radius);
        background: #eaf4ff;
        color: var(--pmdh-blue);
        font-size: var(--pmdh-icon-size-md);
    }
    .pmdh-summary__copy { min-width: 0; }
    .pmdh-summary__label,
    .pmdh-summary__value { display: block; }
    .pmdh-summary__label { color: var(--pmdh-muted); font-size: var(--pmdh-font-size-xs); font-weight: var(--pmdh-font-weight-label); }
    .pmdh-summary__value {
        margin-top: .18rem;
        color: var(--pmdh-text);
        font-size: var(--pmdh-font-size-md);
        font-weight: var(--pmdh-font-weight-value);
        line-height: var(--pmdh-line-height-snug);
        overflow-wrap: anywhere;
    }
    .pmdh-summary__value a { color: var(--pmdh-blue-2); text-decoration: none; }
    .pmdh-summary__muted { color: var(--pmdh-muted); font-weight: var(--pmdh-font-weight-value); }
    .pmdh-rating { display:inline-flex; flex-direction:column; align-items:flex-start; gap:.2rem; max-width:100%; color:inherit !important; text-decoration:none !important; font-weight:var(--pmdh-font-weight-value); }
    .pmdh-rating__stars { display:inline-flex; align-items:center; gap:0; color:#e6a700; line-height:1; }
    .pmdh-rating__star { width:1em; overflow:hidden; font-size:var(--pmdh-icon-size-md); }
    .pmdh-rating__star--half { opacity:.52; }
    .pmdh-rating__star--empty { opacity:.18; }
    .pmdh-rating__copy { display:block; line-height:var(--pmdh-line-height-snug); }
    .pmdh-summary__address { display:inline-flex; align-items:center; gap:.38rem; max-width:100%; }
    .pmdh-summary__address > span:first-child { min-width:0; overflow-wrap:anywhere; white-space:normal; }
    .pmdh-type-chips { display:flex; flex-wrap:wrap; gap:.32rem; }
    .pmdh-type-chip { display:inline-flex; align-items:center; gap:.28rem; max-width:100%; padding:.22rem .46rem; border:1px solid #d8e5f1; border-radius:var(--pmdh-radius); background:#f5f9fd; color:#244b70 !important; font-size:var(--pmdh-font-size-xs); font-weight:var(--pmdh-font-weight-value); line-height:var(--pmdh-line-height-tight); text-decoration:none !important; }
    .pmdh-type-chip__icon { color:var(--pmdh-blue); font-size:var(--pmdh-icon-size-md); }

    .pmdh-summary--territory .pmdh-summary__item { align-items:flex-start; min-height:0; }
    .pmdh-summary--territory .pmdh-summary__details { align-items:center; }
    .pmdh-summary--territory .pmdh-summary__copy { width:100%; }
    .pmdh-summary__facts { display:grid; gap:.28rem; margin:.42rem 0 0; }
    .pmdh-summary__fact { display:grid; grid-template-columns:minmax(72px,.72fr) minmax(0,1.28fr); gap:.45rem; margin:0; padding:.13rem 0; border-radius:var(--pmdh-radius); }
    .pmdh-summary__fact dt,
    .pmdh-summary__fact dd { min-width:0; margin:0; }
    .pmdh-summary__fact dt { color:var(--pmdh-muted); font-size:var(--pmdh-font-size-2xs); font-weight:var(--pmdh-font-weight-label); line-height:var(--pmdh-line-height-snug); }
    .pmdh-summary__fact dd { color:var(--pmdh-text); font-size:var(--pmdh-font-size-xs); font-weight:var(--pmdh-font-weight-value); line-height:var(--pmdh-line-height-snug); overflow-wrap:anywhere; }
    .pmdh-summary__fact small { font-size:var(--pmdh-font-size-2xs); }
    .pmdh-summary__fact--safe dd { color:var(--pmdh-success); }
    .pmdh-summary__fact--warning dd { color:#8a5d00; }
    .pmdh-summary__fact--danger dd { color:var(--pmdh-danger); }
    .pmdh-summary__inherited { margin-left:.15em; color:var(--pmdh-blue); }
    .pmdh-summary__source { display:block; margin-top:.38rem; color:var(--pmdh-muted); font-size:var(--pmdh-font-size-2xs); line-height:var(--pmdh-line-height-snug); }
    .pmdh-summary__currency-list,
    .pmdh-currency-rates--summary { display:grid; gap:.14rem; margin:0; padding:0; list-style:none; }
    .pmdh-summary__currency-item { display:block; min-width:0; overflow-wrap:anywhere; }
    .pmdh-currency-rates--summary li { margin:0; }
    .pmdh-summary__more { display:block; width:fit-content; margin:.2rem 0 0; padding:0; border:0; background:transparent; color:var(--pmdh-muted); font:inherit; font-size:var(--pmdh-font-size-2xs); font-weight:var(--pmdh-font-weight-semibold); line-height:var(--pmdh-line-height-snug); text-align:left; text-decoration:none; cursor:pointer; }
    .pmdh-summary__more::after { content:" >"; }
    .pmdh-summary__fact-link { color:inherit !important; font:inherit; text-decoration:none !important; }

    /* Once moved into slide 2, switch from white fallback cards to the glass two-column treatment. */
    .pmdh-mobile-details-slot .pmdh-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0;
        width: 100%;
        margin: 28px 0 0;
        overflow: hidden;
        border: 1px solid rgba(255,255,255,.16);
        border-radius: 0;
        background: transparent;
        -webkit-backdrop-filter: var(--pmdh-glass-filter);
        backdrop-filter: var(--pmdh-glass-filter);
        box-shadow: none;
    }
    .pmdh-mobile-details-slot .pmdh-summary__item {
        position: relative;
        width: 100%;
        max-width: 100%;
        min-height: 0;
        padding: .8rem;
        flex-direction: column;
        align-items: flex-start;
        gap: .5rem;
        border: 0;
        border-radius: 0;
        background: transparent;
        color: #fff;
        box-shadow: inset -1px -1px 0 rgba(255,255,255,.14);
    }
    .pmdh-mobile-details-slot .pmdh-summary__label { color:#fff; font-size:var(--pmdh-font-size-summary-label); line-height:var(--pmdh-line-height-tight); }
    .pmdh-mobile-details-slot .pmdh-summary__value,
    .pmdh-mobile-details-slot .pmdh-summary__value a { color:rgba(255,255,255,.66) !important; font-size:var(--pmdh-font-size-summary-value); line-height:var(--pmdh-line-height-tight); }
    .pmdh-mobile-details-slot .pmdh-summary__details { grid-column:auto; background:transparent; color:#fff; box-shadow:inset -1px -1px 0 rgba(255,255,255,.14); }
    .pmdh-mobile-details-slot .pmdh-summary__icon { width:34px; height:34px; flex-basis:34px; border:1px solid rgba(255,255,255,.12); border-radius:var(--pmdh-radius); background:rgba(255,255,255,.12); color:#fff; }
    .pmdh-mobile-details-slot .pmdh-summary__copy { width:100%; }
    .pmdh-mobile-details-slot .pmdh-summary__details-arrow { position:absolute; top:.85rem; right:.75rem; margin-left:0; color:rgba(255,255,255,.90); }
    .pmdh-mobile-details-slot .pmdh-summary[data-pmdh-section="territory-summary"] .pmdh-summary__fact { grid-template-columns:1fr; gap:.08rem; }
    .pmdh-mobile-details-slot .pmdh-summary[data-pmdh-section="territory-summary"] .pmdh-summary__fact dt { color:#fff; }
    .pmdh-mobile-details-slot .pmdh-summary[data-pmdh-section="territory-summary"] .pmdh-summary__fact dd,
    .pmdh-mobile-details-slot .pmdh-summary[data-pmdh-section="territory-summary"] .pmdh-summary__fact-link { color:rgba(255,255,255,.66) !important; }
    .pmdh-mobile-details-slot .pmdh-summary__weather-day-length { color:rgba(255,255,255,.66); }
    .pmdh-mobile-details-slot .pmdh-summary__weather { appearance:none; width:100%; color:#fff; font:inherit; text-align:left; cursor:pointer; }
    .pmdh-summary__weather-value { font-variant-numeric:tabular-nums; white-space:nowrap; }
    .pmdh-summary__weather-day-length { display:block; margin-top:.16rem; font-size:var(--pmdh-font-size-2xs); line-height:var(--pmdh-line-height-tight); font-variant-numeric:tabular-nums; white-space:nowrap; }
    .pmdh-summary__weather .pmdh-summary__details-arrow { opacity:.78; }

    /* Territory second-slide controls are non-first-paint. */
    .pmdh--taxonomy .pmdh__hero-details .pmdh-summary { position:static; z-index:auto; }
    .pmdh--taxonomy .pmdh-summary__details > * { pointer-events:none; }
    .pmdh--taxonomy .pmdh-summary__details .pmdh-summary__copy { flex:1 1 auto; width:auto; }
    .pmdh--taxonomy .pmdh-summary__details-arrow { flex:0 0 auto; margin-left:auto; }
    .pmdh--taxonomy .pmdh__actions { display:flex; width:auto; margin-top:24px; }
    .pmdh--taxonomy .pmdh__action--share { width:auto; max-width:100%; height:var(--pmdh-pill-height) !important; min-height:var(--pmdh-pill-height) !important; border-color:var(--pmdh-glass-border); border-radius:var(--pmdh-radius); background:var(--pmdh-glass-background); color:#fff !important; -webkit-backdrop-filter:var(--pmdh-glass-filter); backdrop-filter:var(--pmdh-glass-filter); box-shadow:var(--pmdh-glass-shadow); }
}
