/* PAT Chapter Locator */

.pat-loc-scope {
    --pl-primary: #24478f;
    --pl-primary-dark: #1a3670;
    --pl-navy: #13254d;
    --pl-gold: #d4af35;
    --pl-gold-soft: #fbf3d9;
    --pl-ink: #0f172a;
    --pl-text: #334155;
    --pl-muted: #64748b;
    --pl-faint: #94a3b8;
    --pl-line: #e5e9f0;
    --pl-line-strong: #cfd8e6;
    --pl-fill: #f3f5f9;
    --pl-canvas: #f7f8fb;
    --pl-ring: 0 0 0 4px rgba(36, 71, 143, 0.12);
    --pl-shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05);
    --pl-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px -6px rgba(15, 23, 42, 0.08);
    --pl-shadow-lg: 0 24px 64px -12px rgba(15, 23, 42, 0.28);
    --pl-ease: cubic-bezier(0.16, 1, 0.3, 1);
    font-family: inherit;
    color: var(--pl-text);
    font-size: 14px;
    line-height: 1.45;
    -webkit-font-smoothing: antialiased;
    box-sizing: border-box;
}

.pat-loc-scope *,
.pat-loc-scope *::before,
.pat-loc-scope *::after {
    box-sizing: border-box;
}

.pat-loc-scope [hidden],
.pat-loc-scope[hidden] {
    display: none !important;
}

.pat-loc-scope button,
.pat-loc-scope input,
.pat-loc-scope select,
.pat-loc-scope textarea {
    font: inherit;
    color: inherit;
    letter-spacing: normal;
    text-transform: none;
    margin: 0;
}

.pat-loc-scope button {
    background: none;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    padding: 0;
    min-height: 0;
    min-width: 0;
    line-height: 1.2;
    cursor: pointer;
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
}

.pat-loc-scope h2,
.pat-loc-scope h3,
.pat-loc-scope p,
.pat-loc-scope ul,
.pat-loc-scope li {
    margin: 0;
    padding: 0;
}

.pat-loc-scope ul {
    list-style: none;
}

.pat-loc-scope a {
    text-decoration: none;
    box-shadow: none;
}

.pat-loc-scope svg {
    flex-shrink: 0;
    display: block;
}

.pat-loc-scope .pat-loc-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.pat-loc-scope :focus-visible {
    outline: 2px solid var(--pl-primary);
    outline-offset: 2px;
}

/* ---------- Shell ---------- */

.pat-loc {
    max-width: 1440px;
    margin: 0 auto;
    position: relative;
}

/* ---------- Filter bar ---------- */

.pat-loc-scope .pat-loc-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    margin: 0 0 16px;
    background: #fff;
    border: 1px solid var(--pl-line);
    border-radius: 18px;
    box-shadow: var(--pl-shadow);
    position: relative;
    z-index: 20;
}

.pat-loc-scope .pat-loc-extra {
    display: contents;
}

.pat-loc-scope .pat-loc-extra-head,
.pat-loc-scope .pat-loc-extra-foot,
.pat-loc-scope .pat-loc-extra-label,
.pat-loc-scope .pat-loc-sheet-grab,
.pat-loc-scope .pat-loc-filters-btn {
    display: none;
}

.pat-loc-scope .pat-loc-extra-group {
    display: contents;
}

.pat-loc-scope .pat-loc-field {
    position: relative;
    display: flex;
    align-items: center;
    height: 48px;
    background: var(--pl-fill);
    border: 1px solid transparent;
    border-radius: 12px;
    transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.pat-loc-scope .pat-loc-field:hover {
    background: #edf0f6;
}

.pat-loc-scope .pat-loc-field:focus-within {
    background: #fff;
    border-color: var(--pl-primary);
    box-shadow: var(--pl-ring);
}

.pat-loc-scope .pat-loc-field-search {
    flex: 1 1 320px;
    min-width: 220px;
}

.pat-loc-scope .pat-loc-field-where {
    flex: 0 1 250px;
    min-width: 200px;
}

.pat-loc-scope .pat-loc-combo {
    position: relative;
    flex: 0 1 240px;
    min-width: 190px;
}

.pat-loc-scope .pat-loc-field-sort {
    flex: 0 0 190px;
}

.pat-loc-scope .pat-loc-field-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--pl-faint);
    pointer-events: none;
    transition: color 0.15s ease;
}

.pat-loc-scope .pat-loc-field:focus-within .pat-loc-field-icon {
    color: var(--pl-primary);
}

.pat-loc-scope .pat-loc-input,
.pat-loc-scope input.pat-loc-input[type="search"],
.pat-loc-scope input.pat-loc-input[type="text"] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 100%;
    min-height: 0;
    padding: 0 12px 0 42px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    box-shadow: none;
    outline: none;
    font-size: 15px;
    font-weight: 500;
    color: var(--pl-ink);
    text-overflow: ellipsis;
}

.pat-loc-scope .pat-loc-input::placeholder {
    color: var(--pl-faint);
    font-weight: 400;
    opacity: 1;
}

.pat-loc-scope .pat-loc-input::-webkit-search-cancel-button,
.pat-loc-scope .pat-loc-input::-webkit-search-decoration {
    -webkit-appearance: none;
    display: none;
}

.pat-loc-scope .pat-loc-input:focus {
    outline: none;
    box-shadow: none;
    border: 0;
}

.pat-loc-scope .pat-loc-field-where .pat-loc-input {
    padding-right: 76px;
}

.pat-loc-scope .pat-loc-field-search .pat-loc-input {
    padding-right: 44px;
}

.pat-loc-scope .pat-loc-field-region .pat-loc-input {
    padding-right: 40px;
    cursor: pointer;
}

.pat-loc-scope .pat-loc-field-region .pat-loc-input:focus {
    cursor: text;
}

.pat-loc-scope .pat-loc-select {
    padding-right: 36px;
    cursor: pointer;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    line-height: 46px;
}

.pat-loc-scope .pat-loc-kbd {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    color: var(--pl-muted);
    background: #fff;
    border: 1px solid var(--pl-line);
    border-bottom-width: 2px;
    border-radius: 6px;
    pointer-events: none;
}

.pat-loc-scope .pat-loc-field:focus-within .pat-loc-kbd,
.pat-loc-scope .pat-loc-field.has-value .pat-loc-kbd {
    display: none;
}

.pat-loc-scope .pat-loc-field-clear {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--pl-muted);
    background: #e2e7ef;
    transition: background 0.15s ease, color 0.15s ease;
}

.pat-loc-scope .pat-loc-field-clear:hover {
    background: var(--pl-ink);
    color: #fff;
}

.pat-loc-scope .pat-loc-field-where .pat-loc-field-clear {
    right: 46px;
}

.pat-loc-scope .pat-loc-near-btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--pl-primary);
    background: #fff;
    box-shadow: var(--pl-shadow-sm);
    border: 1px solid var(--pl-line);
    transition: all 0.15s ease;
}

.pat-loc-scope .pat-loc-near-btn:hover {
    background: var(--pl-primary);
    border-color: var(--pl-primary);
    color: #fff;
}

.pat-loc-scope .pat-loc-near-btn.is-active {
    background: var(--pl-primary);
    border-color: var(--pl-primary);
    color: #fff;
}

.pat-loc-scope .pat-loc-near-btn.is-busy svg,
.pat-loc-scope .pat-loc-field-where.is-busy .pat-loc-field-icon {
    animation: pat-loc-pulse 1s ease-in-out infinite;
}

.pat-loc-scope .pat-loc-combo-toggle {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--pl-muted);
    transition: transform 0.2s ease, background 0.15s ease;
}

.pat-loc-scope .pat-loc-combo.is-open .pat-loc-combo-toggle {
    transform: translateY(-50%) rotate(180deg);
}

.pat-loc-scope .pat-loc-combo-toggle:hover {
    background: #e2e7ef;
}

.pat-loc-scope .pat-loc-field-region.has-value .pat-loc-input {
    color: var(--pl-primary);
}

.pat-loc-scope .pat-loc-combo-list {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    min-width: 260px;
    max-height: 320px;
    overflow-y: auto;
    padding: 6px;
    background: #fff;
    border: 1px solid var(--pl-line);
    border-radius: 14px;
    box-shadow: var(--pl-shadow-lg);
    z-index: 30;
    overscroll-behavior: contain;
    animation: pat-loc-pop 0.18s var(--pl-ease);
}

.pat-loc-scope .pat-loc-combo-opt {
    padding: 9px 12px;
    border-radius: 9px;
    font-size: 14px;
    color: var(--pl-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.pat-loc-scope .pat-loc-combo-opt.is-active {
    background: var(--pl-fill);
    color: var(--pl-ink);
}

.pat-loc-scope .pat-loc-combo-opt[aria-selected="true"] {
    color: var(--pl-primary);
    font-weight: 600;
}

.pat-loc-scope .pat-loc-combo-opt[aria-selected="true"]::after {
    content: "";
    width: 16px;
    height: 16px;
    background: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2324478f' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") no-repeat center;
}

.pat-loc-scope .pat-loc-combo-empty {
    padding: 12px;
    font-size: 13px;
    color: var(--pl-muted);
    text-align: center;
}

.pat-loc-scope .pat-loc-hint {
    margin: -6px 4px 14px;
    padding: 10px 14px;
    font-size: 13px;
    color: #7a5b00;
    background: var(--pl-gold-soft);
    border: 1px solid #f0dfa4;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ---------- Main split ---------- */

.pat-loc-scope .pat-loc-main {
    display: grid;
    grid-template-columns: minmax(360px, 440px) minmax(0, 1fr);
    gap: 16px;
    height: clamp(560px, calc(100vh - 150px), 880px);
}

.pat-loc-scope .pat-loc-panel {
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: #fff;
    border: 1px solid var(--pl-line);
    border-radius: 18px;
    box-shadow: var(--pl-shadow);
    overflow: hidden;
}

.pat-loc-scope .pat-loc-panel-head {
    padding: 16px 18px 12px;
    border-bottom: 1px solid var(--pl-line);
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: linear-gradient(180deg, #fff 0%, #fbfcfe 100%);
}

.pat-loc-scope .pat-loc-count-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.pat-loc-scope .pat-loc-count {
    font-size: 15px;
    color: var(--pl-text);
}

.pat-loc-scope .pat-loc-count strong {
    font-size: 20px;
    font-weight: 700;
    color: var(--pl-ink);
    letter-spacing: -0.01em;
    margin-right: 2px;
}

.pat-loc-scope .pat-loc-count em {
    font-style: normal;
    font-weight: 600;
    color: var(--pl-primary);
}

.pat-loc-scope .pat-loc-link {
    font-size: 13px;
    font-weight: 600;
    color: var(--pl-primary);
    white-space: nowrap;
    padding: 4px 2px;
    border-radius: 6px;
}

.pat-loc-scope .pat-loc-link:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.pat-loc-scope .pat-loc-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.pat-loc-scope .pat-loc-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    max-width: 100%;
    height: 30px;
    padding: 0 6px 0 12px;
    font-size: 13px;
    font-weight: 500;
    color: var(--pl-primary);
    background: #eef3fc;
    border: 1px solid #d9e3f6;
    border-radius: 999px;
    transition: all 0.15s ease;
}

.pat-loc-scope .pat-loc-chip-text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pat-loc-scope .pat-loc-chip-x {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(36, 71, 143, 0.12);
    flex-shrink: 0;
}

.pat-loc-scope .pat-loc-chip:hover {
    background: #fdecec;
    border-color: #f6caca;
    color: #b42318;
}

.pat-loc-scope .pat-loc-chip:hover .pat-loc-chip-x {
    background: rgba(180, 35, 24, 0.14);
}

/* Switch */

.pat-loc-scope .pat-loc-switch {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--pl-muted);
    cursor: pointer;
    user-select: none;
    margin: 0;
    font-weight: 400;
}

.pat-loc-scope .pat-loc-switch input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}

.pat-loc-scope .pat-loc-switch-track {
    position: relative;
    width: 36px;
    height: 20px;
    border-radius: 999px;
    background: #cbd5e1;
    transition: background 0.2s ease;
    flex-shrink: 0;
}

.pat-loc-scope .pat-loc-switch-thumb {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.25);
    transition: transform 0.2s var(--pl-ease);
}

.pat-loc-scope .pat-loc-switch input:checked + .pat-loc-switch-track {
    background: var(--pl-primary);
}

.pat-loc-scope .pat-loc-switch input:checked + .pat-loc-switch-track .pat-loc-switch-thumb {
    transform: translateX(16px);
}

.pat-loc-scope .pat-loc-switch input:focus-visible + .pat-loc-switch-track {
    box-shadow: var(--pl-ring);
}

/* ---------- List ---------- */

.pat-loc-scope .pat-loc-list {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    scrollbar-width: thin;
    scrollbar-color: #cfd8e6 transparent;
    overscroll-behavior: contain;
}

.pat-loc-scope .pat-loc-list::-webkit-scrollbar {
    width: 8px;
}

.pat-loc-scope .pat-loc-list::-webkit-scrollbar-thumb {
    background: #d5dce8;
    border-radius: 8px;
    border: 2px solid #fff;
}

.pat-loc-scope .pat-loc-card {
    position: relative;
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr) auto;
    column-gap: 14px;
    row-gap: 12px;
    padding: 14px;
    background: #fff;
    border: 1px solid var(--pl-line);
    border-radius: 14px;
    cursor: pointer;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
    animation: pat-loc-fade 0.25s ease both;
    outline: none;
}

.pat-loc-scope .pat-loc-card:hover,
.pat-loc-scope .pat-loc-card.is-hover {
    border-color: var(--pl-line-strong);
    box-shadow: 0 10px 24px -12px rgba(15, 23, 42, 0.22);
    transform: translateY(-1px);
}

.pat-loc-scope .pat-loc-card:focus-visible {
    border-color: var(--pl-primary);
    box-shadow: var(--pl-ring);
}

.pat-loc-scope .pat-loc-card.is-active {
    border-color: var(--pl-gold);
    box-shadow: 0 0 0 3px rgba(212, 175, 53, 0.22), 0 10px 24px -12px rgba(15, 23, 42, 0.22);
}

.pat-loc-scope .pat-loc-card.is-active::before {
    content: "";
    position: absolute;
    left: -1px;
    top: 14px;
    bottom: 14px;
    width: 3px;
    border-radius: 0 3px 3px 0;
    background: var(--pl-gold);
}

.pat-loc-scope .pat-loc-av {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    overflow: hidden;
    flex-shrink: 0;
    background: var(--pl-fill);
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
    display: flex;
    align-items: center;
    justify-content: center;
}

.pat-loc-scope .pat-loc-av > * {
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    border-radius: 0 !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    object-fit: cover;
    margin: 0 !important;
}

.pat-loc-scope .pat-loc-av .pat-chapter-avatar-letters,
.pat-loc-scope .pat-loc-av span.pat-loc-avatar {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, var(--pl-primary), var(--pl-navy));
    letter-spacing: 0.02em;
}

.pat-loc-scope .pat-loc-av.is-lg {
    width: 72px;
    height: 72px;
    border-radius: 18px;
    box-shadow: 0 0 0 4px #fff, 0 8px 20px -8px rgba(15, 23, 42, 0.35);
}

.pat-loc-scope .pat-loc-av.is-lg .pat-chapter-avatar-letters,
.pat-loc-scope .pat-loc-av.is-lg span.pat-loc-avatar {
    font-size: 18px;
}

.pat-loc-scope .pat-loc-av.is-sm {
    width: 40px;
    height: 40px;
    border-radius: 10px;
}

.pat-loc-scope .pat-loc-card-body {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.pat-loc-scope .pat-loc-card-school {
    font-size: 15px;
    font-weight: 600;
    color: var(--pl-ink);
    line-height: 1.3;
    letter-spacing: -0.005em;
    margin: 0;
}

.pat-loc-scope .pat-loc-card-greek {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--pl-text);
    min-width: 0;
}

.pat-loc-scope .pat-loc-card-greek-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pat-loc-scope .pat-loc-letters {
    display: inline-flex;
    align-items: center;
    height: 20px;
    padding: 0 6px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--pl-gold);
    background: var(--pl-navy);
    border-radius: 6px;
    flex-shrink: 0;
}

.pat-loc-scope .pat-loc-card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 10px;
    font-size: 12.5px;
    color: var(--pl-muted);
    margin-top: 2px;
}

.pat-loc-scope .pat-loc-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    min-width: 0;
}

.pat-loc-scope .pat-loc-meta-item svg {
    color: var(--pl-faint);
}

.pat-loc-scope .pat-loc-card-aside {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.pat-loc-scope .pat-loc-distance {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 24px;
    padding: 0 9px;
    font-size: 12px;
    font-weight: 600;
    color: #7a5b00;
    background: var(--pl-gold-soft);
    border-radius: 999px;
    white-space: nowrap;
}

.pat-loc-scope .pat-loc-nomap {
    font-size: 11px;
    color: var(--pl-faint);
    white-space: nowrap;
}

.pat-loc-scope .pat-loc-card-actions {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding-top: 12px;
    border-top: 1px solid #eef1f6;
}

.pat-loc-scope .pat-loc-act {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 32px;
    padding: 0 12px;
    font-size: 13px;
    font-weight: 600;
    color: var(--pl-primary);
    background: var(--pl-fill);
    border: 1px solid transparent;
    border-radius: 999px;
    transition: all 0.15s ease;
    white-space: nowrap;
}

.pat-loc-scope .pat-loc-act:hover {
    background: #e6ecf7;
    color: var(--pl-primary-dark);
}

.pat-loc-scope .pat-loc-act.is-primary {
    color: #fff;
    background: var(--pl-primary);
}

.pat-loc-scope .pat-loc-act.is-primary:hover {
    background: var(--pl-primary-dark);
    color: #fff;
}

.pat-loc-scope .pat-loc-more {
    padding: 14px;
    text-align: center;
    font-size: 13px;
    color: var(--pl-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Skeleton */

.pat-loc-scope .pat-loc-skel {
    display: flex;
    gap: 14px;
    padding: 14px;
    border: 1px solid var(--pl-line);
    border-radius: 14px;
}

.pat-loc-scope .pat-loc-skel-avatar,
.pat-loc-scope .pat-loc-skel-line {
    background: linear-gradient(90deg, #f1f4f8 25%, #e6ebf2 50%, #f1f4f8 75%);
    background-size: 200% 100%;
    animation: pat-loc-shimmer 1.4s ease-in-out infinite;
    border-radius: 8px;
}

.pat-loc-scope .pat-loc-skel-avatar {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    flex-shrink: 0;
}

.pat-loc-scope .pat-loc-skel-lines {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 9px;
    padding-top: 4px;
}

.pat-loc-scope .pat-loc-skel-line {
    display: block;
    height: 11px;
}

.pat-loc-scope .pat-loc-skel-line.is-short {
    width: 28%;
}

/* Empty + alert */

.pat-loc-scope .pat-loc-empty {
    margin: auto 0;
    padding: 48px 24px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.pat-loc-scope .pat-loc-empty-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--pl-fill);
    color: var(--pl-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
}

.pat-loc-scope .pat-loc-empty-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--pl-ink);
}

.pat-loc-scope .pat-loc-empty-text {
    font-size: 13px;
    color: var(--pl-muted);
    max-width: 280px;
}

.pat-loc-scope .pat-loc-empty .pat-loc-btn {
    margin-top: 12px;
}

.pat-loc-scope .pat-loc-alert {
    margin: 12px 12px 0;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 13px;
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* ---------- Detail panel ---------- */

.pat-loc-scope .pat-loc-detail {
    position: absolute;
    inset: 0;
    z-index: 4;
    background: #fff;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.32s var(--pl-ease);
}

.pat-loc-scope .pat-loc-detail.is-open {
    transform: translateX(0);
}

.pat-loc-scope .pat-loc-detail-top {
    padding: 10px 12px;
    border-bottom: 1px solid var(--pl-line);
    display: flex;
    align-items: center;
}

.pat-loc-scope .pat-loc-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 34px;
    padding: 0 12px 0 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--pl-text);
    border-radius: 999px;
    transition: background 0.15s ease;
}

.pat-loc-scope .pat-loc-back:hover {
    background: var(--pl-fill);
}

.pat-loc-scope .pat-loc-detail-scroll {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
}

.pat-loc-scope .pat-loc-dt-hero {
    position: relative;
    padding: 28px 24px 20px;
    background:
        radial-gradient(120% 140% at 100% 0%, rgba(212, 175, 53, 0.22) 0%, rgba(212, 175, 53, 0) 45%),
        linear-gradient(160deg, #1b326a 0%, #13254d 60%, #0d1b3a 100%);
    color: #fff;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.pat-loc-scope .pat-loc-dt-school {
    font-size: 21px;
    font-weight: 700;
    line-height: 1.25;
    color: #fff;
    letter-spacing: -0.01em;
    margin: 0;
}

.pat-loc-scope .pat-loc-dt-greek {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.82);
}

.pat-loc-scope .pat-loc-dt-hero .pat-loc-letters {
    background: rgba(255, 255, 255, 0.12);
    box-shadow: inset 0 0 0 1px rgba(212, 175, 53, 0.5);
}

.pat-loc-scope .pat-loc-dt-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.pat-loc-scope .pat-loc-dt-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 26px;
    padding: 0 10px;
    font-size: 12px;
    font-weight: 600;
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 999px;
}

.pat-loc-scope .pat-loc-dt-badge.is-gold {
    color: var(--pl-navy);
    background: var(--pl-gold);
}

.pat-loc-scope .pat-loc-dt-body {
    padding: 20px 24px 24px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.pat-loc-scope .pat-loc-dt-rows {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.pat-loc-scope .pat-loc-dt-row {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 10px 0;
    border-bottom: 1px solid #f0f2f6;
}

.pat-loc-scope .pat-loc-dt-row:last-child {
    border-bottom: 0;
}

.pat-loc-scope .pat-loc-dt-ico {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--pl-fill);
    color: var(--pl-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.pat-loc-scope .pat-loc-dt-label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--pl-faint);
}

.pat-loc-scope .pat-loc-dt-value {
    font-size: 14px;
    color: var(--pl-ink);
    font-weight: 500;
    margin-top: 2px;
    word-break: break-word;
}

.pat-loc-scope .pat-loc-dt-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pat-loc-scope .pat-loc-dt-actions-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.pat-loc-scope .pat-loc-dt-note {
    font-size: 13px;
    color: var(--pl-muted);
    background: var(--pl-canvas);
    border: 1px dashed var(--pl-line-strong);
    border-radius: 12px;
    padding: 10px 12px;
}

/* ---------- Buttons ---------- */

.pat-loc-scope .pat-loc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 44px;
    padding: 0 18px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 12px;
    border: 1px solid transparent;
    transition: all 0.15s ease;
    white-space: nowrap;
    text-decoration: none;
    line-height: 1;
}

.pat-loc-scope .pat-loc-btn-primary {
    background: var(--pl-primary);
    color: #fff;
    box-shadow: 0 6px 16px -8px rgba(36, 71, 143, 0.7);
}

.pat-loc-scope .pat-loc-btn-primary:hover {
    background: var(--pl-primary-dark);
    color: #fff;
    transform: translateY(-1px);
}

.pat-loc-scope .pat-loc-btn-gold {
    background: var(--pl-gold);
    color: var(--pl-navy);
}

.pat-loc-scope .pat-loc-btn-gold:hover {
    background: #c9a42c;
    color: var(--pl-navy);
}

.pat-loc-scope .pat-loc-btn-ghost {
    background: #fff;
    color: var(--pl-text);
    border-color: var(--pl-line-strong);
}

.pat-loc-scope .pat-loc-btn-ghost:hover {
    background: var(--pl-fill);
    color: var(--pl-ink);
}

.pat-loc-scope .pat-loc-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.pat-loc-scope .pat-loc-icon-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--pl-muted);
    background: var(--pl-fill);
    flex-shrink: 0;
    transition: all 0.15s ease;
}

.pat-loc-scope .pat-loc-icon-btn:hover {
    background: #e2e7ef;
    color: var(--pl-ink);
}

/* ---------- Map ---------- */

.pat-loc-scope .pat-loc-map-pane {
    position: relative;
    min-height: 0;
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid var(--pl-line);
    box-shadow: var(--pl-shadow);
    background: #e9edf3;
    isolation: isolate;
}

.pat-loc-scope .pat-loc-map {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.pat-loc-scope .pat-loc-map,
.pat-loc-scope .pat-loc-map * {
    box-sizing: content-box;
}

.pat-loc-scope .pat-loc-map img {
    max-width: none !important;
    max-height: none !important;
}

.pat-loc-scope .pat-loc-map .pat-loc-pin,
.pat-loc-scope .pat-loc-map .pat-loc-pin *,
.pat-loc-scope .pat-loc-map .pat-loc-popup,
.pat-loc-scope .pat-loc-map .pat-loc-popup *,
.pat-loc-scope .pat-loc-map .pat-loc-cluster {
    box-sizing: border-box;
}

.pat-loc-scope .pat-loc-map-loading {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-size: 13px;
    font-weight: 500;
    color: var(--pl-muted);
    background:
        linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.5) 50%, rgba(255, 255, 255, 0) 100%) 0 0 / 200% 100%,
        #e9edf3;
    animation: pat-loc-shimmer 1.8s ease-in-out infinite;
    transition: opacity 0.35s ease;
}

.pat-loc-scope .pat-loc-map-loading.is-done {
    opacity: 0;
    pointer-events: none;
}

.pat-loc-scope .pat-loc-spinner {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 3px solid rgba(36, 71, 143, 0.15);
    border-top-color: var(--pl-primary);
    animation: pat-loc-spin 0.8s linear infinite;
}

.pat-loc-scope .pat-loc-map-note {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: #eef1f6;
}

.pat-loc-scope .pat-loc-map-note-card {
    max-width: 340px;
    text-align: center;
    padding: 28px 24px;
    background: #fff;
    border-radius: 18px;
    box-shadow: var(--pl-shadow);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.pat-loc-scope .pat-loc-map-note-card .pat-loc-empty-icon {
    margin-bottom: 6px;
}

.pat-loc-scope .pat-loc-map-note-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--pl-ink);
}

.pat-loc-scope .pat-loc-map-note-text {
    font-size: 13px;
    color: var(--pl-muted);
}

.pat-loc-scope .pat-loc-map-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: #fff;
    color: var(--pl-text);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.16);
    transition: all 0.15s ease;
}

.pat-loc-scope .pat-loc-map-btn:hover {
    color: var(--pl-primary);
    transform: translateY(-1px);
}

/* Advanced marker pins */

.pat-loc-scope .pat-loc-pin {
    width: 30px;
    height: 40px;
    transform-origin: 50% 100%;
    transition: transform 0.18s var(--pl-ease);
    filter: drop-shadow(0 3px 4px rgba(15, 23, 42, 0.3));
    cursor: pointer;
}

.pat-loc-scope .pat-loc-pin svg {
    width: 30px;
    height: 40px;
}

.pat-loc-scope .pat-loc-pin-body {
    fill: var(--pl-primary);
    transition: fill 0.18s ease;
}

.pat-loc-scope .pat-loc-pin-dot {
    fill: var(--pl-gold);
    transition: fill 0.18s ease;
}

.pat-loc-scope .pat-loc-pin.is-hover {
    transform: scale(1.2);
}

.pat-loc-scope .pat-loc-pin.is-active {
    transform: scale(1.3);
}

.pat-loc-scope .pat-loc-pin.is-active .pat-loc-pin-body {
    fill: var(--pl-gold);
}

.pat-loc-scope .pat-loc-pin.is-active .pat-loc-pin-dot {
    fill: var(--pl-navy);
}

.pat-loc-scope .pat-loc-cluster {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    background: radial-gradient(circle at 30% 30%, #3a62b5 0%, #24478f 55%, #13254d 100%);
    box-shadow: 0 0 0 5px rgba(36, 71, 143, 0.18), 0 4px 10px rgba(15, 23, 42, 0.3);
    border: 2px solid #fff;
    cursor: pointer;
    transition: transform 0.15s ease;
}

.pat-loc-scope .pat-loc-cluster:hover {
    transform: scale(1.08);
}

.pat-loc-scope .pat-loc-origin {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #2563eb;
    border: 3px solid #fff;
    box-shadow: 0 0 0 6px rgba(37, 99, 235, 0.22), 0 2px 6px rgba(15, 23, 42, 0.3);
}

/* Map popup (InfoWindow) */

.pat-loc-scope .gm-style .gm-style-iw-c {
    padding: 0 !important;
    border-radius: 16px !important;
    box-shadow: 0 16px 40px -12px rgba(15, 23, 42, 0.35) !important;
    max-width: 300px !important;
}

.pat-loc-scope .gm-style .gm-style-iw-d {
    overflow: hidden !important;
    padding: 0 !important;
    max-height: none !important;
}

.pat-loc-scope .gm-style .gm-style-iw-chr {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 2;
}

.pat-loc-scope .gm-style .gm-style-iw-tc::after {
    background: #fff;
}

.pat-loc-scope .pat-loc-popup {
    position: relative;
    width: 272px;
    padding: 14px;
    font-family: inherit;
    color: var(--pl-text);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.pat-loc-scope .pat-loc-popup-head {
    display: flex;
    gap: 12px;
    align-items: center;
    padding-right: 24px;
}

.pat-loc-scope .pat-loc-popup-school {
    font-size: 14px;
    font-weight: 600;
    color: var(--pl-ink);
    line-height: 1.3;
}

.pat-loc-scope .pat-loc-popup-sub {
    font-size: 12px;
    color: var(--pl-muted);
    margin-top: 2px;
}

.pat-loc-scope .pat-loc-popup-actions {
    display: flex;
    gap: 6px;
}

.pat-loc-scope .pat-loc-popup-actions .pat-loc-act {
    flex: 1;
    justify-content: center;
}

.pat-loc-scope .pat-loc-popup-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--pl-muted);
    background: var(--pl-fill);
}

.pat-loc-scope .pat-loc-popup-close:hover {
    background: #e2e7ef;
    color: var(--pl-ink);
}

/* Mobile peek card */

.pat-loc-scope .pat-loc-peek {
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 84px;
    z-index: 5;
    padding: 14px;
    background: #fff;
    border-radius: 18px;
    box-shadow: var(--pl-shadow-lg);
    display: flex;
    flex-direction: column;
    gap: 12px;
    animation: pat-loc-rise 0.3s var(--pl-ease);
    touch-action: pan-x;
}

.pat-loc-scope .pat-loc-peek.is-dragging {
    transition: none;
}

.pat-loc-scope .pat-loc-peek-main {
    display: flex;
    gap: 12px;
    align-items: center;
    padding-right: 30px;
    cursor: pointer;
}

/* ---------- View toggle (mobile) ---------- */

.pat-loc-scope .pat-loc-view-toggle-wrap {
    display: none;
}

/* ---------- Overlays, sheets, modals ---------- */

.pat-loc-scope.pat-loc-overlay {
    position: fixed;
    inset: 0;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 23, 42, 0.5);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    animation: pat-loc-fade-in 0.2s ease;
}

.pat-loc-scope.pat-loc-backdrop {
    position: fixed;
    inset: 0;
    z-index: 99998;
    background: rgba(15, 23, 42, 0.45);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
    animation: pat-loc-fade-in 0.2s ease;
}

.pat-loc-scope .pat-loc-modal {
    position: relative;
    width: 100%;
    max-width: 520px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    background: #fff;
    border-radius: 20px;
    box-shadow: var(--pl-shadow-lg);
    animation: pat-loc-pop 0.3s var(--pl-ease);
}

.pat-loc-scope .pat-loc-detail-modal {
    max-width: 440px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.pat-loc-scope .pat-loc-detail-modal #pat-loc-sheet-body {
    overflow-y: auto;
    flex: 1;
    min-height: 0;
}

.pat-loc-scope .pat-loc-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 3;
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
}

.pat-loc-scope .pat-loc-modal-close:hover {
    background: rgba(255, 255, 255, 0.28);
    color: #fff;
}

.pat-loc-scope .pat-loc-modal-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 22px 24px 4px;
}

.pat-loc-scope .pat-loc-modal-eyebrow {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--pl-gold);
}

.pat-loc-scope .pat-loc-modal-title {
    margin: 4px 0 0;
    font-size: 20px;
    font-weight: 700;
    color: var(--pl-ink);
    line-height: 1.3;
}

.pat-loc-scope .pat-loc-modal-body {
    padding: 16px 24px 24px;
}

.pat-loc-scope .pat-loc-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.pat-loc-scope .pat-loc-form-field {
    margin-bottom: 14px;
}

.pat-loc-scope .pat-loc-form-field label {
    display: block;
    margin: 0 0 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--pl-text);
}

.pat-loc-scope .pat-loc-form-field input,
.pat-loc-scope .pat-loc-form-field textarea {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 44px;
    padding: 0 14px;
    font-size: 15px;
    color: var(--pl-ink);
    background: var(--pl-fill);
    border: 1px solid transparent;
    border-radius: 12px;
    box-shadow: none;
    transition: all 0.15s ease;
}

.pat-loc-scope .pat-loc-form-field textarea {
    height: auto;
    min-height: 128px;
    padding: 12px 14px;
    line-height: 1.5;
    resize: vertical;
}

.pat-loc-scope .pat-loc-form-field input:focus,
.pat-loc-scope .pat-loc-form-field textarea:focus {
    outline: none;
    background: #fff;
    border-color: var(--pl-primary);
    box-shadow: var(--pl-ring);
}

.pat-loc-scope .pat-loc-form-field.is-invalid input,
.pat-loc-scope .pat-loc-form-field.is-invalid textarea {
    border-color: #ef4444;
    background: #fff;
}

.pat-loc-scope .pat-loc-required {
    color: #dc2626;
}

.pat-loc-scope .pat-loc-field-error {
    margin: 6px 0 0;
    font-size: 12px;
    color: #dc2626;
}

.pat-loc-scope .pat-loc-form-note {
    margin: 0 0 14px;
    padding: 10px 12px;
    font-size: 13px;
    color: #991b1b;
    background: #fef2f2;
    border-radius: 10px;
}

.pat-loc-scope .pat-loc-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 4px;
}

.pat-loc-scope .pat-loc-contact-result {
    text-align: center;
    padding: 36px 28px 28px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.pat-loc-scope .pat-loc-result-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #ecfdf5;
    color: #059669;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
    animation: pat-loc-pop 0.4s var(--pl-ease);
}

.pat-loc-scope .pat-loc-contact-result h3 {
    font-size: 19px;
    font-weight: 700;
    color: var(--pl-ink);
}

.pat-loc-scope .pat-loc-contact-result p {
    font-size: 14px;
    color: var(--pl-muted);
    max-width: 320px;
}

.pat-loc-scope .pat-loc-contact-result .pat-loc-btn {
    margin-top: 14px;
    min-width: 140px;
}

.pat-loc-scope .pat-loc-hp {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.pat-loc-scope .pat-loc-sheet-grab {
    width: 40px;
    height: 5px;
    border-radius: 999px;
    background: #d5dce8;
    margin: 10px auto 0;
}

/* ---------- Animations ---------- */

@keyframes pat-loc-shimmer {
    0% { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

@keyframes pat-loc-spin {
    to { transform: rotate(360deg); }
}

@keyframes pat-loc-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.35; }
}

@keyframes pat-loc-fade {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pat-loc-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes pat-loc-pop {
    from { opacity: 0; transform: scale(0.96) translateY(6px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes pat-loc-rise {
    from { opacity: 0; transform: translateY(24px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pat-loc-sheet-up {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

/* ---------- Medium desktop ---------- */

@media (max-width: 1200px) and (min-width: 993px) {
    .pat-loc-scope .pat-loc-bar {
        flex-wrap: wrap;
    }

    .pat-loc-scope .pat-loc-field-search {
        flex-basis: 100%;
    }

    .pat-loc-scope .pat-loc-field-where,
    .pat-loc-scope .pat-loc-combo,
    .pat-loc-scope .pat-loc-field-sort {
        flex: 1 1 0;
    }

    .pat-loc-scope .pat-loc-main {
        grid-template-columns: minmax(340px, 400px) minmax(0, 1fr);
    }
}

/* ---------- Tablet + mobile ---------- */

@media (max-width: 992px) {
    .pat-loc-scope .pat-loc-bar {
        padding: 6px;
        border-radius: 16px;
    }

    .pat-loc-scope .pat-loc-field-search {
        flex: 1 1 auto;
        min-width: 0;
    }

    .pat-loc-scope .pat-loc-kbd {
        display: none;
    }

    .pat-loc-scope .pat-loc-filters-btn {
        position: relative;
        display: inline-flex;
        align-items: center;
        gap: 8px;
        height: 48px;
        padding: 0 16px;
        font-size: 14px;
        font-weight: 600;
        color: #fff;
        background: var(--pl-primary);
        border-radius: 12px;
        flex-shrink: 0;
    }

    .pat-loc-scope .pat-loc-filters-count {
        min-width: 20px;
        height: 20px;
        padding: 0 6px;
        border-radius: 999px;
        background: var(--pl-gold);
        color: var(--pl-navy);
        font-size: 12px;
        font-weight: 700;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .pat-loc-scope .pat-loc-extra:not(.is-sheet) {
        display: none;
    }

    .pat-loc-scope .pat-loc-main {
        display: block;
        height: auto;
    }

    .pat-loc-scope .pat-loc-panel {
        border: 0;
        border-radius: 0;
        box-shadow: none;
        background: transparent;
        overflow: visible;
    }

    .pat-loc-scope .pat-loc-panel-head {
        padding: 4px 4px 12px;
        border-bottom: 0;
        background: transparent;
    }

    .pat-loc-scope .pat-loc-list {
        overflow: visible;
        padding: 0;
        flex: none;
    }

    .pat-loc-scope .pat-loc-panel-head .pat-loc-switch {
        display: none;
    }

    .pat-loc-scope .pat-loc-alert {
        margin: 0 0 12px;
    }

    .pat-loc-scope .pat-loc-detail {
        display: none !important;
    }

    .pat-loc-scope .pat-loc-map-pane {
        display: none;
        height: calc(100vh - 170px);
        height: calc(100svh - 170px);
        min-height: 420px;
        border-radius: 16px;
    }

    .pat-loc.is-map-view .pat-loc-map-pane {
        display: block;
    }

    .pat-loc.is-map-view .pat-loc-panel {
        display: none;
    }

    .pat-loc-scope .pat-loc-view-toggle-wrap {
        display: flex;
        justify-content: center;
        position: sticky;
        bottom: 16px;
        bottom: calc(16px + env(safe-area-inset-bottom));
        z-index: 15;
        margin-top: 16px;
        pointer-events: none;
    }

    .pat-loc.is-map-view .pat-loc-view-toggle-wrap {
        margin-top: -68px;
        padding-bottom: 16px;
    }

    .pat-loc-scope .pat-loc-view-toggle {
        pointer-events: auto;
        display: inline-flex;
        align-items: center;
        gap: 8px;
        height: 48px;
        padding: 0 22px;
        font-size: 14px;
        font-weight: 600;
        color: #fff;
        background: var(--pl-ink);
        border-radius: 999px;
        box-shadow: 0 12px 28px -8px rgba(15, 23, 42, 0.55);
        transition: transform 0.15s ease;
    }

    .pat-loc-scope .pat-loc-view-toggle:active {
        transform: scale(0.97);
    }

    /* Filter sheet */

    .pat-loc-scope .pat-loc-extra.is-sheet {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 99999;
        display: flex;
        flex-direction: column;
        gap: 16px;
        max-height: 88vh;
        overflow-y: auto;
        padding: 0 20px calc(20px + env(safe-area-inset-bottom));
        background: #fff;
        border-radius: 22px 22px 0 0;
        box-shadow: var(--pl-shadow-lg);
        animation: pat-loc-sheet-up 0.32s var(--pl-ease);
    }

    .pat-loc-scope .pat-loc-extra.is-sheet .pat-loc-sheet-grab {
        display: block;
        margin-bottom: -6px;
    }

    .pat-loc-scope .pat-loc-extra.is-sheet .pat-loc-extra-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .pat-loc-scope .pat-loc-extra-title {
        font-size: 18px;
        font-weight: 700;
        color: var(--pl-ink);
        margin: 0;
    }

    .pat-loc-scope .pat-loc-extra.is-sheet .pat-loc-extra-group {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }

    .pat-loc-scope .pat-loc-extra.is-sheet .pat-loc-extra-label {
        display: block;
        font-size: 12px;
        font-weight: 600;
        letter-spacing: 0.06em;
        text-transform: uppercase;
        color: var(--pl-muted);
        margin: 0;
    }

    .pat-loc-scope .pat-loc-extra.is-sheet .pat-loc-field,
    .pat-loc-scope .pat-loc-extra.is-sheet .pat-loc-combo {
        flex: none;
        width: 100%;
        min-width: 0;
        height: 50px;
    }

    .pat-loc-scope .pat-loc-extra.is-sheet .pat-loc-combo-list {
        position: static;
        max-height: 240px;
        margin-top: 8px;
        box-shadow: none;
        min-width: 0;
    }

    .pat-loc-scope .pat-loc-extra.is-sheet .pat-loc-combo {
        height: auto;
    }

    .pat-loc-scope .pat-loc-extra.is-sheet .pat-loc-extra-foot {
        display: grid;
        grid-template-columns: auto 1fr;
        gap: 10px;
        padding-top: 4px;
        position: sticky;
        bottom: 0;
        background: #fff;
    }

    .pat-loc-scope .pat-loc-extra.is-sheet .pat-loc-input {
        font-size: 16px;
    }

    /* Mobile modals become bottom sheets */

    .pat-loc-scope.pat-loc-overlay {
        align-items: flex-end;
        padding: 0;
    }

    .pat-loc-scope .pat-loc-modal {
        max-width: 100%;
        max-height: 90vh;
        border-radius: 22px 22px 0 0;
        animation: pat-loc-sheet-up 0.32s var(--pl-ease);
        padding-bottom: env(safe-area-inset-bottom);
    }

    .pat-loc-scope .pat-loc-modal > .pat-loc-sheet-grab {
        position: absolute;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        z-index: 3;
    }

    .pat-loc-scope .pat-loc-detail-modal > .pat-loc-sheet-grab {
        background: rgba(255, 255, 255, 0.4);
    }

    .pat-loc-scope .pat-loc-contact-modal .pat-loc-modal-head {
        padding-top: 26px;
    }

    .pat-loc-scope .pat-loc-form-field input,
    .pat-loc-scope .pat-loc-form-field textarea {
        font-size: 16px;
    }
}

@media (min-width: 993px) {
    .pat-loc-scope .pat-loc-modal > .pat-loc-sheet-grab {
        display: none;
    }
}

@media (max-width: 600px) {
    .pat-loc-scope .pat-loc-filters-btn span:not(.pat-loc-filters-count) {
        display: none;
    }

    .pat-loc-scope .pat-loc-filters-btn {
        padding: 0 14px;
    }

    .pat-loc-scope .pat-loc-card {
        grid-template-columns: 44px minmax(0, 1fr) auto;
        column-gap: 12px;
        padding: 12px;
    }

    .pat-loc-scope .pat-loc-card .pat-loc-av {
        width: 44px;
        height: 44px;
    }

    .pat-loc-scope .pat-loc-form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .pat-loc-scope .pat-loc-form-actions {
        flex-direction: column-reverse;
    }

    .pat-loc-scope .pat-loc-form-actions .pat-loc-btn {
        width: 100%;
    }

    .pat-loc-scope .pat-loc-dt-hero {
        padding: 30px 20px 18px;
    }

    .pat-loc-scope .pat-loc-dt-body {
        padding: 18px 20px 22px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .pat-loc-scope *,
    .pat-loc-scope *::before,
    .pat-loc-scope *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}
