/**
 * FaithWorks AI - Shared Stylesheet
 *
 * @file        styles.css
 * @description Shared stylesheet for all pages featuring common styles, navigation,
 *              footer, dropdowns, language selector, and responsive design
 * @author      FaithWorks AI Development Team
 * @date        2026-03-12
 * @version     1.0.0
 *
 * Contents:
 * 1. Reset and Base Styles
 * 2. Navigation (sticky header with dropdown)
 * 3. Products Dropdown
 * 4. Language Selector
 * 5. Footer
 * 6. Responsive Breakpoints
 *
 * Color Palette:
 * - Brand Red: #d62525
 * - Black: #000000
 * - White: #ffffff
 * - Light Gray: #f3f4f6
 * - Medium Gray: #6b7280
 * - Dark Gray: #1f2937
 *
 * Responsive Breakpoints:
 * - Mobile: < 768px
 * - Tablet: 768px - 1024px
 * - Desktop: > 1024px
 *
 * Usage:
 * - Linked in all HTML pages via <link rel="stylesheet" href="styles.css">
 * - Applies to navigation component (components/navigation.html)
 * - Applies to footer component (components/footer.html)
 */

/* ========================================
   FaithWorks AI - Shared Styles
   Common CSS used across all pages
   ======================================== */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica', 'Arial', sans-serif;
    line-height: 1.6;
    color: #333;
    scroll-padding-top: 96px;
}

body.mobile-menu-open {
    overflow: hidden;
}

/* ========================================
   Navigation
   ======================================== */

nav {
    background: #ffffff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

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

.logo {
    display: flex;
    align-items: center;
}

.logo a {
    display: inline-block;
    line-height: 0;
}

.logo img {
    height: 48px;
    width: auto;
    display: block;
}

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

.nav-menu a,
.dropdown-toggle {
    text-decoration: none;
    color: #000000;
    font-weight: 500;
    font-size: 0.9rem;
    transition: color 0.3s, background 0.3s;
}

.dropdown-toggle {
    cursor: pointer;
    background: transparent;
    border: 0;
    padding: 0;
    font-family: inherit;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.nav-menu a:hover,
.dropdown-toggle:hover {
    color: #d62525;
}

.nav-menu a:focus-visible,
.dropdown-toggle:focus-visible,
.menu-toggle:focus-visible,
.lang-dropdown-toggle:focus-visible,
.lang-link:focus-visible {
    outline: 2px solid #d62525;
    outline-offset: 3px;
}

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

.dropdown-content {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #ffffff;
    min-width: 220px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border-radius: 6px;
    margin-top: 0;
    padding: 0.75rem 0 0.5rem 0;
    z-index: 1000;
}

.dropdown.is-open .dropdown-content {
    display: block;
}

.dropdown-caret {
    font-size: 0.9rem;
}

.dropdown-content a {
    display: block;
    padding: 0.75rem 1.25rem;
    color: #000000;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s;
}

.dropdown-content a:hover {
    background: #f3f4f6;
    color: #d62525;
}

.nav-lang-label {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.nav-lang-desktop {
    display: flex;
    align-items: center;
    position: relative;
}

.nav-lang-desktop .lang-dropdown-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    min-width: 120px;
    min-height: 40px;
    padding: 0.5rem 0.85rem;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #ffffff;
    color: #111827;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.nav-lang-desktop .lang-dropdown-toggle:hover {
    border-color: #d62525;
    color: #d62525;
    background: #ffffff;
}

.nav-lang-desktop .lang-caret {
    font-size: 0.7rem;
    transition: transform 0.2s ease;
}

.nav-lang-desktop.is-open .lang-caret {
    transform: rotate(180deg);
}

.nav-lang-desktop .lang-dropdown-menu {
    position: absolute;
    top: calc(100% + 0.15rem);
    right: 0;
    display: flex;
    flex-direction: column;
    min-width: 120px;
    padding: 0.35rem 0;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.12);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-0.25rem);
    transition: opacity 0.18s ease, transform 0.18s ease;
    z-index: 1002;
}

.nav-lang-desktop.is-open .lang-dropdown-menu {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.nav-lang-desktop .lang-link {
    width: 100%;
    padding: 0.55rem 0.95rem;
    text-align: left;
}

.nav-lang-desktop .lang-link:hover {
    color: #d62525;
    background: #f3f4f6;
}

.nav-lang-desktop .lang-link.is-active {
    font-weight: 600;
    text-decoration: none;
}

.nav-lang-mobile {
    display: none;
}

.lang-link {
    background: transparent;
    border: 0;
    padding: 0;
    color: #111827;
    font-family: inherit;
    font-size: 0.95rem;
    cursor: pointer;
}

.lang-link.is-active {
    color: #111827;
    text-decoration: none;
    font-weight: 600;
}

/* Language Selector */
.nav-panel {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.menu-toggle {
    display: none;
}

.menu-close,
.nav-overlay {
    display: none;
}

/* ========================================
   Footer
   ======================================== */

footer {
    background: #1f2937;
    color: #ffffff;
    padding: 3rem 0 2rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.footer-left {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.footer-logo {
    display: block;
    line-height: 0;
}

.footer-logo a {
    display: inline-block;
    line-height: 0;
}

.footer-logo img {
    height: 50px;
    width: auto;
    display: block;
}

.footer-cta {
    color: #ffffff;
    line-height: 1.5;
    max-width: 500px;
    font-size: 1rem;
}

.footer-right h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.footer-contact {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-contact p {
    margin: 0;
    font-size: 0.9rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    line-height: 1.4;
}

.footer-contact strong {
    min-width: 80px;
    font-weight: 600;
}

.footer-contact a {
    color: #ffffff;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-contact a:hover {
    color: #d62525;
}

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

.footer-copyright {
    font-size: 0.9rem;
    color: #ffffff;
    opacity: 0.8;
}

/* Footer Grid */
.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-section h3 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.footer-section ul {
    list-style: none;
}

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

.footer-section a {
    color: #ffffff;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: #d62525;
}

.footer-section p {
    font-size: 0.9rem;
    line-height: 1.6;
}

/* ========================================
   Common Content Sections
   ======================================== */

.content-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 4rem 2rem;
}

.content-section h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2.5rem;
    color: #1f2937;
    text-align: center;
    line-height: 1.2;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Section Title */
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 3rem;
    color: #1f2937;
    line-height: 1.15;
}

/* ========================================
   Responsive Design
   ======================================== */

@media (max-width: 992px) {
    .nav-menu {
        gap: 1.5rem;
    }

    .content-section {
        padding: 3.5rem 1.5rem;
    }

    .container {
        padding: 0 1.5rem;
    }

    .section-title {
        margin-bottom: 2.5rem;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-container {
        padding: 0.875rem 1rem;
    }

    .menu-toggle {
        display: inline-flex;
        align-items: center;
        background: transparent;
        border: 0;
        color: #111827;
        font-family: inherit;
        font-size: 1.75rem;
        font-weight: 500;
        padding: 0;
        line-height: 1;
        cursor: pointer;
    }

    .menu-toggle-label {
        letter-spacing: 0.01em;
    }

    .nav-overlay {
        position: fixed;
        inset: 0;
        display: block;
        background: rgba(255, 255, 255, 0.06);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.2s ease;
        z-index: 999;
    }

    nav.menu-open .nav-overlay {
        opacity: 1;
        pointer-events: auto;
    }

    .nav-panel {
        position: fixed;
        top: 0;
        right: 0;
        width: min(55vw, 430px);
        min-width: 320px;
        height: 100vh;
        background: rgba(255, 255, 255, 0.86);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
        gap: 0;
        padding: 4.85rem 3.25rem 3rem;
        opacity: 0;
        pointer-events: none;
        transform: translateX(100%);
        transition: transform 0.28s ease, opacity 0.2s ease;
        box-shadow: -18px 0 34px rgba(15, 23, 42, 0.12);
        z-index: 1001;
        overflow-y: auto;
    }

    nav.menu-open .nav-panel {
        opacity: 1;
        pointer-events: auto;
        transform: translateX(0);
    }

    .menu-close {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        position: fixed;
        top: 0.875rem;
        right: 0.5rem;
        width: 38px;
        height: 38px;
        background: transparent;
        border: 0;
        color: #3f3f46;
        font-size: 1.95rem;
        line-height: 1;
        cursor: pointer;
        z-index: 1002;
    }

    .nav-menu {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.95rem;
        width: 100%;
        margin: 1.25rem 0 0;
    }

    .nav-menu li {
        width: 100%;
        border-bottom: 0;
    }

    .nav-menu a,
    .dropdown-toggle {
        display: flex;
        width: 100%;
        min-height: 28px;
        border-radius: 0;
        padding: 0;
        font-size: 0.98rem;
        font-weight: 600;
        justify-content: flex-start;
        color: #3f3f46;
        background: transparent;
        text-align: left;
    }

    .nav-menu a:hover,
    .dropdown-toggle:hover {
        background: transparent;
    }

    .logo img {
        height: 40px;
    }

    .dropdown {
        position: static;
        text-align: left;
    }

    .dropdown-content {
        position: static;
        min-width: unset;
        box-shadow: none;
        border-radius: 0;
        display: block;
        padding: 0;
        margin-top: 0;
        background: transparent;
        overflow: visible;
        opacity: 1;
    }

    .dropdown.is-open .dropdown-content {
        padding-top: 0.15rem;
    }

    .dropdown-content a {
        display: flex;
        width: 100%;
        align-items: center;
        background: transparent;
        min-height: 24px;
        padding: 0 0 0 1.9rem;
        font-size: 0.9rem;
        font-weight: 400;
        color: #4b5563;
        text-align: left;
    }

    .dropdown-content a:hover {
        background: transparent;
    }

    .dropdown-caret {
        transition: transform 0.2s ease;
        font-size: 1.35rem;
        font-weight: 700;
        line-height: 1;
        margin-left: 0.85rem;
    }

    .dropdown.is-open .dropdown-caret {
        transform: rotate(180deg);
    }

    .nav-lang-desktop {
        display: none;
    }

    .nav-lang-mobile {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.12rem;
        margin: 1.35rem 0 0;
    }

    .lang-dropdown-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: space-between;
        gap: 0.75rem;
        min-height: 44px;
        min-width: 200px;
        padding: 0.55rem 1.2rem;
        border-radius: 10px;
        border: 1px solid #d1d5db;
        background: #ffffff;
        color: #3f3f46;
        font-family: inherit;
        font-size: 0.98rem;
        font-weight: 600;
        box-shadow: none;
        cursor: pointer;
        appearance: none;
        -webkit-appearance: none;
        -webkit-tap-highlight-color: transparent;
    }

    .lang-dropdown-toggle:focus {
        outline: none;
    }

    .nav-lang-mobile.is-open .lang-dropdown-toggle,
    .nav-lang-mobile.is-selected .lang-dropdown-toggle {
        border-color: #111827;
        background: #f9fafb;
        color: #111827;
    }

    .lang-caret {
        font-size: 0.8rem;
        transition: transform 0.2s ease;
    }

    .nav-lang-mobile.is-open .lang-caret {
        transform: rotate(180deg);
    }

    .lang-dropdown-menu {
        display: flex;
        flex-direction: column;
        min-width: 200px;
        background: #ffffff;
        border: 1px solid #e5e7eb;
        border-radius: 10px;
        box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
        padding: 0.35rem 0;
        opacity: 0;
        pointer-events: none;
        transform: translateY(-0.35rem);
        transition: opacity 0.18s ease, transform 0.18s ease;
    }

    .nav-lang-mobile.is-open .lang-dropdown-menu {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }

    .lang-link {
        width: 100%;
        background: transparent;
        border: 0;
        padding: 0.62rem 1.4rem;
        color: #111827;
        font-family: inherit;
        font-size: 0.98rem;
        font-weight: 400;
        text-align: left;
        cursor: pointer;
    }

    .lang-link.is-active {
        color: #111827;
        background: #f3f4f6;
        text-decoration: none;
        font-weight: 600;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

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

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

    .footer-cta {
        font-size: 0.95rem;
    }

    .footer-contact {
        gap: 0.875rem;
    }

    .footer-contact p {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.125rem;
        font-size: 0.95rem;
    }

    .footer-contact strong {
        min-width: 0;
    }

    .footer-bottom {
        margin-top: 1.5rem;
        padding: 1.25rem 1rem 0;
    }

    .content-section {
        padding: 2.75rem 1rem;
    }

    .container {
        padding: 0 1rem;
    }

    .section-title {
        font-size: 2rem;
        margin-bottom: 2rem;
    }

    .content-section h2 {
        font-size: 1.75rem;
        margin-bottom: 2rem;
    }
}

@media (max-width: 480px) {
    .nav-panel {
        width: min(62vw, 360px);
        min-width: 280px;
        padding: 4.45rem 2.2rem 2.5rem;
    }

    .nav-menu {
        gap: 1.2rem;
        margin-top: 0.9rem;
    }

    .lang-dropdown-toggle,
    .lang-dropdown-menu {
        min-width: 186px;
    }

    .content-section {
        padding: 2.25rem 0.875rem;
    }

    .container {
        padding: 0 0.875rem;
    }

    .section-title {
        font-size: 1.75rem;
        margin-bottom: 1.75rem;
    }

    .content-section h2 {
        font-size: 1.55rem;
        margin-bottom: 1.5rem;
    }
}
