:root {
    --primary: #1a365d;
    --primary-light: #2c5282;
    --secondary: #f8fafc;
    --accent: #3182ce;
    --text: #2d3748;
    --text-light: #718096;
    --white: #ffffff;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --radius: 12px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

a {
    color: var(--primary);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
    color: var(--primary);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Source Sans Pro', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 20px;
    line-height: 1.7;
    color: var(--text);
    background-color: var(--secondary);
    -webkit-font-smoothing: antialiased;
}

.hero-wrap {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-wrap:not(#home) {
    padding: 80px 20px;
}

.hero-wrap-negative {
    background: var(--primary);
    color: var(--white);
    position: relative;
}

.home-grid {
    display: grid;
    grid-template-columns: 45% 55%;
    max-width: 100%;
    margin: 0 auto;
    align-items: stretch;
    min-height: 100vh;
}

.home-grid-item {
    position: relative;
}

.home-grid-item:first-child {
    background: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px;
}

.home-grid-item:last-child {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 60px 80px;
    background: var(--secondary);
}

.portrait {
    width: 320px;
    max-width: 80%;
    height: auto;
    object-fit: cover;
    border-radius: var(--radius);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.section-buero {
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--text-light);
    margin-bottom: 8px;
}

.section-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(36px, 6vw, 56px);
    font-weight: 700;
    line-height: 1.2;
    color: var(--primary);
    margin-bottom: 20px;
}

.hero-wrap-negative .section-title {
    color: var(--white);
}

.section-subtitle {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(20px, 3vw, 28px);
    color: var(--white);
    opacity: 0.9;
    margin-bottom: 24px;
    text-align: left;
}

.section-title-second {
    font-size: clamp(16px, 2vw, 20px);
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 8px;
}

.contact-toolbar {
    display: flex;
    gap: 16px;
    margin: 24px 0;
}

.contact-toolbar a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: transparent;
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
    border: 2px solid var(--primary);
}

.contact-toolbar a:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
}

.contact-toolbar i {
    font-size: 24px;
}

.about-me {
    max-width: 900px;
    margin: 0 auto;
}

.about-me .section-title {
    text-align: left;
}

.about-me-text {
    font-size: 20px;
    line-height: 1.8;
    color: var(--white);
    opacity: 0.9;
    text-align: left;
}

.leistungen {
    background: var(--secondary);
}

.leistungen-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 60px;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

.leistung {
    padding: 24px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.leistung:last-child {
    border-bottom: none;
}

.leistung-titel {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 26px;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 12px;
}

.leistung-text {
    font-size: 18px;
    line-height: 1.7;
    color: var(--text-light);
}

.contact-grid {
    max-width: 1000px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.contact-item {
    text-align: left;
}

.contact-item p {
    margin-bottom: 8px;
    font-size: 18px;
}

.contact-item a {
    --bs-link-color: #ffffff;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 4px 0;
    color: #ffffff !important;
    text-decoration: none;
    border-bottom: 1px dotted rgba(255, 255, 255, 0.5);
    transition: var(--transition);
    font-size: 16px;
}

.contact-item a:hover {
    --bs-link-hover-color: #ffffff;
    border-bottom-color: #ffffff;
}

.contact-item a i {
    font-size: 18px;
    opacity: 0.8;
    color: #ffffff;
}

.contact-item img {
    max-height: 140px;
    margin-bottom: 16px;
    opacity: 1;
}

.contact-item a img {
    transition: var(--transition);
}

.contact-item a:hover img {
    opacity: 0.9;
}

address {
    font-style: normal;
}

.scroll-down-arrow {
    color: var(--primary);
    font-size: 24px;
    text-decoration: none;
    opacity: 0.6;
    transition: var(--transition);
    margin-top: 40px;
    display: inline-block;
}

.hero-wrap-negative .scroll-down-arrow {
    color: var(--white);
}

.scroll-down-arrow:hover {
    opacity: 1;
}

.certification-item {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.certification-item .logo-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-shrink: 0;
}

.certification-item .logo-group a {
    display: block;
    text-decoration: none;
    line-height: 0;
}

.certification-item .logo-group img {
    height: 80px;
    width: auto;
    object-fit: contain;
    transition: var(--transition);
}

.certification-item .logo-group a:hover img {
    opacity: 0.8;
}

.certification-item img {
    height: 80px;
    width: auto;
    object-fit: contain;
    flex-shrink: 0;
}

.certification-item .text-content {
    flex: 1;
}

.footer {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--primary);
    color: white;
    padding: 20px;
    text-align: center;
    font-size: 14px;
}

.footer .btn-link {
    background: none;
    border: none;
    color: var(--white);
    text-decoration: underline;
    cursor: pointer;
    font-size: inherit;
    padding: 0;
    margin-left: 16px;
}

.footer .btn-link:hover {
    opacity: 0.8;
}

.mobile-only {
    display: none;
}

.desktop-only {
    display: block;
}

.modal-dialog {
    max-width: 600px;
}

.modal-content {
    border: none;
    border-radius: var(--radius);
}

.modal-header {
    border-bottom: 1px solid #e2e8f0;
    padding: 24px;
}

.modal-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 24px;
    color: var(--primary);
}

.modal-body {
    padding: 32px 24px;
}

.modal-body h3 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 28px;
    color: var(--primary);
    margin-bottom: 8px;
}

.modal-body h4 {
    font-size: 16px;
    color: var(--text);
    margin-bottom: 4px;
}

.modal-body h5 {
    font-size: 14px;
    color: var(--text-light);
    font-weight: normal;
    margin-bottom: 24px;
}

.modal-body a {
    color: var(--primary);
    text-decoration: underline;
}

.modal-footer {
    border-top: 1px solid #e2e8f0;
    padding: 16px 24px;
}

.btn-secondary {
    background: var(--primary);
    border: none;
    border-radius: 8px;
    padding: 10px 24px;
}

.btn-secondary:hover {
    background: var(--primary-light);
}

.close {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 2px solid var(--primary);
    border-radius: 50%;
    color: var(--primary);
    font-size: 24px;
    cursor: pointer;
    transition: var(--transition);
    opacity: 1;
    padding: 0;
}

.close:hover {
    background: var(--primary);
    color: var(--white);
    opacity: 1;
}

.close span {
    line-height: 1;
}

.imagecenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

@media only screen and (min-width: 769px) {
    .leistungen .section-title {
        margin-bottom: 60px;
    }
}

@media only screen and (max-width: 768px) {
    body {
        font-size: 17px;
    }
    
    .home-grid {
        grid-template-columns: 1fr;
        min-height: auto;
    }
    
    .home-grid-item:first-child {
        padding: 50px 20px;
    }
    
    .home-grid-item:last-child {
        padding: 40px 24px 60px;
        text-align: center;
    }

    .portrait {
        width: 220px;
    }

    .section-title {
        text-align: center;
    }
    
    .section-title-second {
        text-align: center;
    }
    
    .section-buero {
        text-align: center;
    }

    .contact-toolbar {
        justify-content: center;
    }

    .about-me-text {
        padding: 0 20px;
        font-size: 17px;
    }
    
    .leistung-text {
        font-size: 16px;
    }
    
    .leistung-titel {
        font-size: 22px;
    }

    .leistungen-grid {
        grid-template-columns: 1fr;
        padding: 0 16px;
    }

    .leistung {
        padding: 20px 0;
    }

    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .contact-item {
        text-align: center;
    }
    
    .contact-item p {
        font-size: 16px;
    }
    
    .about-me .section-title {
        text-align: center;
    }
    
    .about-me-text {
        text-align: center;
    }
    
    .about-me .section-subtitle {
        text-align: center;
    }

    .hero-wrap:not(#home) {
        padding: 60px 0 0;
    }
    
    .hero-wrap:not(#home) > *:not(.footer) {
        padding: 0 20px;
    }

    .footer {
        position: relative;
        margin-top: 40px;
        padding: 20px 0;
    }

    .certification-item {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }

    .certification-item img {
        height: 60px;
    }

    .certification-item .logo-group {
        flex-direction: column;
        align-items: center;
    }

    .certification-item .logo-group img {
        height: 60px;
    }

    .certification-item .logo-group img:first-child {
        margin-bottom: 8px;
    }

    .certification-item .text-content {
        text-align: center;
    }
    
    .mobile-only {
        display: block;
    }
    
    .desktop-only {
        display: none !important;
    }
}
