/* latin-ext */
@font-face {
  font-family: 'Lato';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/static/fonts/lato-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
  font-family: 'Lato';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/static/fonts/lato-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

body {
    background-color: white;
    color: #333;
    font-family: 'Lato';
    margin: 0;
    /* Full-height flex column so a short page still pushes the footer to the */
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-height: 100dvh;
}

h1 {
  text-align: center;
  font-size: 1.5 rem;
}

main {padding: 1em; flex: 1 0 auto}

#messages {
  width: 100%;
}

.message {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5em 1em;
  font-size: 0.9rem;
}

.message-close {
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 0 0.3em;
  margin: 0;
  color: inherit;
  font-weight: bold;
}

.message-success {
  background-color: #d4edda;
  color: #155724;
}

.message-info {
  background-color: #d1ecf1;
  color: #0c5460;
}

.message-warning, .warning {
  background-color: #fff3cd;
  color: #856404;
}

.message-error {
  background-color: #f8d7da;
  color: #721c24;
}

.message-debug {
  background-color: #e2e3e5;
  color: #383d41;
}

a {color:black}
a:hover {color: #EF7B00}

button, .button {
  background-color: black;
  color: white;
  border: none;
  text-transform: uppercase;
  text-decoration: none;
  margin: 1em;
  padding: 0.5em;
  font-weight: bold;
  border-radius: 0.2em;
  cursor: pointer;
}

.menu-button {
  background: none;
  color: black;
  text-transform: none;
  font-weight: normal;
  border-radius: 0;
  margin: 0;
  padding: 0;
  font-size: 1rem;
  font-family: inherit;
}
.menu-button:hover {
  color: #EF7B00;
}

.action-button {
  background-color: green;

}

form {
  display: block;
  margin: 1em auto;
  max-width: 40em;
}


form.table-form {max-width: none}

label {display: block}
input[type="checkbox"],
input[type="checkbox"] + label,
:has(> input[type="checkbox"]) > label {
  display: inline;
  width: auto;
}
input {
  display: block;
  width: 100%;
  border: 1px solid black;
  border-radius: 0;

}

table {
  border: 1px solid #aaa;
  border-collapse: collapse;
  margin: 0;
  padding: 0;
  width: 100%;
  table-layout: fixed;
}


table tr {
  background-color: #f8f8f8;
  border: 1px solid #ddd;
  padding: .35em;
}
table th,
table td {
  padding: .625em;
  text-align: center;
  border: 1px solid #eee
}

table th {
  font-size: .85em;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.icon-inline {height: 2em; vertical-align: middle}

#nav-logo {
    max-height: 50px;
    max-width: 15rem;
}

#user-nav {
  text-align: left;
}

#user-nav form, #user-nav form button {
  display: inline;
  cursor: pointer;
  margin: 1em;
}

#user-nav a {
  display: inline-block;
  margin: 1em;
  text-decoration: none;
}

@media (min-width: 60rem) {
  #nav-logo {float: left}
  #topnav {margin: 0.5rem 1rem; height: 50px}
  #user-nav {text-align: center}
}

#motto {
    background-color: #EF7B00;
    color: black;
    font-size: 1.2rem;
    text-align: center;
    margin:0; padding: 0.1em;
    text-transform: uppercase;
    width: 100%
}

footer {
    border-top: 5px solid #EF7B00;
    width: 100%;
    text-align: center;
    font-size: 1.3rem;
    padding: 0.5em 0
}

#footer-logo {height:3em; vertical-align: middle}

footer a {
    display: inline-block;
    margin: 0.2em 2em;
    text-decoration: none;
    color: #333;
}


#copyright {
  background-color: #EF7B00;
  text-transform: uppercase;
  padding: 0.2em
}

#event-list {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 1rem;
}

/* Each event */
a:has(> .event-card),
a:has(> .event-card):hover {
  text-decoration: none;
  color: inherit;
}
a:has(> .event-card):hover .event-card {
  background-color: #fff3e0;
}

.event-card {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 0.5rem;
    background-color: #fff;
    text-align: center;
}

/* Title styling */
#event-list h2 {
    font-size: 1.2rem;
    margin: 0.5rem 0;
    max-width: 300px;
    height: 1.5rem;
    overflow: hidden;
}

.event-image, .event-placeholder {
    height: 300px;
    width: 300px;
    object-fit: cover;
    border-radius: 4px;
}

.event-placeholder {
    background-color: #eee;
    color: #666;
    display: flex;
    align-items: center;
    justify-content: center;
    font-style: italic;
    border-radius: 4px;
}

/* Event detail page */

#event-detail-container {
  display: flex;
  flex-direction: column;
  padding: 1rem;
}

#event-detail-title {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 1rem;
}

#event-detail-location {text-align: center}

#event-detail-main {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

#event-detail-left,
#event-detail-tickets {
  width: 100%;
}

#event-gallery {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

#event-gallery a img {
  height: auto;
  cursor: pointer;
}

.event-video {
  position: relative;
  display: block;
}

/* Marks the still as a video rather than another photograph. */
.event-video::after {
  content: "▶";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 2rem;
  line-height: 1;
  color: #fff;
  text-shadow: 0 0 0.5rem rgba(0, 0, 0, 0.8);
  pointer-events: none;
}

#event-video-dialog {
  border: none;
  padding: 0;
  background: transparent;
}

#event-video-dialog video {
  display: block;
  max-width: 90vw;
  max-height: 80vh;
}

#event-description {
  /*max-height: 4.5em;*/
  overflow: hidden;
  position: relative;
}

#event-description.expanded {
  max-height: none;
}

#event-read-more {
  margin-top: 0.5rem;
  cursor: pointer;
  display: hidden;
}


.ticket-holder {
  border-bottom: 1px solid #aaa;
  padding: 0 0 0.5em 0;
}

.remove-item {
  background-color: white;
  color: #c00;
  font-size: 0.75em;
  padding: 0.2em 0.5em;
  margin: 0.2em 0;
  border: 1px solid #c00;
}

.ticket-unavailable .item-input button {
  background-color: #777;
}

.ticket-unavailable, .ticket-unavailable .item-input {
  color: #777;
  border-color: #777
}

/* Ensure the container uses flexbox for layout */
.item-input {
    display: flex; /* Enables flexbox */
    align-items: center; /* Vertically centers items if content height varies */
}

/* Set a uniform height for all direct children of the container, based on the input's border height */
.item-input > * {
    height: 100%; /* Ensures all direct children (buttons and input) have equal height to the container */
    display: flex; /* Enables flexbox on each child for potential inner content alignment */
    align-items: center; /* Vertically centers content in each child if needed */
}

.item-input input {
  -webkit-appearance: textfield;
  -moz-appearance: textfield;
  appearance: textfield;
}

/* Ensure buttons are only as tall as the border of the input, not its contents */
.item-decrement, .item-increment {
    height: 100%; /* Full height of the container (which is based on the input's border) */
    display: flex; /* Enables flexbox for potential inner content alignment in buttons */
    align-items: center; /* Vertically centers any content in the button */
    justify-content: center; /* Horizontally centers any content in the button */
}

.item-decrement, .item-increment {
  color: white;
  background-color: black;
  cursor: pointer;
  font-weight: bold;
  border: none;
}


/* Responsive Layouts */

@media (min-width: 600px) {
  #event-detail-main {
    flex-direction: row;
  }
  #event-read-more {
    display: none;
  }
}

@media (min-width: 600px) and (max-width: 1023px) {
  #event-detail-main {
    justify-content: space-between;
  }
  #event-detail-left,
  #event-detail-tickets {
    flex: 1;
  }
  #event-description {
    max-height: none;
  }

}

@media (min-width: 1024px) {
  #event-detail-main {
    gap: 2rem;
  }

  #event-detail-left {
    flex: 2;
  }

  #event-detail-tickets {
    flex: 1;
  }
}


#event-contact {
  text-align: center;
  margin-top: 1.5rem;
  padding: 0.5em 0;
}

#event-contact-details {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-evenly;
}

#event-contact-details p {
  white-space: nowrap;
}

#event-map {
  height: 300px;
  margin: 1em 0;
}

.ticket {margin: 1em; padding:1em; border: 1px solid #aaa}

@media print {
  body {visibility: hidden}
  main {visibility: visible; position: absolute; margin: 0}
  .noprint {visibility: hidden}
  .ticket {break-inside: avoid;}
}
