html {
  font-size: 100%;
}

body {
  font-family: Arial, sans-serif;
  font-size: 1rem;
  margin: 20px auto;
  max-width: 1200px;
}

h1 {
  font-size: 1.5rem;
}

button {
  font-size: 1rem;
  padding: 10px 20px;
  border: none;
  background: #333;
  color: #fff;
  cursor: pointer;
}

button:hover {
  background: #555;
}

img,
video {
  max-width: 100%;
  height: auto;
}

/* NAV */
nav {
  display: inline-block;
  padding: 10px 15px;
  border: 2px solid #333;
  border-radius: 6px;
  background-color: #f9f9f9;
}

nav a {
  margin-right: 15px;
  text-decoration: none;
  color: #333;
}

nav a.active {
  font-weight: bold;
}

/* FORMS */
form div {
  margin-bottom: 10px;
}

label {
  display: block;
  margin-bottom: 5px;
}

input[type="text"],
textarea,
select {
  width: 100%;
  padding: 8px;
  border: 1px solid #ccc;
}

input[type="checkbox"] {
  margin-right: 5px;
}

/* TABLE */
table {
  width: 100%;
  max-width: 600px;
  margin: 20px 0;
  table-layout: fixed;
  border-collapse: collapse;
  background-image: url('Háttér.jpg');
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}

th,
td {
  border: 1px solid #ccc;
  padding: 8px;
  text-align: left;
  word-wrap: break-word;
}

th:nth-child(1),
td:nth-child(1) {
  width: 30%;
}

th:nth-child(2),
td:nth-child(2) {
  width: 70%;
}

/* FLEX WITH IMAGE */
.flex-with-image {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 15px;
  margin-bottom: 20px;
}

.flex-with-image p {
  flex: 1 1 300px;
  min-width: 0;
}

.flex-with-image img {
  width: 200px;
  flex-shrink: 0;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.flex-with-image.image-left img {
  order: 0;
  margin-right: 15px;
}

.flex-with-image.image-right img {
  order: 1;
  margin-left: auto;
}

/* GALLERY */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 20px 0;
}

.gallery-grid img {
  width: 100%;
  height: auto;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  object-fit: cover;
}

/* MASZAT MAIN */
.maszat-main {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 20px;
}

.maszat-blocks {
  flex: 1 1 300px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.maszat-block {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.maszat-block img {
  width: 100px;
  flex-shrink: 0;
  border-radius: 4px;
}

.maszat-block .content {
  flex: 1;
}

.maszat-large {
  width: 350px;
  flex-shrink: 0;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

/* VIDEO AND FORM */
.video-and-form {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 20px;
  margin-top: 20px;
}

.video-and-form .video-thumb {
  max-width: 400px;
  flex-shrink: 0;
}

.video-and-form form {
  flex-grow: 1;
  max-width: 500px;
  padding: 15px;
  border: 1px solid #ccc;
  border-radius: 6px;
  background-color: #f9f9f9;
}

/* MEDIA QUERIES */
/* Mobile */
@media (max-width: 600px) {
  .flex-with-image,
  .maszat-main,
  .video-and-form,
  .table-with-image {
    flex-direction: column !important;
  }
  .maszat-large,
  .video-and-form .video-thumb {
    width: 100% !important;
  }
  .flex-with-image img,
  .maszat-block img {
    width: 100%;
    max-width: 300px;
    margin: 0 auto 10px;
    display: block;
  }
  table {
    max-width: 100% !important;
  }
}

/* Tablet */
@media (min-width: 601px) and (max-width: 900px) {
  .flex-with-image {
    flex-direction: row;
  }
  .maszat-main,
  .video-and-form {
    flex-wrap: nowrap;
  }
  .maszat-large {
    width: 300px;
  }
}

/* Desktop */
@media (min-width: 901px) {
  .flex-with-image,
  .maszat-main,
  .video-and-form {
    flex-wrap: nowrap;
  }
}
