
@charset "UTF-8";
body {
    margin: 0;
    font-family: Arial, sans-serif;
}

header {
    background-color: #003366;
    color: white;
    padding: 10px 20px;
}

.title-area {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.title {
    font-size: 24px;
    font-weight: bold;
    background-color: #003366;
}

nav {
    flex-grow: 1;
    display: flex;
    justify-content: center;
    gap: 20px;
}

nav a {
    color: white;
    text-decoration: none;
    font-size: 16px;
    padding: 5px 10px;
}

nav a:hover {
    text-decoration: underline;
}

.auth-buttons button {
    color: blue;
    background-color: white;
    border: 1px solid blue;
    padding: 5px 10px;
    margin-bottom: 5px;
    cursor: pointer;
    font-size: 16px;
}

.auth-buttons button:hover {
    background-color: lightgray;
}

main {
    padding: 20px;
}

.dialog {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.dialog.hidden {
    display: none;
}

.dialog-content {
    background: #a9e7d4;
    padding: 20px;
    border-radius: 8px;
    width: 300px;

    max-height: 90vh;
    overflow-y: auto;

    display: flex;
    flex-direction: column;
    gap: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.dialog-content h2 {
    margin: 0;
    color: #003366;
}

.dialog-content label {
    font-weight: bold;
}

.dialog-actions button {
    width: 100%;
    color: white;
    background-color: #003366;
    border: none;
    padding: 10px;
    cursor: pointer;
}

.dialog-actions button:hover {
    background-color: #0055a5;
}

/* Center the Add Pick dialog */
.ap-dialog {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%); /* Center the dialog */
    background: #a9e7d4;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    width: 360px;
}

/* Additional CSS styles for new forms */
#add-item-form, #search-form, #contactForm {
  padding: 20px;
  margin-bottom: 5px;
  margin-left: auto;
  margin-right: auto;
  width: 80%;
  display: block;
  /*background: #f4f4f4;*/
  background: #a9e7d4;
  border: 1px solid #ddd;
  border-radius: 8px;
}

#add-item-form h2, #search-form h2 {
  color: #003366;
}

#add-pick-panel,
#edit-pick-panel {
  margin-bottom: 5px;
  padding: 20px;
  margin: 20px auto;
  margin-top: 0px;
  width: 80%;            /* like contact form */
  background: #a9e7d4;
  border: 1px solid #ddd;
  border-radius: 8px;
}

button:disabled {
  background: lightgray;
  color: gray;
  cursor: not-allowed;
}

/* Contact handling */
#contactForm h2 {
    color: #003366;
}

button:disabled {
    background: lightgray;
    color: gray;
    cursor: not-allowed;
}

#contactForm {
    /*padding: 20px;
    margin: 20px;*/
    /*background: #f4f4f4;*/
    border: 1px solid #ddd;
    border-radius: 8px;
}

#contact-list {
    margin-top: 20px;
}

#contacts {
    list-style: none;
    padding: 0;
}

#contacts li {
    padding: 10px;
    margin: 5px 0;
    background: #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#contacts li button {
    margin-left: 10px;
}

#contact-dropdown-container {
    margin-top: 20px;
}

#contact-dropdown {
    width: 100%;
    max-height: 150px;
    overflow-y: auto;
    border: 1px solid #ddd;
    padding: 5px;
}

#edit-contact-btn {
    margin-top: 10px;
    background-color: #003366;
    color: white;
    border: none;
    padding: 8px;
    cursor: pointer;
}

#edit-contact-btn:disabled {
    background-color: lightgray;
    cursor: not-allowed;
}

/* Generic inline panel style (like your contactForm) for Edit and Add a Pick forms */
.panel {
  display: none;         /* start hidden */
  padding: 16px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  max-width: 820px;      /* tune to taste */
  margin: 12px auto;     /* center-ish; or remove auto to align left */
}

.panel h2 { margin-top: 0; }
.panel .actions { margin-top: 12px; }

.hidden { display: none !important; } /* you already use this; keep consistent */
.panel.hidden { display: none !important; }
.panel:not(.hidden) { display: block; } /* visible when .hidden removed */

/* g popup dialog for edit contact selection */
.modal {
    display: none; /* Hidden by default */
    position: fixed; /* Stay in place */
    z-index: 1; /* Sit on top */
    left: 0;
    top: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Enable scroll if needed */
    background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
  }
  
  .modal-content {
    background: #a9e7d4;
    border: 1px solid #ddd;
    border-radius: 8px;
    /*background-color: #fefefe;*/
    margin: 15% auto; /* 15% from the top and centered */
    padding: 20px;
    /*border: 1px solid #888;*/
    width: 30%; /* Could be more or less (was 80%) */
    max-height: 500px; /* Set a maximum height */
    overflow-y: auto; /* Make the content scrollable */
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
  }

  .modal-message {
    margin-bottom: 1rem;
    font-size: 1rem;
  }
  
  .modal-actions {
    display: flex;
    justify-content: space-between;
  }
  
  .danger-button {
    background-color: #c62828;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
  }
  
  .danger-button:hover {
    background-color: #b71c1c;
  }
  
  #cancel-unsubscribe {
    background-color: #ddd;
    color: #333;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
  }
  
  #cancel-unsubscribe:hover {
    background-color: #ccc;
  }
  
  .close {
    color: #aaa;
    float: right;
    font-size: 1em;  /* was 28px; */
    font-weight: bold;
  }
  
  .close:hover,
  .close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
  }
  
  ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
  }
  
  li {
    padding: 8px 16px;
    border-bottom: 1px solid #ddd;
    cursor: pointer;
  }
  
  li:hover {
    background-color: #f1f1f1;
  }

  /* popup that times out */
  .timeout-popup {
    /* apply 3 second hiding animation after 10 second delay */
    animation: hide 2s 1s forwards;
  
    /* fix popup at the center of screen, optional style */
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: aquamarine;
  
    padding: 20px;
    /* dimming entire screen except popup */
    outline: 100vmax solid #ccc;
  }
  
  @keyframes hide {
    from {
      opacity: 1;
    }
    to {
      opacity: 0;
    }
  }

.gp-dialog {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    font-size: 14px;
  }

  .gp-dialog.hidden {
    display: none;
  }

  .gp-dialog-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
  }

  .gp-dialog-content {
    background: #a9e7d4;
    padding: 10px;
    border-radius: 8px;
    width: 380px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    overflow: hidden;
  }

  .gp-dialog-scrollable {
    overflow-y: auto;
    flex-grow: 1;
  }

  .gp-dialog-content h2 {
    margin: 0;
    color: #003366;
  }

  .gp-dialog-content label,
  .gp-dialog-content h3 {
    font-weight: bold;
    margin: 0.5rem 0 0.25rem;
  }

  .gp-dialog-content select,
  .gp-dialog-content textarea,
  .gp-dialog-content input[type="text"] {
    width: 100%;
    min-height: 1.5rem;
    padding: 4px;
    font-size: 0.9rem;
    box-sizing: border-box;
  }

  .gp-dialog-header {
    font-size: 0.9rem;
    font-weight: bold;
    display: flex;
    align-items: baseline;
    gap: 5px;
    margin-bottom: 4px;
  }

  .inline-action {
    background: none;
    border: none;
    color: #0055cc;
    text-decoration: underline;
    cursor: pointer;
    font-size: inherit;
    font-weight: bold;
    padding: 2px 6px;
    border-radius: 4px;
    transition: all 0.2s ease;
  }

  .inline-action.selected {
    color: white;
    background-color: #0055cc;
    text-decoration: none;
    box-shadow: 0 0 2px #003f99;
  }

  .align-text {
    position: relative;
    top: -1px;
  }

  button {
    font-size: 0.9rem;
    padding: 0.4rem;
    margin-top: 0.5rem;
  }

  button#close-group-dialog {
    background: rgb(191, 191, 240);
    margin-top: 10px;
    border-radius: 6px;
  }

  button#close-group-dialog:hover {
    background: rgba(18, 88, 137, 0.589);
  }
/* newer menu system changed from all buttons */

/* Style the navigation bar */
.menu-bar {
    display: flex;
    gap: 15px;
}

/* Dropdown Button */
.menu-button {
    background-color: #003366;
    color: white;
    border: none;
    padding: 10px 15px;
    font-size: 16px;
    cursor: pointer;
}

/* Dropdown container */
.dropdown {
    position: relative;
    display: inline-block;
}

/* Dropdown content */
.dropdown-content {
    display: none;
    position: absolute;
    background-color: white;
    min-width: 180px;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2);
    z-index: 1;
    border-radius: 5px;
}

/* Dropdown links */
.dropdown-content a {
    color: #003366;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
}

/* Hover behavior */
.dropdown:hover .dropdown-content {
    display: block;
}

/* Hover styling for dropdown items */
.dropdown-content a:hover {
    background-color: #f1f1f1;
}

/* for hovering over a list of picks to be deleted in 
   order to see who each pick is shared with */
/* Tooltip container /
.tooltip {
    position: absolute;
    background: rgba(0, 51, 102, 0.9);
    color: white;
    padding: 10px;
    border-radius: 5px;
    font-size: 14px;
    display: none;
    max-width: 250px;
    white-space: normal;
    z-index: 1000;
    transition: opacity 0.2s ease-in-out;
}

/* Show tooltip when visible /
.tooltip.visible {
    display: block;
    opacity: 1;
    pointer-events: auto; /* Allows interaction with tooltip /
} */

/* Styling for pick list container */
.pick-list {
    width: 100%;
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid #ddd;
    padding: 5px;
    background: white;
}

/* Individual pick item styling */
.pick-item {
    padding: 8px 8px 8px 5px;
    font-size: 16px;
    cursor: pointer;
    border-bottom: 1px solid #ddd;
    transition: background 0.2s ease-in-out;
}

/* Hover effect for pick items */
.pick-item:hover {
    background-color: #003366;
    color: white;
    font-weight: bold;
}

/* Style for the thick line separator */
.pick-item.category-separator {
    /* Clear the thin border from the previous item's bottom or use this instead of the thin one */
    border-top: 2px solid #003366; /* Thicker, prominent line */
    margin-top: 10px; /* Add some vertical spacing above the new category */
    padding-top: 10px; /* Add padding below the thick line */
}

/* Ensure the top item of the list doesn't get unnecessary padding/border if not sorted by category */
.pick-list .pick-item:first-child {
    border-top: none !important;
    margin-top: 0 !important;
    padding-top: 10px; /* Standard top padding */
}
/* The class to indicate a selected item /
.pick-item.selected {
    background-color: #3f51b5; /* A visual indication that the item is selected /
    color: white; /* Ensures text is readable /
}*/

/* Pick form container */
.pick-form {
    margin-top: 10px;
}

/* Hidden template container */
.hidden {
    display: none;
}

/* and specifically when searching for a pick */
a.pick-link {
    color: #0055cc;
    text-decoration: underline;
  }
  
  a.pick-link:visited {
    color: #0055cc; /* same color so they don’t appear "clicked" */
  }

/* Tooltip styling */
.tooltip {
    position: absolute;
    background: rgba(0, 51, 102, 0.9);
    color: white;
    padding: 8px;
    margin-left: 30px;
    border-radius: 5px;
    font-size: 14px;
    display: none;
    max-width: 300px;
    white-space: normal;
    z-index: 1000;
    pointer-events: none; /* this is correct */
    transition: opacity 0.2s ease-in-out;
}

/* Show tooltip */
.tooltip.visible {
    display: block;
    opacity: 1;
}

/* Keep pick sharing select boxes tall enough */
#pick-sharing-dialog .dialog-content select#share-target {
  min-height: 10rem;    /* fallback if size gets overridden */
  width: 100%;
  box-sizing: border-box;
}

/* ensures visible height even before options arrive */
#pick-select {
  min-height: 2.25rem; /* ~1 row; use 3.0rem for ~2 rows */
  display: block;      /* avoids flex/grid collapsing in some layouts */
}


/* Increase the hover area for selectable picks */
#delete-pick-list option {
    padding: 5px 5px 5px 3px; /* was 10px */
    font-size: 16px;
    /*line-height: 1.8;*/
    cursor: pointer;
    /*transition: background 0.2s ease-in-out;*/
}

/* Highlight option when hovered */
#delete-pick-list option:hover {
    background-color: #003366;
    color: #a9e7d4;
    font-weight: bold;
    /*position: relative;*/
    left: 20px;
}

/* for the unsharing a pick dialog */
/* Keep width calculations sane and hide micro-overflow */
#unshare-pick-dialog .dialog-content {
  box-sizing: border-box;
  overflow-x: hidden;     /* prevent the tiny horizontal scroll */
  min-width: 520px;       /* tiny nudge wider; tweak as needed */
}

/* If any flex/grid child was forcing overflow */
#unshare-pick-dialog .pick-list { min-width: 0; }

/* Persistent selection look (applies to all pick lists) */
.pick-list .pick-item.selected,
.pick-list .pick-item.selected:hover {
  background-color: #e6f0ff;   /* light blue */
  color: #002244;              /* readable on light bg */
  font-weight: 600;
  outline: 1px solid #7aa3ff;       /* crisper frame */
  box-shadow: 0 0 0 2px #e6f0ff,     /* feathered halo matching bg */
              0 0 0 1px #bcd3ff inset;
  border-radius: 6px;                /* soften corners */
}

/* Placeholder rows */
.pick-list .pick-item.empty {
  color: #6b7280;
  font-style: italic;
  cursor: default;
  pointer-events: none;
  background: #fafafa;
}

/* The separator container for pick categories when the delete picks list is displayed and sorted */
.category-header {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 15px 0 5px 0;
    color: #003366; /* Match your theme blue */
    font-size: 0.75rem; /* Smaller font */
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    pointer-events: none; /* User can't click the header */
}

/* The lines on the left and right */
.category-header::before,
.category-header::after {
    content: '';
    flex: 1;
    border-bottom: 2px solid #003366; /* Thicker line */
}

/* The spacing around the category name */
.category-header:not(:empty)::before {
    margin-right: .5em;
}

.category-header:not(:empty)::after {
    margin-left: .5em;
}

/* for book label pick selection */
/* Multi-select container */
.multi-select {
    position: relative;
    width: 100%;
}

/* Readonly display input */
.multi-select input[readonly] {
    width: 100%;
    padding: 8px;
    cursor: pointer;
    border: 1px solid #ccc;
    background: #fff;
}

/* Dropdown checkbox list */
.multi-select .dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    max-height: 200px;
    overflow-y: auto;
    background: #fff;
    border: 1px solid #ccc;
    padding: 10px;
    z-index: 999;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.multi-select .dropdown label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
}

.multi-select .dropdown.hidden {
    display: none;
}

/* on signup if a username is already taken */
.error-text {
    color: red;
    font-size: 12px;
}
.success-text {
    color: green;
    font-size: 12px;
}  

/* this is for making menu items look disabled */
.is-disabled {
  color: gray;
  pointer-events: auto; /* prevent clicks */
  text-decoration: none; /* remove underline for clarity */
  opacity: 0.5; /* make it look inactive */
  cursor: default;  /* or non-allowed; */
}


/*
option:ckecked, option:hover {
    color:lightgray;
}*/
/*
selected option {
    color: lightgray;
}*/

/* temp 
.pick-form {
    border: 2px dashed green;
    margin: 10px;
    padding: 10px;
  }
*/