/* Basic Reset & Body - Mobile First */
body {
  font-family: 'Cooper Black', Arial, sans-serif;
  background-color: #111;
  color: #ccc;
  margin: 0;
  padding: 0;
  line-height: 1.6;
  font-size: 16px; /* Base font size for mobile */
}

.container {
  width: 100%;
  /* max-width: 1024px; Applied in media query */
  margin: 0 auto;
  padding: 1em;
  box-sizing: border-box;
}

header, main, footer {
  width: 100%;
}

img, video {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Header */
header img {
  width: 100%;
  height: auto;
}

/* Common Navigation - Mobile */
.main-nav {
  background-color: #333;
  padding: 0.5em 1em; /* Adjusted padding */
  text-align: right; /* Align hamburger to the right */
  margin-bottom: 1em;
  position: relative; /* Needed for absolute positioning of links */
}

.hamburger {
    display: block; /* Show hamburger on mobile */
    background: none;
    border: none;
    color: #eee;
    font-size: 1.8em; /* Make icon larger */
    cursor: pointer;
    padding: 0.2em 0.4em;
}

.nav-links {
    display: none; /* Hide links by default on mobile */
    width: 100%;
    background-color: #444; /* Background for dropdown */
    position: absolute; /* Position dropdown below */
    left: 0;
    top: 100%; /* Position below the nav bar */
    z-index: 10;
    text-align: center;
}

.main-nav.open .nav-links {
    display: block; /* Show links when nav has .open class */
}

.nav-links a {
  color: #eee;
  text-decoration: none;
  padding: 0.8em 1em; /* Padding for touch */
  font-weight: bold;
  display: block; /* Stack links vertically */
  border-bottom: 1px solid #555; /* Separator */
  font-size: 1em;
  margin: 0; /* Remove horizontal margin */
}

 .nav-links a:last-child {
    border-bottom: none;
}

.nav-links a:hover, .nav-links a.active {
  background-color: #555;
}

/* Footer */
footer {
  background: url('imagenes/BackStars.gif');
  color: #fff;
  text-align: center;
  padding: 1em;
  margin-top: 2em;
  font-weight: bold;
}

/* Headings & Links */
h1, h2, h3 {
  color: #FF6633;
  font-size: 1.5em; /* Adjust heading sizes for mobile */
}
h1 { font-size: 1.8em; }
a { color: #FF9900; }
a:hover { color: #FFCC66; }
.text-center { text-align: center; }
.text-justify { text-align: justify; }
.highlight { color: #FF6633; font-weight: bold; }
.light-text { color: #CCCCCC; }

/* Page Specific: index.html - Mobile */
.player-container {
    background-color: #000;
    padding: 1em;
    margin-bottom: 1em;
    border: 1px solid #444;
    text-align: center;
}

.player-container iframe {
    border: none;
    max-width: 100%;
    width: 100%; /* Make iframe take full width on mobile */
    height: 110px; /* Keep original height */
}

.info-text {
    text-align: center;
    font-size: 1.1em;
    font-weight: bold;
    margin-bottom: 1em;
}

/* Page Specific: conocer.html */
.team-grid {
  display: grid;
  grid-template-columns: 1fr; /* Single column on mobile */
  gap: 1.5em;
  background-color: #000;
  padding: 1em;
  border: 1px solid #444;
}

.team-member {
  background-color: #222;
  padding: 1em;
  border-radius: 5px;
  text-align: justify;
}

.team-member img {
  margin-bottom: 1em;
  border-radius: 5px;
}

.team-member h3 {
  text-align: center;
  margin-top: 0;
}

.team-member p {
  font-size: 0.9em;
}

/* Page Specific: historia.html */
.history-content {
  display: flex;
  flex-direction: column; /* Stack elements vertically on mobile */
  gap: 1.5em;
  background-color: #000;
  padding: 1em;
  border: 1px solid #444;
}

.history-text {
  text-align: justify;
}

.history-images {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); /* Responsive images */
  gap: 1em;
}

.history-images figure {
    margin: 0;
    text-align: center;
}

.history-images img {
    border: 1px solid #555;
    margin-bottom: 0.5em;
}

.history-images figcaption {
    font-size: 0.9em;
    color: #aaa;
}

/* Page Specific: eventos.html */
.event-list {
    list-style: none;
    padding: 0;
}

.event-list li {
    background-color: #222;
    margin-bottom: 1em;
    padding: 1em;
    border-left: 5px solid #FF6633;
    border-radius: 4px;
}

.event-list strong {
    color: #FF9900;
}

/* Page Specific: noticias.html */
main video,
.responsive-video {
    width: 100%;
    height: auto;
    max-width: 1000px;
    display: block;
    margin: 1em auto;
    background-color: #000;
    border: 1px solid #555;
}
}

hr {
    border: 0;
    height: 1px;
    background: #555;
    margin: 2em 0;
}

/* Page Specific: contactar.html */
.contact-info {
    text-align: center;
    margin-bottom: 1.5em;
    font-size: 1.1em;
    font-weight: bold;
}

.contact-info a {
    color: #FF9900; /* Match link color */
    text-decoration: none;
}

.contact-info a:hover {
    text-decoration: underline;
}

.map-container {
    text-align: center;
}

.map-container img {
    /* max-width: 900px; Applied in media query */
    margin: 0 auto; /* Center the map image */
    border: 1px solid #444;
}


/* Tablet and Desktop Styles */
@media (min-width: 768px) {
    body {
        font-size: 18px; /* Slightly larger base font */
    }
    .container {
         max-width: 1024px; /* Apply max-width */
    }

    /* Navigation Desktop */
    .main-nav {
        text-align: center; /* Center links on desktop */
        padding: 0.5em 0; /* Restore padding */
    }
    .hamburger {
        display: none; /* Hide hamburger on desktop */
    }
    .nav-links {
        display: block; /* Always show links container */
        position: static; /* Reset positioning */
        background-color: transparent; /* Reset background */
        width: auto; /* Reset width */
    }
    .nav-links a {
        display: inline-block; /* Display links horizontally */
        padding: 0.5em 1em; /* Restore original padding */
        margin: 0 0.5em; /* Restore horizontal margin */
        border-bottom: none; /* Remove separator */
    }
    .nav-links a:hover, .nav-links a.active {
      background-color: #555;
      border-radius: 4px; /* Keep rounded corners for desktop */
    }

    /* Headings Desktop */
    h1, h2, h3 { font-size: 1.8em; } /* Adjust heading sizes */
    h1 { font-size: 2.2em; }

    /* Index Desktop */
    .player-container iframe {
         width: 400px; /* Restore fixed width for player */
    }

    /* Conocer Desktop */
    .team-grid {
      grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); /* Restore grid */
    }

    /* Historia Desktop */
    .history-content {
      flex-direction: row; /* Side-by-side layout */
    }
    .history-text {
      flex: 1;
      min-width: 250px;
    }
    .history-images {
      flex: 2;
      min-width: 300px;
      grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }

    /* Contactar Desktop */
    .map-container img {
        max-width: 900px; /* Limit map size */
    }
}
