/* ====================================================
   TripRouter — Component & Tool Styles
   ==================================================== */

/* ============================================================
   TOOLS SECTION
   ============================================================ */

.tools-api-notice {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(16,185,129,0.08);
  border: 1px solid rgba(16,185,129,0.2);
  border-radius: 9999px;
  padding: 8px 18px;
  font-size: 0.78rem;
  color: #94a3b8;
  margin-top: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.tool-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 0;
  animation: fadeDown 0.4s ease both;
}

.tool-card-wide {
  grid-column: 1 / -1;
}

.tool-card-header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.tool-icon {
  font-size: 2rem;
  flex-shrink: 0;
  line-height: 1;
  filter: drop-shadow(0 0 8px rgba(249,115,22,0.3));
}

.tool-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: white;
  margin-bottom: 2px;
}

.tool-desc {
  font-size: 0.75rem;
  color: #64748b;
}

.tool-free-badge {
  margin-left: auto;
  background: rgba(16,185,129,0.12);
  border: 1px solid rgba(16,185,129,0.25);
  color: #34d399;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 9999px;
  letter-spacing: 0.06em;
  flex-shrink: 0;
  white-space: nowrap;
}

.tool-body { flex: 1; }

.tool-error {
  color: #f87171;
  font-size: 0.875rem;
  padding: 12px;
  background: rgba(239,68,68,0.08);
  border: 1px solid rgba(239,68,68,0.2);
  border-radius: 10px;
}

.tool-loading {
  text-align: center;
  padding: 24px;
  color: #64748b;
  font-size: 0.875rem;
}

.tool-loading .loading-dots {
  display: flex;
  gap: 6px;
  justify-content: center;
  margin-bottom: 10px;
}

/* ============================================================
   CURRENCY CONVERTER
   ============================================================ */

.currency-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}

.currency-grid-results {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.currency-row {
  display: grid;
  grid-template-columns: 28px 52px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 10px;
  transition: all 180ms ease;
  font-size: 0.85rem;
}

.currency-row:hover {
  background: rgba(249,115,22,0.07);
  border-color: rgba(249,115,22,0.2);
}

.currency-flag { font-size: 1.1rem; }
.currency-code { font-weight: 700; color: white; font-size: 0.8rem; }
.currency-name { color: #64748b; font-size: 0.75rem; }

.currency-amount {
  font-weight: 800;
  color: #fb923c;
  font-size: 0.95rem;
  text-align: right;
}

.currency-rate {
  display: none;
}

.currency-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(255,255,255,0.05);
  font-size: 0.72rem;
  color: #475569;
}

.currency-source { color: #475569; }

.currency-loading {
  text-align: center;
  color: #475569;
  padding: 20px;
  font-size: 0.85rem;
}

/* ============================================================
   WEATHER WIDGET
   ============================================================ */

.weather-card {
  background: linear-gradient(135deg, rgba(6,182,212,0.1), rgba(249,115,22,0.05));
  border: 1px solid rgba(6,182,212,0.2);
  border-radius: 14px;
  overflow: hidden;
}

.weather-current {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
}

.weather-icon-big {
  font-size: 3.5rem;
  filter: drop-shadow(0 0 12px rgba(249,115,22,0.3));
  flex-shrink: 0;
}

.weather-city {
  font-family: 'Outfit', sans-serif;
  font-size: 1.1rem;
  font-weight: 800;
  color: white;
  margin-bottom: 4px;
}

.weather-temp {
  font-family: 'Outfit', sans-serif;
  font-size: 2rem;
  font-weight: 900;
  background: linear-gradient(135deg, #06b6d4, #fb923c);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 2px;
}

.weather-desc { font-size: 0.9rem; color: #94a3b8; margin-bottom: 6px; }
.weather-meta { font-size: 0.78rem; color: #64748b; }

.weather-forecast {
  display: flex;
  gap: 0;
  overflow-x: auto;
  padding: 0 4px 4px;
  border-top: 1px solid rgba(255,255,255,0.05);
  scrollbar-width: thin;
}

.forecast-day {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 12px 14px;
  min-width: 80px;
  flex-shrink: 0;
  border-right: 1px solid rgba(255,255,255,0.04);
  transition: background 180ms;
}

.forecast-day:hover { background: rgba(255,255,255,0.03); }
.forecast-day:last-child { border-right: none; }

.forecast-date  { font-size: 0.68rem; color: #64748b; text-align: center; }
.forecast-icon  { font-size: 1.4rem; }
.forecast-temp  { font-size: 0.85rem; font-weight: 700; color: white; }
.forecast-min   { color: #64748b; font-weight: 400; }
.forecast-rain  { font-size: 0.7rem; color: #94a3b8; }

/* ============================================================
   VISA CHECKER
   ============================================================ */

.visa-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.visa-result {
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 12px;
  padding: 16px;
  max-height: 400px;
  overflow-y: auto;
}

/* ============================================================
   PACKING LIST
   ============================================================ */

.packing-result {
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 12px;
  padding: 16px;
  max-height: 400px;
  overflow-y: auto;
}

/* ============================================================
   DUCKDUCKGO SEARCH
   ============================================================ */

.ddg-shortcuts {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.ddg-result-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 14px;
  padding: 18px;
  animation: fadeDown 0.3s ease both;
}

.ddg-answer {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: rgba(16,185,129,0.1);
  border: 1px solid rgba(16,185,129,0.25);
  border-radius: 10px;
  padding: 12px 16px;
  margin-bottom: 14px;
  font-size: 0.95rem;
  font-weight: 600;
  color: white;
}

.ddg-answer-icon { font-size: 1.1rem; flex-shrink: 0; }

.ddg-source {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  color: #64748b;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.ddg-abstract {
  font-size: 0.9rem;
  color: #94a3b8;
  line-height: 1.7;
  margin-bottom: 14px;
}

.ddg-link {
  color: #fb923c;
  text-decoration: none;
  font-size: 0.78rem;
  transition: color 150ms;
}

.ddg-link:hover { color: #fdba74; text-decoration: underline; }

.ddg-related {
  border-top: 1px solid rgba(255,255,255,0.05);
  padding-top: 12px;
  font-size: 0.85rem;
}

.ddg-related strong { color: white; display: block; margin-bottom: 8px; }
.ddg-related ul { padding-left: 18px; }
.ddg-related li { margin-bottom: 6px; color: #94a3b8; }

.ddg-footer {
  border-top: 1px solid rgba(255,255,255,0.04);
  padding-top: 10px;
  margin-top: 12px;
  font-size: 0.7rem;
  color: #475569;
  text-align: center;
}

/* ============================================================
   INTERACTIVE MAP (Leaflet overrides for dark theme)
   ============================================================ */

.leaflet-container {
  background: #0d1526;
  font-family: 'Inter', sans-serif;
}

.leaflet-control-zoom a {
  background: rgba(15,20,40,0.9) !important;
  color: white !important;
  border-color: rgba(249,115,22,0.3) !important;
  border-radius: 6px !important;
}

.leaflet-control-zoom a:hover {
  background: rgba(249,115,22,0.2) !important;
}

.leaflet-popup-content-wrapper {
  background: rgba(15,20,40,0.95) !important;
  color: white !important;
  border: 1px solid rgba(249,115,22,0.3) !important;
  border-radius: 10px !important;
  box-shadow: 0 8px 32px rgba(0,0,0,0.5) !important;
}

.leaflet-popup-tip {
  background: rgba(15,20,40,0.95) !important;
}

.leaflet-popup-content {
  color: white !important;
  font-family: 'Inter', sans-serif !important;
}

.leaflet-attribution-flag { display: none !important; }

/* ============================================================
   PDF PRINT AREA
   ============================================================ */

#pdfPrintArea {
  display: none;
}

@media print {
  /* Hide everything except pdf print area */
  body > * { display: none !important; }
  #pdfPrintArea {
    display: block !important;
    position: fixed;
    inset: 0;
    background: white;
    color: black;
    padding: 40px;
    font-family: 'Inter', sans-serif;
    font-size: 12pt;
    line-height: 1.6;
  }

  .pdf-header {
    text-align: center;
    border-bottom: 3px solid #f97316;
    padding-bottom: 20px;
    margin-bottom: 30px;
  }

  .pdf-logo {
    font-size: 18pt;
    font-weight: 900;
    color: #f97316;
    margin-bottom: 8px;
  }

  .pdf-header h1 {
    font-size: 20pt;
    font-weight: 800;
    margin: 8px 0;
    color: #1e293b;
  }

  .pdf-meta {
    font-size: 10pt;
    color: #64748b;
    margin-top: 6px;
  }

  .pdf-content h1 { font-size: 16pt; color: #f97316; margin: 20px 0 10px; border-bottom: 1px solid #f0f0f0; padding-bottom: 6px; }
  .pdf-content h2 { font-size: 13pt; color: #1e293b; margin: 16px 0 8px; }
  .pdf-content h3 { font-size: 11pt; color: #334155; margin: 12px 0 6px; }
  .pdf-content p  { margin-bottom: 8px; }
  .pdf-content ul { padding-left: 20px; margin-bottom: 8px; }
  .pdf-content li { margin-bottom: 4px; }
  .pdf-content table { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: 10pt; }
  .pdf-content th { background: #fff3e0; border: 1px solid #fed7aa; padding: 6px 10px; color: #c2410c; }
  .pdf-content td { border: 1px solid #e2e8f0; padding: 6px 10px; }
  .pdf-content strong { font-weight: 700; }
  .pdf-content blockquote { border-left: 3px solid #f97316; padding-left: 12px; color: #64748b; margin: 10px 0; }

  .pdf-footer {
    margin-top: 40px;
    padding-top: 16px;
    border-top: 1px solid #e2e8f0;
    font-size: 9pt;
    color: #94a3b8;
    text-align: center;
  }
}

/* ============================================================
   EXISTING COMPONENT STYLES
   ============================================================ */

.budget-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin: 16px 0 24px;
}

.budget-summary-card {
  background: rgba(249,115,22,0.07);
  border: 1px solid rgba(249,115,22,0.18);
  border-radius: 14px;
  padding: 16px;
  text-align: center;
  transition: all 250ms ease;
}

.budget-summary-card:hover { background: rgba(249,115,22,0.14); transform: translateY(-2px); }
.budget-summary-icon   { font-size: 1.8rem; margin-bottom: 8px; }
.budget-summary-label  { font-size: 0.72rem; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 4px; }
.budget-summary-amount { font-size: 1.1rem; font-weight: 800; color: #fb923c; }

/* Explore result area */
.explore-result { margin-top: 24px; }

/* ============================================================
   RESPONSIVE FOR TOOLS
   ============================================================ */

@media (max-width: 900px) {
  .tools-grid { grid-template-columns: 1fr; }
  .tool-card-wide { grid-column: 1; }
  .currency-grid { grid-template-columns: 1fr; }
  .visa-grid { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .weather-current { flex-direction: column; text-align: center; }
  .currency-row { grid-template-columns: 28px 1fr auto; }
  .currency-name { display: none; }
}

/* ============================================================
   INTERACTIVE CHECKLIST
   ============================================================ */

.packing-item-checkbox {
  margin-right: 10px;
  cursor: pointer;
  accent-color: #fb923c;
  width: 15px;
  height: 15px;
  transform: translateY(2px);
}

.result-content li:has(.packing-item-checkbox:checked) {
  text-decoration: line-through;
  opacity: 0.45;
  transition: all 180ms ease;
}
