/* ============================================================
   CMP Accordion Cards — v1.0.0
   Matches CMP brand spec: navy #1a2947, gold #c9a961
   ============================================================ */

/* Wrapper — 3 columns desktop, 1 column mobile */
.cmp-ac-wrapper {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 32px;
    box-sizing: border-box;
    align-items: start;
}

/* Card */
.cmp-ac-card {
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    overflow: hidden;
    transition: box-shadow 200ms ease;
}

.cmp-ac-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.20);
}

/* Header — always visible, clickable */
.cmp-ac-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 32px 32px 24px;
    cursor: pointer;
    text-align: center;
    gap: 16px;
    user-select: none;
    -webkit-user-select: none;
}

.cmp-ac-header:focus {
    outline: 2px solid #c9a961;
    outline-offset: -2px;
    border-radius: 10px;
}

/* Icon circle */
.cmp-ac-icon-wrap {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cmp-ac-icon-wrap .fa {
    font-size: 28px;
}

/* Title row */
.cmp-ac-title-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.cmp-ac-title {
    font-family: 'Lato', sans-serif;
    font-size: 20px;
    font-weight: 600;
    color: #1a2947;
    line-height: 1.3;
}

/* Chevron */
.cmp-ac-chevron {
    display: flex;
    align-items: center;
    color: #1a2947;
    transition: transform 300ms ease;
    flex-shrink: 0;
}

/* Rotate chevron when open */
.cmp-ac-card.is-open .cmp-ac-chevron {
    transform: rotate(180deg);
}

/* Expandable body */
.cmp-ac-body {
    padding: 0 32px 32px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

/* Hidden state — using hidden attribute + CSS */
.cmp-ac-body[hidden] {
    display: none;
}

/* Animation wrapper — JS removes hidden, adds this */
.cmp-ac-body.is-visible {
    display: block;
    animation: cmp-ac-slide-down 250ms ease forwards;
}

@keyframes cmp-ac-slide-down {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Description text */
.cmp-ac-description {
    font-family: 'Lato', sans-serif;
    font-size: 15px;
    color: #1a2947;
    line-height: 1.6;
    text-align: center;
    margin: 20px 0 20px;
    opacity: 0.85;
}

/* Link buttons */
.cmp-ac-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cmp-ac-link-btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #1a2947;
    color: #ffffff;
    text-decoration: none;
    font-family: 'Lato', sans-serif;
    font-size: 14px;
    font-weight: 500;
    padding: 10px 16px;
    border-radius: 6px;
    transition: opacity 150ms ease;
    line-height: 1.4;
}

.cmp-ac-link-btn:hover {
    opacity: 0.88;
    color: #ffffff;
    text-decoration: none;
}

.cmp-ac-arrow {
    flex-shrink: 0;
    margin-left: 8px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

/* Tablet — stack to 1 column */
@media (max-width: 1023px) {
    .cmp-ac-wrapper {
        grid-template-columns: 1fr;
        max-width: 600px;
        padding: 0 16px;
    }
}

/* Mobile */
@media (max-width: 479px) {
    .cmp-ac-wrapper {
        padding: 0 16px;
    }

    .cmp-ac-header {
        padding: 24px 24px 16px;
    }

    .cmp-ac-body {
        padding: 0 24px 24px;
    }
}
