/* Tabelle_corrected.css
   Kachel-Layout (auf Klassen umgestellt): .artikel statt #artikel
   Diese Datei überschreibt alte Regeln und verwendet Grid (responsive).
*/

/* Basis */
body{
  background-image: url(../Hintergrund/hintergrund_marmor.jpg);
  margin: 0;
  padding: 0;
  font-family: Helvetica, Arial, sans-serif;
  color: #333;
}

/* Überschriften */
h1, h2, h3, h4 {
  font-weight: 100;
  margin: 0;
  padding: 0;
}

h1 {
  font-size: 2.5em;
  line-height: 1.8em;
}

h2 {
  font-size: 1.563em;
  line-height: 1.8em;
}

h3 {
  font-size: 1.4em;
  text-align: center;
}

h4 {
  font-size: 1.4em;
  text-decoration: line-through;
}

/* Allgemeiner Text */
p {
  line-height: 1.4em;
  text-align: justify;
}

/* Bilder */
img {
  max-width: 100%;
  border-radius: 10px;
}

/* Header */
header {
  text-align: center;
}

header img {
  width: 10em;
}

/* Navigation */
nav {
  background: #FFFFFF;
  padding: 0.5em 0;
  text-align: center;
}

nav ul {
  padding: 0;
  margin: 0;
}

nav ul li {
  display: inline-block;
  margin: 0 0.3em;
}

nav ul li a {
  color: #454040;
  font-size: 1.125em;
  line-height: 2.2em;
  padding: 0 0.5em;
  text-decoration: none;
}

nav ul li a:hover {
  background: #DBD9D8;
  border-bottom: 3px solid #E7590B;
}

nav ul li a.active {
  border-bottom: 3px solid #E7590B;
}

/* Grid-Container: sorgt dafür, dass .artikel-Elemente Kacheln bilden */
#main{
  width: 96%;
  max-width: 1400px;
  margin: 1.5em auto;
  display: grid !important; /* wichtig, falls alte CSS 'display:block' setzt */
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.1rem;
  box-sizing: border-box;
}

/* Artikel-Kachel (Klasse!) */
.artikel{
  background: #fff;
  border-radius: 12px;
  padding: 1rem;
  text-align: center;
  border: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 3px 8px rgba(0,0,0,0.12);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  box-sizing: border-box;
  /* Stellen sicher, dass floats aus alten CSS ignoriert werden */
  float: none !important;
  width: auto !important;
}

.artikel:hover{
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.18);
}

/* Titel innerhalb der Kachel */
.titel{
  min-height: 3.6em;
  display:flex;
  align-items:center;
  justify-content:center;
  margin-bottom: 0.6rem;
}

/* Bildbereich (unten) */
.unten img{
  max-height:170px;
  width: auto;
  object-fit: contain;
  border-radius: 8px;
}

/* Badge (Neu / Angebot) */
.oben{
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
}

.oben img{
  width:48px;
  height:auto;
  display:block;
}

/* Preisbereich */
.preis{
  margin-top:0.6rem;
}

.preis h2{
  margin:0;
  font-size:1.25rem;
}

.preis h4{
  margin:0;
  color: #666;
}

/* Footer */
footer{
  background:#2F2C2C;
  width: 100%;
  padding:0.5em 0;
  text-align:center;
}

footer ul {
  padding: 0;
  margin: 0;
}

footer ul li {
  display: inline-block;
  padding: 0 0.8em;
  font-size: 0.8em;
  color: #E2DBDB;
  line-height: 2.6em;
}

footer ul li a {
  color: #E2DBDB;
}

/* Mobile Anpassungen */
@media (max-width: 750px){
  #main{
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 0.8rem;
  }

  .oben img{ width:40px; }
}

/* Optional: Wenn du der Kachel eine farbige Background-Eigenschaft aus PHP gibst,
   bitte inline style: <div class="artikel" style="background-color: #ffeedd"> */
