:root {
  --uni-granate: #711610;
  --uni-granate-dark: #520f0a;
  --uni-crema: #FFFDD0;
  --text-dark: #333333;
  --text-light: #ffffff;
  --bg-light: #f9f9f9;
  --bg-dark: #222222;
}

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

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: var(--text-dark);
  line-height: 1.6;
  background-color: var(--bg-light);
}

a {
  text-decoration: none;
  color: var(--uni-granate);
  transition: color 0.3s ease;
}

a:hover {
  color: var(--uni-granate-dark);
}

/* Header */
header {
  background-color: var(--text-light);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 5%;
  transition: all 0.3s ease;
}

header.scrolled {
  padding: 10px 5%;
  background-color: rgba(255, 255, 255, 0.95);
}

.logo-container {
  display: flex;
  align-items: center;
}

.header-logo {
  max-height: 90px;
  width: auto;
  display: block;
  transition: max-height 0.3s ease;
}

header.scrolled .header-logo {
  max-height: 55px;
}

nav ul {
  list-style: none;
  display: flex;
  align-items: center;
}

nav ul li {
  margin-left: 20px;
}

nav ul li a {
  color: var(--text-dark);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 8px 12px;
  border-radius: 4px;
}

nav ul li a:hover {
  background-color: var(--uni-crema);
  color: var(--uni-granate);
}

.btn-moodle {
  background-color: var(--uni-granate);
  color: var(--text-light) !important;
  padding: 10px 20px !important;
  border-radius: 5px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: inline-block;
}

.btn-moodle:hover {
  background-color: var(--uni-granate-dark) !important;
  color: var(--uni-crema) !important;
}

/* Hero Section */
.hero {
  height: 100vh;
  background: linear-gradient(rgba(113, 22, 16, 0.3), rgba(0, 0, 0, 0.5)), url('../img/fip.jpg') center/cover no-repeat;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  color: var(--text-light);
  padding: 0 20px;
  margin-top: 60px; /* offset for fixed header */
}

.hero h1 {
  font-size: 4rem;
  font-weight: 800;
  margin-bottom: 20px;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
  max-width: 900px;
  line-height: 1.2;
}

.hero p {
  font-size: 1.5rem;
  margin-bottom: 40px;
  max-width: 700px;
  font-weight: 300;
}

.hero .btn-main {
  background-color: var(--text-light);
  color: var(--uni-granate);
  padding: 15px 30px;
  font-size: 1.1rem;
  font-weight: bold;
  border-radius: 4px;
  text-transform: uppercase;
  transition: all 0.3s ease;
}

.hero .btn-main:hover {
  background-color: var(--uni-crema);
  transform: translateY(-2px);
}

/* Featured Section */
.featured {
  padding: 80px 5%;
  background-color: var(--text-light);
}

.section-title {
  font-size: 2.5rem;
  color: var(--uni-granate);
  margin-bottom: 40px;
  text-align: center;
  font-weight: 700;
  position: relative;
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background-color: var(--uni-granate);
  margin: 15px auto 0;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.card {
  background-color: var(--bg-light);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  transition: transform 0.3s ease;
}

.card:hover {
  transform: translateY(-10px);
}

.card-img {
  height: 200px;
  background-color: #ddd;
  background-size: cover;
  background-position: center;
}

.card-content {
  padding: 25px;
}

.card-content h3 {
  font-size: 1.4rem;
  color: var(--uni-granate);
  margin-bottom: 15px;
}

.card-content p {
  color: #555;
  margin-bottom: 20px;
}

.card-link {
  font-weight: 600;
  display: inline-flex;
  align-items: center;
}

.card-link::after {
  content: '→';
  margin-left: 5px;
  transition: margin 0.3s ease;
}

.card-link:hover::after {
  margin-left: 10px;
}

/* Call to Action - Moodle */
.moodle-cta {
  background-color: var(--uni-granate);
  color: var(--text-light);
  text-align: center;
  padding: 80px 20px;
}

.moodle-cta h2 {
  font-size: 2.5rem;
  margin-bottom: 20px;
  color: var(--uni-crema);
}

.moodle-cta p {
  font-size: 1.2rem;
  margin-bottom: 30px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.moodle-cta .btn-moodle-large {
  background-color: var(--uni-crema);
  color: var(--uni-granate) !important;
  padding: 15px 40px;
  font-size: 1.2rem;
  font-weight: bold;
  border-radius: 5px;
  text-transform: uppercase;
  display: inline-block;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.moodle-cta .btn-moodle-large:hover {
  background-color: #fff;
  transform: scale(1.05);
}

/* Footer */
footer {
  background-color: var(--bg-dark);
  color: var(--text-light);
  padding: 60px 5% 20px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-col h4 {
  color: var(--uni-crema);
  font-size: 1.2rem;
  margin-bottom: 20px;
  text-transform: uppercase;
}

.footer-col p {
  color: #ccc;
  margin-bottom: 10px;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 10px;
}

.footer-col ul li a {
  color: #ccc;
}

.footer-col ul li a:hover {
  color: var(--text-light);
  padding-left: 5px;
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid #444;
  color: #888;
  font-size: 0.9rem;
}

@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }
  nav ul {
    display: none; /* simple mobile hide for now */
  }
}

/* Feed Styles */
.feed-value {
  font-size: 2.5rem;
  font-weight: bold;
  color: #2e7d32;
  margin: 15px 0;
}
.feed-card {
  border-top: 4px solid var(--uni-granate);
  text-align: center;
}
#industry-news-feed {
  font-size: 0.95rem;
  color: #444;
  margin-top: 15px;
  text-align: left;
}

/* Modal Styles */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}
.modal-overlay.active {
    display: flex;
}
.modal-content {
    background: white;
    width: 90%;
    max-width: 600px;
    border-radius: 8px;
    padding: 20px;
    position: relative;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}
.modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    background: transparent;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
}
.iframe-container {
    width: 100%;
    height: 400px;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}
.iframe-container iframe {
    width: 100%;
    height: 100%;
}
