/* ============================================
   POST-APOCALYPTIC COMPONENT LIBRARY
   Based on Asset Sheets
   ============================================ */

/* ============================================
   STATUS MESSAGES (from asset5.png)
   ============================================ */

.status-message {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border-radius: 8px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  box-shadow:
    var(--shadow-small),
    inset 0 2px 4px rgba(0, 0, 0, 0.6);
  border: 3px solid;
}

.status-message.error {
  background:
    linear-gradient(135deg, rgba(166, 75, 42, 0.3), rgba(139, 52, 30, 0.4)),
    var(--metal-texture),
    var(--vintage-bg-dark);
  border-color: #a64b2a;
  color: #d4863a;
}

.status-message.success {
  background:
    linear-gradient(135deg, rgba(139, 148, 86, 0.3), rgba(107, 115, 66, 0.4)),
    var(--metal-texture),
    var(--vintage-bg-dark);
  border-color: #8b9456;
  color: #c9a961;
}

.status-message.warning {
  background:
    linear-gradient(135deg, rgba(212, 134, 58, 0.3), rgba(184, 103, 15, 0.4)),
    var(--metal-texture),
    var(--vintage-bg-dark);
  border-color: var(--accent);
  color: var(--accent);
}

.status-icon {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 18px;
  font-weight: 900;
  background:
    var(--metal-texture),
    linear-gradient(135deg, var(--accent), var(--accent-rust));
  border: 2px solid var(--accent-warm);
  color: var(--bg);
  box-shadow:
    var(--shadow-small),
    var(--glow-orange);
}

.status-message.error .status-icon {
  background: linear-gradient(135deg, #a64b2a, #8b341e);
  border-color: #702818;
}

.status-message.success .status-icon {
  background: linear-gradient(135deg, #8b9456, #6b7342);
  border-color: #545c35;
  box-shadow: 0 0 20px rgba(139, 148, 86, 0.3);
}

/* ============================================
   PROGRESS INDICATORS (from asset5.png & asset 4.png)
   ============================================ */

.progress-indicator {
  position: relative;
  width: 48px;
  height: 48px;
}

.progress-ring {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 4px solid var(--vintage-bg-medium);
  border-top-color: var(--accent);
  box-shadow:
    var(--shadow-small),
    inset 0 2px 4px rgba(0, 0, 0, 0.7);
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.progress-bar-container {
  width: 100%;
  height: 24px;
  background:
    linear-gradient(180deg, var(--vintage-bg-medium), var(--vintage-bg-dark)),
    var(--metal-texture);
  border: 3px solid var(--vintage-dark-bronze);
  border-radius: 6px;
  box-shadow:
    inset 0 3px 6px rgba(0, 0, 0, 0.7),
    var(--shadow-small);
  overflow: hidden;
  position: relative;
}

.progress-bar-fill {
  height: 100%;
  background:
    var(--metal-texture),
    linear-gradient(90deg, var(--accent-rust), var(--accent) 50%, var(--accent-2));
  box-shadow:
    inset 0 2px 4px rgba(201, 169, 97, 0.4),
    inset 0 -2px 4px rgba(0, 0, 0, 0.6),
    var(--glow-orange);
  transition: width 0.3s ease;
  position: relative;
}

.progress-bar-fill::after {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 8px,
    rgba(0, 0, 0, 0.1) 8px,
    rgba(0, 0, 0, 0.1) 16px
  );
}

/* ============================================
   BADGES & LABELS (from asset 4.png)
   ============================================ */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background:
    linear-gradient(135deg, rgba(212, 134, 58, 0.4), rgba(139, 90, 43, 0.5)),
    var(--metal-texture);
  border: 2px solid var(--accent-warm);
  border-radius: 16px;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  box-shadow:
    var(--shadow-small),
    inset 0 1px 2px rgba(212, 134, 58, 0.3);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
}

.label {
  display: inline-block;
  padding: 8px 16px;
  background:
    var(--rust-gradient),
    var(--metal-texture),
    var(--vintage-bg-medium);
  border: 3px solid var(--vintage-dark-bronze);
  border-radius: 8px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--vintage-text-light);
  box-shadow:
    var(--shadow-small),
    inset 0 2px 4px rgba(212, 134, 58, 0.1),
    inset 0 -2px 4px rgba(0, 0, 0, 0.6);
}

/* ============================================
   TAGS (from asset 4.png)
   ============================================ */

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.tag-item {
  padding: 6px 14px;
  background:
    linear-gradient(135deg, rgba(61, 48, 32, 0.6), rgba(45, 36, 24, 0.7)),
    var(--metal-texture);
  border: 2px solid var(--border-light);
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted-text);
  transition: all 0.2s ease;
  box-shadow: var(--shadow-small);
}

.tag-item:hover {
  background:
    linear-gradient(135deg, rgba(212, 134, 58, 0.2), rgba(184, 103, 15, 0.3)),
    var(--metal-texture);
  border-color: var(--accent-warm);
  color: var(--accent);
  transform: translateY(-1px);
  box-shadow:
    var(--shadow-small),
    var(--glow-orange);
}

/* ============================================
   NAVIGATION (from webasset1.png)
   ============================================ */

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background:
    linear-gradient(90deg, rgba(26, 21, 16, 0.8), rgba(45, 36, 24, 0.9)),
    var(--metal-texture);
  border: 2px solid var(--border);
  border-radius: 8px;
  box-shadow:
    var(--shadow-small),
    inset 0 2px 4px rgba(0, 0, 0, 0.6);
  font-size: 14px;
}

.breadcrumb-item {
  color: var(--muted-text);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.breadcrumb-item:hover {
  color: var(--accent);
}

.breadcrumb-item.current {
  color: var(--accent);
  font-weight: 800;
}

.breadcrumb-separator {
  color: var(--border-light);
  font-size: 12px;
}

/* ============================================
   DROPDOWN (from webasset2.png)
   ============================================ */

.dropdown {
  position: relative;
  width: 240px;
}

.dropdown-button {
  width: 100%;
  padding: 14px 20px;
  background:
    linear-gradient(180deg, var(--panel-light), var(--panel)),
    var(--metal-texture);
  border: 3px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font-size: 15px;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: all 0.2s ease;
  box-shadow:
    var(--shadow-small),
    inset 0 2px 4px rgba(212, 134, 58, 0.08),
    inset 0 -2px 4px rgba(0, 0, 0, 0.6);
}

.dropdown-button::after {
  content: '▼';
  font-size: 10px;
  color: var(--accent);
  transition: transform 0.2s ease;
  text-shadow: var(--glow-orange);
}

.dropdown.open .dropdown-button::after {
  transform: rotate(180deg);
}

.dropdown-button:hover {
  background:
    linear-gradient(180deg, var(--panel), var(--panel-light)),
    var(--metal-texture);
  border-color: var(--accent-warm);
  box-shadow:
    var(--shadow-medium),
    var(--glow-orange);
}

/* ============================================
   TOGGLE SWITCH (from webasset2.png)
   ============================================ */

.toggle-switch {
  position: relative;
  width: 60px;
  height: 32px;
  background:
    linear-gradient(180deg, var(--vintage-bg-medium), var(--vintage-bg-dark)),
    var(--metal-texture);
  border: 3px solid var(--vintage-dark-bronze);
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow:
    inset 0 3px 6px rgba(0, 0, 0, 0.7),
    var(--shadow-small);
}

.toggle-slider {
  position: absolute;
  width: 22px;
  height: 22px;
  background:
    var(--metal-texture),
    linear-gradient(135deg, var(--accent-2), var(--accent-warm));
  border: 2px solid var(--border);
  border-radius: 50%;
  top: 2px;
  left: 2px;
  transition: all 0.3s ease;
  box-shadow:
    var(--shadow-small),
    inset 0 1px 2px rgba(201, 169, 97, 0.3);
}

.toggle-switch.active {
  background:
    linear-gradient(180deg, rgba(212, 134, 58, 0.3), rgba(184, 103, 15, 0.4)),
    var(--metal-texture);
  border-color: var(--accent-warm);
  box-shadow:
    inset 0 3px 6px rgba(0, 0, 0, 0.6),
    var(--glow-orange);
}

.toggle-switch.active .toggle-slider {
  left: calc(100% - 24px);
  background:
    var(--metal-texture),
    linear-gradient(135deg, var(--accent), var(--accent-rust));
  box-shadow:
    var(--shadow-small),
    var(--glow-orange),
    inset 0 1px 2px rgba(201, 169, 97, 0.4);
}

/* ============================================
   CHECKBOX & RADIO (from webasset2.png)
   ============================================ */

.checkbox-wrapper,
.radio-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.checkbox,
.radio {
  width: 28px;
  height: 28px;
  background:
    linear-gradient(180deg, var(--vintage-bg-medium), var(--vintage-bg-dark)),
    var(--metal-texture);
  border: 3px solid var(--vintage-dark-bronze);
  box-shadow:
    inset 0 3px 6px rgba(0, 0, 0, 0.7),
    var(--shadow-small);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.checkbox {
  border-radius: 6px;
}

.radio {
  border-radius: 50%;
}

.checkbox::before {
  content: '✓';
  font-size: 20px;
  font-weight: 900;
  color: var(--accent);
  opacity: 0;
  transform: scale(0);
  transition: all 0.2s ease;
  text-shadow: var(--glow-orange);
}

.radio::before {
  content: '';
  width: 14px;
  height: 14px;
  background:
    radial-gradient(circle, var(--accent), var(--accent-rust));
  border-radius: 50%;
  opacity: 0;
  transform: scale(0);
  transition: all 0.2s ease;
  box-shadow: var(--glow-orange);
}

.checkbox.checked::before,
.radio.selected::before {
  opacity: 1;
  transform: scale(1);
}

.checkbox.checked,
.radio.selected {
  border-color: var(--accent-warm);
  background:
    linear-gradient(180deg, rgba(212, 134, 58, 0.2), var(--vintage-bg-dark)),
    var(--metal-texture);
}

.checkbox-label,
.radio-label {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  user-select: none;
}

/* ============================================
   DATA DISPLAY (from asset 4.png)
   ============================================ */

.data-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background:
    var(--rust-gradient),
    var(--metal-texture),
    var(--panel);
  border: 3px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-medium);
}

.data-table th {
  padding: 14px 18px;
  background:
    linear-gradient(180deg, var(--accent-warm), var(--vintage-dark-bronze)),
    var(--metal-texture);
  color: var(--text);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 13px;
  text-align: left;
  border-bottom: 3px solid var(--border);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.6);
}

.data-table td {
  padding: 12px 18px;
  color: var(--text);
  border-bottom: 2px solid var(--border);
  font-weight: 600;
}

.data-table tr:last-child td {
  border-bottom: none;
}

.data-table tr:hover td {
  background:
    linear-gradient(90deg, rgba(212, 134, 58, 0.1), transparent),
    var(--metal-texture);
}

/* ============================================
   CHARTS & GRAPHS (from asset 4.png)
   ============================================ */

.chart-container {
  padding: 20px;
  background:
    var(--rust-gradient),
    var(--metal-texture),
    var(--panel);
  border: 3px solid var(--border);
  border-radius: var(--radius);
  box-shadow:
    var(--shadow-medium),
    inset 0 2px 4px rgba(0, 0, 0, 0.6);
}

.chart-title {
  font-size: 18px;
  font-weight: 800;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 16px;
  text-shadow: var(--glow-orange);
}

.bar-chart {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  height: 200px;
  padding: 12px;
  background:
    linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.3)),
    var(--metal-texture);
  border: 2px solid var(--border);
  border-radius: 8px;
}

.bar {
  flex: 1;
  background:
    var(--metal-texture),
    linear-gradient(180deg, var(--accent), var(--accent-rust));
  border: 2px solid var(--accent-warm);
  border-radius: 4px 4px 0 0;
  min-height: 20px;
  position: relative;
  box-shadow:
    var(--shadow-small),
    var(--glow-orange);
  transition: all 0.3s ease;
}

.bar:hover {
  filter: brightness(1.2);
  transform: translateY(-4px);
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.rivet-decoration {
  position: relative;
}

.rivet-decoration::after {
  content: '';
  position: absolute;
  width: 8px;
  height: 8px;
  background:
    radial-gradient(circle, var(--accent-warm), var(--vintage-dark-bronze));
  border-radius: 50%;
  border: 2px solid var(--bg);
  box-shadow:
    inset 0 1px 2px rgba(0, 0, 0, 0.8),
    0 1px 2px rgba(0, 0, 0, 0.5);
}

.weathered-border {
  border-style: solid;
  border-image: linear-gradient(
    135deg,
    var(--border) 0%,
    var(--accent-warm) 25%,
    var(--border) 50%,
    var(--accent-warm) 75%,
    var(--border) 100%
  ) 1;
}

.glow-text {
  color: var(--accent);
  text-shadow: var(--glow-orange);
}
