/* =============================================================================
   Norfolk Chamber – Member Directory Styles  v2.0
   ============================================================================= */

/* ── Variables ────────────────────────────────────────────────────────────── */
.norfolk-chamber-directory {
    --nc-primary:       #003057;
    --nc-gold:          #C9A84C;
    --nc-gold-light:    #fdf6e3;
    --nc-radius:        8px;
    --nc-shadow:        0 2px 12px rgba(0,0,0,0.08);
    --nc-shadow-hover:  0 8px 28px rgba(0,0,0,0.14);
    --nc-border:        #e5e7eb;
}

/* ── Search bar ───────────────────────────────────────────────────────────── */
.chamber-search .uk-input {
    border-radius: var(--nc-radius);
    border: 2px solid var(--nc-border);
    padding: 10px 16px 10px 42px;
    font-size: 1rem;
    transition: border-color 0.2s;
    height: 48px;
}
.chamber-search .uk-input:focus {
    border-color: var(--nc-primary);
    outline: none;
}

/* ── Top controls row (search + dropdowns) ───────────────────────────────── */
.chamber-top-controls {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: stretch;
}
.chamber-top-controls .chamber-search {
    flex: 2;
    min-width: 200px;
}
.chamber-filter {
    flex: 1;
    min-width: 160px;
}
.chamber-filter .uk-select {
    height: 48px;
    border-radius: var(--nc-radius);
    border: 2px solid var(--nc-border);
    font-size: 0.95rem;
    transition: border-color 0.2s;
}
.chamber-filter .uk-select:focus {
    border-color: var(--nc-primary);
    outline: none;
}

/* ── Results count ────────────────────────────────────────────────────────── */
.chamber-results-count {
    min-height: 1.4em;
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 8px;
}

/* ── City line on card ────────────────────────────────────────────────────── */
.chamber-city {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.82rem;
    color: #888;
    margin-top: 2px !important;
    margin-bottom: 6px !important;
}

/* ── A–Z filter ───────────────────────────────────────────────────────────── */
.chamber-az-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}
.chamber-az-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 6px;
    border: 1px solid var(--nc-border);
    border-radius: 4px;
    background: #fff;
    color: #555;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    line-height: 1;
}
.chamber-az-btn:hover {
    border-color: var(--nc-primary);
    color: var(--nc-primary);
}
.chamber-az-btn.active {
    background: var(--nc-primary);
    border-color: var(--nc-primary);
    color: #fff;
}

/* ── Member card ──────────────────────────────────────────────────────────── */
.chamber-member-card {
    border-radius: var(--nc-radius);
    box-shadow: var(--nc-shadow);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
    border: 1px solid var(--nc-border);
}
.chamber-member-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--nc-shadow-hover);
}

/* Gold patron highlight */
.chamber-member-card.is-gold-patron {
    border-color: var(--nc-gold);
    box-shadow: 0 2px 16px rgba(201,168,76,0.18);
}
.chamber-member-card.is-gold-patron:hover {
    box-shadow: 0 8px 32px rgba(201,168,76,0.28);
}

/* Gold ribbon */
.chamber-gold-ribbon {
    position: absolute;
    top: 12px;
    right: 0;
    background: var(--nc-gold);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 10px 3px 8px;
    border-radius: 2px 0 0 2px;
    z-index: 2;
}

/* ── Logo ─────────────────────────────────────────────────────────────────── */
.chamber-member-logo-wrap {
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 180px;
    padding: 20px;
    overflow: hidden;
    border-bottom: 1px solid var(--nc-border);
    cursor: pointer;
}
.chamber-member-logo {
    max-width: 75%;
    max-height: 140px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

/* ── Card body ────────────────────────────────────────────────────────────── */
.chamber-member-card .uk-card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 18px 20px 12px;
}

/* ── Sector badge ─────────────────────────────────────────────────────────── */
.chamber-sector-badge {
    display: inline-block;
    background: #eef2f7;
    color: #003057;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 9px;
    border-radius: 20px;
    margin-bottom: 8px;
}

/* ── Title ────────────────────────────────────────────────────────────────── */
.chamber-member-card .uk-card-title {
    font-size: 1.05rem;
    line-height: 1.4;
    margin: 0 0 4px;
}
.chamber-member-card .uk-card-title a:hover {
    color: #003057;
}

/* ── Excerpt ──────────────────────────────────────────────────────────────── */
.chamber-excerpt {
    font-size: 0.875rem;
    color: #555;
    line-height: 1.6;
    flex: 1;
    margin-top: 6px;
}

/* ── Contact list ─────────────────────────────────────────────────────────── */
.chamber-contact {
    margin: 10px 0 0 !important;
    padding: 0;
    font-size: 0.84rem;
    color: #555;
}
.chamber-contact li {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    padding: 2px 0;
}
.chamber-contact a {
    color: inherit;
    text-decoration: none;
    word-break: break-all;
}
.chamber-contact a:hover { color: #003057; }

/* ── Address ──────────────────────────────────────────────────────────────── */
.chamber-address {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    color: #777;
    font-size: 0.82rem;
    margin-top: 8px !important;
}

/* ── Card footer ──────────────────────────────────────────────────────────── */
.uk-card-footer.chamber-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px 14px;
    border-top: 1px solid var(--nc-border);
    margin-top: auto;
}
.chamber-profile-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #003057 !important;
    font-weight: 600;
    font-size: 0.85rem;
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    transition: gap 0.15s;
    font-family: inherit;
}
.chamber-profile-btn:hover { gap: 7px; }

/* ── Social icons ─────────────────────────────────────────────────────────── */
.chamber-social {
    display: flex;
    gap: 7px;
}
.chamber-social a {
    color: #aaa;
    display: flex;
    align-items: center;
    transition: color 0.2s;
}
.chamber-social a:hover { color: #003057; }

/* ── No results ───────────────────────────────────────────────────────────── */
.chamber-no-results {
    border-radius: var(--nc-radius);
}

/* ── Pagination ───────────────────────────────────────────────────────────── */
.chamber-pagination {
    gap: 6px;
    flex-wrap: wrap;
}
.chamber-page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 10px;
    border: 1px solid var(--nc-border);
    border-radius: 4px;
    background: #fff;
    color: #333;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.15s;
}
.chamber-page-btn:hover:not(:disabled) {
    border-color: #003057;
    color: #003057;
}
.chamber-page-btn.active {
    background: #003057;
    border-color: #003057;
    color: #fff;
}
.chamber-page-btn.disabled,
.chamber-page-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}
.chamber-page-dots {
    display: inline-flex;
    align-items: center;
    padding: 0 4px;
    color: #aaa;
    font-size: 1rem;
}

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
    .chamber-az-filter { gap: 3px; }
    .chamber-az-btn { min-width: 28px; height: 28px; font-size: 0.75rem; }
    .chamber-member-card .uk-card-title { font-size: 0.95rem; }
    .chamber-member-logo-wrap { height: 120px; }
}

/* =============================================================================
   In-Grid Member Profile Panel  v4.0
   ============================================================================= */

/* ── Grid area wrapper ────────────────────────────────────────────────────── */
.chamber-grid-area {
    position: relative;
}

/* When the profile is open, take the cards out of flow (keeping their
   rendered size) so the panel height drives the grid-area height. */
.chamber-grid-area.nc-profile-open .chamber-cards-wrap {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    visibility: hidden;
    pointer-events: none;
}

/* ── The in-grid profile panel ────────────────────────────────────────────── */
.nc-profile-panel {
    background: #f8fafc;
    border-radius: 8px;
    overflow: hidden;
    /* clip-path is set and animated via JS */
}

/* ── Top bar ──────────────────────────────────────────────────────────────── */
.nc-screen-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 32px;
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    gap: 16px;
}
.nc-back-btn {
    background: none;
    border: none;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    color: #003057;
    cursor: pointer;
    padding: 6px 0;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: gap 0.15s;
}
.nc-back-btn:hover { gap: 8px; }
.nc-screen-ext-link {
    font-size: 0.85rem;
    font-weight: 600;
    color: #003057;
    text-decoration: none;
    padding: 7px 16px;
    border: 1.5px solid #003057;
    border-radius: 6px;
    white-space: nowrap;
    transition: background 0.15s, color 0.15s;
}
.nc-screen-ext-link:hover { background: #003057; color: #fff; }

/* ── Banner ───────────────────────────────────────────────────────────────── */
.nc-screen-banner {
    width: 100%;
    height: 280px;
    overflow: hidden;
    flex-shrink: 0;
    border-radius: 20px 0 20px 0;
}
.nc-screen-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}
.nc-screen-banner--fallback {
    background: linear-gradient(320deg, #26b9c4, #2691c4);
    height: 160px;
    border-radius: 20px 0 20px 0;
}

/* ── Header strip (logo + title + badges) ─────────────────────────────────── */
.nc-screen-header-strip {
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}
.nc-screen-header-inner {
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 32px;
    display: flex;
    align-items: flex-end;
    gap: 24px;
}
.nc-screen-logo {
    width: 96px;
    height: 96px;
    border-radius: 12px;
    background: #fff;
    border: 3px solid #fff;
    box-shadow: 0 4px 18px rgba(0,0,0,0.12);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: -34px;
    position: relative;
}
.nc-screen-logo img {
    max-width: 82%;
    max-height: 82%;
    width: auto;
    height: auto;
    object-fit: contain;
}
.nc-screen-logo--initial {
    background: #003057;
    color: #fff;
    font-size: 2rem;
    font-weight: 700;
}
.nc-screen-titleblock {
    flex: 1;
    padding: 18px 0 16px;
    min-width: 0;
}
.nc-screen-titleblock h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #003057;
    margin: 0 0 8px;
    line-height: 1.25;
}
.nc-screen-badges {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
}
.nc-sbadge {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 9px;
    border-radius: 20px;
    line-height: 1.6;
}
.nc-sbadge--gold   { background: #fdf6e3; color: #7a5200; border: 1px solid #C9A84C; }
.nc-sbadge--sector { background: #eef2f7; color: #003057; }
.nc-sbadge--city   { background: #f0fdf4; color: #166534; }

/* ── Two-column layout ────────────────────────────────────────────────────── */
.nc-screen-columns {
    max-width: 1160px;
    margin: 0 auto;
    padding: 36px 32px 80px;
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 36px;
    align-items: start;
    width: 100%;
    box-sizing: border-box;
}

/* ── Main column: description + video ────────────────────────────────────── */
.nc-screen-prose {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.07);
    border: 1px solid #e5e7eb;
    padding: 32px 36px;
    font-size: 1rem;
    line-height: 1.8;
    color: #333;
}
.nc-screen-prose p  { margin: 0 0 1em; }
.nc-screen-prose h2,
.nc-screen-prose h3 { color: #003057; margin: 1.4em 0 0.5em; }
.nc-screen-prose a  { color: #003057; }
.nc-screen-prose img {
    max-width: 100%;
    border-radius: 8px;
    display: block;
    margin: 20px auto;
    box-shadow: 0 4px 14px rgba(0,0,0,0.1);
}
.nc-screen-video-wrap {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 4px 18px rgba(0,0,0,0.1);
    margin-top: 24px;
}
.nc-screen-video-wrap iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    border-radius: 10px;
}

/* ── Sidebar cards ────────────────────────────────────────────────────────── */
.nc-screen-sidebar {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.nc-scard {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.07);
    border: 1px solid #e5e7eb;
    padding: 18px 20px;
    font-size: 0.875rem;
    color: #333;
}
.nc-scard--gold {
    background: #fdf6e3;
    border-color: #C9A84C;
    color: #7a5200;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}
.nc-scard-label {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #aaa;
    margin: 0 0 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #f1f3f5;
}
.nc-contact-list {
    list-style: none;
    margin: 0 0 14px;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 9px;
    line-height: 1.5;
}
.nc-contact-list li { word-break: break-word; }
.nc-contact-list a  { color: #003057; text-decoration: none; }
.nc-contact-list a:hover { text-decoration: underline; }
.nc-website-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    background: #003057;
    color: #fff !important;
    border-radius: 7px;
    font-weight: 600;
    font-size: 0.875rem;
    text-decoration: none;
    transition: background 0.18s;
    box-sizing: border-box;
    width: 100%;
    margin-top: 4px;
}
.nc-website-btn:hover { background: #0a4a7c; }
.nc-socials {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.nc-social-pill {
    display: inline-block;
    padding: 6px 12px;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 0.82rem;
    font-weight: 500;
    color: #333;
    text-decoration: none;
    transition: border-color 0.15s, color 0.15s;
}
.nc-social-pill:hover { border-color: #003057; color: #003057; }
.nc-news-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.nc-news-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 9px 4px;
    border-bottom: 1px solid #f5f5f5;
    text-decoration: none;
    color: inherit;
    border-radius: 6px;
    transition: background 0.12s;
}
.nc-news-item:hover { background: #f8fafc; }
.nc-news-thumb {
    width: 62px;
    height: 46px;
    border-radius: 6px;
    object-fit: cover;
    flex-shrink: 0;
    background: #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: #aaa;
}
.nc-news-thumb--empty { object-fit: unset; }
.nc-news-title {
    font-size: 0.82rem;
    font-weight: 600;
    color: #003057;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 3px;
}
.nc-news-date { font-size: 0.75rem; color: #999; }

/* ── Error state ──────────────────────────────────────────────────────────── */
.nc-screen-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 32px;
    text-align: center;
    color: #555;
    gap: 20px;
}

/* ── Skeleton shimmer ─────────────────────────────────────────────────────── */
.nc-skel {
    background: linear-gradient(90deg, #e5e7eb 25%, #f3f4f6 50%, #e5e7eb 75%);
    background-size: 200% 100%;
    animation: nc-shimmer 1.5s ease infinite;
    display: block;
}
@keyframes nc-shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.nc-screen-logo.nc-skel {
    width: 96px;
    height: 96px;
    margin-top: -34px;
    border-radius: 12px;
}

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
    .nc-screen-columns {
        grid-template-columns: 1fr;
        padding: 24px 20px 56px;
        gap: 20px;
    }
    .nc-screen-sidebar { order: -1; }
    .nc-screen-banner  { height: 200px; }
    .nc-screen-banner--fallback { height: 120px; }
    .nc-screen-header-inner { padding: 0 20px; }
    .nc-screen-titleblock h1 { font-size: 1.35rem; }
    .nc-screen-logo { width: 78px; height: 78px; margin-top: -28px; }
    .nc-screen-prose { padding: 22px 20px; }
}
@media (max-width: 600px) {
    .nc-screen-topbar { padding: 10px 16px; }
    .nc-screen-banner { height: 140px; }
    .nc-screen-titleblock h1 { font-size: 1.15rem; }
    .nc-screen-ext-link { display: none; }
}

