:root {
  --primary: #4caf50;
  --primary-dark: #3e8e41;
  --secondary: #333;
  --accent: #ffb200;
  --light-bg: #f5f5f5;
  --input-border: #e0e0e0;
  --text-dark: #212121;
  --text-light: #ffffff;
  --error: #d32f2f;
  --shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  --section-padding: 1.5rem;
  --input-padding: 0.75rem;
  --element-margin: 0.75rem;
}

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

html {
  height: 100%;
}

body {
  font-family: "Roboto", sans-serif;
  line-height: 1.6;
  color: var(--text-dark);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin: 0;
}

/* Header */
.header {
  display: flex;
  justify-content: center;
  align-items: center;
  background: var(--secondary);
  padding: 10px 20px;
  position: fixed;
  top: 0;
  width: 100%;
  height: 70px;
  z-index: 1000;
  box-shadow: var(--shadow);
}

.header img {
  height: 40px;
  margin: 0 15px;
  transition: transform 0.3s ease;
}

.header img:hover {
  transform: scale(1.05);
}

/* Main layout */
.container {
  flex: 1;
  display: flex;
  margin-top: 70px;
}

/* Left side - Hero */
.left-container {
  flex: 1;
  background:
    linear-gradient(rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.2)),
    url("images/ourense.webp") center/cover no-repeat;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 40px;
  color: var(--text-light);
  position: relative;
}

.title-box h1 {
  font-size: 3.5rem;
  margin-bottom: 20px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  line-height: 1.2;
}

.sub-title-box p {
  font-size: 1.5rem;
  max-width: 80%;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.festival-logo img {
  position: relative;
  width: 800px;
  height: auto;
  z-index: 1;
  filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.5));
}

/* Right side - Form */
.right-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: white;
}

.top-box {
  background: var(--light-bg);
  padding-top: 100px;
  padding-left: 30px;
  padding-bottom: 30px;
  font-size: 1.1rem;
}

.top-box p {
  margin-bottom: 15px;
  max-width: 600px;
}

.middle-box {
  padding: 30px;
}

legend {
  font-size: 1.8rem;
  font-weight: bold;
  margin-bottom: 25px;
  color: var(--secondary);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.form-group {
  margin-bottom: 15px;
}

label {
  display: block;
  font-weight: 500;
  margin-bottom: 8px;
}

input {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--input-border);
  border-radius: 4px;
  font-size: 1rem;
  transition: all 0.3s ease;
}

input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.2);
}

.bottom-box {
  background: var(--light-bg);
  padding: 30px;
}

button {
  background: var(--primary);
  color: white;
  border: none;
  padding: 15px 30px;
  font-size: 1.1rem;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: var(--shadow);
}

button:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
}

.login-prompt {
  margin-top: 20px;
  color: var(--text-dark);
  font-size: 1rem;
  font-weight: normal;
  letter-spacing: normal;
}

.login-prompt a {
  color: var(--primary);
  text-decoration: none;
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: normal;
}

.login-prompt a:hover {
  text-decoration: underline;
}

/* Unified Footer */
.unified-footer {
  background: var(--secondary);
  color: #ffffff;
  padding: 1.5rem 0;
  position: static;
  bottom: auto;
  width: 100%;
  margin-top: auto;
  font-family:
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    Oxygen,
    Ubuntu,
    Cantarell,
    "Open Sans",
    "Helvetica Neue",
    sans-serif;
  z-index: 1000;
  flex-shrink: 0;
  letter-spacing: normal;
}

.unified-footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.unified-footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
}

.unified-footer-left p {
  margin: 0;
  opacity: 0.8;
  font-size: 0.85rem;
}

.unified-footer-right-section {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.unified-footer-social h4 {
  margin: 0 0 0.5rem 0;
  font-size: 0.75rem;
  opacity: 0.7;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.unified-social-links {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.unified-social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
  transition:
    background-color 0.2s ease,
    transform 0.2s ease;
}

.unified-social-links a:hover {
  background-color: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

.unified-social-links svg {
  width: 16px;
  height: 16px;
  fill: #ffffff;
  opacity: 0.9;
}

.unified-footer-repo a {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: #ffb200;
  text-decoration: none;
  opacity: 0.9;
  transition: opacity 0.2s ease;
  font-size: 0.85rem;
}

.unified-footer-repo a:hover {
  opacity: 1;
  text-decoration: underline;
}

.unified-footer-repo svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* GitHub FAB */
.github-fab {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 56px;
  height: 56px;
  background-color: #3d3d3d;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transition:
    transform 0.2s ease,
    background-color 0.2s ease;
  z-index: 1001;
  text-decoration: none;
  border: none;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.github-fab:hover {
  transform: scale(1.1);
  background-color: #555555;
}

.github-fab svg {
  display: block;
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  fill: currentColor;
}

/* Responsive Footer */
@media (max-width: 600px) {
  body {
    padding-bottom: 0;
    padding-top: 0;
    min-height: 100vh;
    min-height: 100dvh;
    overflow-x: hidden;
  }

  h1 {
    font-size: 1.5rem;
    padding-bottom: 10px;
  }

  button {
    font-size: 1.3rem;
  }

  .unified-footer {
    position: relative;
    margin-top: auto;
  }

  .unified-footer-content {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }

  .unified-footer-right-section {
    flex-direction: column;
    gap: 1rem;
  }

  .unified-social-links {
    justify-content: center;
  }

  .github-fab {
    bottom: 20px;
  }
}

/* Responsive design */
@media (max-width: 1024px) {
  .container {
    flex-direction: column;
  }

  .left-container {
    min-height: 50vh;
    align-items: center;
    text-align: center;
    padding: 20px;
  }

  .sub-title-box p {
    max-width: 100%;
  }

  .festival-logo {
    position: relative;
    top: auto;
    right: auto;
    margin: 20px 0;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .top-box {
    padding-top: 30px;
  }
}

@media (max-width: 768px) {
  .header {
    height: 60px;
    padding: 5px 10px;
  }

  .header img {
    height: 25px;
    margin: 0 5px;
  }

  .container {
    margin-top: 60px;
    min-height: calc(100vh - 60px - 15px);
  }

  .left-container {
    padding: 20px;
  }

  .title-box h1 {
    font-size: 2.5rem;
  }

  .sub-title-box p {
    font-size: 1.2rem;
  }

  .festival-logo img {
    width: 300px;
  }

  .top-box {
    padding: 20px;
    padding-top: 20px;
  }

  .middle-box,
  .bottom-box {
    padding: 20px;
  }
}

@media (max-width: 480px) {
  .title-box h1 {
    font-size: 2rem;
  }

  .sub-title-box p {
    font-size: 1rem;
  }

  .festival-logo img {
    width: 300px;
  }

  button {
    padding: 12px 24px;
    font-size: 1rem;
  }
}
