
/* The source art is 585x426 black line work. Height-only sizing keeps its real
   proportions (the old fixed 100x70 box with padding squashed it), and the
   invert repaints it white so it reads on the charcoal theme everywhere. */
#logo {
    display: block;
    height: 34px;
    width: auto;
    filter: brightness(0) invert(1);
    opacity: .9;
    transition: opacity .15s ease;
}

a:hover > #logo { opacity: 1; }

@media (min-width: 640px) {
    #logo { height: 42px; }
}

/* Same treatment as #logo, scaled down for the cart header. */
.cart-logo {
    display: block;
    height: 24px;
    width: auto;
    filter: brightness(0) invert(1);
    opacity: .9;
}

#backup-code-list {
    font-family: monospace;
}

@media print {
    .navbar {
        visibility: hidden;
        display: none;
    }
}

.form-label {
    font-size: 16px !important;
}


.card-hover {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-hover:hover {
  transform: translateY(-5px); /* subtle lift */
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15); /* stronger shadow */
}

.card-title {
  color: #f4f4f5;
}

.cart-link .bi-cart4 {
  display: inline-block;
  transition: transform 0.2s ease;
  cursor: pointer;
}

.cart-link:hover .bi-cart4 {
  transform: scale(1.1);
}

.cart-badge {
  font-size: 0.75rem;        /* smaller text */
  width: 1.5rem;             /* fixed size */
  height: 1.5rem;            /* makes it a perfect circle */
  display: flex;             /* center the number */
  align-items: center;
  justify-content: center;
  border: 2px solid white;   /* optional: nice outline */
  box-shadow: 0 0 3px rgba(0,0,0,0.3); /* subtle shadow */
}

.table-responsive {
  overflow: visible !important;
}

/* Product management modals (charcoal theme) */
.modal-dialog:has(.product-modal) {
  width: min(94vw, 860px);
  max-width: 860px;
}

/* Single-field modals (add a category/color) don't need the full 860px. */
.modal-dialog:has(.product-modal--compact) {
  width: min(94vw, 440px);
  max-width: 440px;
}

.product-modal {
  color: #f4f4f5;
  border: 0;
  border-radius: .85rem;
  overflow: hidden;
  background: #27272a;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .55);
}

.product-modal__header {
  padding: 1rem 1.35rem;
  color: #fff;
  border: 0;
  background: #3f3f46;
}

.product-modal__eyebrow {
  margin: 0 0 .2rem;
  color: #a1a1aa;
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.product-modal__body {
  padding: 1.35rem;
  background: #18181b;
}

.product-modal__section {
  padding: 1.1rem;
  margin-bottom: .9rem;
  border: 1px solid #3f3f46;
  border-radius: .65rem;
  background: #27272a;
}

.product-modal__section:last-child { margin-bottom: 0; }

.product-modal__section h6 {
  margin: 0 0 .3rem;
  color: #f4f4f5;
  font-size: 1rem;
  font-weight: 700;
}

.product-modal__section > p,
.choice-modal__description {
  margin-bottom: 1rem;
  color: #a1a1aa;
  font-size: .88rem;
}

.product-modal .form-label {
  margin-bottom: .45rem;
  color: #a1a1aa;
  font-size: .75rem !important;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.product-modal .form-control,
.product-modal .form-select {
  min-height: 42px;
  border-color: #3f3f46;
  border-radius: .45rem;
  color: #f4f4f5;
  background-color: #18181b;
  transition: border-color .15s ease, box-shadow .15s ease;
}

.product-modal .form-control:hover,
.product-modal .form-select:hover { border-color: #52525b; }

.product-modal .form-control::placeholder { color: #71717a; }

.product-modal .form-control[type="file"] {
  padding: .25rem;
}

.product-modal .form-control[type="file"]::file-selector-button {
  padding: .42rem .7rem;
  margin: -.25rem .7rem -.25rem -.25rem;
  border: 0;
  border-radius: .28rem 0 0 .28rem;
  color: #e4e4e7;
  font-weight: 600;
  background: #3f3f46;
}

.product-modal .form-control:focus,
.product-modal .form-select:focus {
  border-color: #71717a;
  color: #f4f4f5;
  background-color: #18181b;
  box-shadow: 0 0 0 .2rem rgba(161, 161, 170, .2);
}

.product-modal .form-text { margin-top: .35rem; color: #a1a1aa; font-size: .78rem; }

.product-modal #div_id_category > div,
.product-modal #div_id_colors > div,
.product-modal #div_id_available_sizes > div {
  display: grid;
  grid-template-columns: 1fr;
  gap: .4rem;
}

.product-modal__choice-list .form-check {
  display: block;
  width: 100%;
}

.product-modal #div_id_category .form-check,
.product-modal #div_id_colors .form-check,
.product-modal #div_id_available_sizes .form-check {
  position: relative;
  display: flex;
  align-items: center;
  gap: .55rem;
  min-height: 0;
  width: 100%;
  padding: .55rem .7rem;
  margin: 0;
  border: 1px solid #3f3f46;
  border-radius: .45rem;
  background: #18181b;
}

.product-modal #div_id_category .form-check-label,
.product-modal #div_id_colors .form-check-label,
.product-modal #div_id_available_sizes .form-check-label {
  display: block;
  height: auto;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: #d4d4d8;
  font-size: .84rem;
  font-weight: 500;
  line-height: 1.2;
  cursor: pointer;
  background: transparent;
  transition: color .15s ease;
}

.product-modal #div_id_category .form-check-label::before,
.product-modal #div_id_colors .form-check-label::before,
.product-modal #div_id_available_sizes .form-check-label::before {
  content: "";
  position: absolute;
  inset: 0;
  cursor: pointer;
}

.product-modal #div_id_category .form-check:hover,
.product-modal #div_id_colors .form-check:hover,
.product-modal #div_id_available_sizes .form-check:hover {
  border-color: #52525b;
  background: #27272a;
}

.product-modal #div_id_category .form-check:has(.form-check-input:checked),
.product-modal #div_id_colors .form-check:has(.form-check-input:checked),
.product-modal #div_id_available_sizes .form-check:has(.form-check-input:checked) {
  border-color: #a1a1aa;
  background: #3f3f46;
}

.product-modal #div_id_category .form-check:has(.form-check-input:checked) .form-check-label,
.product-modal #div_id_colors .form-check:has(.form-check-input:checked) .form-check-label,
.product-modal #div_id_available_sizes .form-check:has(.form-check-input:checked) .form-check-label { color: #fff; }

.product-modal #div_id_category .form-check-input,
.product-modal #div_id_colors .form-check-input,
.product-modal #div_id_available_sizes .form-check-input {
  float: none;
  flex: 0 0 auto;
  margin: 0;
}

.product-modal .form-check-input {
  width: 1.05em;
  height: 1.05em;
  border-color: #52525b;
  background-color: #18181b;
  box-shadow: none;
}

.product-modal .form-check-input:checked { background-color: #71717a; border-color: #71717a; }

.product-modal__toggle-list { display: grid; gap: .55rem; }

.product-modal__toggle {
  position: relative;
  display: flex;
  align-items: center;
  gap: .65rem;
  min-height: 44px;
  padding: .65rem .8rem;
  border: 1px solid #3f3f46;
  border-radius: .45rem;
  background: #18181b;
}

.product-modal__toggle .form-check-input {
  flex: 0 0 auto;
  width: 1.1em;
  height: 1.1em;
  margin: 0;
}

.product-modal__toggle label {
  margin: 0;
  color: #e4e4e7;
  font-weight: 600;
  cursor: pointer;
}

.product-modal__toggle label::before {
  content: "";
  position: absolute;
  inset: 0;
  cursor: pointer;
}

.product-modal__toggle:hover {
  border-color: #52525b;
  background: #27272a;
}

.product-modal__footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid #3f3f46;
  background: #27272a;
}

.product-modal__footer .btn { border: 0; border-radius: .45rem; font-weight: 600; }
.product-modal__footer .btn-light { color: #f4f4f5; background: #52525b; }
.product-modal__footer .btn-light:hover { color: #fff; background: #63636d; }
.product-modal__footer .btn-dark {
  color: #18181b;
  background: #e4e4e7;
}
.product-modal__footer .btn-dark:hover { color: #18181b; background: #fff; }

.pricing-modal__intro {
  display: flex;
  gap: .75rem;
  padding: .85rem 1rem;
  margin-bottom: 1rem;
  border-radius: .5rem;
  border: 1px solid #3f3f46;
  color: #e4e4e7;
  background: #18181b;
  font-size: .88rem;
}

.pricing-modal__intro i { margin-top: .1rem; color: #a1a1aa; }
.pricing-modal__intro span { display: block; color: #a1a1aa; }

.pricing-rule-list { border-top: 1px solid #3f3f46; }
.pricing-rule-list__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .7rem .15rem;
  border-bottom: 1px solid #3f3f46;
}
.pricing-rule-list__item span,
.pricing-rule-list__item small { display: block; color: #a1a1aa; font-size: .82rem; }

@media (max-width: 575.98px) {
  .modal-dialog:has(.product-modal) { width: calc(100vw - 1rem); }
  .product-modal__body { padding: 1rem; }
  .product-modal__section { padding: 1rem; }
}


#cart-items-container::-webkit-scrollbar {
  width: 8px;
}

#cart-items-container::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 10px;
}

#cart-items-container::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 10px;
}

#cart-items-container::-webkit-scrollbar-thumb:hover {
  background: #555;
}

#cart-sidebar {
  z-index: 9999;
}

/* Cart sidebar chrome is styled with utility classes in base.html. */

#cart-overlay {
  z-index: 9998;
}


.glass-card {
    transform: translateZ(0);
    isolation: isolate;
}

  .fade-in-up {
    animation: fadeInUp 0.8s ease-out;
  }

  .fade-in-right-wrapper {
    animation: fadeInRight 0.8s ease-out;
  }

  @keyframes fadeInUp {
    from {
      opacity: 0;
      transform: translateY(30px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  @keyframes fadeInRight {
    from {
      opacity: 0;
      transform: translateX(30px);
    }
    to {
      opacity: 1;
      transform: translateX(0);
    }
  }


/* ---------------------------------------------------------------------------
   Charcoal theme for the Bootstrap components used outside the custom modals:
   confirm dialogs, the table action dropdowns, toasts, and the filter selects.
   --------------------------------------------------------------------------- */
.modal-content {
  color: #f4f4f5;
  background-color: #27272a;
  border: 1px solid #3f3f46;
}

.modal-content .modal-header,
.modal-content .modal-footer {
  border-color: #3f3f46;
}

.modal-content .btn-close {
  filter: invert(1) grayscale(100%) brightness(200%);
}

.modal-content .text-muted { color: #a1a1aa !important; }

.dropdown-menu {
  color: #e4e4e7;
  background-color: #27272a;
  border: 1px solid #3f3f46;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .5);
}

.dropdown-menu .dropdown-item,
.dropdown-menu button {
  color: #e4e4e7;
  background-color: transparent;
}

.dropdown-menu .dropdown-item:hover,
.dropdown-menu button:hover {
  color: #fff;
  background-color: #3f3f46;
}

.toast {
  color: #f4f4f5;
  background-color: #27272a;
  border: 1px solid #3f3f46;
}

/* Filter selects on the summary screen are plain Bootstrap controls. */
.form-select,
.form-control {
  color: #f4f4f5;
  background-color: #18181b;
  border-color: #3f3f46;
}

.form-select:focus,
.form-control:focus {
  color: #f4f4f5;
  background-color: #18181b;
  border-color: #71717a;
  box-shadow: 0 0 0 .2rem rgba(161, 161, 170, .2);
}

.form-control::placeholder { color: #71717a; }

/* Bootstrap renders the select arrow as a dark SVG; lighten it for dark fields. */
.form-select {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23a1a1aa' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
}


/* --- Confirm-delete dialog ------------------------------------------------- */
.product-modal__danger {
  display: flex;
  align-items: flex-start;
  gap: .9rem;
}

.product-modal__danger-icon {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: .6rem;
  color: #fca5a5;
  background: rgba(239, 68, 68, .12);
}

.product-modal__danger-icon svg { width: 1.25rem; height: 1.25rem; }
.product-modal__danger p { color: #a1a1aa; font-size: .88rem; }
.product-modal__danger strong { color: #f4f4f5; }

/* --- Order summary modal ---------------------------------------------------- */
.summary-item-list { margin: 0; padding: 0; list-style: none; }

.summary-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: .75rem;
  padding: .7rem 0;
  border-bottom: 1px solid #3f3f46;
}

.summary-item:last-child { border-bottom: 0; }
.summary-item__body { display: flex; flex-direction: column; gap: .15rem; min-width: 0; }
.summary-item__body strong { color: #f4f4f5; font-size: .9rem; }
.summary-item__body span { color: #a1a1aa; font-size: .8rem; }

.summary-item__tag {
  align-self: flex-start;
  margin-top: .25rem;
  padding: .1rem .4rem;
  border-radius: .3rem;
  color: #d4d4d8 !important;
  background: #3f3f46;
  font-size: .72rem !important;
}

.summary-item__remove {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  padding: 0;
  border: 0;
  border-radius: .35rem;
  color: #71717a;
  background: transparent;
  transition: color .15s ease, background-color .15s ease;
}

.summary-item__remove svg { width: .9rem; height: .9rem; }
.summary-item__remove:hover { color: #fca5a5; background: rgba(239, 68, 68, .12); }

.summary-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-top: .9rem;
  padding-top: .8rem;
  border-top: 1px solid #3f3f46;
}

.summary-total span { color: #a1a1aa; font-size: .85rem; }
.summary-total strong { color: #fafafa; font-size: 1.15rem; }

/* --- Buttons: solid fills, no outlines -------------------------------------- */
.product-modal__footer .btn-danger,
.btn-danger {
  border-color: transparent;
  color: #fff;
  background-color: #b91c1c;
}

.product-modal__footer .btn-danger:hover,
.btn-danger:hover {
  border-color: transparent;
  background-color: #991b1b;
}

/* Bootstrap's close icon is a dark SVG; invert it for dark headers. */
.modal-content .btn-close,
.product-modal .btn-close {
  filter: invert(1) grayscale(100%) brightness(200%);
  opacity: .65;
}

.modal-content .btn-close:hover,
.product-modal .btn-close:hover { opacity: 1; }
