/* Reset e Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #4285f4;
    --primary-hover: #3367d6;
    --success-color: #0f9d58;
    --success-hover: #0b8043;
    --danger-color: #db4437;
    --danger-hover: #c53929;
    --secondary-color: #5f6368;
    --background-color: #f8f9fa;
    --card-background: #ffffff;
    --text-color: #202124;
    --border-color: #dadce0;
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
    --shadow-hover: 0 3px 6px rgba(0, 0, 0, 0.16), 0 3px 6px rgba(0, 0, 0, 0.23);
    --facebook-color: #1877f2;
    --facebook-hover: #166fe5;
    --google-color: #4285f4;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
header {
    text-align: center;
    margin-bottom: 20px;
    padding: 25px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

header h1 {
    font-size: 2.2em;
    margin-bottom: 8px;
}

.subtitle {
    font-size: 1em;
    opacity: 0.9;
}

/* Card */
.card {
    background: var(--card-background);
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: var(--shadow);
    transition: box-shadow 0.3s ease;
}

.card:hover {
    box-shadow: var(--shadow-hover);
}

.card h2 {
    margin-bottom: 20px;
    color: var(--primary-color);
    font-size: 1.8em;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 10px;
}

/* Form Elements */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-color);
}

.form-group input[type="text"],
.form-group input[type="tel"],
.form-group input[type="url"],
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1em;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Buttons */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 4px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background-color: var(--primary-hover);
    box-shadow: var(--shadow-hover);
}

.btn-success {
    background-color: var(--success-color);
    color: white;
    margin-left: 10px;
}

.btn-success:hover:not(:disabled) {
    background-color: var(--success-hover);
    box-shadow: var(--shadow-hover);
}

.btn-danger {
    background-color: var(--danger-color);
    color: white;
}

.btn-danger:hover:not(:disabled) {
    background-color: var(--danger-hover);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: white;
    margin-left: 10px;
}

.btn-secondary:hover:not(:disabled) {
    background-color: #3c4043;
}

.btn-edit {
    background-color: #ff9800;
    color: white;
    padding: 8px 16px;
    font-size: 0.9em;
}

.btn-edit:hover {
    background-color: #f57c00;
}

/* Info Box */
.info-box {
    background-color: #e8f0fe;
    padding: 15px;
    border-radius: 4px;
    border-left: 4px solid var(--primary-color);
    margin-top: 20px;
}

.info-box h3 {
    margin-bottom: 10px;
    color: var(--primary-color);
}

/* Locations Grid */
.locations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.location-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.location-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.location-card h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.3em;
}

.location-card p {
    margin-bottom: 8px;
    color: var(--secondary-color);
}

.location-card strong {
    color: var(--text-color);
}

.location-actions {
    margin-top: 15px;
    display: flex;
    gap: 10px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s ease;
}

.modal.show {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.modal-content {
    background-color: var(--card-background);
    margin: 2% auto;
    border-radius: 8px;
    width: 90%;
    max-width: 700px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    padding: 20px 30px;
    background: linear-gradient(135deg, var(--primary-color), #34a853);
    color: white;
    border-radius: 8px 8px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    color: white;
    border: none;
    padding: 0;
}

.close {
    color: white;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.close:hover {
    transform: scale(1.2);
}

.modal-body {
    padding: 30px;
    max-height: 70vh;
    overflow-y: auto;
}

.modal-body h3 {
    color: var(--primary-color);
    margin-top: 25px;
    margin-bottom: 15px;
    font-size: 1.2em;
}

.form-actions {
    margin-top: 30px;
    display: flex;
    justify-content: flex-end;
}

/* Notifications */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 25px;
    border-radius: 4px;
    color: white;
    font-weight: 600;
    box-shadow: var(--shadow-hover);
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s ease;
    z-index: 2000;
}

.notification.show {
    opacity: 1;
    transform: translateX(0);
}

.notification.success {
    background-color: var(--success-color);
}

.notification.error {
    background-color: var(--danger-color);
}

.notification.info {
    background-color: var(--primary-color);
}

/* Loading Spinner */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Footer */
footer {
    text-align: center;
    padding: 20px 0;
    color: var(--secondary-color);
    margin-top: 40px;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }

    header h1 {
        font-size: 2em;
    }

    .card {
        padding: 20px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .locations-grid {
        grid-template-columns: 1fr;
    }

    .modal-content {
        width: 95%;
        margin: 5% auto;
    }

    .btn-success {
        margin-left: 0;
        margin-top: 10px;
    }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 40px;
    color: var(--secondary-color);
}

.empty-state svg {
    width: 100px;
    height: 100px;
    margin-bottom: 20px;
    opacity: 0.5;
}

/* Hours Section */
.hours-section {
    margin-top: 15px;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.hours-help {
    font-size: 0.9em;
    color: var(--secondary-color);
    margin-bottom: 15px;
    font-style: italic;
}

/* Day Hours Block - Nuova struttura con 2 fasce orarie */
.day-hours-block {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 12px;
    padding: 15px;
    transition: box-shadow 0.2s ease;
}

.day-hours-block:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.day-header {
    margin-bottom: 10px;
}

.day-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 600;
    color: var(--text-color);
}

.day-toggle input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.day-toggle span {
    font-size: 1em;
}

.day-slots {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-left: 28px;
}

.time-slot {
    display: flex;
    align-items: center;
    gap: 8px;
}

.time-slot input[type="time"] {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95em;
    transition: border-color 0.3s ease;
    width: 130px;
}

.time-slot input[type="time"]:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

.time-slot span {
    font-weight: 600;
    color: var(--secondary-color);
}

/* Stili per compatibilità con vecchia struttura */
.hour-row {
    display: grid;
    grid-template-columns: 150px 1fr auto 1fr;
    gap: 10px;
    align-items: center;
    margin-bottom: 15px;
    padding: 10px;
    background: white;
    border-radius: 4px;
    border: 1px solid var(--border-color);
}

.hour-row label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--text-color);
    margin: 0;
}

.hour-row input[type="checkbox"] {
    cursor: pointer;
    width: 18px;
    height: 18px;
}

.hour-row input[type="time"] {
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95em;
    transition: border-color 0.3s ease;
}

.hour-row input[type="time"]:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

.hour-row span {
    text-align: center;
    font-weight: 600;
    color: var(--secondary-color);
}

.hours-display {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
    font-size: 0.95em;
    line-height: 1.8;
}

.hours-display strong {
    display: block;
    margin-bottom: 5px;
    color: var(--primary-color);
}

/* Responsive Hours */
@media (max-width: 768px) {
    .hour-row {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .hour-row span {
        display: none;
    }

    .day-hours-block {
        padding: 12px;
    }

    .day-slots {
        padding-left: 0;
    }

    .time-slot {
        flex-wrap: wrap;
    }

    .time-slot input[type="time"] {
        width: 100%;
    }
}

/* Search Container */
.search-container {
    margin-bottom: 25px;
    padding: 20px;
    background: linear-gradient(135deg, #e8f0fe 0%, #f3e8fd 100%);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.search-box {
    display: flex;
    gap: 10px;
    align-items: center;
}

.search-input {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid var(--border-color);
    border-radius: 30px;
    font-size: 1em;
    background: white;
    transition: all 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(66, 133, 244, 0.15);
}

.search-input::placeholder {
    color: #9aa0a6;
}

.btn-small {
    padding: 10px 16px;
    font-size: 0.9em;
    border-radius: 20px;
}

.search-stats {
    margin-top: 12px;
    font-size: 0.9em;
    color: var(--secondary-color);
    font-weight: 500;
}

/* Highlight matches */
mark {
    background-color: #fbbc04;
    color: var(--text-color);
    padding: 1px 4px;
    border-radius: 3px;
}

/* Responsive Search */
@media (max-width: 768px) {
    .search-container {
        padding: 15px;
    }

    .search-input {
        padding: 12px 16px;
        font-size: 0.95em;
    }

    .search-box {
        flex-direction: column;
    }

    .btn-small {
        width: 100%;
    }
}

/* =====================================================
   ORARI SPECIALI
   ===================================================== */

.special-hours-section {
    margin-top: 15px;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

#specialHoursContainer {
    margin-bottom: 15px;
}

.special-hour-entry {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 12px;
    padding: 15px;
    transition: box-shadow 0.2s ease;
}

.special-hour-entry:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.special-hour-row {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.special-hour-date {
    flex: 0 0 auto;
}

.special-hour-date label {
    display: block;
    font-size: 0.85em;
    color: var(--secondary-color);
    margin-bottom: 4px;
}

.special-date-input {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95em;
    transition: border-color 0.3s ease;
}

.special-date-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

.special-hour-closed {
    flex: 0 0 auto;
}

.closed-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.95em;
    color: var(--text-color);
}

.closed-toggle input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--danger-color);
}

.special-hour-times {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

.special-hour-times.disabled {
    opacity: 0.4;
    pointer-events: none;
}

.special-hour-times input[type="time"] {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95em;
    width: 120px;
    transition: border-color 0.3s ease;
}

.special-hour-times input[type="time"]:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

.special-hour-times span {
    font-weight: 600;
    color: var(--secondary-color);
}

.btn-remove {
    background-color: var(--danger-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    font-size: 1.2em;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    padding: 0;
    line-height: 1;
}

.btn-remove:hover {
    background-color: var(--danger-hover);
    transform: scale(1.1);
}

/* Special Hours Display in Card */
.special-hours-display {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
    font-size: 0.95em;
    line-height: 1.8;
}

.special-hours-display strong {
    display: block;
    margin-bottom: 5px;
    color: #ff9800;
}

.closed-badge {
    background-color: var(--danger-color);
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.85em;
    font-weight: 600;
}

/* Responsive Special Hours */
@media (max-width: 768px) {
    .special-hour-row {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .special-hour-date,
    .special-hour-closed,
    .special-hour-times {
        width: 100%;
    }

    .special-date-input {
        width: 100%;
    }

    .special-hour-times input[type="time"] {
        width: 100%;
    }

    .btn-remove {
        align-self: flex-end;
    }
}

/* =====================================================
   NUOVI CAMPI (Profile, OpenInfo, LatLng, ServiceArea)
   ===================================================== */

/* Textarea per descrizione */
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1em;
    font-family: inherit;
    resize: vertical;
    min-height: 100px;
    transition: border-color 0.3s ease;
}

.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

/* Contatore caratteri */
.char-counter {
    display: block;
    text-align: right;
    font-size: 0.85em;
    color: var(--secondary-color);
    margin-top: 5px;
}

/* Select styling */
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1em;
    background-color: white;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

/* Input number per coordinate */
.form-group input[type="number"] {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1em;
    transition: border-color 0.3s ease;
}

.form-group input[type="number"]:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

/* Area di servizio */
.service-area-section {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    margin-top: 10px;
}

.service-area-section > label {
    display: block;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--text-color);
}

#serviceAreaPlaces {
    margin-bottom: 10px;
}

.service-area-place {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.service-area-place-input {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95em;
    transition: border-color 0.3s ease;
}

.service-area-place-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

/* Status badge per le card */
.status-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.85em;
    font-weight: 600;
}

.status-badge.open {
    background-color: #e6f4ea;
    color: var(--success-color);
}

.status-badge.closed-temp {
    background-color: #fef7e0;
    color: #f9a825;
}

.status-badge.closed-perm {
    background-color: #fce8e6;
    color: var(--danger-color);
}

/* Display descrizione nella card */
.profile-display {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
    font-size: 0.9em;
    color: var(--secondary-color);
    line-height: 1.5;
}

.profile-display strong {
    display: block;
    margin-bottom: 5px;
    color: var(--text-color);
}

/* Service area display */
.service-area-display {
    margin-top: 8px;
    font-size: 0.9em;
}

.service-area-display strong {
    color: var(--text-color);
}

.service-area-display .places-list {
    color: var(--secondary-color);
    font-style: italic;
}

/* Responsive per nuovi campi */
@media (max-width: 768px) {
    .service-area-place {
        flex-direction: column;
        align-items: stretch;
    }

    .service-area-place .btn-remove {
        align-self: flex-end;
    }
}

/* =====================================================
   TABS NAVIGATION
   ===================================================== */

.tabs-container {
    margin-bottom: 20px;
}

.tabs {
    display: flex;
    gap: 0;
    background: var(--card-background);
    border-radius: 8px;
    padding: 5px;
    box-shadow: var(--shadow);
}

.tab-btn {
    flex: 1;
    padding: 15px 25px;
    border: none;
    background: transparent;
    font-size: 1em;
    font-weight: 600;
    color: var(--secondary-color);
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.tab-btn:hover {
    background: var(--background-color);
}

.tab-btn.active {
    background: var(--primary-color);
    color: white;
}

.tab-btn.active[data-tab="facebook"] {
    background: var(--facebook-color);
}

.tab-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 4px;
    font-weight: bold;
    font-size: 1.1em;
}

.tab-btn[data-tab="google"] .tab-icon {
    background: linear-gradient(135deg, #4285f4, #34a853, #fbbc05, #ea4335);
    color: white;
}

.tab-btn[data-tab="facebook"] .tab-icon {
    background: var(--facebook-color);
    color: white;
}

.tab-btn.active .tab-icon {
    background: white;
}

.tab-btn.active[data-tab="google"] .tab-icon {
    color: var(--primary-color);
}

.tab-btn.active[data-tab="facebook"] .tab-icon {
    color: var(--facebook-color);
}

/* Tab content */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* =====================================================
   AUTH STATUS BAR
   ===================================================== */

.auth-status-bar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 15px;
    padding: 15px 20px;
    background: var(--card-background);
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: var(--shadow);
    border-left: 4px solid var(--google-color);
}

.auth-status-bar span {
    font-weight: 600;
}

.auth-status-bar.fb {
    border-left-color: var(--facebook-color);
}

/* =====================================================
   FACEBOOK SPECIFIC STYLES
   ===================================================== */

.btn-facebook {
    background-color: var(--facebook-color);
    color: white;
}

.btn-facebook:hover:not(:disabled) {
    background-color: var(--facebook-hover);
    box-shadow: var(--shadow-hover);
}

.btn-google {
    background-color: var(--google-color);
    color: white;
}

.btn-google:hover:not(:disabled) {
    background-color: var(--primary-hover);
    box-shadow: var(--shadow-hover);
}

/* Facebook page card */
.fb-card {
    border-left: 4px solid var(--facebook-color);
}

.fb-page-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.fb-page-picture {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    object-fit: cover;
}

.fb-category {
    display: inline-block;
    font-size: 0.85em;
    color: var(--secondary-color);
    background: var(--background-color);
    padding: 3px 10px;
    border-radius: 12px;
    margin-top: 5px;
}

/* Facebook modal header */
.fb-header {
    background: linear-gradient(135deg, var(--facebook-color), #4267b2) !important;
}

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

@media (max-width: 768px) {
    .tabs {
        flex-direction: column;
    }

    .tab-btn {
        justify-content: flex-start;
        padding: 12px 20px;
    }

    .auth-status-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        text-align: center;
    }

    .fb-page-header {
        flex-direction: column;
        text-align: center;
    }

    .fb-page-picture {
        width: 80px;
        height: 80px;
    }
}

/* =====================================================
   REVIEWS STYLES
   ===================================================== */

/* Reviews Controls */
.reviews-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.reviews-filter {
    padding: 10px 15px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95em;
    background-color: white;
    cursor: pointer;
    min-width: 180px;
}

.reviews-filter:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Reviews Summary Box */
.reviews-summary {
    margin-bottom: 25px;
}

.reviews-summary-box {
    display: flex;
    gap: 40px;
    padding: 25px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e8f0fe 100%);
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.reviews-summary-box.fb-summary {
    background: linear-gradient(135deg, #f8f9fa 0%, #e7f3ff 100%);
}

.summary-main {
    text-align: center;
    min-width: 150px;
}

.average-rating {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.rating-number {
    font-size: 3em;
    font-weight: 700;
    color: var(--text-color);
    line-height: 1;
}

.total-count {
    font-size: 0.9em;
    color: var(--secondary-color);
}

/* Star Display */
.star-display {
    display: flex;
    gap: 2px;
}

.star {
    font-size: 1.2em;
    color: #dadce0;
}

.star.full {
    color: #fbbc04;
}

.star.half {
    color: #fbbc04;
    opacity: 0.6;
}

/* Rating Distribution */
.rating-distribution {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.rating-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.rating-label {
    font-size: 0.9em;
    color: var(--secondary-color);
    min-width: 45px;
}

.rating-bar-container {
    flex: 1;
    height: 10px;
    background-color: #e0e0e0;
    border-radius: 5px;
    overflow: hidden;
}

.rating-bar {
    height: 100%;
    background: linear-gradient(90deg, #fbbc04, #f9a825);
    border-radius: 5px;
    transition: width 0.5s ease;
}

.rating-count {
    font-size: 0.85em;
    color: var(--secondary-color);
    min-width: 30px;
    text-align: right;
}

/* Reviews List */
.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Review Card */
.review-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    transition: box-shadow 0.3s ease;
}

.review-card:hover {
    box-shadow: var(--shadow-hover);
}

.review-card.google-review {
    border-left: 4px solid var(--google-color);
}

.review-card.fb-review {
    border-left: 4px solid var(--facebook-color);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.review-author {
    display: flex;
    align-items: center;
    gap: 12px;
}

.author-photo {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.author-photo-placeholder {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.author-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.author-name {
    font-weight: 600;
    color: var(--text-color);
    font-size: 1.05em;
}

.review-date {
    font-size: 0.85em;
    color: var(--secondary-color);
}

.page-name {
    font-size: 0.8em;
    color: var(--facebook-color);
    background: #e7f3ff;
    padding: 2px 8px;
    border-radius: 10px;
}

.review-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}

.review-source-badge {
    font-size: 0.75em;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.review-source-badge.google {
    background-color: #e8f0fe;
    color: var(--google-color);
}

.review-source-badge.facebook {
    background-color: #e7f3ff;
    color: var(--facebook-color);
}

.review-rating {
    display: flex;
    gap: 2px;
}

.review-rating .star {
    font-size: 1.1em;
}

/* Review Content */
.review-content {
    margin-bottom: 15px;
}

.review-content p {
    color: var(--text-color);
    line-height: 1.6;
    margin: 0;
}

.review-content .no-content {
    color: var(--secondary-color);
}

/* Review Reply */
.review-reply {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-top: 15px;
    border-left: 3px solid var(--primary-color);
}

.reply-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 8px;
}

.reply-header strong {
    color: var(--primary-color);
    font-size: 0.9em;
}

.reply-date {
    font-size: 0.8em;
    color: var(--secondary-color);
}

.review-reply p {
    margin: 0;
    color: var(--secondary-color);
    font-size: 0.95em;
    line-height: 1.5;
}

/* Review Actions */
.review-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
}

.btn-reply {
    background-color: var(--primary-color);
    color: white;
    padding: 8px 16px;
    font-size: 0.85em;
}

.btn-reply:hover {
    background-color: var(--primary-hover);
}

/* Loading and Error States */
.loading-state,
.error-state,
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--secondary-color);
}

.error-state {
    color: var(--danger-color);
}

/* Modal Small */
.modal-small {
    max-width: 500px;
}

/* Responsive Reviews */
@media (max-width: 768px) {
    .reviews-controls {
        flex-direction: column;
        align-items: stretch;
    }

    .reviews-filter {
        width: 100%;
    }

    .reviews-summary-box {
        flex-direction: column;
        gap: 25px;
    }

    .summary-main {
        border-bottom: 1px solid var(--border-color);
        padding-bottom: 20px;
    }

    .review-header {
        flex-direction: column;
    }

    .review-meta {
        flex-direction: row;
        align-items: center;
        width: 100%;
        justify-content: space-between;
    }

    .review-actions {
        flex-direction: column;
    }

    .review-actions .btn {
        width: 100%;
    }
}
