/* 
   Bridge IT Design System - Mobile-First Responsive
   Optimized for iPhone and all mobile devices
*/

:root {
    /* Palette */
    --bg-light: #EDEAE5;
    --bg-white: #FFFFFF;
    --bg-dark: #1a1a1a;
    --text-dark: #2d2d2d;
    --accent: #8b7355;

    /* Mappings */
    --color-bg: var(--bg-light);
    --color-bg-alt: var(--bg-white);
    --color-text-main: var(--text-dark);
    --color-text-muted: #666666;
    --color-accent: var(--accent);
    --color-border: rgba(0, 0, 0, 0.08);

    --color-primary: var(--bg-dark);
    --color-secondary: var(--bg-white);
    --color-success: #1a1a1a;
    --color-error: #B91C1C;

    /* Typography - Mobile First */
    --font-heading: 'Manrope', 'Helvetica Neue', 'Roboto', sans-serif;
    --font-body: 'Manrope', 'Helvetica Neue', 'Roboto', sans-serif;

    /* Type Scale - Mobile Optimized */
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.75rem;
    --font-size-3xl: 2.25rem;
    --font-size-hero: 2.5rem;

    /* Spacing - Mobile First */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 3rem;
    --spacing-xl: 4rem;

    /* Borders & Effects */
    --radius-sm: 0px;
    --radius-md: 0px;
    --radius-lg: 0px;

    --transition-base: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Reset & Base */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    font-weight: 300;
    line-height: 1.6;
    color: var(--color-text-main);
    background-color: var(--color-bg);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: var(--spacing-sm);
    letter-spacing: -0.02em;
    text-transform: uppercase;
}

h1 {
    font-size: var(--font-size-3xl);
}

h2 {
    font-size: var(--font-size-2xl);
}

h4 {
    font-size: var(--font-size-xl);
    font-weight: 700;
}

p {
    margin-bottom: var(--spacing-sm);
    color: var(--color-text-muted);
    line-height: 1.7;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-base);
}

ul {
    list-style: none;
}

/* Grid System - Mobile First */
.container {
    max-width: 100%;
    padding: 0 5%;
    margin: 0 auto;
    border: none;
    position: relative;
}

.container--fluid {
    max-width: 100%;
    padding: 0 5%;
}

.grid {
    display: grid;
    gap: var(--spacing-md);
    grid-template-columns: 1fr;
    /* Mobile first: single column */
}

.grid-2 {
    grid-template-columns: 1fr;
}

.grid-3 {
    grid-template-columns: 1fr;
}

.grid-4 {
    grid-template-columns: 1fr;
}

/* Section Spacing */
.section {
    padding: var(--spacing-xl) 0;
}

/* Components */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    font-weight: 600;
    font-size: var(--font-size-sm);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all var(--transition-base);
    min-height: 44px;
    /* iOS touch target */
    white-space: nowrap;
}

.btn-primary {
    background: var(--color-primary);
    color: var(--color-secondary);
    border: 1px solid var(--color-primary);
}

.btn-primary:hover,
.btn-primary:active {
    background: transparent;
    color: var(--color-primary);
}

.btn-secondary {
    background: transparent;
    border: 1px solid var(--color-text-main);
    color: var(--color-text-main);
}

.btn-secondary:hover,
.btn-secondary:active {
    background: var(--color-text-main);
    color: var(--color-secondary);
}

/* Navbar - Mobile First */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(237, 234, 229, 0.98);
    height: 70px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: all var(--transition-base);
    backdrop-filter: blur(10px);
}

.navbar.scrolled {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    width: 100%;
    padding: 0 5%;
}

.nav-logo h3 {
    margin: 0;
    font-weight: 800;
    letter-spacing: -0.05em;
    text-transform: none;
    font-size: 1.25rem;
}

.nav-menu {
    display: none;
    /* Hidden on mobile by default */
}

.hamburger {
    display: block;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    min-width: 44px;
    min-height: 44px;
}

/* Hero Section - Mobile First */
.section--hero {
    min-height: 100vh;
    padding: 90px 5% 3rem 5%;
    background-color: var(--bg-light);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    text-align: center;
}

.hero-content {
    max-width: 100%;
    text-align: center;
    z-index: 10;
    /* Above overlay */
    margin-bottom: 2rem;
    position: relative;
}

.hero-title {
    font-size: var(--font-size-hero);
    line-height: 1.15;
    margin-bottom: var(--spacing-md);
    letter-spacing: -0.02em;
    color: var(--text-dark);
}

.hero-subtitle {
    font-size: var(--font-size-base);
    color: var(--color-text-muted);
    border-left: 2px solid var(--accent);
    border-right: 2px solid var(--accent);
    padding: 0 1rem;
    margin: 0 auto var(--spacing-lg) auto;
    max-width: 90%;
}

.hero-cta {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
}

.hero-cta span {
    font-size: 0.85rem !important;
    margin-left: 0 !important;
}

.hero-image {
    display: block;
    width: 100%;
    max-width: 500px;
    height: 300px;
    position: relative;
    margin-top: 2rem;
    opacity: 0.7;
    border-radius: 4px;
    overflow: hidden;
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Section Headers */
.section-header {
    padding: 0;
    margin-bottom: var(--spacing-lg);
    text-align: center;
}

.section-label {
    color: var(--accent);
    font-weight: 700;
    letter-spacing: 0.15em;
    font-size: 0.7rem;
    display: block;
    margin-bottom: 0.75rem;
}

/* Tech Stack */
.tech-stack-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1.5rem;
    opacity: 0.6;
    font-weight: 700;
    letter-spacing: 0.08em;
    padding: 1rem;
    font-size: 0.75rem;
}

/* Method Steps - Mobile */
.method-steps {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.method-step {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 2rem;
    align-items: flex-start;
}

.method-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--color-border);
    line-height: 1;
}

.method-content h4 {
    margin-bottom: 0.5rem;
    color: var(--color-text-main);
    font-size: 1.1rem;
}

.method-content p {
    font-size: 0.9rem;
    line-height: 1.6;
}

.method-image {
    display: none;
    /* Hide on mobile to save space */
}

/* Service Cards - Mobile Optimized */
.service-card-visual {
    background: var(--bg-light);
    border: 1px solid var(--color-border);
    transition: var(--transition-base);
    display: flex;
    flex-direction: column;
    margin-bottom: 1.5rem;
}

.service-img-container {
    height: 200px;
    overflow: hidden;
}

.service-img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(20%);
}

.service-content {
    padding: 1.5rem;
}

.service-number {
    color: var(--accent);
    font-weight: 800;
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    margin-bottom: 0.75rem;
    display: block;
}

.service-desc {
    font-size: 0.95rem;
    margin-bottom: 1rem;
    color: var(--color-text-muted);
}

.service-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.service-tags li {
    background: rgba(0, 0, 0, 0.03);
    padding: 0.4rem 0.7rem;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Swiper */
.swiper {
    width: 100%;
    padding: 0 5% 2rem 5%;
}

.swiper-nav {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    margin-top: 1rem;
}

/* Project Cards */
.card-project {
    background: var(--bg-white);
    min-height: 350px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1.5rem;
    border: 1px solid var(--color-border);
}

.card-project h4 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.project-cat {
    color: var(--accent);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    margin-bottom: 0.75rem;
    display: block;
}

/* FAQ - Mobile Optimized */
.faq-item {
    border-bottom: 1px solid var(--color-border);
}

.faq-question {
    width: 100%;
    text-align: left;
    padding: 1.25rem 0;
    background: none;
    border: none;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 44px;
}

.faq-question::after {
    content: '+';
    font-size: 1.5rem;
    font-weight: 300;
    transition: transform 0.3s;
    margin-left: 1rem;
    flex-shrink: 0;
}

.faq-item.active .faq-question::after {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    opacity: 0.8;
}

.faq-answer p {
    font-size: 0.9rem;
    line-height: 1.6;
}

.faq-item.active .faq-answer {
    max-height: 500px;
    margin-bottom: 1.5rem;
}

/* Footer */
.footer {
    background: var(--bg-dark);
    color: #ffffff;
    padding: var(--spacing-xl) 5%;
}

.footer h2 {
    font-size: 1.5rem;
}

.footer p {
    color: #999;
}

.contact-form {
    background: rgba(255, 255, 255, 0.05);
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.form-input,
textarea,
select {
    width: 100%;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 1rem;
    margin-bottom: 1rem;
    min-height: 44px;
}

textarea {
    min-height: 120px;
    resize: vertical;
}

select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23fff' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

/* Card - Generic */
.card {
    background: var(--bg-white);
    padding: 1.5rem;
    border: 1px solid var(--color-border);
    margin-bottom: 1rem;
}

/* Stats */
.stats-section {
    background: var(--bg-dark);
    color: #fff;
    padding: var(--spacing-xl) 5%;
}

.stat-value {
    color: var(--accent);
    font-size: 2.5rem;
    font-weight: 700;
}

/* Tablet Breakpoint (768px+) */
@media (min-width: 768px) {
    :root {
        --font-size-hero: 3.5rem;
        --font-size-3xl: 3rem;
        --font-size-2xl: 2rem;
        --spacing-md: 2rem;
        --spacing-lg: 4rem;
        --spacing-xl: 6rem;
    }

    .grid-2 {
        grid-template-columns: repeat(2, 1fr);
    }

    .grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }

    .hero-subtitle {
        font-size: var(--font-size-lg);
    }

    .hero-cta {
        flex-direction: row;
        justify-content: center;
    }

    .hero-cta span {
        margin-left: 1rem !important;
    }

    .method-image {
        display: block;
        background: #f0f0f0;
        height: 100%;
        min-height: 400px;
        position: relative;
        overflow: hidden;
    }

    .method-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        filter: grayscale(100%);
    }

    .section-header {
        display: flex;
        justify-content: space-between;
        align-items: flex-end;
        text-align: left;
    }
}

/* Desktop Breakpoint (1024px+) */
@media (min-width: 1024px) {
    :root {
        --font-size-hero: 4.5rem;
        --font-size-3xl: 4rem;
        --font-size-2xl: 2.5rem;
        --spacing-md: 2.5rem;
        --spacing-lg: 5rem;
        --spacing-xl: 8rem;
    }

    .navbar {
        height: 100px;
        background: transparent;
    }

    .navbar.scrolled {
        background: rgba(237, 234, 229, 0.95);
        height: 80px;
    }

    .nav-menu {
        display: flex;
        gap: var(--spacing-md);
    }

    .nav-link {
        font-size: 0.85rem;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.1em;
        position: relative;
    }

    .nav-link::after {
        content: '';
        position: absolute;
        bottom: -5px;
        left: 0;
        width: 0;
        height: 2px;
        background: var(--color-accent);
        transition: width var(--transition-base);
    }

    .nav-link:hover::after {
        width: 100%;
    }

    .hamburger {
        display: none;
    }

    .grid-3 {
        grid-template-columns: repeat(3, 1fr);
    }

    .grid-4 {
        grid-template-columns: repeat(4, 1fr);
    }

    .section--hero {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
        padding-top: 100px;
    }

    .hero-content {
        max-width: 50%;
        text-align: left;
        margin-bottom: 0;
    }

    .hero-subtitle {
        border-right: none;
        padding-right: 0;
        margin-left: 0;
        margin-right: 0;
    }

    .hero-image {
        display: none;
        /* Hidden on desktop for clean text contrast */
    }

    .method-step {
        flex-direction: row;
        gap: 2rem;
        align-items: flex-start;
    }

    .method-number {
        font-size: 3rem;
        min-width: 60px;
    }
}

/* Large Desktop (1440px+) */
@media (min-width: 1440px) {
    :root {
        --font-size-hero: 5.5rem;
    }
}