/* =======================================================================
   BASE — Mobile first
   =======================================================================*/

.header {
    display: flex;
    flex-wrap:wrap;
    align-items:center;
    /*border:2px solid red;*/
    /*background-color: #ffffff;*/
    margin-top: 10px;
    margin-bottom: 10px;

}

.header .rl{
    display:flex;
    justify-content: space-between;
    align-items:center;

}

.header .image {
    background: url("iaeste-logo.png")
    no-repeat;
    background-size: cover;
    width: 152px;
    height: 46px;
    /*border:2px solid green;*/
    margin: 10px;
    align-items:center;
}

.header .text {
    /*border:2px solid blue;*/
    display: inline-block;
    color:#0b3d59;

}

.header .rtext {
    /*border:2px solid orange;*/
    display: inline-block;
    margin: 5px;
}

body {
  font-family: Arial, sans-serif;
  margin: 10px;
  padding: 0;
  font-size: 16px;                 /* Base size larger for mobile */
  background: #fafafa;
}

/* =======================================================================
   FILTERS — Optimiert für Handy
   =======================================================================*/

#filters {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

#filters select {
  width: 100%;
  padding: 14px 12px;
  font-size: 1.1rem;
  border-radius: 8px;
  border: 1px solid #ccc;
  background: white;
}

/* =======================================================================
   CARDS — Mobile friendly
   =======================================================================*/

.card {
  background: white;
  border: 1px solid #ddd;
  border-radius: 12px;
  padding: 18px;
  margin: 1px 0;
  cursor: pointer;
  font-size: 1.05rem;
  line-height: 1.4;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.card strong {
  font-size: 1.2rem;               /* Bigger title */
  display: inline-block;
  margin-bottom: 6px;
}

.card em {
  display: block;
  font-size: 1rem;
  color: #666;
  margin-bottom: 3px;
}

/* Hover nur für Desktop */
@media (hover: hover) {
  .card:hover {
    background-color: #f3f3f3;
    transform: scale(1.01);
  }
}

/* =======================================================================
   MODAL — Mobile First
   =======================================================================*/

.modal {
  display: none;
  position: fixed;
  inset: 0;
  background-color: rgba(0,0,0,0.6);
  padding: 15px;
  z-index: 2000;
}

.modal-content {
  background: white;
  border-radius: 14px;
  padding: 10px;
  
  @media (min-width: 800px) {
    padding: 20px;
  }
  width: 100%;
  max-width: 95%;
  margin: 40px auto;
  max-height: 85vh;
  overflow-y: auto;
  font-size: 1.05rem;
}

.close {
  float: right;
  font-size: 28px;
  font-weight: bold;
  margin-top: -5px;
  cursor: pointer;
}

/* =======================================================================
   DESKTOP EXTRAS
   =======================================================================*/

@media (min-width: 800px) {

  body {
    max-width: 900px;
    margin: 20px auto;
    font-size: 16px;
  }

  #filters {
    flex-direction: row;
    flex-wrap: wrap;
  }

  #filters select {
    flex: 1 1 200px;
    font-size: 1rem;
  }

  .card {
    padding: 20px;
    font-size: 1rem;
  }
}

/*immer nur 1 Karte */
#cardsContainer {
  display: grid;
  grid-template-columns: 1fr;
  row-gap: 6px;      /* vertikal */
  column-gap: 12px;  /* horizontal */
}