/**
 * Theme bridge CSS — loaded AFTER production tia-frontend.css
 * Only theme shell (header/footer/main) + small fixes so design matches live plugin UI.
 * Do not re-implement the full design system here.
 */

/* Theme body baseline when not using Hello Elementor */
body.tia-theme {
    margin: 0;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #111827;
    background: #fff;
    line-height: 1.55;
}

body.tia-theme a {
    text-decoration: none;
}

/* ---- Theme PHP header (matches plugin .tia-top-bar + white nav) ---- */
.tia-site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.tia-site-header .tia-top-bar {
    background: linear-gradient(135deg, #1d4ed8 0%, #7c3aed 50%, #dc2626 100%) !important;
    color: #fff !important;
    font-size: 14px !important;
    padding: 10px 0 !important;
    text-align: center;
}

.tia-header-main {
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
}

.tia-header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.tia-site-title {
    font-weight: 800;
    font-size: 1.25rem;
    color: #0f172a;
}

.tia-brand .custom-logo-link img,
.tia-brand .custom-logo {
    max-height: 56px;
    width: auto;
    object-fit: contain;
}

.tia-menu {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 8px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.tia-menu a {
    color: #374151 !important;
    font-weight: 500 !important;
    padding: 10px 14px !important;
    display: inline-block;
    transition: color 0.2s;
}

.tia-menu a:hover {
    color: #2563eb !important;
}

.tia-header-cta .tia-btn,
.tia-header-cta a.tia-btn-primary {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: #fff !important;
    border: none;
    border-radius: 8px;
    padding: 10px 18px;
    font-weight: 700;
}

/* Skip link */
.tia-skip-link {
    position: absolute;
    left: -9999px;
}
.tia-skip-link:focus {
    left: 12px;
    top: 12px;
    z-index: 10000;
    background: #fff;
    padding: 8px 12px;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,.15);
}

/* Main content area — let directory templates go full bleed */
.tia-main {
    min-height: 50vh;
}

/* ---- Theme PHP footer ---- */
.tia-site-footer {
    background: #0f172a;
    color: #e2e8f0;
    padding: 48px 0 0;
    margin-top: 0;
}

.tia-footer-grid {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px 32px;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 28px;
}

.tia-footer-title {
    color: #fff;
    margin: 0 0 12px;
    font-size: 1.05rem;
}

.tia-footer-links {
    list-style: none;
    margin: 0;
    padding: 0;
}

.tia-footer-links a {
    color: #cbd5e1;
}

.tia-footer-links a:hover {
    color: #fff;
}

.tia-footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 16px 0;
    font-size: 0.9rem;
    color: #94a3b8;
}

.tia-footer-bottom .tia-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Full-width directory pages: kill leftover theme padding */
body.tia-directory-page .tia-main,
body.tia-full-width .tia-main {
    padding: 0;
    max-width: none;
}

/* Admin bar offset for sticky header */
body.admin-bar .tia-site-header {
    top: 32px;
}
@media screen and (max-width: 782px) {
    body.admin-bar .tia-site-header {
        top: 46px;
    }
}

@media (max-width: 900px) {
    .tia-footer-grid {
        grid-template-columns: 1fr;
    }
    .tia-header-inner {
        flex-wrap: wrap;
        padding: 12px 16px;
    }
    .tia-header-cta {
        display: none;
    }
}
