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

/* BODY */
body {
  font-family: Arial, sans-serif;
  background-color: #0f172a;
  background-image: url('/mitarbeiterportal/assets/hintergrund.png');
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  background-attachment: fixed;
  color: #1f2937;
}

/* LOGIN */
.login-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  padding: 20px;
}

.login-card {
  background: #ffffff;
  padding: 30px;
  border-radius: 12px;
  width: 320px;
  text-align: center;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.logo-box {
  margin-bottom: 15px;
}

.logo-box img {
  max-width: 220px;
  height: auto;
  display: block;
  margin: 0 auto;
}

.portal-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 20px;
  line-height: 1.3;
}

.login-card h2 {
  margin-bottom: 12px;
}

.login-error {
  color: #b91c1c;
  background: #fee2e2;
  border-radius: 8px;
  padding: 10px;
  margin-bottom: 10px;
}

/* INPUTS */
input {
  width: 100%;
  box-sizing: border-box;
  margin: 10px 0;
  padding: 10px;
  border: 1px solid #cccccc;
  border-radius: 6px;
}

/* BUTTON */
button {
  width: 100%;
  padding: 12px;
  background: #6a1b9a;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

button:hover {
  background: #4a148c;
}

/* DASHBOARD */
.dashboard-container {
  display: flex;
  justify-content: center;
  padding: 40px 20px;
}

.dashboard-card {
  background: #ffffff;
  border-radius: 20px;
  padding: 30px;
  width: 100%;
  max-width: 1200px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

h1 {
  margin-bottom: 10px;
}

.welcome-text {
  margin-bottom: 20px;
}

.selection-header {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-bottom: 24px;
}

.selection-header img {
  width: 220px;
  max-width: 38%;
  height: auto;
  border-radius: 10px;
}

.selection-header .welcome-text {
  margin-bottom: 0;
}

.portal-selection-grid {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

/* INFO BOX */
.info-box {
  background: #dbeafe;
  border-left: 6px solid #3b82f6;
  padding: 20px;
  border-radius: 12px;
  margin-bottom: 25px;
}

.info-box h2 {
  margin-bottom: 10px;
  color: #1e40af;
}

.info-content {
  font-size: 16px;
  line-height: 1.5;
  color: #1f2937;
  white-space: pre-line;
}

/* GRID */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

/* TILES */
.dashboard-box {
  display: block;
  text-decoration: none;
  background: #f3f4f6;
  border-radius: 15px;
  padding: 20px;
  transition: all 0.2s ease;
  border: 1px solid #e5e7eb;
  min-height: 170px;
  overflow: hidden;
}

.dashboard-box h2 {
  color: #6a1b9a;
  margin-bottom: 10px;
  line-height: 1.25;
  word-break: break-word;
  overflow-wrap: break-word;
}

.dashboard-box p {
  color: #374151;
}

.dashboard-box:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* HIGHLIGHT TILE */
.dashboard-box.highlight {
  background: linear-gradient(135deg, #6a1b9a, #3949ab);
  color: #ffffff;
  border: none;
}

.dashboard-box.highlight h2 {
  color: #ffffff;
}

.dashboard-box.highlight p {
  color: rgba(255, 255, 255, 0.9);
}

.dashboard-box.highlight:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.25);
}

/* LOGOUT AREA */
.logout-area {
  margin-top: 30px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

.logout-button {
  background: #6a1b9a;
  color: #ffffff;
  padding: 10px 18px;
  border-radius: 10px;
  text-decoration: none;
}

.logout-button:hover {
  background: #4a148c;
}

/* DOCUMENT TILE WITH LANGUAGE BUTTONS */
.doc-box {
  display: flex;
  flex-direction: column;
  background: #f3f4f6;
  border-radius: 15px;
  padding: 20px;
  border: 1px solid #e5e7eb;
  min-height: 170px;
  overflow: hidden;
}

.doc-box h2 {
  color: #6a1b9a;
  margin-bottom: 10px;
  line-height: 1.25;
  word-break: break-word;
  overflow-wrap: break-word;
}

.doc-box p {
  color: #374151;
  margin-bottom: 15px;
}

.lang-buttons {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  width: 100%;
  margin-top: auto;
}

.lang-button {
  display: block;
  text-align: center;
  background: #6a1b9a;
  color: #ffffff;
  padding: 8px 0;
  border-radius: 8px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  transition: background 0.2s ease;
}

.lang-button:hover {
  background: #4a148c;
}

/* MOBILE */
@media (max-width: 600px) {
  .dashboard-card {
    padding: 20px;
  }

  h1 {
    font-size: 22px;
  }

  .dashboard-box {
    padding: 15px;
  }

  .logout-area {
    justify-content: center;
  }

  .selection-header {
    flex-direction: column;
    text-align: center;
  }

  .selection-header img {
    max-width: 220px;
  }
}
