/*
==================================================
    GERMAN CONSULTING WEBSITE - STYLE.CSS
==================================================

TABLE OF CONTENTS:
1.  :root - CSS Variables
2.  Global Styles & Typography
3.  Layout & Helpers
4.  Header & Navigation
5.  Section Styles
    5.1 Hero Section
    5.2 Services Section
    5.3 About Section (Snippet & Full Page)
    5.4 News Section
    5.5 External Resources Section
    5.6 Contact Section (Snippet & Full Page)
6.  Component Styles
    6.1 Buttons & Forms
    6.2 Cards (Universal)
    6.3 Timeline (About Page)
7.  Footer
8.  Page-Specific Styles
    8.1 Legal Pages (Privacy, Terms)
    8.2 Success Page
9.  Animations & Interactions
10. Media Queries (Responsiveness)

==================================================
*/

/* 1. :root - CSS Variables
-------------------------------------------------- */
:root {
    --gradient-start: #0f172a; /* Deep Slate Blue */
    --gradient-end: #1e293b;   /* Darker Slate Blue */
    --primary-color: #3b82f6; /* Bright Blue */
    --primary-color-darker: #2563eb;
    --secondary-color: #4ade80; /* Bright Green */
    --accent-color: #f472b6;   /* Bright Pink */
    
    --text-dark: #1e293b;
    --text-light: #f1f5f9;
    --text-grey: #64748b;

    --background-light: #f8fafc;
    --background-dark: #020617;
    --border-color: #e2e8f0;

    --font-heading: 'Poppins', sans-serif;
    --font-body: 'Work Sans', sans-serif;

    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    
    --header-height: 80px;
}

/* 2. Global Styles & Typography
-------------------------------------------------- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 100%;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    line-height: 1.7;
    color: var(--text-grey);
    background-color: var(--background-light);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6, .title, .subtitle {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.3;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.05);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-color-darker);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* 3. Layout & Helpers
-------------------------------------------------- */
#page-container {
    overflow-x: hidden;
}

.section {
    padding: 5rem 1.5rem;
}

.container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* 4. Header & Navigation
-------------------------------------------------- */
.header.is-fixed-top {
    height: var(--header-height);
    background: var(--background-dark) !important;
    box-shadow: var(--shadow-md);
    transition: background-color 0.3s ease;
}

.navbar {
    height: var(--header-height);
}

.navbar-item {
    font-family: var(--font-body);
    font-weight: 500;
    font-size: 1.1rem;
    color: var(--text-light) !important;
    transition: background-color 0.3s ease, color 0.3s ease;
    position: relative;
    padding: 0.5rem 1.25rem;
}

.navbar-item::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.navbar-item:hover::after,
.navbar-item.is-active::after {
    width: 60%;
}

.navbar-burger {
    color: var(--text-light);
    height: var(--header-height);
    width: var(--header-height);
}

/* 5. Section Styles
-------------------------------------------------- */

/* 5.1 Hero Section */
#hero {
    position: relative;
    color: var(--text-light);
    background-color: var(--background-dark);
}

#hero .hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    z-index: 1;
}

#particles-js {
    position: absolute;
    width: 100%;
    height: 100%;
    z-index: 2;
}

#hero .hero-body {
    position: relative;
    z-index: 3;
    display: flex;
    justify-content: center;
    align-items: center;
}

#hero .title.is-1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    color: #FFFFFF;
    font-weight: 700;
}

#hero .subtitle.is-3 {
    font-size: clamp(1.2rem, 3vw, 1.5rem);
    font-weight: 400;
    color: #FFFFFF;
    max-width: 800px;
    margin: 1.5rem auto 0;
}

/* 5.2 Services, 5.4 News (Uses global card styles) */
/* Styling is primarily handled by .card component */
.has-background-light {
    background-color: var(--background-light) !important;
}

/* 5.3 About Section */
#about img {
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
}

/* 5.5 External Resources Section */
#resources .resource-list {
    list-style: none;
    padding: 0;
}

#resources .box {
    background-color: #fff;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    margin-bottom: 1.5rem;
}

#resources .box:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

#resources .box p {
    margin-bottom: 0.5rem;
}
#resources .box .title a {
    color: var(--text-dark);
}

/* 5.6 Contact Section */
#contact .button {
    margin-top: 1rem;
}
#contact .map-container iframe {
    border-radius: 8px;
    box-shadow: var(--shadow-md);
}

/* 6. Component Styles
-------------------------------------------------- */

/* 6.1 Buttons & Forms */
.button, button, input[type='submit'] {
    font-family: var(--font-heading);
    font-weight: 600;
    border-radius: 50px !important; /* Pill shape */
    border: 2px solid transparent;
    padding-left: 2rem !important;
    padding-right: 2rem !important;
    transition: all 0.3s ease-in-out;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.button.is-primary {
    background-color: var(--primary-color) !important;
    color: var(--text-light) !important;
}
.button.is-primary:hover {
    background-color: var(--primary-color-darker) !important;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(59, 130, 246, 0.3);
}

.button.is-link {
    background-color: transparent !important;
    border-color: var(--primary-color) !important;
    color: var(--primary-color) !important;
}

.button.is-link:hover {
    background-color: var(--primary-color) !important;
    color: var(--text-light) !important;
    transform: translateY(-2px);
}

.input, .textarea {
    border-radius: 8px !important;
    border: 1px solid var(--border-color);
    box-shadow: none;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.input:focus, .textarea:focus {
    border-color: var(--primary-color) !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2) !important;
}

/* 6.2 Cards (Universal for Services, News etc.) */
.card {
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.4s ease;
    height: 100%; /* Make cards in a row equal height */
    display: flex;
    flex-direction: column;
    text-align: center;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.card .card-image {
    width: 100%;
}

.card .card-image figure {
    width: 100%;
    height: 220px; /* Fixed height for image container */
    overflow: hidden;
}

.card .card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures image covers the area, cropping as needed */
    transition: transform 0.4s ease;
}

.card:hover .card-image img {
    transform: scale(1.05);
}

.card .card-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
}

.card .card-content .title,
.card .card-content .subtitle {
    text-align: center;
    width: 100%;
}

/* 6.3 Timeline (About Page) */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 3px;
    background: linear-gradient(var(--gradient-start), var(--gradient-end));
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -1.5px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
}

.timeline-item:nth-child(odd) {
    left: 0;
}
.timeline-item:nth-child(even) {
    left: 50%;
}

.timeline-item:nth-child(odd) .timeline-content {
    text-align: right;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    right: -10px;
    background-color: var(--background-light);
    border: 4px solid var(--primary-color);
    top: 20px;
    border-radius: 50%;
    z-index: 1;
}
.timeline-item:nth-child(even)::after {
    left: -10px;
}

.timeline-content {
    padding: 20px 30px;
    background-color: #fff;
    position: relative;
    border-radius: 6px;
    box-shadow: var(--shadow-sm);
}

/* 7. Footer
-------------------------------------------------- */
.footer {
    background-color: var(--background-dark) !important;
    padding: 4rem 1.5rem 2rem;
    color: var(--text-grey);
}
.footer .title {
    color: var(--text-light);
}
.footer a {
    color: var(--text-grey);
    transition: color 0.3s ease;
}
.footer a:hover {
    color: var(--primary-color);
}
.footer ul {
    list-style: none;
    margin: 0;
    padding: 0;
}
.footer ul li {
    margin-bottom: 0.75rem;
}

/* 8. Page-Specific Styles
-------------------------------------------------- */
/* 8.1 Legal Pages (Privacy, Terms) */
.page-legal main {
    padding-top: calc(var(--header-height) + 2rem);
    padding-bottom: 4rem;
}
.page-legal h1, .page-legal h2 {
    margin-bottom: 1.5rem;
}

/* 8.2 Success Page */
#success-page-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}
#success-page-container main {
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* 9. Animations & Interactions
-------------------------------------------------- */
/* Scroll-triggered animation setup */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* 10. Media Queries (Responsiveness)
-------------------------------------------------- */
/* Tablet */
@media screen and (max-width: 1023px) {
    .section {
        padding: 4rem 1.5rem;
    }
}

/* Mobile */
@media screen and (max-width: 768px) {
    .section {
        padding: 3rem 1rem;
    }

    /* Burger Menu */
    .navbar-menu {
        background-color: var(--background-dark);
        box-shadow: 0 8px 16px rgba(0,0,0,0.1);
        padding: 1rem 0;
    }
    
    .navbar-item {
        padding: 1rem 1.5rem;
    }
    
    .columns.is-vcentered {
      display: flex;
      flex-direction: column-reverse;
    }
    
    .columns.is-vcentered .column:last-child {
      margin-bottom: 2rem;
    }

    /* Timeline on Mobile */
    .timeline::after {
        left: 31px;
    }
    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }
    .timeline-item:nth-child(even) {
        left: 0;
    }
    .timeline-item::after {
        left: 21px;
    }
    .timeline-item:nth-child(odd) .timeline-content {
        text-align: left;
    }
}