/**
 * Copyright (c) 2026 Estait Group LLC
 * All rights reserved.
 * 
 * Base Theme Styles - Inheritable via Custom CSS API
 * Uses Material Design Component (MDC) CSS custom properties
 * All MDC components inherit these automatically
 */

/* CSS Custom Properties - NO HARDCODED FALLBACKS - Inherit from site custom CSS */
:root {
    /* Map custom variables to MDC theme system */
    /* Custom CSS (wp_custom_css) defines --mdc-theme-* variables per site */
    --primary-color: var(--mdc-theme-primary);
    --primary-dark: var(--mdc-theme-secondary);
    --primary-light: var(--mdc-theme-primary-alpha, rgba(102, 126, 234, 0.1));
    
    /* Secondary Colors */
    --secondary-color: var(--mdc-theme-secondary);
    --secondary-light: var(--mdc-theme-secondary-alpha, rgba(118, 75, 162, 0.1));
    
    /* Background Colors - Use MDC theme from custom CSS */
    --bg-body: var(--mdc-theme-background);
    --bg-section: var(--mdc-theme-surface);
    --bg-card: var(--mdc-theme-surface);
    --bg-hero: var(--bg-hero-gradient, linear-gradient(135deg, var(--mdc-theme-primary) 0%, var(--mdc-theme-secondary) 100%));
    
    /* Text Colors - NO HARDCODED VALUES */
    --text-primary: var(--neutral-dark, var(--mdc-theme-primary));
    --text-secondary: var(--text-secondary-color, #666666);
    --text-on-primary: var(--mdc-theme-on-primary);
    
    /* Typography - Inherit from MDC (custom CSS defines this) */
    --font-family: var(--mdc-typography-font-family);
    --font-heading: var(--mdc-typography-headline1-font-family, var(--font-family));
    --font-body: var(--mdc-typography-body1-font-family, var(--font-family));
    
    /* Button Colors - NO FALLBACKS */
    --btn-primary-bg: var(--mdc-theme-primary);
    --btn-primary-text: var(--mdc-theme-on-primary);
    --btn-secondary-bg: var(--btn-secondary-bg-custom, rgba(255,255,255,0.2));
    --btn-secondary-text: var(--mdc-theme-on-primary);
    --btn-cta-bg: var(--mdc-theme-on-primary);
    --btn-cta-text: var(--mdc-theme-primary);
    
    /* Spacing */
    --section-padding: 60px 20px;
    --card-padding: 32px;
    --button-padding: 14px 32px;
    
    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-full: 50%;
}

/* Apply font inheritance to all text elements */
body,
h1, h2, h3, h4, h5, h6,
p, a, span, div,
button, input, textarea, select {
    font-family: var(--font-family);
}

/* Hero Section */
.hero-section {
    background: var(--bg-hero);
    padding: 80px 20px;
    text-align: center;
    color: var(--text-on-primary);
    margin-bottom: 60px;
}

.hero-content {
    max-width: 900px;
    margin: 0 auto;
}

.hero-section h1 {
    font-size: 3rem;
    margin-bottom: 24px;
    font-weight: 500;
    color: inherit !important;
}

.site-main {
    padding-top: 20px;
}

.hero-section p {
    font-size: 1.3rem;
    margin-bottom: 32px;
    opacity: 0.95;
}

/* Button Styles */
.btn {
    padding: var(--button-padding);
    border-radius: var(--radius-sm);
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.btn-primary {
    background: var(--btn-cta-bg);
    color: var(--btn-cta-text);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.3);
}

.btn-secondary {
    background: var(--btn-secondary-bg);
    color: var(--btn-secondary-text);
    border: 2px solid currentColor;
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.3);
}

.btn-container {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Feature Cards */
.feature-card {
    background: var(--bg-card);
    padding: var(--card-padding);
    border-radius: var(--radius-md);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.feature-icon {
    width: 64px;
    height: 64px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.feature-icon.primary {
    background: var(--primary-light);
    color: var(--primary-color);
}

.feature-icon.secondary {
    background: var(--secondary-light);
    color: var(--secondary-color);
}

.feature-card h3 {
    margin-bottom: 16px;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Sections */
.features-section {
    max-width: 1200px;
    margin: 0 auto 60px;
    padding: 0 20px;
}

.features-section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 48px;
    color: var(--text-primary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 32px;
}

.stats-section {
    background: var(--bg-section);
    padding: var(--section-padding);
    margin-bottom: 60px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    text-align: center;
    max-width: 1200px;
    margin: 0 auto;
}

.stat-value {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 8px;
}

.stat-value.primary {
    color: var(--primary-color);
}

.stat-value.secondary {
    color: var(--secondary-color);
}

.stat-label {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* CTA Section */
.cta-section {
    max-width: 900px;
    margin: 0 auto 60px;
    padding: 60px 40px;
    background: var(--bg-hero);
    border-radius: var(--radius-lg);
    text-align: center;
    color: var(--text-on-primary);
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
}

.cta-section h2 {
    font-size: 2.5rem;
    margin-bottom: 16px;
    color: inherit;
}

.cta-section p {
    font-size: 1.2rem;
    margin-bottom: 32px;
    opacity: 0.95;
}

/* Icon styling within text */
.material-icons {
    vertical-align: middle;
    font-size: inherit;
}

.feature-icon .material-icons {
    font-size: 32px;
}

/* Footer Styles - Higher specificity to override MDC card */
footer.network-footer {
    background-color: var(--mdc-theme-primary) !important;
    color: var(--mdc-theme-on-primary) !important;
    padding: 28px 14px 14px;
    margin-top: 42px;
    border-radius: 0 !important;
}

.network-footer__title {
    color: inherit !important;
    margin-bottom: 16px;
}

.network-footer__bottom {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.2);
}

.network-footer__bottom p {
    color: inherit !important;
    margin: 0;
}

/* Utility Classes for Color Overrides */
.bg-primary { background-color: var(--primary-color) !important; }
.bg-secondary { background-color: var(--secondary-color) !important; }
.text-primary { color: var(--text-primary) !important; }
.text-secondary { color: var(--text-secondary) !important; }
