/*
Theme Name: TechFix Block Theme
Theme URI: https://github.com/yourusername/tech_fix
Author: Your Name
Author URI: https://yourdomain.com
Description: A clean, modern block theme for tech repair and IT services. Built for trust and clarity.
Requires at least: 6.2
Tested up to: 6.6
Requires PHP: 8.0
Version: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: tech_fix
Tags: block-patterns, block-styles, full-site-editing, one-column, two-columns, blog, services, technology
*/

/* ============================================
   Custom Styles Beyond theme.json
   ============================================ */

/* Smooth transitions globally */
* {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

/* Card hover effects for service cards */
.service-card {
    border: 1px solid var(--wp--preset--color--border-light, #E2E8F0);
    border-radius: 12px;
    padding: var(--wp--preset--spacing--40, 2rem);
    background: var(--wp--preset--color--surface, #FFFFFF);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.service-card:hover {
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
    transform: translateY(-6px);
}

/* Problem/Solution table responsiveness */
.services-table {
    border-collapse: separate;
    border-spacing: 0;
    border-radius: 12px;
    overflow: hidden;
}

.services-table th {
    background: var(--wp--preset--color--deep-blue, #1B2A4A);
    color: #FFFFFF;
    font-weight: 600;
    padding: 1rem 1.5rem;
    text-align: left;
}

.services-table td {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--wp--preset--color--border-light, #E2E8F0);
    background: #FFFFFF;
}

.services-table tr:last-child td {
    border-bottom: none;
}

.services-table tr:hover td {
    background: var(--wp--preset--color--warm-white, #F8FAFC);
}

/* Mobile table stacking */
@media (max-width: 768px) {
    .services-table,
    .services-table thead,
    .services-table tbody,
    .services-table th,
    .services-table td,
    .services-table tr {
        display: block;
    }
    
    .services-table thead tr {
        position: absolute;
        top: -9999px;
        left: -9999px;
    }
    
    .services-table td {
        border: none;
        position: relative;
        padding-left: 50%;
        min-height: 3.5rem;
    }
    
    .services-table td:before {
        position: absolute;
        top: 1rem;
        left: 1.5rem;
        width: 45%;
        padding-right: 10px;
        white-space: nowrap;
        font-weight: 700;
        color: var(--wp--preset--color--deep-blue, #1B2A4A);
    }
    
    .services-table td:nth-of-type(1):before { content: "You Might Be Seeing..."; }
    .services-table td:nth-of-type(2):before { content: "How I Fix It"; }
    
    .services-table tr {
        border-bottom: 2px solid var(--wp--preset--color--border-light, #E2E8F0);
        margin-bottom: 1rem;
    }
}

/* FAQ accordion styling */
.wp-block-details {
    border: 1px solid var(--wp--preset--color--border-light, #E2E8F0);
    border-radius: 8px;
    margin-bottom: 0.5rem;
    overflow: hidden;
}

.wp-block-details summary {
    cursor: pointer;
    padding: 1.25rem 1.5rem;
    font-weight: 600;
    font-size: 1.05rem;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #FFFFFF;
}

.wp-block-details summary::-webkit-details-marker {
    display: none;
}

.wp-block-details summary::after {
    content: "+";
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--wp--preset--color--teal, #0D9488);
    transition: transform 0.3s ease;
}

.wp-block-details[open] summary::after {
    content: "\2212";
    transform: rotate(180deg);
}

.wp-block-details[open] summary {
    color: var(--wp--preset--color--teal, #0D9488);
    border-bottom: 1px solid var(--wp--preset--color--border-light, #E2E8F0);
}

.wp-block-details .wp-block-details__content {
    padding: 1.25rem 1.5rem;
    background: var(--wp--preset--color--warm-white, #F8FAFC);
    line-height: 1.7;
}

/* Blog post readability */
.single-post .entry-content,
.blog .entry-content {
    max-width: 72ch;
    margin-inline: auto;
}

.single-post .entry-content p,
.blog .entry-content p {
    line-height: 1.85;
    margin-bottom: 1.5rem;
}

/* Step-by-step guide styling */
.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--wp--preset--color--teal, #0D9488);
    color: #FFFFFF;
    border-radius: 50%;
    font-weight: 700;
    font-size: 1rem;
    margin-right: 0.75rem;
    flex-shrink: 0;
}

/* Testimonial styling */
.testimonial-quote {
    border-left: 4px solid var(--wp--preset--color--teal, #0D9488);
    background: var(--wp--preset--color--warm-white, #F8FAFC);
    padding: 2rem;
    border-radius: 0 12px 12px 0;
    position: relative;
}

.testimonial-quote::before {
    content: "\201C";
    font-size: 4rem;
    color: var(--wp--preset--color--teal, #0D9488);
    opacity: 0.2;
    position: absolute;
    top: -10px;
    left: 16px;
    font-family: Georgia, serif;
    line-height: 1;
}

/* Trust bar badges */
.trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
}

/* Pricing cards */
.pricing-card {
    border: 2px solid var(--wp--preset--color--border-light, #E2E8F0);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
    background: #FFFFFF;
}

.pricing-card.featured {
    border-color: var(--wp--preset--color--teal, #0D9488);
    box-shadow: 0 8px 30px rgba(13, 148, 136, 0.12);
    transform: scale(1.03);
}

.pricing-card:hover {
    border-color: var(--wp--preset--color--teal, #0D9488);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.08);
}

.pricing-price {
    font-size: 3rem;
    font-weight: 700;
    color: var(--wp--preset--color--deep-blue, #1B2A4A);
    margin: 1rem 0;
}

/* CTA banner in blog posts */
.cta-banner {
    background: linear-gradient(135deg, var(--wp--preset--color--deep-blue, #1B2A4A), #2D4A6A);
    color: #FFFFFF;
    padding: 2.5rem;
    border-radius: 12px;
    text-align: center;
    margin: 3rem 0;
}

.cta-banner a {
    color: #FFFFFF;
    text-decoration: underline;
    font-weight: 600;
}

/* Print-friendly */
@media print {
    header,
    footer,
    .wp-block-buttons,
    .cta-banner,
    nav,
    .site-header,
    .site-footer {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        color: #000;
        background: #FFF;
    }
    
    a {
        text-decoration: underline;
        color: #000;
    }
}

/* Accessibility: focus styles */
a:focus-visible,
button:focus-visible,
summary:focus-visible {
    outline: 3px solid var(--wp--preset--color--teal, #0D9488);
    outline-offset: 3px;
}

/* Skip to content link for accessibility */
.skip-link {
    position: absolute;
    top: -100px;
    left: 0;
    background: var(--wp--preset--color--deep-blue, #1B2A4A);
    color: #FFF;
    padding: 0.75rem 1.5rem;
    z-index: 9999;
    text-decoration: none;
    border-radius: 0 0 8px 0;
}

.skip-link:focus {
    top: 0;
}