/* App specific layout and components styling */

/* Header styling */
.site-header {
  color: #fff;
  padding: 10px 0;
  /* Removed box-shadow */
}

.header-container {
  background-color: var(--header-bg); /* Moved background here */
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100px; /* Explicit height for vertical centering */
  gap: 20px; /* Added gap between logo and nav */
  /* Removed flex-wrap: wrap; to keep logo and nav on one line */
}

.logo-container {
  margin-left: 2em; /* Add 2em margin to the left of the logo */
}

.logo-container .logo {
  height: 60px;
  width: auto;
}

.main-nav .nav-list {
  list-style: none;
  display: flex;
  gap: 20px;
  flex-wrap: nowrap; /* Ensure nav links don't wrap prematurely */
}

.nav-link {
  color: #fff;
  font-weight: bold;
  padding: 8px 12px;
  border-radius: 4px;
  transition: background-color 0.2s, color 0.2s;
}

.nav-link:hover, .nav-link.active {
  background-color: var(--nav-hover);
  color: var(--irks-yellow);
}

/* Home Page */
.hero-section {
  padding: 10px 0; /* Changed top padding to 10px */
  /* Removed border: 2px dashed red; */
  max-width: 1200px; /* Match container width */
  margin: 0 auto; /* Center it */
}

.hero-logo {
  width: 100%;
  max-width: 1200px; /* Set max width to 1200px */
  height: auto; /* Maintain aspect ratio */
  object-fit: contain; /* Ensure image is fully visible */
  margin-bottom: 20px;
}

.hero-title {
  font-size: 4.5rem; /* Increased font size */
  color: var(--irks-blue);
  width: 90%; /* Span 90% of container */
  margin: 0 auto; /* Center it */
  text-shadow: 
    4px 4px 8px rgba(0, 0, 0, 0.7), /* Original Bigger drop shadow */
    -1px -1px 0 #fff,
    1px -1px 0 #fff,
    -1px 1px 0 #fff,
    1px 1px 0 #fff; /* Added White text outline */
}

.hero-subtitle {
  font-size: 3rem; /* Slightly smaller */
  margin-bottom: 30px;
  color: var(--irks-red); /* Changed to red */
  text-shadow: 
    4px 4px 8px #000; /* 100% black drop shadow */
}

.hero-divider {
  border: none;
  height: 2px;
  background-color: var(--irks-blue);
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
}

.welcome-section {
  max-width: 960px;
  margin: 0 auto 40px auto;
  font-size: 1.1rem;
  color: var(--irks-blue); /* Match 'Indian River Kontrol Society' color */
  background-color: rgba(255, 255, 255, 0.5); /* 50% opaque white */
  padding: 20px; /* Add some padding for better appearance */
  border-radius: 8px; /* Optional: add some rounded corners */
  box-shadow: 0 4px 8px rgba(0,0,0,0.1); /* Optional: add a subtle shadow */
}

.welcome-section p {
  margin-bottom: 15px;
}

/* Cards */
.action-cards {
  display: flex;
  justify-content: center;
  gap: 30px;
  flex-wrap: wrap;
  margin-top: 40px;
  /* Removed border: 2px dashed red; */
}

.card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 25px;
  width: 100%;
  max-width: 300px;
  box-shadow: 0 4px 6px rgba(0,0,0,0.05);
  text-align: center;
  transition: transform 0.2s;
  overflow: hidden; /* Ensure image stays within card boundaries */
}

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

.card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.card-link:hover {
  text-decoration: none;
  color: inherit;
}

.contact-card-img {
  width: 100px; /* Fixed width */
  height: 100px; /* Fixed height */
  border-radius: 8px; /* Square with rounded corners */
  object-fit: cover; /* Cover the area, cropping if necessary */
  margin-bottom: 15px; /* Space below image */
  display: block; /* Ensures margin auto works */
  margin-left: auto;
  margin-right: auto;
}

.card h3 {
  font-size: 1.25rem;
  color: var(--irks-blue);
}

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

.btn {
  display: inline-block;
  background-color: var(--irks-blue);
  color: #fff;
  padding: 10px 20px;
  border-radius: 4px;
  font-weight: bold;
  transition: background-color 0.2s;
}

.btn:hover {
  background-color: var(--nav-hover);
  color: #fff;
}

/* Footer styling */
.site-footer {
  background-color: rgba(59, 89, 143, 0.6); /* 60% opaque #3b598f */
  border-top: 5px solid var(--irks-blue);
  padding: 40px 0 20px 0;
  margin-top: auto;
  /* Removed box-shadow: 0 4px 6px rgba(0,0,0,0.1); */
}

.footer-affiliations {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  margin-bottom: 30px;
  flex-wrap: wrap;
}

.affiliation-logo {
  height: 80px;
  width: auto;
  object-fit: contain;
}

.footer-copyright {
  font-size: 0.9rem;
  color: #000; /* Set to 100% black */
}

.footer-copyright p {
  margin-bottom: 5px;
}

.footer-contact a {
  color: var(--irks-blue);
  font-weight: bold;
}

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

/* Responsive adjustments */
@media (max-width: 768px) {
  .header-container {
    display: flex; /* Ensure flex behavior */
    flex-direction: row; /* Keep items in a row */
    flex-wrap: nowrap; /* Prevent wrapping */
    justify-content: space-between; /* Logo left, other elements right */
    align-items: center; /* Vertically align items */
    height: 60px; /* Set height for small screens */
  }
  
  .logo-container {
    margin-bottom: 15px;
  }

  .hamburger-center-wrapper {
    /* flex-grow: 1; Removed */
    display: flex;
    /* justify-content: center; Removed */
    align-items: center;
    margin-right: 2em; /* Add 2em margin to the right */
  }
  
  .main-nav .nav-list {
    justify-content: center;
  }
  
  .hero-title {
    font-size: 2.25rem; /* 50% of 4.5rem */
  }
  
  .hero-subtitle {
    font-size: 1.5rem; /* 50% of 3rem */
  }
  
  .action-cards {
    flex-direction: column;
    align-items: center;
  }

  .card {
    max-width: 90%; /* Allow cards to span wider on small screens, with a slight margin */
    width: 100%; /* Ensure it takes full available width */
  }
}

/* Reports Aggregator */
.reports-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  text-align: left;
}

@media (min-width: 768px) {
  .reports-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .report-hero {
    grid-column: span 3;
  }
  .report-sidebar {
    grid-column: span 1;
  }
  .report-main-bottom {
    grid-column: span 2;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

@media (max-width: 639px) {
  .report-main-bottom {
    grid-template-columns: 1fr;
  }
}

.report-card {
  background-color: #f9fafb;
  padding: 20px;
  border-left: 4px solid #ccc;
  border-radius: 4px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.report-card h3 {
  font-size: 1rem;
  margin-bottom: 15px;
  text-decoration: underline;
  text-align: left;
}

.report-hero {
  border-left-color: var(--irks-red);
}
.report-hero h3 { color: #b91c1c; }

.report-vp { border-left-color: #2563eb; }
.report-vp h3 { color: #1d4ed8; }

.report-safety { border-left-color: #16a34a; }
.report-safety h3 { color: #15803d; }

.report-rep-sec { border-left-color: #ea580c; }
.report-rep-sec h3 { color: #c2410c; }

.report-mem-sec { border-left-color: #9333ea; }
.report-mem-sec h3 { color: #7e22ce; }

.report-treasurer { border-left-color: #3b82f6; }
.report-treasurer h3 { color: #2563eb; }

.report-content {
  line-height: 1.6;
  white-space: pre-wrap;
  text-align: left;
}

.email-view {
  background-color: #fff !important;
  box-shadow: none !important;
  max-width: 800px;
}

/* Page Specific Content Styles */
.page-content {
  padding: 20px; /* Adjusted padding */
  background-color: #fff; /* White background */
  border-radius: 8px; /* Rounded corners */
  box-shadow: 0 4px 8px rgba(0,0,0,0.1); /* Subtle shadow */
  max-width: 900px; /* Constrain width for better readability */
  margin: 20px auto; /* Center it with some top/bottom margin */
}

/* Membership Form Styles */
.membership-form {
  max-width: 600px;
  margin: 40px auto;
  background-color: #F5F5DC; /* Beige background */
  padding: 30px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

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

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: bold;
  color: #333;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"] {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 1rem;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group input[type="tel"]:focus {
  border-color: var(--irks-blue);
  outline: none;
  box-shadow: 0 0 0 2px rgba(0, 0, 160, 0.2); /* Subtle focus ring */
}

.membership-form .btn {
  width: auto;
  padding: 12px 25px;
  font-size: 1.1rem;
}

.membership-form .btn:hover {
  background-color: var(--nav-hover);
}

.page-title {
  font-size: 2.5rem;
  margin-bottom: 30px;
}

.section-title {
  font-size: 1.8rem;
  margin: 30px 0 20px 0;
}

.divider {
  border: none;
  height: 2px;
  background-color: var(--irks-blue);
  width: 100%;
  max-width: 800px;
  margin: 40px auto;
}

.info-section {
  max-width: 800px;
  margin: 0 auto;
  font-size: 1.1rem;
}

.info-section p {
  margin-bottom: 15px;
}

/* Contact Grid Layout */
.contact-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  margin: 0 auto;
  max-width: 900px;
}

.contact-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 20px;
  width: 100%;
  max-width: 250px;
  text-align: center;
  box-shadow: 0 4px 6px rgba(0,0,0,0.05);
  overflow: hidden; /* Ensure content stays within the card */
}

.contact-card h3 {
  font-size: 1.1rem;
  margin-bottom: 15px;
  color: var(--irks-blue);
}

.contact-name {
  font-weight: bold;
  font-size: 1.2rem;
  margin-bottom: 5px;
  word-break: break-word; /* Allow long words to break and wrap */
}

.contact-phone {
  margin-bottom: 10px;
  color: #555;
}

.contact-email {
  color: var(--irks-blue);
  font-weight: bold;
  word-break: break-all;
}

.contact-email:hover {
  text-decoration: underline;
}

/* Resource List */
.resource-list {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.resource-list h2 {
  margin-bottom: 20px;
}

.resource-list p {
  margin-bottom: 15px;
}

.resource-link {
  color: var(--irks-blue);
  font-weight: bold;
  font-size: 1.1rem;
}

.resource-link:hover {
  text-decoration: underline;
  color: var(--irks-red);
}

.mt-4 {
  margin-top: 2rem;
}

.mt-2 {
  margin-top: 1rem;
}

.text-sm {
  font-size: 0.9rem;
}

.justify-center {
  justify-content: center;
}

.inline-block {
  display: inline-block;
}

/* Helper classes */
.mb-12 { margin-bottom: 3rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-6 { margin-top: 1.5rem; }
.ml-2 { margin-left: 0.5rem; }
.font-bold { font-weight: bold; }
.italic { font-style: italic; }
.text-lg { font-size: 1.125rem; }
.text-xl { font-size: 1.25rem; }
.whitespace-nowrap { white-space: nowrap; }
.max-w-4xl { max-width: 56rem; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* Responsive Table */
.table-container {
  overflow-x: auto;
  margin: 0 auto;
  box-shadow: 0 4px 6px rgba(0,0,0,0.05);
  border-radius: 8px;
  background: #fff;
}

.events-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.events-table th,
.events-table td {
  padding: 12px 15px;
  border-bottom: 1px solid #ddd;
}

.events-table th {
  background-color: var(--irks-blue);
  color: #fff;
  font-weight: bold;
}

.events-table tbody tr:nth-of-type(even) {
  background-color: #f3f4f6;
}

.events-table tbody tr:hover {
  background-color: #f1f5f9;
}

.events-table .row-closed td {
  background-color: #fee2e2;
  color: #991b1b;
}

/* Mobile responsive table adjustments */
@media screen and (max-width: 768px) {
  .events-table {
    border: 0;
  }

  .events-table thead {
    display: none;
  }

  .events-table tr {
    display: block;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background-color: #fff !important; /* overrides nth-child styling on mobile */
  }

  .events-table td {
    display: block;
    text-align: right;
    border-bottom: 1px solid #eee;
  }

  .events-table td:last-child {
    border-bottom: 0;
  }

  .events-table td::before {
    content: attr(data-label);
    float: left;
    font-weight: bold;
    text-transform: uppercase;
    color: var(--irks-blue);
  }
}

/* FileUpload Specific Styles */
.drop-zone {
  border: 2px dashed #ccc;
  border-radius: 8px;
  padding: 40px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 20px;
  position: relative; /* For absolute positioning of input */
  background-color: rgba(255, 255, 255, 0.8); /* Semi-transparent white */
}

.drop-zone:hover {
  border-color: var(--irks-blue);
  background-color: rgba(255, 255, 255, 0.9);
}

.drop-zone.dragging {
  border-color: var(--irks-red);
  background-color: rgba(255, 255, 255, 0.95);
}

.file-list {
  margin-top: 20px;
  text-align: left;
  background-color: rgba(255, 255, 255, 0.8); /* Semi-transparent white */
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.file-list ul {
  list-style: none;
  padding: 0;
}

.file-list li {
  margin-bottom: 5px;
  padding: 5px 0;
  border-bottom: 1px dashed #eee;
}

.file-list li:last-child {
  border-bottom: none;
}

/* PicFrame styles */
.pic-frame-container {
  width: 100%;
  max-width: 1200px; /* Match container/image-card max width */
  background-color: #000;
  margin: 2rem auto; /* Center it with auto margins */
  overflow: hidden;
  box-shadow: 0 4px 8px rgba(0,0,0,0.3); /* Match general card shadows */
  border-radius: 8px; /* Optional: match the rounded corners of other cards */
}

.pic-frame-inner {
  width: 100%;
  height: 500px;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.pic-frame-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 1s ease-in-out;
}

@media (max-width: 768px) {
  .pic-frame-inner {
    height: 300px;
  }
}
