/* NavigateAUC Styles - Mobile First */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background: #f5f5f5;
  min-height: 100vh;
  padding: 0;
}

.container {
  max-width: 100%;
  margin: 0;
  background: white;
  min-height: 100vh;
  padding: 20px;
}

h1 {
  color: #004b87;
  text-align: center;
  margin-bottom: 30px;
  font-size: 1.8rem;
}

/* Building Grid - Mobile First */
.buildings-grid {
  display: flex;
  flex-direction: column;
  gap: 15px;
  width: 100%;
  max-width: 500px;
  margin: 0 auto;
}

.building-box {
  display: block;
  padding: 25px 20px;
  background: #004b87;
  color: white;
  text-decoration: none;
  border-radius: 12px;
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0, 75, 135, 0.2);
}

.building-box h3 {
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.4;
  margin: 0;
}

.building-box .subtitle {
  font-size: 0.9rem;
  opacity: 0.9;
  margin-top: 5px;
  display: block;
}

/* Disabled boxes - grayed out */
.building-box.disabled {
  background: #9e9e9e;
  opacity: 0.7;
  pointer-events: none;
  cursor: not-allowed;
}

.building-box.disabled .coming-soon {
  display: block;
  margin-top: 10px;
  font-size: 0.85rem;
  font-style: italic;
  opacity: 0.8;
}

/* Active box - SSE */
.building-box.active {
  background: #004b87;
}

.building-box.active:active {
  transform: scale(0.98);
  box-shadow: 0 1px 4px rgba(0, 75, 135, 0.3);
}

.form-group input,
.form-group select {
  padding: 12px;
  border: 2px solid #ddd;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: #667eea;
}

.btn {
  padding: 15px 30px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn:active {
  transform: translateY(0);
}

.result-container {
  margin-top: 30px;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 10px;
  border-left: 5px solid #667eea;
}

.result-container h2 {
  color: #333;
  margin-bottom: 15px;
}

.path-display {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 20px 0;
}

.path-node {
  padding: 10px 20px;
  background: #667eea;
  color: white;
  border-radius: 25px;
  font-weight: bold;
}

.path-arrow {
  color: #764ba2;
  font-size: 1.5rem;
  font-weight: bold;
}

.distance-info {
  padding: 15px;
  background: white;
  border-radius: 8px;
  margin-top: 15px;
}

.distance-info p {
  margin: 5px 0;
  color: #555;
}

.distance-info strong {
  color: #667eea;
}

.error-message {
  padding: 15px;
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
  border-radius: 8px;
  margin-top: 20px;
}

.success-message {
  padding: 15px;
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
  border-radius: 8px;
  margin-top: 20px;
}

/* Map visualization styles */
.map-container {
  margin-top: 30px;
  border: 2px solid #ddd;
  border-radius: 10px;
  overflow: hidden;
  background: #fafafa;
}

#mapCanvas {
  display: block;
  width: 100%;
  height: auto;
  cursor: crosshair;
}

.loading {
  text-align: center;
  padding: 40px;
  color: #667eea;
  font-size: 1.2rem;
}

.spinner {
  display: inline-block;
  width: 40px;
  height: 40px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid #667eea;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Responsive design */
@media (max-width: 768px) {
  h1 {
    font-size: 1.8rem;
  }

  .container {
    padding: 20px;
  }

  .path-display {
    flex-direction: column;
    align-items: stretch;
  }

  .path-node {
    text-align: center;
  }
}

/* Error Pages (404, Error) */
.error-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  padding: 40px 20px;
}

.error-content {
  text-align: center;
  max-width: 500px;
}

.error-code {
  font-size: 6rem;
  color: #004b87;
  margin-bottom: 15px;
  font-weight: bold;
}

.error-icon {
  font-size: 4rem;
  margin-bottom: 15px;
}

.error-page h2 {
  color: #333;
  font-size: 1.5rem;
  margin-bottom: 15px;
  font-weight: 600;
}

.error-page p {
  color: #666;
  font-size: 1.1rem;
  line-height: 1.6;
  margin-bottom: 30px;
}

.error-actions {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Buttons */
.btn-primary {
  display: inline-block;
  padding: 15px 30px;
  background: #004b87;
  color: white;
  text-decoration: none;
  border-radius: 10px;
  font-weight: 600;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 2px 8px rgba(0, 75, 135, 0.2);
}

.btn-primary:active {
  transform: scale(0.98);
  box-shadow: 0 1px 4px rgba(0, 75, 135, 0.3);
}

.btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  background: #9e9e9e;
  color: white;
  text-decoration: none;
  border-radius: 10px;
  font-weight: 600;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 2px 8px rgba(158, 158, 158, 0.2);
}

.btn-secondary:active {
  transform: scale(0.98);
  box-shadow: 0 1px 4px rgba(158, 158, 158, 0.3);
}

/* About Page */
.about-section {
  max-width: 500px;
  margin: 0 auto;
}

.about-section h2 {
  color: #004b87;
  font-size: 1.8rem;
  margin-bottom: 20px;
  font-weight: 600;
}

.about-section h3 {
  color: #333;
  font-size: 1.3rem;
  margin-top: 30px;
  margin-bottom: 15px;
  font-weight: 600;
}

.about-intro {
  padding: 20px;
  background: #f5f5f5;
  border-radius: 10px;
  margin-bottom: 30px;
}

.about-intro p {
  color: #555;
  font-size: 1.05rem;
  line-height: 1.6;
  margin: 0;
}

.feature-list {
  padding-left: 25px;
  color: #555;
  line-height: 1.8;
  margin-bottom: 30px;
}

.feature-list li {
  margin: 10px 0;
}

.tech-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin-bottom: 30px;
}

.tech-card {
  padding: 20px;
  background: white;
  border: 2px solid #004b87;
  border-radius: 10px;
  text-align: center;
}

.tech-card strong {
  display: block;
  color: #004b87;
  font-size: 1rem;
  margin-bottom: 8px;
}

.tech-card p {
  color: #666;
  font-size: 0.9rem;
  margin: 0;
  line-height: 1.4;
}

.how-it-works {
  padding: 20px;
  background: #f5f5f5;
  border-radius: 10px;
  margin-bottom: 30px;
}

.how-it-works ol {
  padding-left: 25px;
  color: #555;
  line-height: 1.8;
}

.how-it-works li {
  margin: 12px 0;
}

.graph-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.graph-item {
  background: white;
  border: 2px solid #004b87;
  border-radius: 10px;
  padding: 15px;
  text-align: center;
}

.graph-item h4 {
  color: #004b87;
  font-size: 1.1rem;
  margin-bottom: 12px;
  font-weight: 600;
}

.graph-item img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.graph-item p {
  color: #666;
  font-size: 0.9rem;
  line-height: 1.4;
  margin: 0;
}

.about-cta {
  text-align: center;
  margin-top: 40px;
}

/* Footer */
.site-footer {
  margin-top: 50px;
  padding: 30px 20px 20px;
  background: #f5f5f5;
  border-top: 2px solid #e0e0e0;
  text-align: center;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 30px;
  margin-bottom: 20px;
}

.footer-links a {
  color: #004b87;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  transition: color 0.2s;
}

.footer-links a:active {
  color: #c69214;
}

.footer-info {
  margin-bottom: 15px;
}

.footer-info .copyright {
  color: #333;
  font-size: 0.9rem;
  margin-bottom: 5px;
}

.footer-info .version {
  color: #999;
  font-size: 0.8rem;
  font-style: italic;
}

.footer-contact {
  margin-top: 15px;
}

.footer-contact p {
  color: #666;
  font-size: 0.85rem;
}

.footer-contact a {
  color: #004b87;
  text-decoration: none;
}

.footer-contact a:active {
  color: #c69214;
}
