/* CC Museum Footer — V1 (designed to layer inside the theme's #bottom div with its existing gradient/DNA bg) */

.ccmsi-footer {
    --ccmsi-fg: #ffffff;
    --ccmsi-label: #a8c0dc;
    --ccmsi-muted: #9eb0cc;
    --ccmsi-accent: #f5b942;
    --ccmsi-green: #4ade80;
    --ccmsi-amber: #f5b942;
    --ccmsi-gray:  #a8b6cc;
    color: var(--ccmsi-fg);
    padding: 4.5rem 3rem 3rem;
    font-size: 1.0625rem;
    line-height: 1.65;
    font-family: inherit;
}

/* Holiday banner */
.ccmsi-holiday {
    background: rgba(255, 213, 122, 0.12);
    border: 1px solid rgba(255, 213, 122, 0.35);
    color: #ffd57a;
    padding: 0.85rem 1.25rem;
    border-radius: 4px;
    margin: 0 auto 2.5rem;
    max-width: 720px;
    text-align: center;
    font-weight: 500;
}

/* Status pill — small, inline, centered */
.ccmsi-status-pill {
    display: inline-flex;
    align-items: baseline;
    gap: 0.6rem;
    margin: 0 auto 3rem;
    padding: 0.4rem 1.1rem;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    font-size: 0.95rem;
}
.ccmsi-status-pill { display: flex; justify-content: center; width: max-content; }
/* Center the pill in its parent (the .ccmsi-footer flexes via text-align) */
.ccmsi-footer { text-align: center; } /* enables auto-centering of inline-flex pill */
.ccmsi-footer-body, .ccmsi-bottom-bar { text-align: left; } /* but body content stays left-aligned */

.ccmsi-status-pill .ccmsi-status-label {
    font-weight: 600;
    letter-spacing: 0.02em;
}
.ccmsi-status-pill .ccmsi-status-detail {
    color: var(--ccmsi-label);
    font-style: italic;
}
.ccmsi-dot {
    display: inline-block;
    width: 9px; height: 9px;
    border-radius: 50%;
    box-shadow: 0 0 8px currentColor;
    transform: translateY(-1px);
}
.ccmsi-dot--green { color: var(--ccmsi-green); background: var(--ccmsi-green); }
.ccmsi-dot--amber { color: var(--ccmsi-amber); background: var(--ccmsi-amber); }
.ccmsi-dot--gray  { color: var(--ccmsi-gray);  background: var(--ccmsi-gray);  }

/* Main 3-column body */
.ccmsi-footer-body {
    display: grid;
    grid-template-columns: minmax(180px, 280px) 1fr 1fr;
    gap: 4rem;
    max-width: 1200px;
    margin: 0 auto;
    align-items: start;
}

/* Logo */
.ccmsi-logo {
    display: flex;
    justify-content: center;
}
.ccmsi-logo img,
.ccmsi-logo-img {
    max-width: 100%;
    width: 240px;
    height: auto;
}

/* Section titles */
.ccmsi-block-title {
    color: var(--ccmsi-label);
    font-size: 1.25rem;
    font-weight: 400;
    margin: 0 0 1.5rem;
    letter-spacing: 0;
    text-transform: none;
}
/* Visit block */
.ccmsi-address {
    font-style: normal;
    margin: 0 0 1.25rem;
}
.ccmsi-museum-name {
    display: inline-block;
    margin-bottom: 0.25rem;
    font-weight: 700;
}
.ccmsi-phone, .ccmsi-email {
    margin: 0 0 0.4rem;
}
.ccmsi-phone a, .ccmsi-email a {
    color: var(--ccmsi-fg);
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.18);
    transition: border-color 0.2s ease;
}
.ccmsi-phone a:hover, .ccmsi-email a:hover {
    border-bottom-color: var(--ccmsi-fg);
}
.ccmsi-socials {
    margin-top: 1.5rem;
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
}
.ccmsi-social {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    color: var(--ccmsi-fg);
    border: 1px solid rgba(255,255,255,0.28);
    border-radius: 50%;
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.ccmsi-social:hover {
    background: rgba(255,255,255,0.10);
    border-color: rgba(255,255,255,0.5);
    transform: translateY(-1px);
}
.ccmsi-social svg {
    width: 18px;
    height: 18px;
    display: block;
}

/* Clickable address — subtle, only shows on hover */
.ccmsi-directions {
    color: inherit;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s ease;
}
.ccmsi-directions:hover {
    text-decoration: underline;
    text-decoration-style: dotted;
    text-underline-offset: 3px;
}

/* Hours */
.ccmsi-hours-list {
    display: grid;
    grid-template-columns: max-content 1fr;
    column-gap: 1.5rem;
    row-gap: 0.55rem;
    margin: 0;
}
.ccmsi-hours-list dt {
    color: var(--ccmsi-label);
    font-weight: 600;
}
.ccmsi-hours-list dd { margin: 0; }
.ccmsi-star {
    color: var(--ccmsi-accent);
    margin-left: 0.35rem;
}
.ccmsi-summer-note {
    margin-top: 1.25rem;
    color: var(--ccmsi-label);
    font-size: 0.95rem;
    font-style: italic;
}

/* Bottom bar */
.ccmsi-bottom-bar {
    border-top: 1px solid rgba(255,255,255,0.10);
    margin: 4rem auto 0;
    padding-top: 1.75rem;
    max-width: 1200px;
    text-align: center;
    color: var(--ccmsi-label);
    font-size: 0.9rem;
}
.ccmsi-quick-links {
    margin-bottom: 0.75rem;
}
.ccmsi-quick-links a {
    color: var(--ccmsi-fg);
    text-decoration: none;
    margin: 0 0.35rem;
}
.ccmsi-quick-links a:hover { text-decoration: underline; }
.ccmsi-copyright {
    margin: 0;
}

/* Mobile */
@media (max-width: 900px) {
    .ccmsi-footer {
        padding: 3rem 1.5rem 2rem;
    }
    .ccmsi-footer-body {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        text-align: center;
    }
    .ccmsi-logo img,
    .ccmsi-logo-img { width: 180px; }
    .ccmsi-hours-list {
        justify-content: center;
        max-width: 320px;
        margin: 0 auto;
    }
    .ccmsi-socials { justify-content: center; }
    .ccmsi-bottom-bar { margin-top: 3rem; }
    .ccmsi-quick-links { line-height: 2.2; }
}

/* Specificity bumps: theme styles inside #bottom were overriding label colors. */
#bottom .ccmsi-footer .ccmsi-block-title,
#bottom .ccmsi-footer .ccmsi-hours-list dt,
#bottom .ccmsi-footer .ccmsi-summer-note,
#bottom .ccmsi-footer .ccmsi-status-detail,
#bottom .ccmsi-footer .ccmsi-bottom-bar,
#bottom .ccmsi-footer .ccmsi-copyright {
    color: #cfdcef;
}

#bottom .ccmsi-footer a,
#bottom .ccmsi-footer .ccmsi-quick-links a,
#bottom .ccmsi-footer .ccmsi-bottom-bar a,
#bottom .ccmsi-footer .ccmsi-phone a,
#bottom .ccmsi-footer .ccmsi-email a {
    color: #ffffff;
}

#bottom .ccmsi-footer .ccmsi-museum-name,
#bottom .ccmsi-footer .ccmsi-address {
    color: #ffffff;
}

/* Status pill specificity bump too */
#bottom .ccmsi-footer .ccmsi-status-pill {
    color: #ffffff;
}
#bottom .ccmsi-footer .ccmsi-status-pill .ccmsi-status-detail {
    color: #cfdcef;
}

/* Quick link separators (dots) */
#bottom .ccmsi-footer .ccmsi-quick-links span[aria-hidden] {
    color: #7a8ca6;
}

/* Ensure social icons stay white (SVG uses currentColor) */
#bottom .ccmsi-footer .ccmsi-social {
    color: #ffffff;
}
#bottom .ccmsi-footer .ccmsi-social svg path {
    fill: currentColor;
}

/* Directions link inherits white from address */
#bottom .ccmsi-footer .ccmsi-directions {
    color: #ffffff;
}

/* Credentials row */
.ccmsi-credentials {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 3rem;
    flex-wrap: wrap;
    max-width: 1200px;
    margin: 3.5rem auto 0;
    padding: 0 1rem;
}
.ccmsi-credential {
    height: 80px;
    width: auto;
    max-width: 140px;
    object-fit: contain;
    opacity: 0.92;
    transition: opacity 0.2s ease;
}
.ccmsi-credential:hover {
    opacity: 1;
}

#bottom .ccmsi-footer .ccmsi-credential {
    height: 80px;
    width: auto;
}

@media (max-width: 768px) {
    .ccmsi-credentials {
        gap: 1.75rem;
        margin-top: 2.5rem;
    }
    .ccmsi-credential {
        height: 60px;
        max-width: 110px;
    }
}

/* Entrance animation — staggered fade-up when footer scrolls into view.
   IntersectionObserver in assets/footer.js adds .is-visible. */
.ccmsi-footer .ccmsi-status-pill,
.ccmsi-footer .ccmsi-logo,
.ccmsi-footer .ccmsi-hours,
.ccmsi-footer .ccmsi-visit,
.ccmsi-footer .ccmsi-bottom-bar,
.ccmsi-footer .ccmsi-holiday {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.7s ease-out, transform 0.7s ease-out;
    will-change: opacity, transform;
}
.ccmsi-footer.is-visible .ccmsi-holiday      { opacity: 1; transform: none; transition-delay: 0ms; }
.ccmsi-footer.is-visible .ccmsi-status-pill  { opacity: 1; transform: none; transition-delay: 80ms; }
.ccmsi-footer.is-visible .ccmsi-logo         { opacity: 1; transform: none; transition-delay: 180ms; }
.ccmsi-footer.is-visible .ccmsi-hours        { opacity: 1; transform: none; transition-delay: 240ms; }
.ccmsi-footer.is-visible .ccmsi-visit        { opacity: 1; transform: none; transition-delay: 300ms; }
.ccmsi-footer.is-visible .ccmsi-bottom-bar   { opacity: 1; transform: none; transition-delay: 720ms; }

/* Credentials: animate each badge individually with a stagger, plus a subtle scale-in. */
.ccmsi-footer .ccmsi-credential {
    opacity: 0;
    transform: translateY(14px) scale(0.96);
    transition: opacity 0.65s ease-out, transform 0.65s ease-out;
    will-change: opacity, transform;
}
.ccmsi-footer.is-visible .ccmsi-credential:nth-child(1) { opacity: 0.92; transform: none; transition-delay: 440ms; }
.ccmsi-footer.is-visible .ccmsi-credential:nth-child(2) { opacity: 0.92; transform: none; transition-delay: 560ms; }
.ccmsi-footer.is-visible .ccmsi-credential:nth-child(3) { opacity: 0.92; transform: none; transition-delay: 680ms; }
.ccmsi-footer.is-visible .ccmsi-credential:nth-child(n+4) { opacity: 0.92; transform: none; transition-delay: 800ms; }

@media (prefers-reduced-motion: reduce) {
    .ccmsi-footer .ccmsi-status-pill,
    .ccmsi-footer .ccmsi-logo,
    .ccmsi-footer .ccmsi-hours,
    .ccmsi-footer .ccmsi-visit,
    .ccmsi-footer .ccmsi-bottom-bar,
    .ccmsi-footer .ccmsi-holiday,
    .ccmsi-footer .ccmsi-credential {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .ccmsi-footer .ccmsi-credential { opacity: 0.92; }
}

/* Upcoming summer preview (appears within 30 days of summer start) */
.ccmsi-summer-upcoming {
    margin-top: 1.5rem;
    padding: 0.9rem 1.1rem;
    background: rgba(245, 185, 66, 0.08);
    border: 1px solid rgba(245, 185, 66, 0.28);
    border-radius: 6px;
}
.ccmsi-summer-upcoming-title {
    margin: 0 0 0.6rem;
    color: var(--ccmsi-accent);
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.4;
}
.ccmsi-summer-upcoming-list {
    display: grid;
    grid-template-columns: max-content 1fr;
    column-gap: 1.25rem;
    row-gap: 0.3rem;
    margin: 0;
    font-size: 0.9rem;
}
.ccmsi-summer-upcoming-list dt {
    color: var(--ccmsi-label);
    font-weight: 600;
}
.ccmsi-summer-upcoming-list dd {
    margin: 0;
    color: var(--ccmsi-fg);
}

/* Specificity bumps so the existing theme doesn't override colors */
#bottom .ccmsi-footer .ccmsi-summer-upcoming-title { color: var(--ccmsi-accent); }
#bottom .ccmsi-footer .ccmsi-summer-upcoming-list dt { color: #cfdcef; }
#bottom .ccmsi-footer .ccmsi-summer-upcoming-list dd { color: #ffffff; }
