.vote-container {
  /* Use flexbox to center the form card horizontally and vertically */
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  min-height: 100%;
  background-color: #f8f8f8
}

.vote-container .vote-card-wide {
  /* The card container */
  width: 100%;
  box-sizing: border-box; /* keep the 40px padding inside the 100% width */
  max-width: 800px; /* Max width for a clean look on large screens */
  padding: 40px;
  background-color: #ffffff; /* White background for the card */
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); /* Subtle shadow */
  border-radius: 8px;
}
h1
{
  font-size: 1.5em;
}
h1 i
{
  font-weight: normal;
  font-size: 1em;
}

h2
{
  font-size: 1.25em;
}
h3
{
  font-size: 1.25em;
}
.observer-note
{
  -moz-border-radius: 0.5rem;
  -webkit-border-radius: 0.5rem;
  border-radius: 0.5rem;
  background-color: #f0f7fb;
  /* background-image: url("../Images/icons/Pencil-48.png"); */
  /* background-position: 9px 0px; */
  /*background-repeat: no-repeat; */
  /*     border: solid 1px #3498db;*/
  /* line-height: 18px; */
  overflow: hidden;
  padding: 0.5rem 0.75rem 1rem 1rem;
  margin-bottom: 1rem;
  width: min(60rem, 90%);
}

.vote-box {
  border-style: solid;
  border-width: 1px;
  margin: 1rem;
  padding-top: 0rem;
  padding-right: 1rem;
  padding-bottom: 1rem;
  padding-left: 1rem;
  margin: 0;
  width: min(60rem, 90%);
  background-color: #ffffcb;
  border-radius: 0.2rem;
}

.vote_row {
  display: flex;
  flex-wrap: wrap;
  gap: 0; /* spacing between elements */
  align-items: center; /* vertical alignment */
}

.vote_element {
  display: flex;
  flex-direction: column; /* stack abbr on top of vote */
  align-items: center; /* center text under each element */
  padding: 4px;
  border: 1px solid #ccc;
  min-width: 7ch; /* Fit "Pending" */
}

.vote_abbr {
  font-weight: bold;
  margin-bottom: 5px;
}

.vote_vote {
  color: gray;
}

.reviewer-comment {
  width: min(60rem, 95%);
  height: 4rem;
}

.accordion {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 1rem;
  margin: 0;
  width: min(60rem, 90%);
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.accordion h2 {
  margin-bottom: 16px;
  font-size: 1.25em;
}

.accordion details {
  background-color: #e6f4ff; /* light blue background */
  border: 1px solid #b3daff; /* optional border (slightly darker) */
  border-radius: 8px;        /* rounded corners */
  margin-bottom: 8px;
  overflow: hidden;
  padding: 4px;              /* small padding inside the blue box */
}
/*
.accordion summary {
  cursor: pointer;
  padding: 10px 15px;
  background-color: transparent;
  font-weight: bold;
  outline: none;
}
*/

details {
  margin-bottom: 14px;
}

summary {
  font-weight: bold;
  cursor: pointer;
  padding: 8px;
  border-radius: 5px;
  transition: background 0.15s;
}

summary:hover {
  background: #f0f0f0;
}

details[open] summary {
  background: #e7e7e7;
}

details p {
  margin: 8px 0 0 16px;
  color: #333;
}

.external-links
{
  -moz-border-radius: 0.5rem;
  -webkit-border-radius: 0.5rem;
  border-radius: 0.5rem;
  background-color: #f0f7fb;
  /* background-image: url("../Images/icons/Pencil-48.png"); */
  /* background-position: 9px 0px; */
  /*background-repeat: no-repeat; */
  /*     border: solid 1px #3498db;*/
  /* line-height: 18px; */
  overflow: hidden;
  padding: 0.5rem 0.75rem;
  width: fit-content
}

.back_button
{
  display: inline-block;
  font-size: 1.5rem;
  margin-top: 1rem;
  margin-bottom: 1.5rem;
  background: #c2d0ff;
  color: black;
  padding: 0.25rem;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
  border-radius: 0.5rem;
}

/* Sticky footer holding the Back button and Edit link. Negative margins
   cancel the card's 40px padding so the bar spans the full card width and
   sits flush with its bottom edge. */
.vote-footer {
  position: sticky;
  bottom: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 1.5rem -40px -40px;
  padding: 0.75rem 40px;
  background: rgb(255 255 255 / 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-top: 1px solid #e5e7eb;
  border-radius: 0 0 8px 8px;
  box-shadow: 0 -4px 12px rgb(15 23 42 / 0.06);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

.vote-footer a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.5rem;
  margin: 0;
  padding: 0 1rem;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  border-radius: 0.5rem;
  transition: background-color 0.15s ease, border-color 0.15s ease,
              transform 0.05s ease;
}

.vote-footer a:active {
  transform: translateY(1px);
}

.vote-footer a:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}

/* Back: quiet secondary button with a leading arrow */
.vote-footer .back_button {
  color: #374151;
  background: #fff;
  border: 1px solid #d1d5db;
}

.vote-footer .back_button::before {
  content: "\2190";
  font-size: 1.1em;
}

.vote-footer .back_button:hover {
  background: #f3f4f6;
  border-color: #9ca3af;
}

/* Edit: primary action, pushed to the right */
.vote-footer .edit_button {
  margin-left: auto;
  color: #fff;
  background: #2563eb;
  border: 1px solid #2563eb;
}

.vote-footer .edit_button:hover {
  background: #1d4ed8;
  border-color: #1d4ed8;
}

@media (max-width: 420px) {
  .vote-footer {
    padding-inline: 1rem;
  }

  .vote-footer a {
    padding: 0 0.75rem;
  }
}

.dynamic-iframe-wrapper {
  position: relative;
  width: 100%;
  /* Fallback or max width constraint if needed */
  aspect-ratio: 4 / 3;
}

.dynamic-iframe-wrapper iframe {
  width: 100% !important;
  height: 100% !important;
  border: none;
}

/* On mobile screens where text wrapping causes vertical stretching */
@media (max-width: 700px) {
  .dynamic-iframe-wrapper {
    min-height: 500px;  /* Gives it enough breathing room so scrollbars vanish */
  }
  
  .dynamic-iframe-wrapper iframe {
    height: 500px; /* Forces a safe mobile height */
  }
}
