/* ==========================================================================
   BRANCHES ARCHIVE & SINGLE LAYOUT
   Uses Global Theme Variables (style.css)
   ========================================================================== */

/* --- Grid System for Layouts --- */
.row-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    align-items: start;
}

.grid-2-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

/* Mobile Responsiveness */
@media (max-width: 992px) {
    .row-layout { grid-template-columns: 1fr; }
}

@media (max-width: 576px) {
    .grid-2-col { grid-template-columns: 1fr; }
}

/* --- Branches Grid (Archive) --- */
.branches-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}

/* --- Branch Card Customization --- */
.branch-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    border: 1px solid var(--color-border);
}

.branch-card__image {
    position: relative;
    overflow: hidden;
    height: 220px;
}

.branch-card__image img {
    transition: transform 0.5s ease;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.branch-card:hover .branch-card__image img {
    transform: scale(1.05);
}

/* Status Badges */
.badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.35rem 0.85rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    z-index: 2;
    background-color: var(--color-surface);
    box-shadow: var(--shadow-sm);
}

.badge-open {
    color: var(--color-success);
    border: 1px solid rgba(79, 138, 109, 0.2);
}

.badge-closed {
    color: var(--color-danger);
    border: 1px solid rgba(198, 90, 90, 0.2);
}

/* Utility Icons (Using the pseudo-elements you defined) */
.icon-whatsapp::before {
    content: "\f232"; 
    font-family: "Font Awesome 6 Brands";
}
.icon-clock::before {
    content: "\f017"; 
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
}

/* --- WhatsApp Floating Component --- */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25D366; /* WhatsApp Green */
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    z-index: 9999;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    background-color: #20BA5A;
}

.whatsapp-float svg {
    width: 32px;
    height: 32px;
}

.whatsapp-tooltip {
    position: absolute;
    right: 70px;
    background: var(--color-surface);
    color: var(--color-text);
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.8rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--color-border);
}

.whatsapp-float:hover .whatsapp-tooltip {
    opacity: 1;
    visibility: visible;
}

/* --- Mobile Sticky CTA (Single Branch) --- */
.mobile-sticky-cta {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: var(--color-surface);
    padding: 15px;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.1);
    z-index: 1000;
    display: none; /* Hidden on desktop */
}

@media (max-width: 768px) {
    .mobile-sticky-cta { display: block; }
    .whatsapp-float { bottom: 85px; } /* Move up to avoid overlap */
}

/* Dark Mode Overrides inside this specific file */
body.dark-mode .badge {
    background-color: var(--color-surface);
    color: var(--color-text);
}