/**
 * Vista Guest Author - Frontend Styles
 * Integrated with Elementor System Colors
 */

/* ============================================
   Elementor Integration - CSS Variables
   These will be populated by Elementor globals
   ============================================ */
:root {
    --vista-author-primary-color: var(--e-global-color-primary, #2563eb);
    --vista-author-secondary-color: var(--e-global-color-secondary, #64748b);
    --vista-author-text-color: var(--e-global-color-text, #1e293b);
    --vista-author-accent-color: var(--e-global-color-accent, #f59e0b);
    --vista-author-heading-font: var(--e-global-typography-primary-font-family, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
    --vista-author-body-font: var(--e-global-typography-text-font-family, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
}

/* ============================================
   Author Box - Main Container
   ============================================ */
.vista-author-box {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 1.5rem;
    padding: 1.5rem;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin: 2rem 0;
    font-family: var(--vista-author-body-font);
    align-items: start;
}

.vista-author-label {
    grid-column: 1 / -1;
    margin: 0 0 0.5rem 0;
    font-size: 0.875rem;
    color: #000000 !important;
    font-family: var(--vista-author-body-font);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ============================================
   Author Avatar
   ============================================ */
.vista-author-avatar {
    flex-shrink: 0;
}

.vista-author-avatar img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    background: #f8fafc;
    border: 2px solid #e5e7eb;
    object-fit: cover;
}

/* ============================================
   Author Content
   ============================================ */
.vista-author-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.vista-author-name {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--vista-author-text-color);
    font-family: var(--vista-author-heading-font);
}

.vista-author-title {
    margin: 0;
    font-size: 0.95rem;
    color: #6b7280;
    font-style: italic;
    font-family: var(--vista-author-body-font);
}

.vista-author-bio {
    margin: 0.5rem 0;
    color: #6b7280;
    line-height: 1.6;
    font-size: 0.95rem;
    font-family: var(--vista-author-body-font);
}

/* ============================================
   Author Links & Contact
   ============================================ */
.vista-author-link {
    margin: 0.5rem 0 0 0;
}

.vista-author-url {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: #ffffff !important;
    color: #000000 !important;
    text-decoration: none !important;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    transition: all 0.2s ease;
    font-family: var(--vista-author-body-font);
}

.vista-author-url:hover {
    background: var(--vista-author-secondary-color, #64748b) !important;
    color: #ffffff !important;
    text-decoration: none !important;
    border-color: var(--vista-author-secondary-color, #64748b);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ============================================
   Social Links
   ============================================ */
.vista-author-social {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.vista-author-social-link {
    display: inline-flex;
    align-items: center;
    padding: 0.375rem 0.75rem;
    background: white;
    color: var(--vista-author-secondary-color);
    border: 1px solid var(--vista-author-secondary-color);
    text-decoration: none;
    border-radius: 50px;
    font-size: 0.875rem;
    transition: all 0.2s;
    font-family: var(--vista-author-body-font);
}

.vista-author-social-link:hover {
    background: var(--vista-author-secondary-color);
    color: white;
    text-decoration: none;
}

/* ============================================
   Author Snippet (One-liner)
   ============================================ */
.vista-author-snippet {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1rem;
    font-family: var(--vista-author-body-font);
}

.vista-author-snippet-label {
    color: var(--vista-author-secondary-color);
    font-weight: 500;
    font-size: 1rem;
}

.vista-author-snippet-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    vertical-align: middle;
    border: 2px solid #e5e7eb;
}

.vista-author-snippet-name {
    color: var(--vista-author-text-color);
    font-weight: 600;
    font-size: 1rem;
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 768px) {
    .vista-author-box {
        grid-template-columns: 70px 1fr;
        gap: 1.25rem;
        padding: 1.25rem;
    }

    .vista-author-avatar img {
        width: 70px;
        height: 70px;
    }

    .vista-author-name {
        font-size: 1.1rem;
    }

    .vista-author-title {
        font-size: 0.9rem;
    }

    .vista-author-bio {
        font-size: 0.9rem;
    }
}

@media (max-width: 600px) {
    .vista-author-box {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 1rem;
        padding: 1rem;
    }

    .vista-author-avatar {
        justify-self: center;
    }

    .vista-author-avatar img {
        width: 80px;
        height: 80px;
    }

    .vista-author-content {
        align-items: center;
    }

    .vista-author-social {
        justify-content: center;
    }

    .vista-author-link {
        text-align: center;
    }
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
    .vista-author-box {
        background: #ffffff;
        border: 1px solid #000000;
        page-break-inside: avoid;
    }

    .vista-author-url,
    .vista-author-social {
        display: none;
    }
}
