/*
Theme Name: Poor Credit Mortgage UK
Theme URI: https://poorcreditmortgageuk.co.uk
Author: Find Adviser
Author URI: https://poorcreditmortgageuk.co.uk
Description: A professional lead generation theme for poor credit mortgage services in the UK. Features dynamic location detection, SEO optimization, and Formspree integration.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: poor-credit-mortgage-uk
Tags: one-column, custom-colors, custom-logo, featured-images, theme-options, translation-ready
*/

/* ===== CSS Variables ===== */
:root {
    --primary: 204 70% 53%;
    --primary-foreground: 0 0% 100%;
    --secondary: 145 63% 49%;
    --secondary-foreground: 0 0% 100%;
    --navy: 204 80% 21%;
    --navy-foreground: 0 0% 100%;
    --background: 210 20% 98%;
    --foreground: 204 80% 21%;
    --card: 0 0% 100%;
    --card-foreground: 204 80% 21%;
    --muted: 210 15% 90%;
    --muted-foreground: 204 30% 40%;
    --accent: 145 63% 49%;
    --accent-foreground: 0 0% 100%;
    --border: 210 20% 85%;
    --input: 210 20% 85%;
    --ring: 204 70% 53%;
    --radius: 0.75rem;
}

/* ===== Reset & Base ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: hsl(var(--foreground));
    background-color: hsl(var(--background));
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 700;
    line-height: 1.2;
    color: hsl(var(--navy));
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

@media (min-width: 768px) {
    h1 { font-size: 3.5rem; }
    h2 { font-size: 2.5rem; }
    h3 { font-size: 1.75rem; }
}

a {
    color: hsl(var(--primary));
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: hsl(var(--secondary));
}

img {
    max-width: 100%;
    height: auto;
}

/* ===== Skip Link ===== */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: hsl(var(--navy));
    color: hsl(var(--navy-foreground));
    padding: 8px 16px;
    z-index: 100;
    transition: top 0.3s;
}

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

/* ===== Container ===== */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

@media (min-width: 768px) {
    .container {
        padding: 0 2rem;
    }
}

/* ===== Header ===== */
.site-header {
    background: linear-gradient(135deg, hsl(var(--navy)) 0%, hsl(204 70% 30%) 100%);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 50;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.site-logo svg {
    width: 48px;
    height: 48px;
}

.site-logo span {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.25rem;
    font-weight: 700;
    color: white;
}

/* ===== Hero Section ===== */
.hero-section {
    background: linear-gradient(135deg, hsl(var(--navy)) 0%, hsl(204 70% 30%) 50%, hsl(var(--primary)) 100%);
    padding: 3rem 0 4rem;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    align-items: center;
}

@media (min-width: 1024px) {
    .hero-grid {
        grid-template-columns: 1fr 1fr;
        gap: 4rem;
    }
}

.hero-text {
    color: white;
    text-align: center;
}

@media (min-width: 1024px) {
    .hero-text {
        text-align: left;
    }
}

.hero-text h1 {
    color: white;
    margin-bottom: 1.5rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.hero-text h1 .highlight {
    color: hsl(var(--secondary));
}

.hero-description {
    font-size: 1.125rem;
    opacity: 0.95;
    margin-bottom: 2rem;
    line-height: 1.7;
}

.hero-benefits {
    list-style: none;
    margin-bottom: 2rem;
}

.hero-benefits li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    font-size: 1rem;
}

.hero-benefits li svg {
    flex-shrink: 0;
    color: hsl(var(--secondary));
}

.trust-indicators {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

@media (min-width: 1024px) {
    .trust-indicators {
        justify-content: flex-start;
    }
}

.trust-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    opacity: 0.9;
}

.trust-item svg {
    color: hsl(var(--secondary));
}

/* ===== Lead Form ===== */
.lead-form-card {
    background: white;
    border-radius: var(--radius);
    padding: 2rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    border: 1px solid hsl(var(--border));
}

.form-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.form-header h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.form-header p {
    color: hsl(var(--muted-foreground));
    font-size: 0.875rem;
}

.lead-form .form-group {
    margin-bottom: 1rem;
}

.lead-form label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: hsl(var(--foreground));
    font-size: 0.875rem;
}

.lead-form input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid hsl(var(--border));
    border-radius: calc(var(--radius) - 4px);
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
    background: hsl(var(--background));
}

.lead-form input:focus {
    outline: none;
    border-color: hsl(var(--primary));
    box-shadow: 0 0 0 3px hsl(var(--primary) / 0.1);
}

.lead-form input::placeholder {
    color: hsl(var(--muted-foreground));
}

.submit-btn {
    width: 100%;
    padding: 1rem;
    background: linear-gradient(135deg, hsl(var(--secondary)) 0%, hsl(145 63% 40%) 100%);
    color: white;
    border: none;
    border-radius: calc(var(--radius) - 4px);
    font-size: 1.125rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px hsl(var(--secondary) / 0.3);
}

.submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.form-footer {
    text-align: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid hsl(var(--border));
}

.form-footer p {
    font-size: 0.75rem;
    color: hsl(var(--muted-foreground));
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.form-success {
    text-align: center;
    padding: 2rem;
}

.form-success svg {
    width: 64px;
    height: 64px;
    color: hsl(var(--secondary));
    margin-bottom: 1rem;
}

.form-success h3 {
    color: hsl(var(--secondary));
    margin-bottom: 0.5rem;
}

/* ===== Trust Badges Section ===== */
.trust-badges-section {
    padding: 4rem 0;
    background: white;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    margin-bottom: 1rem;
}

.section-header p {
    color: hsl(var(--muted-foreground));
    max-width: 600px;
    margin: 0 auto;
}

.badges-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .badges-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .badges-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.badge-card {
    background: hsl(var(--background));
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    padding: 1.5rem;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.badge-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.badge-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    background: linear-gradient(135deg, hsl(var(--primary) / 0.1) 0%, hsl(var(--secondary) / 0.1) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.badge-icon svg {
    width: 32px;
    height: 32px;
    color: hsl(var(--primary));
}

.badge-card h3 {
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
}

.badge-card p {
    font-size: 0.875rem;
    color: hsl(var(--muted-foreground));
}

/* ===== Testimonials Section ===== */
.testimonials-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, hsl(var(--background)) 0%, hsl(210 20% 95%) 100%);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .testimonials-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .testimonials-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.testimonial-card {
    background: white;
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid hsl(var(--border));
    position: relative;
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 4rem;
    font-family: Georgia, serif;
    color: hsl(var(--primary) / 0.1);
    line-height: 1;
}

.stars {
    display: flex;
    gap: 0.25rem;
    margin-bottom: 1rem;
}

.stars svg {
    width: 20px;
    height: 20px;
    color: #fbbf24;
    fill: #fbbf24;
}

.testimonial-text {
    font-style: italic;
    color: hsl(var(--foreground));
    margin-bottom: 1rem;
    line-height: 1.7;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding-top: 1rem;
    border-top: 1px solid hsl(var(--border));
}

.author-avatar {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, hsl(var(--primary)) 0%, hsl(var(--secondary)) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 1.125rem;
}

.author-info h4 {
    font-size: 0.875rem;
    font-family: 'Inter', sans-serif;
    margin-bottom: 0.25rem;
}

.author-info p {
    font-size: 0.75rem;
    color: hsl(var(--muted-foreground));
}

/* ===== SEO Content Section ===== */
.seo-content-section {
    padding: 4rem 0;
    background: white;
}

.seo-content-section h2 {
    text-align: center;
    margin-bottom: 3rem;
}

.content-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 1024px) {
    .content-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.content-card {
    background: hsl(var(--background));
    border-radius: var(--radius);
    padding: 1.5rem;
    border: 1px solid hsl(var(--border));
}

.content-card-header {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.content-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, hsl(var(--primary)) 0%, hsl(var(--secondary)) 100%);
    border-radius: calc(var(--radius) - 4px);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.content-icon svg {
    width: 24px;
    height: 24px;
    color: white;
}

.content-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.25rem;
}

.content-card > p {
    color: hsl(var(--muted-foreground));
    line-height: 1.7;
    margin-bottom: 1rem;
}

.content-card ul {
    list-style: none;
    padding: 0;
}

.content-card ul li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.9375rem;
}

.content-card ul li svg {
    flex-shrink: 0;
    color: hsl(var(--secondary));
    margin-top: 0.25rem;
}

/* ===== FAQ Section ===== */
.faq-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, hsl(var(--background)) 0%, hsl(210 20% 95%) 100%);
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: white;
    border-radius: var(--radius);
    margin-bottom: 1rem;
    border: 1px solid hsl(var(--border));
    overflow: hidden;
}

.faq-question {
    width: 100%;
    padding: 1.25rem 1.5rem;
    background: none;
    border: none;
    text-align: left;
    font-size: 1rem;
    font-weight: 600;
    color: hsl(var(--foreground));
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.2s;
}

.faq-question:hover {
    background: hsl(var(--background));
}

.faq-question svg {
    flex-shrink: 0;
    transition: transform 0.2s;
}

.faq-item.active .faq-question svg {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 1.5rem;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.active .faq-answer {
    padding: 0 1.5rem 1.25rem;
    max-height: 500px;
}

.faq-answer p {
    color: hsl(var(--muted-foreground));
    line-height: 1.7;
}

/* ===== Disclaimer Section ===== */
.disclaimer-section {
    padding: 3rem 0;
    background: hsl(var(--navy));
    color: white;
}

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

.disclaimer-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.disclaimer-header svg {
    color: hsl(var(--secondary));
}

.disclaimer-header h2 {
    color: white;
    font-size: 1.5rem;
}

.disclaimer-text {
    opacity: 0.9;
    line-height: 1.8;
}

.disclaimer-text p {
    margin-bottom: 1rem;
}

.disclaimer-text ul {
    list-style: none;
    padding: 0;
    margin: 1rem 0;
}

.disclaimer-text ul li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.disclaimer-text ul li svg {
    flex-shrink: 0;
    color: hsl(var(--secondary));
    margin-top: 0.25rem;
}

.author-info-box {
    margin-top: 2rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
    border-left: 4px solid hsl(var(--secondary));
}

.author-info-box p {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.author-info-box svg {
    color: hsl(var(--secondary));
}

/* ===== Footer ===== */
.site-footer {
    background: hsl(204 80% 15%);
    color: white;
    padding: 3rem 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 768px) {
    .footer-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 2rem;
    }
}

.footer-logo-section {
    display: flex;
    flex-direction: column;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.footer-logo svg {
    width: 32px;
    height: 32px;
}

.footer-logo span {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 600;
}

.footer-services h4 {
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 1rem;
    color: white;
}

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

.footer-services ul li {
    margin-bottom: 0.5rem;
}

.footer-services ul li a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.875rem;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-services ul li a:hover {
    color: white;
}

.footer-copyright {
    text-align: left;
}

@media (min-width: 768px) {
    .footer-copyright {
        text-align: right;
    }
}

.footer-copyright p {
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
    color: rgba(255, 255, 255, 0.6);
}

.footer-copyright .fca-note {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
}

/* ===== Utility Classes ===== */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-8 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-8 { margin-bottom: 2rem; }

.hidden { display: none; }

@media (max-width: 767px) {
    .hide-mobile { display: none; }
}

@media (min-width: 768px) {
    .hide-desktop { display: none; }
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.6s ease forwards;
}

/* ===== Print Styles ===== */
@media print {
    .site-header,
    .lead-form-card,
    .site-footer {
        display: none;
    }
    
    body {
        font-size: 12pt;
        color: black;
        background: white;
    }
}
