/* CSS Variables - Grant Thornton / Rawstone Fusion */
:root {
    /* Brand Colors */
    --color-primary: #4F2D7F;
    /* Purple - Brand Identity */
    --color-primary-dark: #371e59;
    --color-secondary: #00838F;
    /* Teal - Accents */
    --color-accent: #9BD732;
    /* Green - Minor highlights */

    --color-bg-light: #FFFFFF;
    --color-bg-off-white: #F8F9FA;
    --color-bg-dark: #1A1A1A;

    --color-text-main: #2D2D2D;
    --color-text-light: #555555;
    --color-text-lighter: #888888;

    --color-border: #E5E5E5;

    /* Typography */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Spacing */
    --container-width: 1280px;
    --spacing-xs: 0.5rem;
    --spacing-sm: 1.5rem;
    --spacing-md: 3rem;
    --spacing-lg: 5rem;
    --spacing-xl: 8rem;

    /* Effects */
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --radius-sm: 4px;
    --radius-md: 8px;
}

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

html {
    scroll-behavior: smooth;
    background-color: white;
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: var(--font-body);
    color: var(--color-text-main);
    line-height: 1.6;
    background-color: white;
    -webkit-font-smoothing: antialiased;
    box-shadow: none;
    margin: 0;
    overflow-x: hidden;
    width: 100%;
}

h1,
h2,
h3,
h4,
h5 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-primary);
}

a {
    text-decoration: none;
    transition: 0.3s;
    color: inherit;
}

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

ul {
    list-style: none;
}

/* Utilities */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 2rem;
}

.section-tag {
    display: block;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--color-secondary);
    margin-bottom: 1rem;
}

.highlight {
    color: var(--color-secondary);
}

.text-white {
    color: white !important;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.9rem 2.2rem;
    font-weight: 600;
    font-family: var(--font-heading);
    border-radius: var(--radius-sm);
    /* Rawstone uses sharper corners often */
    font-size: 1rem;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

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

.btn-primary:hover {
    background-color: var(--color-primary-dark);
    transform: translateY(-2px);
}

.btn-outline-white {
    background-color: transparent;
    border-color: white;
    color: white;
}

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

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: var(--shadow-sm);
    padding: 1rem 0;
}

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

.logo {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--color-primary);
    letter-spacing: -0.5px;
}

.logo-highlight {
    color: var(--color-secondary);
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

.nav-links a:not(.btn) {
    font-weight: 500;
    color: var(--color-text-main);
    font-size: 0.95rem;
}

.nav-links a:not(.btn):hover {
    color: var(--color-primary);
}

.hamburger {
    display: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--color-primary);
}

/* Hero Section - Corporate Style */
.hero {
    padding-top: 180px;
    padding-bottom: 100px;
    background-color: white;
    /* Changed from #f4f6fa to remove "edge lighting" feel */
    position: relative;
    overflow: hidden;
}

/* Removed Edge Lighting Effect (.hero::after) per user request */
/* Ensure no overlay */
.hero-overlay {
    display: none;
}

.hero-content {
    max-width: 800px;
    position: relative;
    z-index: 2;
}

/* Dropdown Menu */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    box-shadow: var(--shadow-md);
    min-width: 220px;
    border-radius: var(--radius-sm);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    padding: 0.5rem 0;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li a {
    display: block;
    padding: 0.8rem 1.5rem;
    font-size: 0.9rem;
    color: var(--color-text-main);
    border-bottom: 1px solid #f0f0f0;
}

.dropdown-menu li:last-child a {
    border-bottom: none;
}

.dropdown-menu li a:hover {
    background-color: var(--color-bg-off-white);
    color: var(--color-primary);
    padding-left: 1.8rem;
    /* slight shift effect */
}

/* Insights Grid */
.insights-section {
    padding: var(--spacing-lg) 0;
}

.insights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
}

.insight-card {
    background: white;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid var(--color-border);
}

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

.insight-image {
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--color-primary);
}

.insight-content {
    padding: 1.5rem;
}

.insight-date {
    font-size: 0.8rem;
    color: var(--color-text-lighter);
    display: block;
    margin-bottom: 0.5rem;
}

.insight-content h3 {
    font-size: 1.2rem;
    margin-bottom: 0.8rem;
}

.read-more {
    color: var(--color-secondary);
    font-weight: 600;
    font-size: 0.9rem;
    margin-top: 1rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* Services Detail Pages */
.service-detail {
    padding: var(--spacing-lg) 0;
    border-bottom: 1px solid var(--color-border);
}

.bg-off-white {
    background-color: var(--color-bg-off-white);
}

.service-grid {
    display: grid;
    grid-template-columns: 1fr;
    /* Single column for clarity or 2 if needed */
    gap: 3rem;
    max-width: 900px;
    margin: 0 auto;
}

.service-icon {
    font-size: 3rem;
    color: var(--color-secondary);
    margin-bottom: 1.5rem;
}

.check-list {
    margin-top: 1.5rem;
}

.check-list li {
    position: relative;
    padding-left: 2rem;
    margin-bottom: 0.8rem;
    color: var(--color-text-light);
}

.check-list li::before {
    content: '\f00c';
    /* FontAwesome check */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    top: 2px;
    color: var(--color-accent);
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--color-bg-dark);
    color: white;
    padding: 1rem 0;
    z-index: 2000;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    display: none;
    /* JS will show flex */
}

.cookie-banner.show {
    transform: translateY(0);
    display: block;
}

.cookie-banner .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cookie-banner a {
    color: var(--color-accent);
    text-decoration: underline;
}

/* Page Header */
.page-header {
    background-color: var(--color-primary);
    color: white;
    padding: 180px 0 80px;
    text-align: center;
}

.page-header h1 {
    color: white;
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.page-header p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

.page-header .eyebrow {
    color: var(--color-accent);
}

/* Newsletter */
.newsletter-form-container {
    max-width: 500px;
    margin: 2rem auto 0;
}

.newsletter-form {
    display: flex;
    gap: 0.5rem;
}

.newsletter-form input {
    flex: 1;
    padding: 0.8rem;
    border: none;
    border-radius: var(--radius-sm);
}

/* ============================================================
   SMALL LAPTOP / NARROW WINDOW — 1024px and below
   PRIMARY FIX: Collapse all two-column layouts before they
   overflow — this is the root cause reported in the audit.
   ============================================================ */
@media (max-width: 1024px) {

    /* Reduce large vertical section padding */
    .contact,
    .firm-profile {
        padding: 4rem 0;
    }

    /* Section heading sizes */
    .profile-content h2,
    .section-header h2 {
        font-size: 2.1rem;
    }

    /* Contact form card padding reduced */
    .corporate-form {
        padding: 2rem 1.75rem;
    }

    /* Submit button full-width when form stacks */
    .corporate-form button[type="submit"],
    .corporate-form .btn {
        width: 100%;
        text-align: center;
    }
}

/* ============================================================
   TABLET & MOBILE RESPONSIVE — 768px and below
   ============================================================ */
@media (max-width: 768px) {

    /* Container safe padding */
    .container {
        padding: 0 1.25rem;
    }

    /* Header & Nav */
    .header {
        padding: 0.75rem 0;
    }

    .hamburger {
        display: flex;
        z-index: 1001;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: min(80%, 320px);
        height: 100vh;
        background-color: white;
        flex-direction: column;
        align-items: flex-start;
        padding: 5rem 2rem 2rem;
        box-shadow: -5px 0 20px rgba(0, 0, 0, 0.15);
        transition: right 0.3s ease-in-out;
        z-index: 1000;
        overflow-y: auto;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links li {
        width: 100%;
        margin-bottom: 1.25rem;
    }

    .nav-links a {
        font-size: 1.1rem;
        display: block;
    }

    /* Nav CTA button on mobile */
    .nav-links .btn {
        display: block;
        width: 100%;
        text-align: center;
        margin-top: 0.5rem;
    }

    /* Mobile Dropdowns */
    .dropdown-menu {
        position: static;
        box-shadow: none;
        border: none;
        padding-left: 1rem;
        display: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        margin-top: 0.5rem;
        min-width: unset;
        width: 100%;
    }

    .dropdown.active .dropdown-menu {
        display: block;
    }

    /* Hero */
    .hero {
        padding-top: 110px;
        padding-bottom: 50px;
    }

    .hero h1 {
        font-size: 2.4rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }

    .hero-buttons .btn {
        width: 100%;
        text-align: center;
    }

    /* Standard Page Headers */
    .page-header {
        padding-top: 110px !important;
        padding-bottom: 2rem !important;
    }

    .page-header h1 {
        font-size: 2rem !important;
    }

    .page-header p {
        font-size: 1rem !important;
    }

    /* Section spacing */
    .contact,
    .firm-profile,
    .expertise,
    .insights-section {
        padding: 3.5rem 0;
    }

    /* Section headings */
    .section-header h2,
    .mission h2,
    .cta-section h2,
    .profile-content h2 {
        font-size: 1.9rem;
    }

    .expertise-grid,
    .insights-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .sidebar {
        order: 2;
        position: static;
    }

    /* Contact items */
    .contact-item {
        flex-direction: row;
        gap: 1rem;
        align-items: flex-start;
    }

    /* Contact form */
    .corporate-form {
        padding: 1.75rem 1.25rem;
    }

    .form-row,
    .corporate-form .form-row {
        display: flex !important;
        flex-direction: column !important;
        gap: 1rem;
        margin-bottom: 1rem;
    }

    .corporate-form input,
    .corporate-form textarea {
        font-size: 1rem;
        padding: 0.9rem 1rem;
    }

    .corporate-form button[type="submit"],
    .corporate-form .btn {
        width: 100%;
        text-align: center;
    }

    /* Newsletter */
    .newsletter-form {
        flex-direction: column;
        gap: 0.75rem;
    }

    .newsletter-form input,
    .newsletter-form button {
        width: 100%;
        border-radius: var(--radius-sm) !important;
    }

    /* CTA section */
    .cta-section .btn {
        width: 100%;
        max-width: 320px;
    }

    /* Profile stats */
    .profile-stats {
        padding: 1.75rem;
    }

    /* Footer */
    .footer-top {
        flex-direction: column;
        align-items: flex-start;
        gap: 2rem;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    .footer-links {
        display: flex;
        gap: 1.5rem;
        justify-content: center;
    }

    /* Cookie Banner */
    .cookie-banner {
        padding: 1.25rem;
    }

    .cookie-banner .container {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    /* Article hero image */
    .article-hero {
        height: 220px;
    }

    /* Breadcrumbs */
    .breadcrumbs .container {
        white-space: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* Sidebar widget */
    .sidebar-widget {
        padding: 1.5rem;
    }

    /* Key contact card */
    .contact-card {
        flex-direction: column;
        text-align: center;
    }
}

/* ============================================================
   PHONE — 480px and below (375px iPhone SE safe)
   ============================================================ */
@media (max-width: 480px) {

    .container {
        padding: 0 1rem;
    }

    /* Hero */
    .hero {
        padding-top: 100px;
        padding-bottom: 40px;
    }

    .hero h1 {
        font-size: 1.9rem;
        line-height: 1.15;
    }

    .hero p {
        font-size: 0.95rem;
    }

    /* Page headers */
    .page-header h1 {
        font-size: 1.7rem !important;
        line-height: 1.2 !important;
    }

    /* Section headings */
    .section-header h2,
    .mission h2,
    .cta-section h2,
    .profile-content h2,
    .page-content h2 {
        font-size: 1.6rem;
    }

    /* Stat numbers */
    .stat-num {
        font-size: 2rem;
    }

    /* Contact form */
    .corporate-form {
        padding: 1.25rem 1rem;
        border-radius: var(--radius-sm);
    }

    /* Reduce section padding on phones */
    .contact,
    .firm-profile,
    .expertise,
    .insights-section,
    .mission {
        padding: 2.5rem 0;
    }

    /* Expertise card */
    .expertise-card {
        padding: 1.75rem 1.25rem;
    }

    /* Insight cards */
    .insight-image {
        height: 150px;
    }

    /* Footer */
    .footer {
        padding: 2.5rem 0 1.5rem;
    }

    /* Cookie banner buttons: side by side on small screens */
    .cookie-banner .container {
        align-items: center;
    }

    /* Nav CTA — smaller padding */
    .nav-links .btn {
        padding: 0.7rem 1.5rem;
        font-size: 0.95rem;
    }

    /* Article layout */
    .article-hero {
        height: 180px;
    }

    .article-meta {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    /* Back button */
    .back-btn {
        font-size: 0.9rem;
    }

    /* Profile stats */
    .profile-stats {
        padding: 1.25rem;
    }
}


.hero h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--color-primary);
}

.hero p {
    font-size: 1.3rem;
    color: var(--color-text-light);
    max-width: 650px;
    margin-bottom: 2.5rem;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.btn-outline-white {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

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

/* Mission - Clean & Centered */
.mission {
    padding: var(--spacing-lg) 0;
    background-color: white;
    text-align: center;
}

.mission-box {
    max-width: 900px;
    margin: 0 auto;
}

.mission h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--color-primary);
}

.mission p {
    font-size: 1.1rem;
    color: var(--color-text-light);
    line-height: 1.8;
}

/* Expertise Grid */
.expertise {
    padding: var(--spacing-lg) 0;
    background-color: var(--color-bg-off-white);
}

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

.section-header h2 {
    font-size: 2.5rem;
}

.expertise-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
}

.expertise-card {
    background: white;
    padding: 2.5rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s, box-shadow 0.3s;
    border-bottom: 3px solid transparent;
}

.expertise-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
    border-bottom-color: var(--color-secondary);
}

.card-icon {
    font-size: 2rem;
    color: var(--color-secondary);
    margin-bottom: 1.5rem;
}

.expertise-card h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
}

.expertise-card p {
    color: var(--color-text-light);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.card-list li {
    font-size: 0.9rem;
    color: var(--color-text-light);
    padding-left: 1.2rem;
    position: relative;
    margin-bottom: 0.5rem;
}

.card-list li::before {
    content: '•';
    color: var(--color-secondary);
    position: absolute;
    left: 0;
    font-weight: bold;
}

/* Firm Profile */
.firm-profile {
    padding: var(--spacing-xl) 0;
    background: white;
}

.profile-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: center;
}

.profile-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

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

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

.text-link:hover {
    gap: 0.8rem;
}

.profile-stats {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    background: var(--color-bg-off-white);
    padding: 3rem;
    border-radius: var(--radius-md);
}

.stat-item {
    padding-left: 1.5rem;
    border-left: 3px solid var(--color-secondary);
}

.stat-num {
    display: block;
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--color-primary);
    margin-bottom: 0.5rem;
    font-family: var(--font-heading);
}

.stat-desc {
    font-size: 0.9rem;
    color: var(--color-text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* CTA Section */
.cta-section {
    background-color: var(--color-primary);
    padding: 5rem 0;
    text-align: center;
    color: white;
}

.cta-section h2 {
    color: white;
    margin-bottom: 1rem;
    font-size: 2.5rem;
}

.cta-section p {
    margin-bottom: 2rem;
    opacity: 0.9;
    font-size: 1.1rem;
}

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

.btn-white:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
}

/* Contact Global */
.contact {
    padding: var(--spacing-xl) 0;
}

.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
}

.contact-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.contact-item i {
    width: 40px;
    height: 40px;
    background-color: rgba(79, 45, 127, 0.1);
    color: var(--color-primary);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.contact-item h4 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.contact-item p,
.contact-item a {
    display: block;
    color: var(--color-text-light);
    font-size: 0.95rem;
}

.corporate-form {
    background: white;
    padding: 3rem;
    box-shadow: var(--shadow-md);
    border-radius: var(--radius-md);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.corporate-form input,
.corporate-form textarea {
    width: 100%;
    padding: 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 1rem;
}

.corporate-form input:focus,
.corporate-form textarea:focus {
    outline: none;
    border-color: var(--color-secondary);
}

.corporate-form textarea {
    margin-bottom: 1.5rem;
}

/* Footer */
.footer {
    background-color: var(--color-bg-dark);
    color: white;
    padding: 4rem 0 2rem;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.5);
    margin-top: 0.5rem;
}

.footer-socials {
    display: flex;
    gap: 1.5rem;
}

.footer-socials a {
    color: white;
    width: 35px;
    height: 35px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}


/* Grant Thornton Style Additions */

/* Breadcrumbs */
.breadcrumbs {
    background-color: #f8f9fa;
    padding: 1rem 0;
    font-size: 0.9rem;
    color: var(--color-text-light);
    border-bottom: 1px solid var(--color-border);
}

.breadcrumbs a {
    color: var(--color-primary);
    margin-right: 0.5rem;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

.breadcrumbs span {
    margin-right: 0.5rem;
    color: var(--color-text-lighter);
}

.breadcrumb-current {
    color: var(--color-text-main);
    font-weight: 600;
}

/* Page Layout (Sidebar) */
.page-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4rem;
    padding: var(--spacing-lg) 0;
}

/* Main Content */
.page-content p {
    margin-bottom: 1.5rem;
    font-size: 1.05rem;
}

.page-content h2 {
    font-size: 2rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: var(--color-primary);
}

.page-content ul {
    list-style: disc;
    padding-left: 1.5rem;
    margin-bottom: 2rem;
    color: var(--color-text-main);
}

.page-content li {
    margin-bottom: 0.8rem;
}

/* Sidebar */
.sidebar {
    position: sticky;
    top: 120px;
    /* Adjust based on header height */
    height: fit-content;
}

.sidebar-widget {
    background: #f8f9fa;
    padding: 2rem;
    border-radius: var(--radius-sm);
    margin-bottom: 2rem;
    border-top: 4px solid var(--color-secondary);
}

.sidebar-widget h3 {
    font-size: 1.2rem;
    margin-bottom: 1.2rem;
    color: var(--color-primary);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding-bottom: 0.8rem;
}

.contact-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.contact-avatar {
    width: 60px;
    height: 60px;
    background-color: #ddd;
    border-radius: 50%;
    object-fit: cover;
}

.contact-info h4 {
    font-size: 1rem;
    margin-bottom: 0.2rem;
}

.contact-info p {
    font-size: 0.85rem;
    color: var(--color-text-light);
    margin: 0;
}

.sidebar-links {
    list-style: none;
    padding: 0;
}

.sidebar-links li {
    margin-bottom: 0.8rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding-bottom: 0.8rem;
}

.sidebar-links a {
    color: var(--color-text-main);
    font-weight: 500;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.sidebar-links i {
    font-size: 0.8rem;
    color: var(--color-secondary);
}

/* Article Specific */
.article-meta {
    display: flex;
    gap: 1.5rem;
    font-size: 0.9rem;
    color: var(--color-text-light);
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--color-border);
    padding-bottom: 1rem;
}

.article-hero {
    height: 400px;
    background-size: cover;
    background-position: center;
    border-radius: var(--radius-md);
    margin-bottom: 2rem;
}

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-primary);
    font-weight: 600;
    margin-bottom: 2rem;
}

.back-btn:hover {
    gap: 0.2rem;
    /* Move back slightly */
}

/* Mobile Responsive Adjustments for New Layout */
@media (max-width: 900px) {
    .page-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .sidebar {
        position: static;
        order: 2;
        /* Move sidebar to bottom on mobile */
    }
}
/* ============================================================
   FORM ENHANCEMENTS — Labels, Inline Errors, Success State
   ============================================================ */

/* Field groups with labels */
.field-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.field-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-text-main);
    letter-spacing: 0.02em;
}

.field-label .required {
    color: #e53e3e;
    margin-left: 2px;
}

/* Inputs inside field-groups */
.corporate-form .field-group input,
.corporate-form .field-group textarea {
    width: 100%;
    margin-bottom: 0;
}

/* Space between field-group rows */
.corporate-form .field-group,
.corporate-form > .field-group {
    margin-bottom: 1.25rem;
}

.corporate-form .form-row {
    margin-bottom: 0;
}

/* Inline field error state */
.corporate-form input.field-error,
.corporate-form textarea.field-error {
    border-color: #e53e3e;
    background-color: #fff5f5;
}

.field-error-msg {
    font-size: 0.8rem;
    color: #e53e3e;
    display: block;
    margin-top: 0.25rem;
}

/* Form-level error banner */
.form-error-banner {
    display: none;
    background: #fff5f5;
    border: 1px solid #feb2b2;
    color: #c53030;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    margin-bottom: 1.25rem;
}

/* Submit button spacing */
.btn-submit-inquiry {
    margin-top: 0.5rem;
    width: 100%;
    padding: 1rem 2rem;
    font-size: 1rem;
}

/* Inline success message */
.form-success {
    display: none;
    text-align: center;
    padding: 3rem 2rem;
    background: white;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
}

.form-success.visible {
    display: block;
    animation: fadeInUp 0.4s ease-out;
}

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

.form-success-icon {
    font-size: 3.5rem;
    color: #38a169;
    margin-bottom: 1rem;
}

.form-success h3 {
    font-size: 1.6rem;
    margin-bottom: 0.75rem;
    color: var(--color-primary);
}

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

/* ============================================================
   ACCESSIBILITY — Focus & Hover States (WCAG AA)
   ============================================================ */

/* Universal visible focus ring */
:focus-visible {
    outline: 3px solid var(--color-secondary);
    outline-offset: 3px;
    border-radius: 3px;
}

/* Buttons */
.btn:focus-visible {
    outline: 3px solid var(--color-secondary);
    outline-offset: 3px;
}

/* Skip to content (screen readers + keyboard) */
.skip-link {
    position: absolute;
    top: -100%;
    left: 1rem;
    background: var(--color-primary);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0 0 4px 4px;
    font-size: 0.9rem;
    z-index: 9999;
    text-decoration: none;
}

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

/* Nav links hover */
.nav-links a:not(.btn):focus-visible {
    outline: 2px solid var(--color-secondary);
    outline-offset: 4px;
    border-radius: 2px;
}

/* Form inputs focus */
.corporate-form input:focus,
.corporate-form textarea:focus {
    outline: none;
    border-color: var(--color-secondary);
    box-shadow: 0 0 0 3px rgba(0, 131, 143, 0.15);
}

/* ============================================================
   CONTACT FORM WRAPPER — ensures form fills full column width
   ============================================================ */
.contact-form-wrapper {
    width: 100%;
    min-width: 0; /* prevents grid blowout */
}

/* Profile stats: single column on phones */
@media (max-width: 600px) {
    .profile-stats {
        grid-template-columns: 1fr;
    }
}

/* ============================================================
   LAYOUT RESPONSIVE OVERRIDES
   MUST be at the end of file — after all component declarations
   so these rules override the desktop two-column values.
   ============================================================ */

/* ── Collapse two-column layouts at 1024px ── */
@media (max-width: 1024px) {
    .profile-grid,
    .contact-layout,
    .page-layout {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    .sidebar {
        position: static !important;
        order: 2 !important;
    }

    /* Form row (Name + Email side by side) → stacked */
    .form-row {
        grid-template-columns: 1fr !important;
        gap: 1rem;
    }

    /* Profile stats: 3-up row on tablet */
    .profile-stats {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
}

/* ── Single column on phones (≤600px) ── */
@media (max-width: 600px) {
    .profile-stats {
        grid-template-columns: 1fr !important;
    }
}

/* ============================================================
   CRISP IMAGE RENDERING — logo and all content images
   ============================================================ */

/* Base reset — all images scale fluidly and never stretch */
img {
    max-width: 100%;
    height: auto;
    display: block;
    /* High-quality downscaling on all browsers */
    image-rendering: auto;
    -ms-interpolation-mode: bicubic;
}

/* Logo — always crisp at every size */
.logo img {
    display: block;
    height: clamp(44px, 5vw, 60px); /* fluid: 44px on phones, 60px on desktop */
    width: auto;
    max-width: none;            /* never let max-width: 100% crush the logo */
    object-fit: contain;
    /* Force GPU compositing layer — prevents sub-pixel blur during scroll */
    transform: translateZ(0);
    backface-visibility: hidden;
    /* Hint browser to use high-quality interpolation */
    image-rendering: -webkit-optimize-contrast;
    image-rendering: auto;
}

/* Footer logo — slightly smaller, white-background pill */
footer .logo img {
    height: clamp(36px, 4vw, 50px);
    background: white;
    padding: 5px;
    border-radius: 4px;
}

/* Content / article images — fluid, never crop */
.page-content img,
.insight-body img,
article img {
    width: 100%;
    height: auto;
    border-radius: var(--radius-sm);
    object-fit: cover;
}

/* Hero background images — always fill section at native quality */
.hero,
.page-header,
[style*="background-image"] {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
