:root {
    --primary-color: #00ff88;
    --primary-dim: rgba(0, 255, 136, 0.2);
    --bg-dark: #121212;
    --bg-card: #1e1e1e;
    --bg-card-hover: #252525;
    --text-light: #ffffff;
    --text-muted: #a0a0a0;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; scroll-behavior: smooth; }
body { background-color: var(--bg-dark); color: var(--text-light); line-height: 1.6; }

/* Navbar */
.navbar { display: flex; justify-content: space-between; align-items: center; padding: 1.5rem 5%; background-color: rgba(18, 18, 18, 0.95); position: fixed; width: 100%; top: 0; z-index: 1000; border-bottom: 1px solid #333; }
.logo { font-size: 1.8rem; font-weight: bold; }
.logo span { color: var(--primary-color); }
.nav-links { list-style: none; display: flex; gap: 2rem; }
.nav-links a { color: var(--text-light); text-decoration: none; font-weight: 500; transition: 0.3s; }
.nav-links a:hover { color: var(--primary-color); }

/* Hero */
.hero { height: 100vh; display: flex; align-items: center; justify-content: center; text-align: center; background: linear-gradient(rgba(0,0,0,0.85), rgba(0,0,0,0.85)), url('https://images.unsplash.com/photo-1517836357463-d25dfeac3438?q=80&w=2070&auto=format&fit=crop') center/cover; padding: 0 20px; }
.hero-content h1 { font-size: 4rem; margin-bottom: 1rem; }
.hero-content span { color: var(--primary-color); }
.hero-content p { font-size: 1.2rem; color: var(--text-muted); margin-bottom: 2rem; max-width: 600px; margin: 0 auto 2rem auto; }

.btn { display: inline-block; padding: 1rem 2.5rem; background-color: var(--primary-color); color: var(--bg-dark); text-decoration: none; font-weight: bold; border-radius: 8px; border: none; cursor: pointer; transition: 0.3s; font-size: 1rem; text-align: center; }
.btn:hover { transform: translateY(-3px); box-shadow: 0 10px 20px var(--primary-dim); }
.btn-full { width: 100%; margin-top: 1rem; }
.btn-small { padding: 0.8rem 1.5rem; width: 100%; margin-top: 1rem; }

section { padding: 6rem 5%; }
section h2 { text-align: center; font-size: 2.5rem; margin-bottom: 3rem; border-bottom: 2px solid var(--primary-dim); display: inline-block; padding-bottom: 10px; left: 50%; position: relative; transform: translateX(-50%); }

/* Calculator */
.calc-container { max-width: 600px; margin: 0 auto; background-color: var(--bg-card); padding: 2.5rem; border-radius: 15px; border: 1px solid #333; }
.input-group { margin-bottom: 1.5rem; }
.input-group-row { display: flex; gap: 1rem; margin-bottom: 1rem; }
.input-group-row input { flex: 1; }
label { display: block; margin-bottom: 0.5rem; color: var(--text-muted); font-size: 0.9rem; }
input, select { width: 100%; padding: 0.8rem; border-radius: 8px; border: 1px solid #444; background: #121212; color: #fff; font-size: 1rem; outline: none; }
input:focus, select:focus { border-color: var(--primary-color); }
.result-box { margin-top: 1.5rem; font-size: 1.1rem; font-weight: bold; text-align: center; color: var(--primary-color); }

/* Dashboard Tracker */
.dashboard-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.dash-card { background-color: var(--bg-card); padding: 2rem; border-radius: 15px; border: 1px solid #333; }
.dash-card h3 { margin-bottom: 1.5rem; color: var(--text-light); }
.progress-group { margin-bottom: 1rem; }
.progress-group label { display: flex; justify-content: space-between; font-weight: bold; color: #fff; }
progress { width: 100%; height: 12px; border-radius: 10px; -webkit-appearance: none; appearance: none; margin-top: 5px; }
progress::-webkit-progress-bar { background-color: #333; border-radius: 10px; }
progress::-webkit-progress-value { background-color: var(--primary-color); border-radius: 10px; transition: width 0.5s ease; }

/* Hydration */
.water-card { text-align: center; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.water-btn { width: 150px; height: 150px; border-radius: 50%; background-color: transparent; border: 4px solid #00a8ff; color: #00a8ff; font-size: 1.2rem; font-weight: bold; cursor: pointer; transition: 0.3s; margin-bottom: 1.5rem; }
.water-btn:hover { background-color: rgba(0, 168, 255, 0.1); transform: scale(1.05); }
.water-status { font-size: 1.5rem; font-weight: bold; }

/* Grid & Cards (Workouts) */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 2rem; }
.card { background-color: var(--bg-card); padding: 2.5rem 2rem; border-radius: 15px; text-align: center; transition: 0.3s; border: 1px solid #333; cursor: pointer; }
.card:hover { transform: translateY(-10px); background-color: var(--bg-card-hover); border-color: var(--primary-color); }
.card h3 { color: var(--primary-color); margin-bottom: 1rem; font-size: 1.4rem; }
.click-hint { display: block; margin-top: 1.5rem; font-size: 0.9rem; color: var(--text-muted); font-weight: bold; transition: 0.3s; }
.card:hover .click-hint { color: var(--primary-color); }

/* Modals */
.modal { display: none; position: fixed; z-index: 2000; left: 0; top: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.85); backdrop-filter: blur(5px); }
.modal-content { background-color: var(--bg-card); margin: 10% auto; padding: 2.5rem; border: 1px solid var(--primary-color); width: 90%; max-width: 600px; border-radius: 15px; position: relative; color: #fff; }
.modal-content h2 { font-size: 1.8rem; margin-bottom: 1.5rem; color: var(--primary-color); }
.modal-content ul { padding-left: 1.5rem; line-height: 2; font-size: 1.1rem; }
.close { color: #aaa; position: absolute; right: 20px; top: 15px; font-size: 28px; font-weight: bold; cursor: pointer; transition: 0.3s; }
.close:hover { color: var(--primary-color); }

footer { text-align: center; padding: 2rem; background-color: #0a0a0a; color: var(--text-muted); border-top: 1px solid #333; }

/* Food Search Database */
.api-search-box {
    display: flex;
    gap: 10px;
    margin-bottom: 0.5rem;
    margin-top: 1rem;
}

.api-search-box input {
    flex: 1; /* Zwingt das Eingabefeld, den maximalen Platz einzunehmen */
    margin: 0; 
}

.search-status {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.btn-search {
    padding: 0 1rem;
    width: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    border-radius: 8px;
}