/* FWS Global Styles - Light Mist Green Theme */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Times New Roman", Times, serif;
  font-size: 12pt;
  color: #1a1a1a;
  background: #d0e8d0;
}

/* Header */
.site-header {
  background: #b5cfb5;
  color: #1a1a1a;
  padding: 10px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #8aaa8a;
}

.site-header .site-title {
  font-size: 26pt;
  font-weight: bold;
  color: #1a1a1a;
}

.site-header .user-area {
  display: flex;
  align-items: center;
  gap: 12px;
}

.site-header .user-email {
  font-size: 11pt;
  color: #5a5a00;
}

/* Auth buttons in header */
.auth-btn {
  padding: 5px 14px;
  border: none;
  background: #6b6b1e;
  color: #fff;
  font-family: "Times New Roman", Times, serif;
  font-size: 11pt;
  cursor: pointer;
}

.auth-btn:hover {
  background: #8a8a28;
}

/* Navigation */
.site-nav {
  background: #c4dcc4;
  padding: 0;
  display: flex;
  justify-content: flex-start;
  border-bottom: 2px solid #8aaa8a;
}

.site-nav a {
  color: #1a1a1a;
  text-decoration: underline;
  padding: 10px 18px;
  font-size: 13pt;
  display: inline-block;
  transition: color 0.2s;
}

.site-nav a:hover {
  color: #3a3a00;
}

.site-nav a.active {
  color: #000;
  font-weight: bold;
}

.site-nav a.disabled {
  color: #888;
  pointer-events: none;
  cursor: default;
  text-decoration: none;
}

/* Main content */
.main-content {
  max-width: 900px;
  margin: 8px auto;
  background: transparent;
  padding: 5px 40px 5px 20px;
  min-height: 400px;
}

.page-title {
  font-size: 26pt;
  text-align: center;
  margin-bottom: 6px;
  color: #1a1a1a;
}

/* Action buttons row */
.action-buttons {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 24px;
}

.btn {
  padding: 6px 20px;
  font-family: "Times New Roman", Times, serif;
  font-size: 12pt;
  cursor: pointer;
  border: none;
  background: #6b6b1e;
  color: #fff;
  min-width: 80px;
}

.btn:hover {
  background: #8a8a28;
}

.btn:disabled {
  background: #aaa;
  cursor: default;
}

.btn-danger {
  background: #7a2020;
}

.btn-danger:hover {
  background: #9a2828;
}

.btn-save {
  background: #1e6b1e;
}

.btn-save:hover {
  background: #288a28;
}

/* Form fields */
.form-group {
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.form-group label {
  width: 160px;
  text-align: right;
  font-weight: bold;
  flex-shrink: 0;
  color: #1a1a1a;
}

.form-group input,
.form-group select,
.form-group textarea {
  font-family: "Times New Roman", Times, serif;
  font-size: 12pt;
  padding: 4px 8px;
  border: 1px solid #7a9a7a;
  border-radius: 0;
  background: #f0f8f0;
  color: #1a1a1a;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #6b6b1e;
  box-shadow: 0 0 3px rgba(107,107,30,0.35);
}

/* Search-mode highlight: fields that can be typed into for a VIEW search */
.field-search {
  background: #d6eeff !important;
  border-color: #5599cc !important;
}

/* Field sizes based on character widths from requirements */
.field-4  { width: 60px; }
.field-2  { width: 40px; }
.field-3  { width: 50px; }
.field-5  { width: 70px; }
.field-15 { width: 180px; }
.field-20 { width: 230px; }
.field-25 { width: 280px; }
.field-35 { width: 370px; }
.field-50 { width: 500px; }

/* Inline fields */
.form-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.form-inline label {
  width: auto;
  text-align: left;
}

/* Results table */
.results-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 16px;
}

.results-table th,
.results-table td {
  padding: 8px 12px;
  border: 1px solid #8aaa8a;
  text-align: left;
}

.results-table th {
  background: #6b6b1e;
  color: #fff;
  font-weight: bold;
}

.results-table tr:nth-child(even) {
  background: #c0d8c0;
}

.results-table tr:hover {
  background: #b4cfb0;
}

/* Scrollable results area */
.results-area {
  max-height: 500px;
  overflow-y: auto;
  border: 1px solid #8aaa8a;
  margin-top: 16px;
}

/* Status messages */
.status-msg {
  text-align: center;
  padding: 10px;
  margin: 10px 0;
}

.status-msg.success {
  background: #c0e0c0;
  color: #1a4a1a;
  border: 1px solid #6aaa6a;
}

.status-msg.error {
  background: #e8c0c0;
  color: #4a1a1a;
  border: 1px solid #aa6a6a;
}

/* Footer */
.site-footer {
  text-align: center;
  padding: 20px;
  color: #4a4a4a;
  font-size: 11pt;
  margin-top: 40px;
}

/* Modal overlay for login/register */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.45);
  z-index: 100;
  justify-content: center;
  align-items: center;
}

.modal-overlay.active {
  display: flex;
}

.modal {
  background: #e0eee0;
  padding: 30px;
  border: 1px solid #8aaa8a;
  width: 400px;
  max-width: 90%;
}

.modal h2 {
  text-align: center;
  margin-bottom: 20px;
  font-size: 18pt;
  color: #1a1a1a;
}

.modal .form-group {
  flex-direction: column;
  align-items: stretch;
}

.modal .form-group label {
  width: auto;
  text-align: left;
  margin-bottom: 4px;
}

.modal .form-group input {
  width: 100%;
}

.modal .btn {
  width: 100%;
  margin-top: 12px;
}

.modal .close-btn {
  background: transparent;
  border: none;
  font-size: 18pt;
  float: right;
  cursor: pointer;
  color: #555;
}

.modal .close-btn:hover {
  color: #000;
}

/* Wide horizontal modals (register / login) */
.modal-wide {
  width: auto;
  max-width: 95%;
}

.modal-field-row {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.modal-field-row input {
  flex: 1;
  min-width: 0;
  font-size: 18pt;
  padding: 6px 10px;
  height: auto;
}

.modal-wide .btn {
  width: auto;
  display: block;
  margin: 12px auto 0;
}

/* Photo preview */
.photo-preview {
  margin-top: 12px;
  text-align: center;
}

.photo-preview img {
  max-width: 400px;
  max-height: 300px;
  border: 1px solid #7a9a7a;
}

/* Home page content */
.home-block {
  width: fit-content;
  margin: 0 auto;
}

.home-intro {
  font-style: italic;
  margin-bottom: 12px;
  color: #1a1a1a;
}

.home-intro .highlight {
  background: #6b6b1e;
  color: #fff;
  padding: 1px 5px;
  font-style: normal;
}

.home-list {
  padding-left: 28px;
  list-style-position: outside;
  line-height: 2.2;
}

.home-list li {
  display: flex;
  align-items: baseline;
  padding: 0;
}

.home-list a {
  color: #5a5a00;
  text-decoration: underline;
  display: inline-block;
  min-width: 90px;
  flex-shrink: 0;
}

.home-list a:hover {
  color: #3a3a00;
}

.home-desc {
  line-height: 1.2;
}

/* Home page table layout */
.home-table {
  border-collapse: separate;
  border-spacing: 0 2px;
  font-size: 1.08rem;
}

.home-table td {
  vertical-align: top;
  padding: 2px 0;
  line-height: 1.4;
}

.home-btn {
  white-space: nowrap;
  padding-right: 6px !important;
}

.home-btn a {
  color: #5a5a00;
  text-decoration: underline;
  font-weight: bold;
  display: inline-block;
  min-width: 80px;
}

.home-btn a:hover {
  color: #3a3a00;
}

.home-dash {
  padding: 4px 10px !important;
  white-space: nowrap;
  color: #555;
}

.home-note {
  font-size: 0.95rem;
  color: #666;
  font-style: italic;
}

/* Contact page */
.webmaster-info {
  text-align: center;
  line-height: 1.2;
  font-size: 13pt;
  margin-bottom: 28px;
  color: #1a1a1a;
}

.webmaster-info .wm-label {
  font-weight: bold;
  font-size: 14pt;
}

.contact-send-section {
  border-top: 1px solid #8aaa8a;
  padding-top: 20px;
}

.contact-send-title {
  text-align: left;
  font-size: 14pt;
  font-weight: bold;
  margin-bottom: 20px;
  margin-left: 5ch;
  color: #1a1a1a;
}

.contact-form-wrap {
  width: fit-content;
  margin-left: 5ch;
}

.contact-form-wrap .form-group label {
  text-align: left;
  width: 90px;
}

.contact-wide-field {
  font-family: "Times New Roman", Times, serif;
  font-size: 12pt;
  padding: 4px 8px;
  border: 1px solid #7a9a7a;
  background: #f0f8f0;
  color: #1a1a1a;
  width: calc(580px - 9ch);
}

.contact-message-field {
  font-family: "Times New Roman", Times, serif;
  font-size: 12pt;
  padding: 6px 8px;
  border: 1px solid #7a9a7a;
  background: #f0f8f0;
  color: #1a1a1a;
  width: calc(580px - 9ch);
  min-height: 160px;
  resize: vertical;
  overflow-y: auto;
  line-height: 1.5;
}

.contact-wide-field:focus,
.contact-message-field:focus {
  outline: none;
  border-color: #6b6b1e;
  box-shadow: 0 0 3px rgba(107,107,30,0.35);
}

/* Family table — auto-width columns, no wrapping in data cells */
.family-table {
  width: auto;
}

.family-table th {
  text-align: center;
  white-space: normal;
  padding: 6px 10px;
}

.family-table td {
  white-space: nowrap;
  padding: 6px 10px;
}

/* Member clone section */
.clone-section {
  margin: 14px 0 20px 0;
  padding: 10px 16px 12px 16px;
  background: #e4efe4;
  border: 1px dashed #7a9a7a;
}

.clone-header {
  font-weight: bold;
  margin-bottom: 8px;
  color: #1a1a1a;
}

.clone-or {
  color: #555;
  font-style: italic;
  padding: 0 6px;
  white-space: nowrap;
}

.clone-row {
  margin-top: 6px;
  flex-wrap: nowrap;
  align-items: center;
}

/* Event announce divider */
.announce-divider {
  border: none;
  border-top: 1px dashed #8aaa8a;
  margin: 18px 0 14px 0;
}

/* Report page */
.report-instructions {
  margin-bottom: 10px;
  line-height: 2;
}

.report-instructions ol {
  padding-left: 24px;
  line-height: 1.2;
  margin: 0;
}

.report-instructions ol li {
  margin-bottom: 3px;
}

.report-fields {
  margin: 8px 0 10px 0;
  display: inline-block;
}

.report-field-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 4px;
}

.report-field-row input[type="checkbox"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: #6b6b1e;
  flex-shrink: 0;
}

.report-field-row label {
  font-size: 12pt;
  cursor: pointer;
  color: #1a1a1a;
  min-width: 220px;
}

.report-field-note {
  color: #555;
  font-size: 10.5pt;
  font-style: italic;
}

.report-group-row {
  margin-top: 4px;
}

/* Photo lightbox */
.lightbox-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.88);
  z-index: 200;
  justify-content: center;
  align-items: center;
}

.lightbox-overlay.active {
  display: flex;
}

.lightbox-overlay img {
  max-width: 95vw;
  max-height: 92vh;
  object-fit: contain;
  touch-action: pinch-zoom;
  cursor: default;
  box-shadow: 0 0 40px rgba(0,0,0,0.8);
}

.lightbox-close {
  position: fixed;
  top: 16px;
  right: 24px;
  font-size: 36pt;
  color: #fff;
  background: transparent;
  border: none;
  cursor: pointer;
  line-height: 1;
  opacity: 0.85;
  z-index: 201;
}

.lightbox-close:hover {
  opacity: 1;
}

#photo-img {
  cursor: zoom-in;
}

/* Photo notes */
.photo-notes p {
  color: #4a4a4a;
  font-size: 12pt;
  margin: 0 0 3px 0;
}

/* Info page textarea */
.info-textarea {
  font-family: "Courier New", Courier, monospace;
  font-size: 11pt;
  width: calc(80ch + 18px);
  display: block;
  padding: 8px;
  border: 1px solid #7a9a7a;
  background: #f0f8f0;
  color: #1a1a1a;
  resize: none;
  overflow-x: hidden;
  overflow-y: auto;
  line-height: 1.4;
  white-space: pre;
}

.info-textarea:focus {
  outline: none;
  border-color: #6b6b1e;
  box-shadow: 0 0 3px rgba(107,107,30,0.35);
}
