/* =========================
   RESET & BASIS
========================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #15e5f0;
    --white: #ffffff;
    --dark: #020617;
    --gray: #64748b;
    --light-bg: #f8fafc;
    --shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    --radius: 16px;
    --max-width: 1200px;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background: var(--light-bg);
    color: #1e293b;
    line-height: 1.6;
}

section {
    padding: 100px 20px;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
}

h2 {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 50px;
    font-weight: 800;
}

/* =========================
   HEADER & NAV
========================= */
header {
    background: var(--white);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

nav {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

nav a {
    margin-left: 20px;
    font-weight: 600;
    color: #475569;
    transition: color 0.3s;
}

nav a:hover {
    color: var(--primary);
}

/* =========================
   HERO
========================= */


/* =========================
   COMPONENTS (CARDS & BUTTONS)
========================= */
.button {
    background: var(--primary);
    padding: 14px 32px;
    border-radius: 50px;
    font-weight: 700;
    display: inline-block;
    color: #000;
    transition: transform 0.2s, box-shadow 0.2s;
}

.button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(21, 229, 240, 0.4);
}

/* Die universelle Kachel-Klasse */
.box, .service-card, .team-member, .reference-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 24px;
    transition: transform 0.3s ease;
}

.box:hover {
    transform: translateY(-5px);
}

/* =========================
   GRIDS (DESKTOP FIRST)
========================= */

/* =========================
   LEISTUNGEN – ALLES AUF EINER HÖHE
========================= */
.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    align-items: stretch; /* Sorgt dafür, dass alle Kacheln in einer Reihe gleich hoch sind */
}

.service-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 24px;
}

/* 1. Die Überschrift h3: Feste Mindesthöhe für 2 Zeilen - ÜBERSCHRIFTEN OBEN BÜNDIG*/
.service-card h3 {
    margin-bottom: 15px;
    font-size: 1.25rem;
    line-height: 1.3;
    
    /* Reserviert Platz für 2 Zeilen */
    min-height: 2.6em; 
    
    /* Sorgt dafür, dass der Text oben beginnt */
    display: block; 
    text-align: left;
}

/* 2. Der Text p: Nimmt den restlichen verfügbaren Platz ein */
.service-card p {
    font-size: 0.95rem;
    color: var(--gray);
    margin-bottom: 25px;
    flex-grow: 1; /* Schiebt den Button nach ganz unten */
}

/* 3. Der Button: Bleibt immer am unteren Rand der Kachel */
.service-card .button {
    align-self: flex-start; /* Verhindert, dass der Button über die ganze Breite gestreckt wird */
    margin-top: auto; 
}

.service-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: calc(var(--radius) - 8px);
    margin-bottom: 20px;
}

.service-card h3 { margin-bottom: 12px; }
.service-card p { font-size: 0.95rem; margin-bottom: 20px; color: var(--gray); flex-grow: 1; }

/* 2. TEAM (3 Spalten) */
.team-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
}

.team-member {
    text-align: center;
}

.team-member img {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 50%;
    margin: 0 auto 20px;
    border: 4px solid var(--primary);
}

/* =========================
   3. REFERENZEN – OPTIMIERT
========================= */
.references-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
}

.reference-card {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px; /* Mehr Innenabstand für ein wertiges Design */
    min-height: 140px; /* Erhöht von 120px auf 140px für mehr Platz */
    background: var(--white);
}

.reference-card img {
    /* Hier ist die Magie: */
    width: auto;
    height: auto;
    max-width: 100%;  /* Nutzt die volle Breite der Box */
    max-height: 100px; /* Erhöht von 80px auf 100px */
    object-fit: contain; /* Verhindert Verzerrungen */
    transition: transform 0.3s ease;
}

/* Kleiner Bonus: Ein dezenter Effekt beim Drüberfahren */
.reference-card:hover img {
    transform: scale(1.05); 
}

/* =========================
   CTA SECTION
========================= */
.cta {
    background: var(--dark);
    color: white;
    text-align: center;
}

/* =========================
   FOOTER
========================= */
footer {
    background: #0f172a;
    color: #94a3b8;
    text-align: center;
    padding: 60px 20px;
}

footer a { margin: 0 10px; }
footer a:hover { color: var(--primary); }

/* =========================
   ZWEI-SPALTEN-LAYOUT (BILD/TEXT)
========================= */
.split-section {
    display: grid;
    grid-template-columns: 2fr 1fr; /* Text breiter als Bild */
    gap: 60px;
    align-items: center;
}

.split-image-container {
    text-align: center;
}

.split-image-container img {
    max-width: 320px; /* Hier begrenzst du die Bildgröße zentral */
    width: 100%;
    height: auto;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

/* Responsive Anpassung für Tablets und Handys */
@media (max-width: 900px) {
    .split-section {
        grid-template-columns: 1fr; /* Stapelt Text und Bild untereinander */
        gap: 40px;
        text-align: center;
    }
    
    .split-image-container img {
        max-width: 250px; /* Auf dem Handy etwas kleiner */
    }
}

/* =========================
   RESPONSIVE DESIGN
========================= */

/* Tablets (max 1024px) */
@media (max-width: 1024px) {
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .team-grid { grid-template-columns: repeat(2, 1fr); }
    .references-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Kleine Tablets & große Handys (max 768px) */
@media (max-width: 768px) {
    .hero h1 { font-size: 2.5rem; }
    nav { flex-direction: column; gap: 15px; }
    nav a { margin: 0 10px; }
}

/* Handys (max 480px) */
@media (max-width: 480px) {
    .services-grid, 
    .team-grid, 
    .references-grid { 
        grid-template-columns: 1fr; 
    }
    
    section { padding: 60px 20px; }
    .hero h1 { font-size: 2rem; }
}

/* =========================
   RECHTLICHE SEITEN (Impressum, Datenschutz)
========================= */

/* Zentriert die rechtlichen Inhalte und begrenzt die Breite für bessere Lesbarkeit */
.legal-content {
    max-width: 800px; /* Textzeilen sollten nicht zu lang sein */
    margin: 40px auto;
    text-align: left;
    padding: 40px; /* Mehr Platz innerhalb der weißen Box */
}

.legal-content h1 {
    margin-bottom: 30px;
    border-bottom: 3px solid var(--primary);
    display: inline-block;
    padding-bottom: 5px;
}

.legal-content h3 {
    margin: 30px 0 10px 0;
    color: var(--dark);
    font-size: 1.4rem;
}

.legal-content p {
    margin-bottom: 20px;
    color: #334155;
    line-height: 1.8; /* Größerer Zeilenabstand für bessere Lesbarkeit */
}

.legal-content a {
    color: var(--primary);
    text-decoration: underline;
    font-weight: 500;
}

.legal-content a:hover {
    color: var(--dark);
}

/* Anpassung für mobile Geräte */
@media (max-width: 600px) {
    .legal-content {
        padding: 20px;
        margin: 20px auto;
    }
}

/* Einrückung für Listen im Datenschutz/Impressum */
.legal-content ul {
    margin-left: 25px;   /* Erzeugt die Einrückung nach rechts */
    margin-bottom: 20px; /* Abstand nach unten zum nächsten Text */
    list-style-type: disc; /* Klassische Aufzählungspunkte */
}

.legal-content li {
    margin-bottom: 8px;  /* Kleiner Abstand zwischen den einzelnen Punkten */
    color: #334155;
    line-height: 1.6;
}

.phone-link {
    color: inherit; /* Übernimmt die Farbe vom Text (schwarz/dunkel) */
    text-decoration: none; /* Entfernt den Unterstrich */
    transition: color 0.3s ease;
}

/* Telefondirektwahl für smartphone*/

.phone-link:hover {
    color: var(--primary); /* Wird beim Drüberfahren türkis */
    text-decoration: underline;
}

/* Optional: Ein kleines Telefon-Icon vor der Nummer (falls gewünscht) */
.phone-link::before {
    content: "📞 "; 
    font-size: 0.9em;
}


/* Spezifische Liste für die Anwalts-Sektion */
.split-text ul li {
    list-style: none;
    position: relative;
    padding-left: 25px;
    margin-bottom: 12px;
}

.split-text ul li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: bold;
}

/* Spezielle Korrektur für die Team-Sektion (Anwälte) */
.team-alignment-fix {
    display: grid !important;
    grid-template-columns: 1fr 2fr !important; /* Exaktes 1:2 Verhältnis */
    gap: 60px;
    align-items: start !important; /* Bild und Text beginnen exakt oben */
}

.team-alignment-fix .split-text h2 {
    margin-top: 0 !important; /* Entfernt den Standard-Abstand der Überschrift */
    padding-top: 0 !important;
    line-height: 1.1; /* Verhindert, dass Zeilenabstand das "Bündig-Sein" stört */
}

.team-alignment-fix img {
    display: block;
    width: 100%;
    height: auto;
}


.hero {
    position: relative;
    height: 100vh; /* Oder die gewünschte Höhe */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden; /* Wichtig, damit das Video nicht übersteht */
    color: white; /* Textfarbe auf Weiß setzen für besseren Kontrast */
}
/* =========================
   HERO SEKTION (VIDEO)
========================= */
.hero {
    position: relative;
    width: 100%;
    height: 100vh; /* Füllt den ganzen Bildschirm */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: white;
    background: #000; /* Fallback-Farbe, falls Video nicht lädt */
}

.hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: 1; /* Video nach vorne */
    transform: translate(-50%, -50%);
    object-fit: cover;
}

/* Der dunkle Schleier (Overlay), damit man den Text lesen kann */
/* Der dunkle Schleier (Overlay), damit man den Text lesen kann */
.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Von 0.5 (50%) auf 0.8 (80%) Transparenz erhöht = 30% dunkler */
    background: rgba(0, 0, 0, 0.8); 
    z-index: 2; /* Über das Video */
}

/* Der Text-Inhalt */
.hero .container.hero-content {
    position: relative;
    z-index: 3; /* Ganz nach oben über Video und Overlay */
    text-align: center;
}

.hero h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 24px;
}

.hero p {
    font-size: 1.25rem;
    max-width: 700px;
    margin: 0 auto 40px;
}
/* Mobile Optimierung: Untereinander auf kleinen Schirmen */
@media (max-width: 768px) {
    .team-alignment-fix {
        grid-template-columns: 1fr !important;
        gap: 30px;
    }
}