/* Global Styles - Sigma Commercial */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Commercial Color Scheme */
    --primary-blue: #0056b3;
    --primary-dark: #1a1a2e;
    --accent-orange: #ff6b35;
    --accent-teal: #00a896;
    --text-primary: #212529;
    --text-secondary: #666;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --border-light: #e0e0e0;

    /* Risk levels */
    --risk-low: #28a745;
    --risk-moderate: #ffc107;
    --risk-high: #fd7e14;
    --risk-very-high: #dc3545;
    --risk-extreme: #212529;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-white);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Skip to content link for accessibility */
.skip-to-content {
    position: absolute;
    top: -100px;
    left: 0;
    background: var(--primary-blue);
    color: white;
    padding: 1rem;
    z-index: 9999;
    transition: top 0.3s;
}

.skip-to-content:focus {
    top: 0;
}

/* Header and Navigation */
header {
    background-color: var(--primary-dark);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.main-nav {
    padding: 1rem 0;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
    text-decoration: none;
    display: flex;
    align-items: center;
}

.logo img {
    height: 50px;
    width: auto;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    align-items: center;
}

.nav-menu a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: opacity 0.3s;
    padding: 0.5rem;
    line-height: 1.3;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-menu a:hover,
.nav-menu a.active {
    opacity: 0.8;
    text-decoration: underline;
}

/* Dropdown Navigation */
.nav-dropdown {
    position: relative;
}

.nav-dropdown > a {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.nav-dropdown > a::after {
    content: '';
    border: solid white;
    border-width: 0 2px 2px 0;
    display: inline-block;
    padding: 3px;
    transform: rotate(45deg);
    margin-left: 4px;
    margin-bottom: 2px;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--primary-dark);
    min-width: 200px;
    padding: 0.5rem 0;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
    z-index: 1001;
}

.nav-dropdown:hover .dropdown-menu {
    display: block;
}

.dropdown-menu li {
    list-style: none;
}

.dropdown-menu a {
    display: block;
    padding: 0.75rem 1.5rem;
    width: 100%;
    text-align: left;
}

.dropdown-menu a:hover {
    background: rgba(255,255,255,0.1);
}

/* CTA Button in Nav */
.nav-cta .button {
    background-color: var(--accent-orange);
    color: white;
    padding: 0.6rem 1.25rem;
    border-radius: 4px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.3s;
}

.nav-cta .button:hover {
    background-color: #e55a2b;
    opacity: 1;
    text-decoration: none;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: white;
    margin: 5px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-blue));
    color: white;
    padding: 5rem 0;
    text-align: center;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.hero-ctas {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Page Hero Section (Subpages) */
.page-hero {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-blue));
    color: white;
    padding: 3rem 0;
    text-align: center;
}

.page-hero h1 {
    font-size: 2.25rem;
    margin-bottom: 0.5rem;
}

.page-hero .lead {
    font-size: 1.125rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

/* Buttons */
.cta-button {
    display: inline-block;
    background-color: var(--accent-orange);
    color: white;
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: 4px;
    font-weight: bold;
    transition: background-color 0.3s, transform 0.2s;
}

.cta-button:hover {
    background-color: #e55a2b;
    transform: translateY(-2px);
}

.button {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background-color: var(--primary-blue);
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s, transform 0.2s;
    font-weight: 500;
}

.button:hover {
    background-color: #004494;
    transform: translateY(-2px);
}

.button-primary {
    background-color: var(--accent-orange);
}

.button-primary:hover {
    background-color: #e55a2b;
}

.button-outline {
    background-color: transparent;
    border: 2px solid var(--primary-blue);
    color: var(--primary-blue);
}

.button-outline:hover {
    background-color: var(--primary-blue);
    color: white;
}

.button-outline-white {
    background-color: transparent;
    border: 2px solid white;
    color: white;
}

.button-outline-white:hover {
    background-color: white;
    color: var(--primary-dark);
}

/* Section Styling */
section {
    padding: 4rem 0;
}

section h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
    color: var(--primary-dark);
}

section.bg-light {
    background-color: var(--bg-light);
}

/* Card Styling */
.card {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.card h3 {
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

.card p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

/* Grid Layouts */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

/* Feature List */
.feature-list {
    list-style: none;
    margin-bottom: 2rem;
}

.feature-list li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    line-height: 1.5;
}

.feature-list li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--risk-low);
    font-weight: bold;
}

/* Icon Box */
.icon-box {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

/* CTA Section */
.cta-section {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-blue));
    color: white;
    padding: 4rem 0;
    text-align: center;
}

.cta-section h2 {
    color: white;
    margin-bottom: 1rem;
}

.cta-section p {
    margin-bottom: 2rem;
    opacity: 0.9;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Footer */
footer {
    background-color: var(--primary-dark);
    color: white;
    padding: 3rem 0 1rem;
    margin-top: 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-column h3 {
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.footer-column ul {
    list-style: none;
}

.footer-column li {
    margin-bottom: 0.5rem;
}

.footer-column a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-column a:hover {
    color: white;
    text-decoration: underline;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.8;
}

/* Tables */
.comparison-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.comparison-table th,
.comparison-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-light);
}

.comparison-table th {
    background: var(--primary-dark);
    color: white;
    font-weight: 600;
}

.comparison-table tr:hover {
    background-color: var(--bg-light);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .nav-menu {
        gap: 1rem;
    }

    .hero h1 {
        font-size: 2.25rem;
    }

    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--primary-dark);
        flex-direction: column;
        padding: 1rem 0;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        z-index: 1000;
    }

    .nav-menu.active {
        display: flex;
    }

    .nav-dropdown .dropdown-menu {
        position: static;
        display: none;
        box-shadow: none;
        padding-left: 1rem;
    }

    .nav-dropdown.open .dropdown-menu {
        display: block;
    }

    .nav-dropdown > a::after {
        transform: rotate(45deg);
        transition: transform 0.3s;
    }

    .nav-dropdown.open > a::after {
        transform: rotate(-135deg);
    }

    .mobile-menu-toggle {
        display: block;
    }

    .hero {
        padding: 3rem 0;
    }

    .hero h1 {
        font-size: 2rem;
        line-height: 1.2;
    }

    .hero-subtitle {
        font-size: 1.125rem;
    }

    .hero-ctas {
        flex-direction: column;
        align-items: center;
    }

    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    section {
        padding: 3rem 0;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

    .page-hero h1 {
        font-size: 1.75rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .nav-menu a {
        padding: 1rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        display: flex;
        align-items: center;
        justify-content: center;
        text-align: center;
        line-height: 1.4;
        word-wrap: break-word;
        hyphens: auto;
        min-height: 3rem;
    }

    .nav-menu a:last-child {
        border-bottom: none;
    }
}

/* Accessibility */
:focus {
    outline: 2px solid var(--primary-blue);
    outline-offset: 2px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --primary-blue: #0044aa;
        --primary-dark: #000000;
        --accent-orange: #cc5500;
        --text-primary: #000000;
        --text-secondary: #333333;
        --border-light: #666666;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Print styles */
@media print {
    header,
    footer,
    .mobile-menu-toggle,
    .cta-button,
    .button {
        display: none !important;
    }

    body {
        font-size: 12pt;
        line-height: 1.4;
        color: black;
        background: white;
    }

    a[href^="http"]:after {
        content: " (" attr(href) ")";
        font-size: 10pt;
    }

    .page-break {
        page-break-before: always;
    }
}
