/* ========================================
   optiCESS Website Styles
   Color scheme: gray #5a5a5a, white #ffffff, blue #0f32c8
   ======================================== */

/* CSS Variables */
:root {
    --primary-blue: #0f32c8;
    --primary-blue-light: #1a4fd6;
    --primary-blue-dark: #0a2399;
    --gray-dark: #5a5a5a;
    --gray-medium: #888888;
    --gray-light: #e5e5e5;
    --white: #ffffff;
    --black: #1a1a1a;
    --shadow: rgba(0, 0, 0, 0.1);
    --shadow-dark: rgba(0, 0, 0, 0.2);
    --transition: all 0.3s ease;
    --font-primary: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Reset & Base */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-primary);
    font-weight: 400;
    line-height: 1.6;
    color: var(--gray-dark);
    background-color: var(--white);
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ========================================
   Navigation
   ======================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--white);
    box-shadow: 0 2px 10px var(--shadow);
    transition: var(--transition);
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 20px var(--shadow-dark);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    order: 2;
}

.logo-img {
    height: 50px;
    width: auto;
}

.logo-svg {
    height: 40px;
    width: auto;
}

.logo-text-opti {
    font-family: var(--font-primary);
    font-size: 28px;
    font-weight: 300;
    fill: var(--gray-dark);
}

.logo-text-cess {
    font-family: var(--font-primary);
    font-size: 28px;
    font-weight: 700;
    fill: var(--primary-blue);
}

/* Navigation Menu */
.nav-menu {
    display: flex;
    align-items: center;
    gap: 30px;
    order: 1;
    flex: 1;
}

.nav-link {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--gray-dark);
    padding: 8px 0;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-blue);
    transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-blue);
}

/* Dropdown */
.dropdown {
    position: relative;
}

.dropdown-toggle::after {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    margin-left: 6px;
    transition: var(--transition);
}

.dropdown:hover .dropdown-toggle::after {
    transform: rotate(-135deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 180px;
    background: var(--white);
    box-shadow: 0 10px 30px var(--shadow-dark);
    border-radius: 8px;
    padding: 10px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li a {
    display: block;
    padding: 10px 20px;
    font-size: 0.9rem;
    color: var(--gray-dark);
}

.dropdown-menu li a:hover {
    background: var(--gray-light);
    color: var(--primary-blue);
}

/* Mobile Toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.hamburger {
    display: block;
    width: 100%;
    height: 3px;
    background: var(--gray-dark);
    border-radius: 2px;
    transition: var(--transition);
    position: relative;
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 3px;
    background: var(--gray-dark);
    border-radius: 2px;
    transition: var(--transition);
}

.hamburger::before {
    top: -8px;
}

.hamburger::after {
    top: 8px;
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);
    overflow: hidden;
    padding: 100px 20px 60px;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
}

.hero-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
}

.shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.1;
}

.shape-1 {
    width: 400px;
    height: 400px;
    background: var(--primary-blue);
    top: -100px;
    right: -100px;
    animation: float 8s ease-in-out infinite;
}

.shape-2 {
    width: 300px;
    height: 300px;
    background: var(--primary-blue);
    bottom: -50px;
    left: -50px;
    animation: float 10s ease-in-out infinite reverse;
}

.shape-3 {
    width: 200px;
    height: 200px;
    background: var(--gray-dark);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: pulse 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-30px) rotate(5deg);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.1;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.1);
        opacity: 0.15;
    }
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
}

.hero-title {
    margin-bottom: 20px;
}

.title-line {
    display: block;
    font-size: 1.5rem;
    font-weight: 300;
    color: var(--gray-dark);
    margin-bottom: 10px;
}

.title-highlight {
    display: block;
    font-size: 4rem;
    font-weight: 700;
    color: var(--primary-blue);
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--gray-dark);
    margin-bottom: 30px;
}

.hero-text {
    font-size: 1.1rem;
    color: var(--gray-medium);
    max-width: 600px;
    margin: 0 auto 40px;
    line-height: 1.8;
}

/* Button */
.btn {
    display: inline-block;
    padding: 15px 40px;
    font-size: 1rem;
    font-weight: 500;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background: var(--primary-blue);
    color: var(--white);
    border: 2px solid var(--primary-blue);
}

.btn-primary:hover {
    background: var(--primary-blue-dark);
    border-color: var(--primary-blue-dark);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(15, 50, 200, 0.3);
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    animation: bounce 2s ease-in-out infinite;
}

.scroll-indicator span {
    display: block;
    font-size: 0.85rem;
    color: var(--gray-medium);
    margin-bottom: 10px;
}

.scroll-arrow {
    width: 24px;
    height: 24px;
    border-right: 2px solid var(--gray-medium);
    border-bottom: 2px solid var(--gray-medium);
    transform: rotate(45deg);
    margin: 0 auto;
}

@keyframes bounce {
    0%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    50% {
        transform: translateX(-50%) translateY(10px);
    }
}

/* ========================================
   Sections
   ======================================== */
.section {
    padding: 100px 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--black);
    text-align: center;
    margin-bottom: 60px;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--primary-blue);
    margin: 20px auto 0;
    border-radius: 2px;
}

.section-intro {
    text-align: center;
    max-width: 800px;
    margin: -30px auto 50px;
    font-size: 1.1rem;
    color: var(--gray-dark);
    line-height: 1.8;
}

/* ========================================
   About Section
   ======================================== */
.about {
    background: var(--white);
}

.content-block {
    display: flex;
    align-items: flex-start;
    gap: 30px;
    margin-bottom: 50px;
    padding: 40px;
    background: var(--white);
    border-radius: 15px;
    box-shadow: 0 5px 30px var(--shadow);
    transition: var(--transition);
}

.content-block:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px var(--shadow-dark);
}

.content-icon {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-blue-light) 100%);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.content-icon svg {
    width: 40px;
    height: 40px;
    color: var(--white);
}

.content-text h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--black);
    margin-bottom: 15px;
}

.content-text p {
    font-size: 1rem;
    color: var(--gray-dark);
    line-height: 1.8;
}

/* ========================================
   Portfolio Section
   ======================================== */
.portfolio {
    background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 100%);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.portfolio-card {
    background: var(--white);
    border-radius: 15px;
    padding: 35px;
    box-shadow: 0 5px 30px var(--shadow);
    transition: var(--transition);
}

.portfolio-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px var(--shadow-dark);
}

.portfolio-card-large {
    grid-column: 1 / -1;
}

.card-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-blue-light) 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.card-icon svg {
    width: 30px;
    height: 30px;
    color: var(--white);
}

.portfolio-card h3 {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--black);
    margin-bottom: 20px;
}

.portfolio-card ul {
    list-style: none;
}

.portfolio-card li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 10px;
    color: var(--gray-dark);
    font-size: 0.95rem;
}

.portfolio-card li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    width: 6px;
    height: 6px;
    background: var(--primary-blue);
    border-radius: 50%;
}

.card-note {
    margin-top: 15px;
    padding: 15px;
    background: var(--gray-light);
    border-radius: 8px;
    font-size: 0.9rem;
    color: var(--gray-dark);
    font-style: italic;
}

/* Manufacturing Grid */
.manufacturing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 25px;
}

.manufacturing-item h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-blue);
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--gray-light);
}

.manufacturing-item ul {
    list-style: none;
}

.manufacturing-item li {
    padding-left: 15px;
    margin-bottom: 6px;
    font-size: 0.9rem;
}

.manufacturing-item li::before {
    width: 4px;
    height: 4px;
    top: 9px;
}

/* ========================================
   Contact Section
   ======================================== */
.contact {
    background: var(--white);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.contact-item {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.contact-icon {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-blue-light) 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-icon svg {
    width: 24px;
    height: 24px;
    color: var(--white);
}

.contact-text h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--black);
    margin-bottom: 8px;
}

.contact-text p {
    color: var(--gray-dark);
    line-height: 1.7;
}

.contact-text a {
    color: var(--primary-blue);
}

.contact-text a:hover {
    text-decoration: underline;
}

.contact-map {
    background: var(--gray-light);
    border-radius: 15px;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.map-placeholder {
    text-align: center;
    color: var(--gray-medium);
}

.map-placeholder svg {
    width: 60px;
    height: 60px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.map-placeholder p {
    font-size: 1.1rem;
    font-weight: 500;
}

/* ========================================
   Impressum Section
   ======================================== */
.impressum {
    background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 100%);
}

.impressum-content {
    max-width: 900px;
    margin: 0 auto;
}

.impressum-header {
    background: var(--white);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 5px 30px var(--shadow);
    margin-bottom: 40px;
    text-align: center;
}

.impressum-header h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 20px;
}

.impressum-header p {
    color: var(--gray-dark);
    margin-bottom: 10px;
    line-height: 1.7;
}

.impressum-header a {
    color: var(--primary-blue);
}

.impressum-header a:hover {
    text-decoration: underline;
}

.impressum-section {
    background: var(--white);
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 30px var(--shadow);
    margin-bottom: 20px;
}

.impressum-section h4 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--black);
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--gray-light);
}

.impressum-section p {
    color: var(--gray-dark);
    line-height: 1.8;
    text-align: justify;
}

/* ========================================
   Footer
   ======================================== */
.footer {
    background: var(--black);
    color: var(--white);
    padding: 60px 0 30px;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.footer-logo .logo-svg {
    height: 35px;
}

.footer-logo .logo-text-opti {
    fill: var(--gray-light);
}

.footer-logo .logo-text-cess {
    fill: var(--primary-blue-light);
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
}

.footer-links a {
    color: var(--gray-light);
    font-size: 0.95rem;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary-blue-light);
}

.footer-copyright {
    color: var(--gray-medium);
    font-size: 0.85rem;
    text-align: center;
}

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 992px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .content-block {
        flex-direction: column;
        text-align: center;
    }

    .content-icon {
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: var(--white);
        flex-direction: column;
        justify-content: flex-start;
        padding: 100px 30px 30px;
        box-shadow: -10px 0 30px var(--shadow-dark);
        transition: var(--transition);
        gap: 0;
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu li {
        width: 100%;
    }

    .nav-link {
        display: block;
        padding: 15px 0;
        border-bottom: 1px solid var(--gray-light);
    }

    .dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        padding-left: 20px;
        background: transparent;
    }

    .nav-toggle.active .hamburger {
        background: transparent;
    }

    .nav-toggle.active .hamburger::before {
        transform: rotate(45deg);
        top: 0;
    }

    .nav-toggle.active .hamburger::after {
        transform: rotate(-45deg);
        top: 0;
    }

    .title-highlight {
        font-size: 2.8rem;
    }

    .title-line {
        font-size: 1.2rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    .section {
        padding: 60px 0;
    }

    .section-title {
        font-size: 2rem;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .manufacturing-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 80px 15px 40px;
    }

    .title-highlight {
        font-size: 2.2rem;
    }

    .hero-text {
        font-size: 1rem;
    }

    .btn {
        padding: 12px 30px;
        font-size: 0.9rem;
    }

    .content-block,
    .portfolio-card,
    .impressum-header,
    .impressum-section {
        padding: 25px;
    }

    .footer-links {
        flex-direction: column;
        gap: 15px;
    }
}

/* ========================================
   Utility Classes
   ======================================== */
.text-center {
    text-align: center;
}

.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 20px; }
.mt-3 { margin-top: 30px; }
.mb-1 { margin-bottom: 10px; }
.mb-2 { margin-bottom: 20px; }
.mb-3 { margin-bottom: 30px; }

/* Fade-in animation for elements */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Print styles */
@media print {
    .navbar,
    .scroll-indicator,
    .footer {
        display: none;
    }

    .section {
        page-break-inside: avoid;
        padding: 30px 0;
    }

    .hero {
        min-height: auto;
        padding: 50px 20px;
    }
}
