/* Glasgow Surveyors - Main Stylesheet */
/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #003d5c;
    --secondary-color: #0066a1;
    --accent-color: #ff6b35;
    --text-dark: #1a1a1a;
    --text-light: #666666;
    --background-light: #f8f9fa;
    --white: #ffffff;
    --success: #28a745;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.2);
    --transition: all 0.3s ease;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--white);
    overflow-x: hidden;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
}

h2 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
}

p {
    margin-bottom: 1rem;
    line-height: 1.8;
}

/* Header & Navigation */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    z-index: 1000;
    transition: var(--transition);
}

.header.scrolled {
    box-shadow: var(--shadow-md);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-weight: 700;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    color: var(--text-dark);
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover {
    color: var(--secondary-color);
    background: var(--background-light);
}

.nav-link.active {
    color: var(--secondary-color);
}

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--primary-color);
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6rem 2rem 4rem;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-background img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    animation: kenBurns 30s ease-in-out infinite alternate;
}

@keyframes kenBurns {
    0% {
        transform: scale(1) translateX(0);
    }
    50% {
        transform: scale(1.1) translateX(-2%);
    }
    100% {
        transform: scale(1.05) translateX(2%);
    }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 61, 92, 0.85) 0%, rgba(0, 102, 161, 0.75) 100%);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    max-width: 1400px;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text {
    color: var(--white);
    animation: fadeInUp 1s ease-out;
}

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

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.95;
    line-height: 1.6;
}

.hero-keywords {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.keyword-badge {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.hero-form {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    animation: fadeInRight 1s ease-out 0.3s both;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    border: none;
    transition: var(--transition);
    font-size: 1rem;
}

.btn-primary {
    background: var(--accent-color);
    color: var(--white);
}

.btn-primary:hover {
    background: #e55a2b;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--white);
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: var(--white);
}

/* Sections */
.section {
    padding: 5rem 2rem;
    position: relative;
}

.section-alt {
    background: var(--background-light);
}

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

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

.section-title {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.section-subtitle {
    color: var(--text-light);
    font-size: 1.125rem;
    max-width: 800px;
    margin: 0 auto;
}

/* Cards */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    cursor: pointer;
}

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

.card-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.card-content {
    padding: 2rem;
}

.card-title {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.card-text {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.card-link {
    color: var(--secondary-color);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.card-link:hover {
    gap: 1rem;
}

/* Service Cards */
.service-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.service-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 2rem;
    margin-bottom: 1.5rem;
}

/* Team Members */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 3rem;
}

.team-member {
    text-align: center;
}

.team-image {
    width: 100%;
    aspect-ratio: 3/4;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.team-member:hover .team-image {
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

.team-name {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.team-role {
    color: var(--secondary-color);
    font-weight: 600;
    margin-bottom: 1rem;
}

.team-bio {
    color: var(--text-light);
    line-height: 1.8;
}

/* Reviews */
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.review-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    position: relative;
}

.review-stars {
    color: #ffc107;
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.review-text {
    color: var(--text-dark);
    font-style: italic;
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.review-author {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.review-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-weight: 700;
}

.review-author-info h4 {
    margin-bottom: 0.25rem;
    color: var(--primary-color);
}

.review-author-info p {
    margin: 0;
    color: var(--text-light);
    font-size: 0.875rem;
}

/* FAQ */
.faq-container {
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
}

.faq-item {
    background: var(--white);
    border-radius: 8px;
    margin-bottom: 1rem;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}

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

.faq-question span:first-child {
    flex: 1;
    padding-right: 1rem;
}

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

.faq-icon {
    transition: transform 0.3s ease;
    font-size: 1.5rem;
    color: var(--secondary-color);
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-in-out;
}

.faq-answer-content {
    padding: 0 2rem 1.5rem;
    color: var(--text-light);
    line-height: 1.8;
    font-size: 1rem;
}

.faq-answer-content a {
    color: var(--secondary-color);
    text-decoration: underline;
}

.faq-answer-content a:hover {
    color: var(--accent-color);
}

/* Areas Covered */
.areas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.area-card {
    background: var(--white);
    padding: 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.area-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-md);
}

.area-image-wrapper {
    width: 100%;
    height: 180px;
    overflow: hidden;
    position: relative;
}

.area-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.area-card:hover .area-image {
    transform: scale(1.1);
}

.area-card h3,
.area-card p {
    padding: 0 1.5rem;
}

.area-name {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 1.125rem;
    margin-top: 1.25rem;
}

.area-card p {
    padding-bottom: 1.5rem;
}

/* Stats */
.stats-section {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    padding: 4rem 2rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    text-align: center;
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: block;
}

.stat-label {
    font-size: 1.125rem;
    opacity: 0.95;
}

/* Blog */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    align-items: stretch;
}

.blog-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    text-decoration: none;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.blog-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.blog-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
}

.blog-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.blog-content > div:first-child {
    flex: 1;
    margin-bottom: 1rem;
}

.blog-content .btn {
    align-self: flex-start;
    margin-top: auto;
}

.blog-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    color: var(--text-light);
}

.blog-title {
    color: var(--primary-color);
    font-size: 1.25rem;
    line-height: 1.4;
    margin-bottom: 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-excerpt {
    color: var(--text-light);
    line-height: 1.6;
    font-size: 0.95rem;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-article {
    max-width: 900px;
    margin: 0 auto;
    padding: 8rem 2rem 4rem;
}

.blog-article-header {
    margin-bottom: 3rem;
}

.blog-article-title {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.blog-article-meta {
    display: flex;
    gap: 2rem;
    color: var(--text-light);
    margin-bottom: 2rem;
}

.blog-article-image {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 3rem;
}

.blog-article-content {
    font-size: 1.125rem;
    line-height: 1.9;
    color: var(--text-dark);
}

.blog-article-content h2 {
    color: var(--primary-color);
    margin-top: 2.5rem;
    margin-bottom: 1rem;
}

.blog-article-content h3 {
    color: var(--secondary-color);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.blog-article-content ul, 
.blog-article-content ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.blog-article-content li {
    margin-bottom: 0.5rem;
    line-height: 1.8;
}

/* Footer */
.footer {
    background: var(--primary-color);
    color: var(--white);
    padding: 3rem 2rem 1rem;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    color: var(--white);
    margin-bottom: 1.5rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--white);
    padding-left: 5px;
}

.footer-bottom {
    max-width: 1400px;
    margin: 0 auto;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    text-align: center;
    color: rgba(255, 255, 255, 0.8);
}

/* Contact Form Styling */
.hbspt-form {
    max-width: 100%;
}

.hbspt-form input,
.hbspt-form textarea,
.hbspt-form select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: inherit;
    font-size: 1rem;
    margin-bottom: 1rem;
    transition: var(--transition);
}

.hbspt-form input:focus,
.hbspt-form textarea:focus,
.hbspt-form select:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(0, 102, 161, 0.1);
}

/* Animations */
.fade-in {
    animation: fadeIn 1s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.slide-up {
    animation: slideUp 0.8s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Scroll Reveal */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.reveal.active,
.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Loading Spinner */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: var(--white);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .card-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
    
    .areas-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: rgba(255, 255, 255, 0.98);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--shadow-md);
        padding: 2rem 0;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .mobile-toggle {
        display: block;
    }
    
    .section {
        padding: 3rem 1.5rem;
    }
    
    .hero {
        padding: 5rem 1.5rem 3rem;
        min-height: auto;
    }
    
    .reviews-grid,
    .blog-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-grid {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    
    .faq-question {
        padding: 1.25rem 1.5rem;
        font-size: 1rem;
    }
    
    .faq-answer-content {
        padding: 0 1.5rem 1.25rem;
        font-size: 0.95rem;
    }
    
    .faq-icon {
        font-size: 1.25rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
    
    .team-grid {
        grid-template-columns: 1fr;
        max-width: 400px;
        margin: 0 auto;
    }
}

@media (max-width: 480px) {
    :root {
        font-size: 14px;
    }
    
    .nav-container {
        padding: 1rem;
    }
    
    .hero-keywords {
        display: none;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .card-grid,
    .areas-grid {
        grid-template-columns: 1fr;
    }
    
    .area-image-wrapper {
        height: 200px;
    }
}

/* Print Styles */
@media print {
    .header,
    .footer,
    .hero-form {
        display: none;
    }
}
