.auth-card-body input[type="text"]:focus,
.auth-card-body input[type="email"]:focus,
.auth-card-body input[type="password"]:focus,
.auth-card-body input[type="number"]:focus,
.auth-card-body select:focus {
  border-color: #28a745 !important;
  box-shadow: none !important;
}
/* Signup form fields styling to match login */
.auth-card-body input[type="text"],
.auth-card-body input[type="email"],
.auth-card-body input[type="password"],
.auth-card-body input[type="number"],
.auth-card-body select {
  background-color: #23272b !important;
  color: #e0e0e0 !important;
  border: 1px solid #ffc107 !important;
  font-family: Arial, Helvetica, sans-serif !important;
  text-transform: none !important;
  font-size: 1rem;
  border-radius: 4px;
}
/* Auth Card Styles */
.auth-card {
  background-color: #23272b !important;
  border-radius: 12px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.5);
  border: 1px solid #444 !important;
}
.auth-card-header {
  background-color: #1a1a1a !important;
  color: #ffc107 !important;
  border-bottom: 1px solid #ffc107 !important;
  font-family: var(--font-main);
}
.auth-card-body {
  background-color: #23272b !important;
  color: #e0e0e0 !important;
}
.auth-form-label {
  color: #ffc107 !important;
  font-weight: 600;
}
.auth-form-input {
  background-color: #23272b !important;
  color: #e0e0e0 !important;
  border: 1px solid #ffc107 !important;
  font-family: Arial, Helvetica, sans-serif !important;
  text-transform: none !important;
  font-size: 1rem;
}
.auth-btn {
  background-color: #ffc107 !important;
  color: #23272b !important;
  font-weight: bold;
  border-radius: 6px;
}
.auth-link {
  color: #ffc107 !important;
  text-decoration: underline;
}
.auth-link:hover {
  color: #fff200 !important;
}
.auth-center {
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
/* Loot modal styles */
#lootmodal .list-group-item {
  background-color: #343a40 !important; /* dark grey */
  color: #e0e0e0 !important;
  border: none !important;
}
#lootmodal .loot-qty-input {
  background-color: #23272b !important;
  color: #e0e0e0 !important;
  border: 1px solid #495057 !important;
}
#lootmodal .btn-primary.loot-take-btn {
  background-color: #28a745 !important;
  border-color: #28a745 !important;
  border-radius: 10, 5 ;
  color: #fff !important;
}
#lootmodal #lootTakeAllBtn {
  background-color: #28a745 !important;
  border-color: #28a745 !important;
  color: #fff !important;
}
/* Make the main content area a flex column for map layout */
.main-content-flex {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 600px;
}

.map-header {
  flex: 0 0 auto;
  padding: 0rem 1.5rem 0.5rem 1.5rem;
  background: transparent;
  z-index: 2;
}

/* The Dead Web - Main Stylesheet */

/* Google Fonts Import */

/* Custom Alert Styles */
.custom-alert {
  animation: fadeInDown 0.5s;
  border-radius: 0.75rem;
  font-size: 1.1rem;
  padding: 0.75rem 1.25rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.25);
  background: #23272b;
  color: #fff;
  min-width: 300px;
  max-width: 500px;
}

@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-30px); }
  to { opacity: 1; transform: translateY(0); }
}
@import url("https://fonts.googleapis.com/css2?family=Lacquer:wght@400&display=swap");

/* CSS Custom Properties (Variables) */
:root {
  /* Typography */
  --font-main: "Lacquer", sans-serif;
  --font-secondary: "Arial", sans-serif; /* Placeholder for future selection */
  --font-tertiary: "Helvetica", sans-serif; /* Placeholder for future selection */
  --font-numeric: "Roboto Mono", "Consolas", "Monaco", monospace; /* For numbers and stats */
  
  /* Color Variables (for future expansion) */
  --bg-primary: #1a1a1a;
  --bg-secondary: #2d2d2d;
  --bg-accent: #333;
  --text-primary: #e0e0e0;
  --border-color: #444;
}

/* Base Styles */
body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-main);
}

/* Navbar Styles */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1030; /* Bootstrap's navbar z-index */
  box-shadow: 0 2px 4px rgba(0,0,0,0.1); /* Add subtle shadow for depth */
  height: 4rem; /* Fixed height for consistency */
  min-height: 4rem;
}

.navbar-brand {
  font-weight: bold;
  font-size: 1.5rem;
  font-family: var(--font-main);
}

/* Numeric Typography - Better readability for numbers */
.numeric,
.stat-value,
.health-value,
.energy-value,
.ammo-count,
.days-count,
.death-count {
  font-family: var(--font-numeric);
  font-weight: 600;
}

/* Apply numeric font to stat displays */
.stat-item span:last-child,
.stat-mobile span.small {
  font-family: var(--font-numeric);
}

/* Rest duration dropdowns - use numeric font for all text */
.rest-duration-select,
.rest-duration-select option {
  font-family: var(--font-numeric) !important;
  font-weight: 500;
}

/* Sidebar Styles */
.sidebar {
  background-color: #2d2d2d;
  border-right: none;
}

/* Make sidebar sticky on desktop */
@media (min-width: 768px) {
  .sidebar {
    position: sticky;
    top: 4rem; /* Match navbar height exactly */
    height: calc(100vh - 4rem);
    overflow-y: auto;
  }
}

.player-info {
  background-color: #333;
  border-radius: 8px;
  margin-bottom: 1rem;
}

.player-avatar {
  width: 80px;
  height: 80px;
  background-color: #555;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}

.stat-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.25rem;
}

.menu-section {
  background-color: #333;
  border-radius: 8px;
}

.menu-item {
  display: block;
  padding: 0.75rem 1rem;
  color: #e0e0e0;
  text-decoration: none;
  border-bottom: 1px solid #444;
  transition: background-color 0.2s;
}

.menu-item:hover {
  background-color: #404040;
  color: #fff;
}

.menu-item:last-child {
  border-bottom: none;
}

/* Main Content Styles */
.main-content {
  background-color: #2d2d2d;
  border-radius: 8px;
  min-height: calc(100vh - 56px - 2rem);
}

/* Adjust main content height on mobile to account for mobile nav */
@media (max-width: 767px) {
  .main-content {
    min-height: calc(100vh - 56px - 200px);
  }
}

/* Progress Bar Styles */
.health-bar,
.energy-bar {
  height: 8px;
  border-radius: 4px;
  overflow: hidden;
}

.health-bar .progress-bar {
  background-color: #dc3545;
}

.energy-bar .progress-bar {
  background-color: #ffc107;
}

/* Mobile-specific styles */
.player-info-mobile {
  background-color: #333;
  border-radius: 8px;
  max-width: 600px;
  margin: 0 auto;
}

.mobile-nav {
  max-width: 600px;
  margin: 0 auto;
}

.player-avatar-small {
  width: 40px;
  height: 40px;
  background-color: #555;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.stat-mobile {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  color: #e0e0e0;
  font-size: 0.875rem;
}

.mobile-nav-item {
  flex: 1;
  min-width: fit-content;
  text-align: center;
}

.mobile-nav-item:hover {
  background-color: #555;
  border-color: #666;
}

/* Responsive adjustments */
@media (max-width: 575px) {
  .mobile-nav {
    gap: 0.25rem !important;
  }
  
  .mobile-nav-item {
    font-size: 0.75rem;
    padding: 0.375rem 0.5rem;
  }
}

/* Inventory Card Styles */
.item-card {
  background-color: #3a3a3a;
  border: none;
  height: 100%;
  transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
  color: #f0f0f0;
}

.item-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  background-color: #404040;
}

.item-image-placeholder {
  width: 50px;
  height: 50px;
  background-color: #4a4a4a;
  border: none;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  transition: background-color 0.2s ease-in-out;
}

.item-image-placeholder:hover {
  background-color: #555;
}

.item-image-placeholder i {
  font-size: 1.2rem;
  color: #bbb;
}

.item-card .card-title {
  color: #f0f0f0;
  font-size: 0.9rem;
  font-weight: 600;
}

.item-card .badge {
  font-family: var(--font-numeric);
}

.item-card .btn-group {
  box-shadow: none;
}

.item-card .btn-sm {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
}

.item-card .text-muted {
  color: #ccc !important;
}

.item-card small.text-muted {
  color: #bbb !important;
}

/* Item card grid layout */
.item-card-grid {
  display: grid;
  grid-template-rows: auto auto auto auto;
  gap: 0.5rem;
}

.item-header-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 0.5rem;
}

.item-content-row {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: center;
  gap: 0.25rem;
}

.item-content-row.stackable {
  grid-template-columns: auto 1fr;
}

.item-info-column {
  text-align: right;
  font-size: 0.8rem;
}

.item-dropdown-arrow {
  text-align: center;
  height: 20px;
}

.item-dropdown-arrow button {
  color: #999;
  text-decoration: none;
  border: none;
  background: none;
  height: 20px;
  line-height: 1;
  padding: 0;
  transition: color 0.2s ease-in-out;
}

.item-dropdown-arrow button:hover {
  color: var(--text-primary);
}

.item-dropdown-arrow i {
  font-size: 0.7rem;
}

/* Vertical Progress Bar for Condition */
.condition-progress {
  width: 10px;
  height: 50px;
  background-color: #2a2a2a;
  border: none;
  border-radius: 5px;
  position: relative;
  overflow: hidden;
  display: inline-block;
}

.condition-progress.in-card {
  height: 50px;
  width: 10px;
}

.condition-progress.in-dropdown {
  height: 60px;
  width: 12px;
  margin-right: 8px;
}

.condition-progress-fill {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  border-radius: 0 0 5px 5px;
  transition: height 0.3s ease-in-out;
}

.condition-progress-fill.excellent {
  background: linear-gradient(to top, #28a745, #34ce57);
}

.condition-progress-fill.good {
  background: linear-gradient(to top, #17a2b8, #20c997);
}

.condition-progress-fill.fair {
  background: linear-gradient(to top, #ffc107, #ffed4e);
}

.condition-progress-fill.poor {
  background: linear-gradient(to top, #fd7e14, #ff922b);
}

.condition-progress-fill.broken {
  background: linear-gradient(to top, #dc3545, #e74c3c);
}

.condition-label {
  font-size: 0.7rem;
  font-weight: 600;
  color: #ccc;
  display: inline-block;
  vertical-align: top;
  line-height: 1.2;
  margin-top: 2px;
}

/* Inventory section headers */
.inventory-section-header {
  color: var(--text-primary);
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 0.5rem;
  margin-bottom: 1rem;
}

/* Responsive inventory adjustments */
@media (max-width: 575px) {
  .item-card .card-body {
    padding: 0.75rem;
  }
  
  .item-image-placeholder {
    width: 40px;
    height: 40px;
  }
  
  .item-card .card-title {
    font-size: 0.8rem;
  }
}

/* Equipment Slots Styling */
.equipment-slot {
  background-color: #3a3a3a;
  border: 2px solid #555;
  border-radius: 8px;
  padding: 0.75rem;
  text-align: center;
  transition: all 0.2s ease-in-out;
  min-height: 80px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  cursor: pointer;
}

.equipment-slot:hover {
  border-color: #777;
  background-color: #404040;
}

.equipment-slot.weapon-slot {
  border-color: #dc3545;
}

.equipment-slot.weapon-slot:hover {
  border-color: #c82333;
}

.slot-icon {
  font-size: 1.5rem;
  color: #999;
  margin-bottom: 0.5rem;
}

.weapon-slot .slot-icon {
  color: #dc3545;
}

.slot-label {
  font-size: 0.7rem;
  color: #ccc;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.equipped-item {
  font-size: 0.8rem;
  color: #f0f0f0;
  font-weight: 500;
  line-height: 1.2;
}

.empty-slot {
  font-size: 0.75rem;
  color: #777;
  font-style: italic;
}

.equipment-stats {
  background-color: #2a2a2a;
  border-radius: 6px;
  padding: 0.75rem;
}

.equipment-stats .stat-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-size: 0.85rem;
  color: #ddd;
}

.equipment-stats .stat-item:last-child {
  margin-bottom: 0;
}

.equipment-stats .stat-item i {
  width: 16px;
  font-size: 0.9rem;
}

/* Description text styling in item detail dropdowns */
div[id^="equipmentDetails"] small,
div[id^="details"] small {
  color: #e0e0e0 !important;
}

/* Equipment button group styling */
.equipment-slot .d-flex .btn {
  flex: 1 1 0 !important;
  min-width: 0 !important;
  width: 50%;
}

/* Number input fields should use numeric font */
input[type="number"],
.form-control[type="number"] {
  font-family: var(--font-numeric) !important;
  font-weight: 600 !important;
}

/* World Map Styles */
.map-container-card {
  height: 75vh; /* Make the card itself take most of the viewport */
  min-height: 650px;
  max-height: 90vh; /* Prevent it from getting too tall */
}

.map-container-card .card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 0; /* Remove padding so map fills completely */
  overflow: hidden; /* Ensure nothing escapes the card body */
}

.map-window {
  position: relative;
  flex: 1 1 auto !important;
  min-height: 0;
  height: 60vh;
  width: 100%;
  max-width: 100%;
  max-height: 60vh;
  box-sizing: border-box;
  background: #222 !important;
  border: 4px solid #17a2b8 !important;
  cursor: grab;
  touch-action: none;
  user-select: none;
  overflow: hidden;
  border-radius: 0;
  z-index: 10;
}

.map-window:active {
  cursor: grabbing;
}

.map-content {
  position: absolute;
  width: 1632px !important;
  height: 640px !important;
  max-width: none !important;
  max-height: none !important;
  box-sizing: border-box;
  overflow: visible;
  will-change: transform;
  }

/* Responsive adjustments */
@media (max-width: 900px) {
  .map-window {
    position: relative;
    width: 100%;
    height: 40vh;
    max-width: 100%;
    max-height: 40vh;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    z-index: 10;
    overflow: hidden;
    border-radius: 0;
  }
  .main-content,
  .main-content-flex,
  .map-container-card,
  .card-body {
    padding: 0 !important;
    margin: 0 !important;
    box-sizing: border-box;
    height: auto;
    min-height: 0;
  }
}

.location-marker {
    position: absolute;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 3px solid;
    color: white;
    font-weight: bold;
    font-size: 16px;
    text-align: center;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    pointer-events: all; /* Ensure markers can still be clicked */
    touch-action: manipulation; /* Allow taps but prevent other gestures */
}

.location-marker.current {
    background-color: #28a745 !important;
    border-color: #155724 !important;
    box-shadow: 0 0 20px rgba(40, 167, 69, 0.8), 0 2px 8px rgba(0,0,0,0.3) !important;
    animation: pulse 2s infinite;
    z-index: 110;
}

.location-marker.discovered {
    background-color: #007bff !important;
    border-color: #004085 !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3) !important;
    z-index: 105;
}

.location-marker.unknown {
    background-color: #6c757d !important;
    border-color: #495057 !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3) !important;
    z-index: 100;
}

.location-marker:hover {
    transform: scale(1.1);
    z-index: 120;
}

@keyframes pulse {
    0%, 100% { 
        transform: scale(1); 
        box-shadow: 0 0 20px rgba(40, 167, 69, 0.8), 0 2px 8px rgba(0,0,0,0.3);
    }
    50% { 
        transform: scale(1.05); 
        box-shadow: 0 0 30px rgba(40, 167, 69, 1), 0 2px 12px rgba(0,0,0,0.4);
    }
}

.location-info {
  width: 100%;
  background: rgba(0, 0, 0, 0.85);
  color: white;
  padding: 1rem;
  border-radius: 8px;
  margin-top: 1rem;
  margin-bottom: 0;
  min-width: 0;
  z-index: 10;
  display: none;
  box-sizing: border-box;
}

.map-controls-overlay {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 1000;
  background: rgba(0,0,0,0.0);
  pointer-events: auto;
}

.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.05;
    background-image: 
        linear-gradient(rgba(255,255,255,.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.1) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
    z-index: 1;
}

/* Location Detail Page Styles */
.location-header-card {
    border-radius: 0.5rem;
    overflow: hidden;
}

.location-header-card .card-header {
    border-bottom: none;
    position: relative;
}

/* Reduce space between travel info and map window */
.location-stats-bar {
    margin-bottom: 0.5rem;
}
.map-container-card {
    margin-top: 0.5rem;
}

.location-action-cards .card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border-radius: 0.5rem;
}

.location-action-cards .card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.location-action-cards .card-body {
    min-height: 120px;
}

.location-action-cards .card-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.125);
}

/* Card color themes */
.border-warning .card-header.bg-warning {
    background: linear-gradient(135deg, #ffc107 0%, #ff8c00 100%) !important;
}

.border-success .card-header.bg-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
}

.border-info .card-header.bg-info {
    background: linear-gradient(135deg, #17a2b8 0%, #007bff 100%) !important;
}

.border-primary .card-header.bg-primary {
    background: linear-gradient(135deg, #007bff 0%, #6610f2 100%) !important;
}

.border-secondary .card-header.bg-secondary {
    background: linear-gradient(135deg, #6c757d 0%, #495057 100%) !important;
}

.border-light .card-header.bg-light {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%) !important;
}

/* Action button styling */
.location-action-cards .btn {
    transition: all 0.2s ease;
}

.location-action-cards .btn:hover {
    transform: scale(1.02);
}

/* Quick actions grid styling */
.d-grid.gap-2 .btn {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
}

/* Badge styling enhancements */
.badge.fs-6 {
    font-size: 0.875rem !important;
    padding: 0.5rem 1rem;
}

/* Container cards responsive spacing */
@media (max-width: 768px) {
    .location-action-cards .col-md-6,
    .location-action-cards .col-lg-4 {
        margin-bottom: 1rem;
    }
    
    .location-action-cards .card-body {
        min-height: auto;
    }
}
