/* styles.css */
:root {
  --color-primary: 229 100% 64%;
  --color-secondary: 237 33% 60%;
  --color-neutral: 220 25% 85%;
  --color-base: 0 0% 0%;
  --color-muted: 220 28% 25%;
  --color-inverted: 100 100% 100%;
  --color-success: 142 71% 45%;
  --color-error: 0 75% 60%;
  --color-warning: 25 95% 53%;
  --color-inactive: 0 0% 63%;
  --color-info: 210 100% 60%;
  --color-background: 100 100% 100%;
  --color-background-secondary: 0 0% 97%;
}

.dark {
  --color-primary: 229 100% 64%;
  --color-secondary: 237 33% 60%;
  --color-neutral: 0 0% 15%;
  --color-base: 100 100% 100%;
  --color-muted: 0 0% 76%;
  --color-inverted: 220 14% 60%;
  --color-background: 240 3% 6%;
  --color-background-secondary: 240 2% 8%;
}

/* Lokale Headline-Font (font.ttf liegt neben index.html/styles.css) */
@font-face {
  font-family: "SyncHostHead";
  src: url("./font.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
  background-color: hsl(var(--color-background));
  color: hsl(var(--color-base));
  min-height: 100vh;
  line-height: 1.6;
  transition: background-color 0.3s, color 0.3s;
}

h1, h2, h3,
.page-title, .card-title,
.logo-text {
  font-family: "SyncHostHead", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
}

.container {
  max-width: 1420px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  max-width: 1420px;
  width: calc(100% - 2rem);
  padding: 0.5rem 2rem;
  border: 1px solid hsl(var(--color-neutral));
  border-radius: 1rem;
  background-color: hsl(var(--color-background-secondary));
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 50;
  margin-top: 1rem;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: hsl(var(--color-base));
}

.logo-img {
  width: 40px;
  height: 40px;
  border-radius: 0.5rem;
  object-fit: cover;
  display: block;
}

.logo-text {
  font-size: 1.25rem;
  font-weight: 700;
}

.dark-mode-toggle {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  border: 1px solid transparent;
  background: transparent;
  color: hsl(var(--color-base));
  cursor: pointer;
  transition: all 0.3s;
}

.dark-mode-toggle:hover {
  background: hsla(var(--color-primary) / 0.1);
  border-color: hsla(var(--color-primary) / 0.3);
}

/* Main Content */
.main {
  padding-top: 120px;
  padding-bottom: 4rem;
}

.page-header {
  text-align: center;
  margin-bottom: 3rem;
}

.page-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.page-title span {
  color: hsl(var(--color-primary));
}

.page-subtitle {
  color: hsl(var(--color-muted));
  font-size: 1.125rem;
}

/* Cards */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.card {
  background: hsl(var(--color-background-secondary));
  border: 1px solid hsl(var(--color-neutral));
  border-radius: 1rem;
  padding: 2rem;
  transition: all 0.3s;
}

.card:hover {
  border-color: hsl(var(--color-primary));
}

.card-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.card-icon {
  width: 48px;
  height: 48px;
  background: hsl(var(--color-primary));
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.25rem;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
}

.card-content p {
  color: hsl(var(--color-muted));
  margin-bottom: 0.5rem;
}

.card-content a {
  color: hsl(var(--color-primary));
  text-decoration: none;
  transition: opacity 0.3s;
}

.card-content a:hover {
  opacity: 0.8;
}

.inline-icon {
  color: hsl(var(--color-primary));
  margin-right: 0.5rem;
}

/* Full Width Card */
.card-full {
  grid-column: 1 / -1;
}

.card-full .card-content h3 {
  font-size: 1.125rem;
  font-weight: 600;
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
  color: hsl(var(--color-base));
}

.card-full .card-content h3:first-child {
  margin-top: 0;
}

/* Footer */
.footer {
  border-top: 1px solid hsl(var(--color-neutral));
  padding: 2rem 0;
  text-align: center;
}

.footer-text {
  color: hsl(var(--color-muted));
  font-size: 0.875rem;
}

.footer-text a {
  color: hsl(var(--color-primary));
  text-decoration: none;
}

.footer-handle {
  margin-left: 0.75rem;
  color: hsl(var(--color-muted));
}

/* Responsive */
@media (max-width: 768px) {
  .page-title {
    font-size: 2rem;
  }

  .header {
    padding: 0.5rem 1rem;
  }

  .cards-grid {
    grid-template-columns: 1fr;
  }
}
