/* ==========================================================================
   CompliSanc Marketing Website – Modern professional design
   ========================================================================== */

:root {
    --primary: #0f172a;
    --primary-hover: #1e293b;
    --accent: #0d9488;
    --accent-light: #14b8a6;
    --accent-muted: rgba(13, 148, 136, 0.12);
    --text: #0f172a;
    --text-muted: #475569;
    --text-light: #64748b;
    --bg: #ffffff;
    --bg-subtle: #f8fafc;
    --bg-muted: #f1f5f9;
    --border: #e2e8f0;
    --border-light: #f1f5f9;
    --radius: 8px;
    --radius-sm: 6px;
    --radius-lg: 12px;
    --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 4px 16px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 12px 40px rgba(15, 23, 42, 0.1);
    --transition: 0.2s ease;
    --header-h: 72px;
}

/* Legacy variable names for compatibility */
:root {
    --primary-color: var(--primary);
    --primary-dark: #020617;
    --primary-light: #1e293b;
    --secondary-color: var(--accent);
    --accent-color: var(--accent);
    --text-dark: var(--text);
    --text-medium: var(--text-muted);
    --text-light: var(--text-light);
    --bg-light: var(--bg-subtle);
    --bg-white: var(--bg);
    --border-color: var(--border);
    --shadow-sm: var(--shadow-xs);
    --shadow-md: var(--shadow-sm);
    --shadow-lg: var(--shadow-md);
    --shadow-xl: var(--shadow-lg);
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

* {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

input,
textarea {
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}

img {
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    pointer-events: none;
    max-width: 100%;
    height: auto;
    display: block;
}

/* Skip link for keyboard/screen reader users */
.skip-link {
    position: absolute;
    top: -100px;
    left: 1rem;
    z-index: 9999;
    padding: 0.75rem 1.25rem;
    background: var(--primary);
    color: #fff;
    font-weight: 600;
    text-decoration: none;
    border-radius: var(--radius-sm);
    transition: top var(--transition);
}
.skip-link:focus {
    top: 1rem;
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.logo img {
    pointer-events: auto !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: 44px !important;
    width: auto !important;
    max-width: 200px !important;
    min-height: 36px !important;
    min-width: 36px !important;
    max-height: 44px !important;
    object-fit: contain !important;
    flex-shrink: 0 !important;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--header-h);
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

/* ==========================================================================
   Typography
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.25;
    color: var(--text);
    letter-spacing: -0.02em;
}

h1 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
}

h2 {
    font-size: clamp(1.375rem, 3vw, 1.75rem);
}

h3 {
    font-size: 1.125rem;
}

h4 {
    font-size: 1rem;
}

p {
    margin-bottom: 0.75rem;
    color: var(--text-muted);
    font-size: 0.9375rem;
    line-height: 1.65;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color var(--transition);
}

a:hover {
    color: var(--accent-light);
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */

.header {
    background: var(--bg);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border-light);
    box-shadow: var(--shadow-xs);
}

.header-container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 1.5rem;
    height: var(--header-h);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    color: var(--primary);
}

.nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-links {
    display: flex;
    gap: 0.25rem;
    list-style: none;
}

.nav-links a {
    color: var(--text);
    font-weight: 500;
    font-size: 0.875rem;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    transition: background var(--transition), color var(--transition);
}

.nav-links a:hover {
    color: var(--accent);
    background: var(--accent-muted);
}

.nav-links a.active {
    color: var(--accent);
    background: var(--accent-muted);
}

.nav-links a::after {
    display: none;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text);
    padding: 0.5rem;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.875rem;
    text-align: center;
    transition: all var(--transition);
    cursor: pointer;
    border: none;
    text-decoration: none;
    min-width: 120px;
    -webkit-appearance: none;
    appearance: none;
}

.btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.btn-primary {
    background: var(--accent) !important;
    color: white !important;
    box-shadow: var(--shadow-xs);
}

.btn-primary:hover {
    background: var(--accent-light) !important;
    color: white !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(13, 148, 136, 0.35);
}

.btn-secondary {
    background: var(--bg) !important;
    color: var(--accent) !important;
    border: 1.5px solid var(--accent) !important;
}

.btn-secondary:hover {
    background: var(--accent-muted) !important;
    color: var(--accent) !important;
    border-color: var(--accent) !important;
    transform: translateY(-1px);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.hero {
    background: linear-gradient(160deg, var(--primary) 0%, #1e293b 50%, #334155 100%);
    color: white;
    padding: clamp(3rem, 8vw, 5rem) 1.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 80% 50% at 50% -20%, rgba(13, 148, 136, 0.15), transparent);
    pointer-events: none;
}

.hero-container {
    max-width: 720px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.hero-tagline {
    font-size: 0.9375rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-light);
    margin-bottom: 0.5rem;
    opacity: 0.95;
}

.hero h1 {
    color: white;
    font-size: clamp(1.875rem, 4.5vw, 2.75rem);
    margin-bottom: 1rem;
    line-height: 1.2;
    font-weight: 700;
    letter-spacing: -0.03em;
}

.hero p {
    color: rgba(255, 255, 255, 0.88);
    font-size: 1rem;
    margin-bottom: 1.5rem;
    line-height: 1.65;
}

.hero-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-buttons .btn {
    min-width: 140px;
    padding: 0.75rem 1.5rem;
}

.hero-buttons .btn-primary {
    background: white !important;
    color: var(--primary) !important;
}

.hero-buttons .btn-primary:hover {
    background: var(--bg-subtle) !important;
    color: var(--primary) !important;
    box-shadow: var(--shadow-md);
}

.hero .hero-buttons .btn-secondary {
    background: transparent !important;
    border: 1.5px solid rgba(255, 255, 255, 0.6) !important;
    color: white !important;
}

.hero .hero-buttons .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: white !important;
    color: white !important;
}

/* CTA sections (light background) */
.section .hero-buttons .btn-primary,
section.section .hero-buttons .btn-primary,
.section:not(.hero) .hero-buttons .btn-primary {
    background: var(--accent) !important;
    color: white !important;
}

.section .hero-buttons .btn-primary:hover,
section.section .hero-buttons .btn-primary:hover,
.section:not(.hero) .hero-buttons .btn-primary:hover {
    background: var(--accent-light) !important;
    color: white !important;
}

.section .hero-buttons .btn-secondary,
section.section .hero-buttons .btn-secondary,
.section:not(.hero) .hero-buttons .btn-secondary {
    background: var(--bg) !important;
    border: 1.5px solid var(--accent) !important;
    color: var(--accent) !important;
}

.section .hero-buttons .btn-secondary:hover,
section.section .hero-buttons .btn-secondary:hover,
.section:not(.hero) .hero-buttons .btn-secondary:hover {
    background: var(--accent-muted) !important;
    color: var(--accent) !important;
    border-color: var(--accent) !important;
}

/* ==========================================================================
   Stats Bar
   ========================================================================== */

.stats-bar {
    background: var(--primary);
    color: white;
    padding: 1.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    align-items: center;
    text-align: center;
}

.stat-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.stat-number {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: white;
    line-height: 1.1;
}

.stat-label {
    font-size: 0.8125rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: rgba(255, 255, 255, 0.9);
}

.stat-detail {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.65);
}

.stat-cta {
    justify-content: center;
}

.stat-cta .btn {
    margin-top: 0.25rem;
}

.stat-cta .btn-primary {
    background: var(--accent) !important;
    color: white !important;
    border: none !important;
}

.stat-cta .btn-primary:hover {
    background: var(--accent-light) !important;
    color: white !important;
}

/* ==========================================================================
   Solutions Grid (What We Do)
   ========================================================================== */

.solutions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.solution-card {
    background: var(--bg);
    padding: 1.75rem;
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-xs);
    transition: border-color var(--transition), box-shadow var(--transition);
}

.solution-card:hover {
    border-color: var(--border);
    box-shadow: var(--shadow-sm);
}

.solution-card h3 {
    font-size: 1.125rem;
    margin-bottom: 0.375rem;
    color: var(--text);
}

.solution-subline {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 0.75rem;
    font-style: italic;
}

.solution-card p:not(.solution-subline) {
    font-size: 0.9375rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.solution-link {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--accent);
    text-decoration: none;
    transition: color var(--transition);
}

.solution-link:hover {
    color: var(--accent-light);
}

.solution-link::after {
    content: ' →';
}

/* ==========================================================================
   Container & Sections
   ========================================================================== */

.container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section {
    padding: clamp(2.5rem, 6vw, 4rem) 0;
}

/* Inner-page hero: same as home but no tagline needed; consistent padding from .hero */
.page-content {
    min-height: 40vh;
}

.section-title {
    text-align: center;
    margin-bottom: 2rem;
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
}

.section-title h2 {
    margin-bottom: 0.5rem;
}

.section-title p {
    font-size: 0.9375rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* ==========================================================================
   Features Grid
   ========================================================================== */

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.25rem;
}

.feature-card {
    background: var(--bg);
    padding: 1.5rem;
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-xs);
    transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}

.feature-card:hover {
    border-color: var(--border);
    box-shadow: var(--shadow-sm);
    transform: translateY(-2px);
}

.feature-icon {
    font-size: 1.75rem;
    margin-bottom: 0.75rem;
    line-height: 1;
}

.feature-card h3 {
    margin-bottom: 0.5rem;
    font-size: 1.0625rem;
    font-weight: 600;
}

.feature-card p {
    color: var(--text-muted);
    font-size: 0.875rem;
    line-height: 1.55;
    margin-bottom: 0;
}

/* ==========================================================================
   Pricing (legacy / contact-style pages)
   ========================================================================== */

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.25rem;
}

.pricing-card {
    background: var(--bg);
    border: 1px solid var(--border-light);
    border-radius: var(--radius);
    padding: 1.5rem;
    text-align: center;
    transition: all var(--transition);
    position: relative;
    box-shadow: var(--shadow-xs);
}

.pricing-card:hover {
    border-color: var(--border);
    box-shadow: var(--shadow-sm);
    transform: translateY(-2px);
}

.pricing-card.featured {
    border-color: var(--accent);
    box-shadow: 0 0 0 1px var(--accent);
}

.pricing-name {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.375rem;
}

.pricing-price {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--primary);
    margin: 0.625rem 0;
}

.pricing-features {
    list-style: none;
    margin: 1.25rem 0;
    text-align: left;
}

.pricing-features li {
    padding: 0.5rem 0;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border-light);
    font-size: 0.875rem;
}

.pricing-features li:last-child {
    border-bottom: none;
}

.pricing-features li::before {
    content: '✓';
    color: var(--accent);
    font-weight: bold;
    margin-right: 0.5rem;
}

/* ==========================================================================
   Contact Form
   ========================================================================== */

.contact-form {
    max-width: 560px;
    margin: 0 auto;
    background: var(--bg);
    padding: 1.75rem;
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-xs);
}

.form-group {
    margin-bottom: 1.125rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.375rem;
    font-weight: 500;
    color: var(--text);
    font-size: 0.875rem;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.625rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    font-family: inherit;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-muted);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* Contact page layout and components (no inline styles) */
.contact-page-grid {
    grid-template-columns: 1fr 1fr;
    align-items: start;
}
.contact-form-heading {
    margin-bottom: 0.5rem;
}
.contact-form-intro {
    color: var(--text-medium);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}
.contact-form .btn[type="submit"] {
    width: 100%;
}
.form-message {
    margin-top: 1rem;
    display: none;
}
.form-message.visible {
    display: block;
}
.contact-info-heading {
    margin-bottom: 1.5rem;
}
.contact-info-card {
    margin-bottom: 1.5rem;
}
.contact-info-card:last-of-type {
    margin-bottom: 0;
}
.contact-email-line {
    margin-top: 0.5rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
    background: var(--primary);
    color: white;
    padding: 3rem 0 1.5rem;
    margin-top: 4rem;
}

.footer-container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    color: white;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    letter-spacing: 0.02em;
}

/* Section background utilities (avoid inline styles) */
.section.bg-subtle {
    background: var(--bg-subtle);
}
.section.bg-light {
    background: var(--bg-light);
}

/* CTA section lead text */
.cta-lead {
    font-size: 0.9375rem;
    color: var(--text-muted);
}
.cta-lead--sm {
    font-size: 0.875rem;
    color: var(--text-medium);
}

/* Content section call-to-action spacing */
.content-cta {
    margin-top: 2rem;
}

.footer-section p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
    line-height: 1.55;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
    transition: color var(--transition);
}

.footer-section a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.8125rem;
    margin: 0;
}

/* ==========================================================================
   Content Sections (features long-form, about, privacy)
   ========================================================================== */

.content-section {
    max-width: 680px;
    margin: 0 auto;
}

.content-section h2 {
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}

.content-section h3 {
    margin-top: 1.25rem;
    margin-bottom: 0.375rem;
}

.content-section ul,
.content-section ol {
    margin-left: 1.25rem;
    margin-bottom: 0.75rem;
}

.content-section li {
    margin-bottom: 0.25rem;
    color: var(--text-muted);
    font-size: 0.9375rem;
    line-height: 1.6;
}

/* ==========================================================================
   Utilities
   ========================================================================== */

.text-center {
    text-align: center;
}

.mb-4 { margin-bottom: 1.5rem; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: block;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg);
        flex-direction: column;
        padding: 1rem;
        box-shadow: var(--shadow-lg);
        z-index: 999;
        border-bottom: 1px solid var(--border-light);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links a {
        padding: 0.75rem 1rem;
        display: block;
    }

    .section {
        padding: 2rem 0;
    }

    .features-grid,
    .pricing-grid {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1.25rem;
    }

    .stat-cta {
        grid-column: 1 / -1;
    }

    .solutions-grid {
        grid-template-columns: 1fr;
    }

    .container {
        padding: 0 1rem;
    }

    .header-container {
        padding: 0 1rem;
    }

    .logo img {
        height: 40px !important;
        min-height: 40px !important;
        max-height: 40px !important;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 2.5rem 1rem;
    }

    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }

    .hero-buttons .btn {
        width: 100%;
        min-width: auto;
    }

    .logo img {
        height: 36px !important;
        min-height: 36px !important;
        max-height: 36px !important;
    }

    .feature-card,
    .pricing-card {
        padding: 1.25rem;
    }

    .contact-form {
        padding: 1.25rem;
    }
}

/* ==========================================================================
   Legacy / fallbacks
   ========================================================================== */

@supports not (display: grid) {
    .features-grid,
    .pricing-grid,
    .footer-grid {
        display: block;
    }
    .features-grid > *,
    .pricing-grid > *,
    .footer-grid > * {
        margin-bottom: 1rem;
    }
}

/* Print */
@media print {
    .header,
    .footer,
    .hero-buttons,
    .btn {
        display: none !important;
    }
    .section {
        page-break-inside: avoid;
    }
}
