/* Component System for SalesforceConsultants.io
 * Centralized component styles for consistent design
 */

/* ===== TEXT COMPONENTS ===== */
.text-component {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
}

.text-heading {
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
    color: var(--text-on-light);
}

.text-heading-dark {
    color: var(--text-on-dark);
}

.text-body {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-on-light);
    font-weight: 400;
}

.text-body-dark {
    color: var(--text-on-dark);
    opacity: 0.95;
}

.text-muted {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.text-high-contrast {
    color: var(--text-dark);
    font-weight: 600;
}

/* ===== CARD COMPONENTS ===== */
.card {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-medium);
    transition: var(--transition);
}

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

.card-dark {
    background: var(--dark);
    color: var(--text-on-dark);
}

.card-teal {
    background: var(--gradient-card);
    color: var(--text-on-dark);
}

/* ===== BUTTON COMPONENTS ===== */
.btn-component {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    border: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    min-height: 48px; /* WCAG touch target size */
}

.btn-primary-component {
    background: var(--teal);
    color: var(--text-on-dark);
}

.btn-primary-component:hover {
    background: var(--teal-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.btn-secondary-component {
    background: transparent;
    color: var(--teal);
    border: 2px solid var(--teal);
}

.btn-secondary-component:hover {
    background: var(--teal);
    color: var(--text-on-dark);
}

/* ===== FOOTER COMPONENT (Site-Wide) ===== */
footer,
.footer-component {
    background: var(--dark);
    color: var(--text-on-dark);
    padding: var(--spacing-xl) 0 var(--spacing-md);
    margin-top: var(--margin-2xl);
}

.footer-content,
.footer-component .footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: var(--gap-lg);
    margin-bottom: var(--margin-md);
}

.footer-section {
    padding: 0;
}

.footer-section h3 {
    color: var(--teal);
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: var(--spacing-sm);
}

.footer-section p,
.footer-section li {
    font-size: 0.875rem;
    line-height: 1.6;
    color: var(--text-on-dark);
    opacity: 0.9;
    margin-bottom: var(--spacing-xs);
}

.footer-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-section ul li {
    margin-bottom: var(--spacing-xs);
}

.footer-section a {
    color: var(--text-on-dark);
    text-decoration: none;
    opacity: 0.85;
    transition: var(--transition);
}

.footer-section a:hover {
    color: var(--teal);
    opacity: 1;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.15);
    padding-top: var(--spacing-sm);
    text-align: center;
    font-size: 0.8rem;
    opacity: 0.8;
}

.footer-bottom p {
    margin: var(--spacing-xs) 0;
    font-size: 0.8rem;
}

.footer-bottom a {
    color: var(--accent-gold);
    text-decoration: none;
    transition: var(--transition);
}

.footer-bottom a:hover {
    color: var(--teal);
    text-decoration: underline;
}

/* ===== IMAGE COMPONENTS (Site-Wide) ===== */
.img-component {
    max-width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    /* Prevent layout shifts */
    aspect-ratio: attr(width) / attr(height);
}

.img-logo {
    max-width: 100%;
    height: auto;
    object-fit: contain;
    /* Standardized spacing for logos */
    margin: 0;
    padding: var(--spacing-xs);
}

.img-profile {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    /* Standardized spacing for profile images */
    margin-bottom: var(--spacing-md);
}

/* Image spacing utilities */
.img-margin-sm { margin: var(--spacing-sm); }
.img-margin-md { margin: var(--spacing-md); }
.img-margin-lg { margin: var(--spacing-lg); }
.img-padding-sm { padding: var(--spacing-sm); }
.img-padding-md { padding: var(--spacing-md); }

/* ===== SECTION COMPONENTS (Site-Wide) ===== */
.section-component {
    padding: var(--section-padding-md);
}

.section-component-dark {
    background: var(--dark);
    color: var(--text-on-dark);
    padding: var(--section-padding-md);
}

.section-component-light {
    background: var(--white);
    color: var(--text-on-light);
    padding: var(--section-padding-md);
}

/* ===== CONTAINER COMPONENT ===== */
.container-component {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

@media (max-width: 768px) {
    .container-component {
        padding: 0 var(--spacing-md);
    }
    
    .section-component,
    .section-component-dark,
    .section-component-light {
        padding: var(--spacing-xl) 0;
    }
    
    footer,
    .footer-component {
        padding: var(--spacing-lg) 0 var(--spacing-sm);
    }
    
    .footer-content,
    .footer-component .footer-grid {
        grid-template-columns: 1fr;
        gap: var(--gap-md);
    }
    
    .footer-section h3 {
        font-size: 0.95rem;
        margin-bottom: var(--spacing-xs);
    }
    
    .footer-section p,
    .footer-section li {
        font-size: 0.8rem;
    }
}
