/* ==========================================================================
   CGC Blocks — Combined Frontend Styles
   v1.0.0
   ========================================================================== */


/* ============================================================
   1. COUNTRY GUIDE CARD  (cgc/country-guide-card)
   ============================================================ */

.cgc-card {
    position: relative;
    background: #ffffff;
    border: 1px solid #e8e8e8;
    border-radius: 12px;
    padding: 28px 28px 24px;
    box-shadow: 0 1px 4px rgba(0,0,0,.06);
    transition: box-shadow .2s ease, transform .2s ease;
    display: flex;
    flex-direction: column;
}

.cgc-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,.10);
    transform: translateY(-2px);
}

.cgc-card__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.cgc-card__title {
    font-size: 1.35rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
    line-height: 1.25;
    letter-spacing: -.01em;
}

/* Circular image flag */
.cgc-card__flag {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    overflow: hidden;
    border: 1px solid rgba(0,0,0,.08);
    background: #f0f0f0;
}

.cgc-card__flag-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cgc-card__flag-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    background: #f5f5f5;
}

.cgc-card__description {
    font-size: .875rem;
    color: #5a5a5a;
    line-height: 1.6;
    margin: 0 0 20px;
}

.cgc-card__links {
    display: flex;
    flex-direction: column;
    border-top: 1px solid #f0f0f0;
    padding-top: 4px;
}

.cgc-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-decoration: none;
    color: #444;
    font-size: .875rem;
    padding: 10px 0;
    border-bottom: 1px solid #f5f5f5;
    transition: color .15s ease;
}

.cgc-link:last-child { border-bottom: none; }

.cgc-link:hover { color: #c0392b; }
.cgc-link:hover .cgc-link__arrow { transform: translateX(3px); color: #c0392b; }

.cgc-link__label { font-weight: 400; }

.cgc-link__arrow {
    flex-shrink: 0;
    font-size: .95rem;
    color: #888;
    transition: transform .2s ease, color .15s ease;
}

/* Responsive grid wrapper — add class cgc-grid to a Group block */
.cgc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px,1fr));
    gap: 24px;
    align-items: start;
}

@media (max-width:768px){
    .cgc-grid { grid-template-columns: 1fr; }
    .cgc-card { padding: 22px 20px 18px; }
    .cgc-card__flag { width:44px; height:44px; }
}


/* ============================================================
   2. CTA BANNER  (cgc/cta-banner)
   ============================================================ */

.cgc-cta {
    padding: 40px 0;
    max-width: 680px;
}

.alignwide .cgc-cta,
.alignfull .cgc-cta { max-width: 100%; }

.cgc-cta__title {
    font-size: 1.55rem;
    font-weight: 700;
    color: #111;
    margin: 0 0 16px;
    line-height: 1.25;
    letter-spacing: -.015em;
}

@media (max-width:600px){ .cgc-cta__title { font-size: 1.25rem; } }

.cgc-cta__description {
    font-size: .9375rem;
    color: #3a3a3a;
    line-height: 1.65;
    margin: 0 0 28px;
    max-width: 660px;
}

.cgc-cta__actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.cgc-cta__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 22px;
    background-color: #0057e7;
    color: #fff !important;
    font-size: .9375rem;
    font-weight: 600;
    border-radius: 6px;
    text-decoration: none;
    white-space: nowrap;
    transition: filter .18s ease, transform .15s ease;
    border: none;
    cursor: pointer;
}

.cgc-cta__btn:hover {
    filter: brightness(1.12);
    transform: translateY(-1px);
    color: #fff !important;
    text-decoration: none;
}

.cgc-cta__btn:active { filter: brightness(.95); transform: translateY(0); }

.cgc-cta__link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: .9375rem;
    font-weight: 500;
    color: #111;
    text-decoration: none;
    transition: color .15s ease;
}

.cgc-cta__link:hover { color: #0057e7; }
.cgc-cta__link:hover .cgc-cta__link-arrow { transform: translateX(4px); }

.cgc-cta__link-arrow {
    display: inline-block;
    transition: transform .2s ease;
}

@media (max-width:480px){
    .cgc-cta { padding: 28px 0; }
    .cgc-cta__actions { flex-direction: column; align-items: flex-start; gap: 14px; }
}


/* ============================================================
   3. FEATURE GRID  (cgc/feature-grid)
   ============================================================ */

.cgc-feature-grid {
    display: grid;
    grid-template-columns: repeat(var(--cgc-cols,3), 1fr);
    gap: 48px 40px;
    padding: 8px 0;
}

.cgc-feature-grid__item {
    display: flex;
    flex-direction: column;
}

.cgc-feature-grid__icon {
    width: 44px;
    height: 44px;
    margin-bottom: 14px;
    flex-shrink: 0;
}

.cgc-feature-grid__icon-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.cgc-feature-grid__icon-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    color: #4a90d9;
    background: #f0f6ff;
    border-radius: 6px;
}

.cgc-feature-grid__title {
    font-size: 1rem;
    font-weight: 700;
    color: #111;
    margin: 0 0 10px;
    line-height: 1.3;
}

.cgc-feature-grid__description {
    font-size: .9rem;
    color: #3a3a3a;
    line-height: 1.65;
    margin: 0;
}

@media (max-width:900px){
    .cgc-feature-grid { grid-template-columns: repeat(2,1fr); gap: 36px 28px; }
}

@media (max-width:560px){
    .cgc-feature-grid { grid-template-columns: 1fr; gap: 28px 0; }
}
