/* ===================================================================
   VERBESSERTE ITEM-DETAILANSICHT
   Moderne Card-Struktur mit besserer UX und Konsistenz
   =================================================================== */

/* Breadcrumb-Styling */
.lp-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  margin: 0;
  list-style: none;
  font-size: 14px;
  background: var(--color-bg-body, #fff);
  border-radius: 8px;
  border: 1px solid var(--color-border, #e5e7eb);
}

/* Wenn Breadcrumb bereits in einer Card liegt, keine zweite Umrandung/Fläche */
.item-section-card .lp-breadcrumb {
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
}

.lp-breadcrumb li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.lp-breadcrumb a {
  color: var(--color-text-secondary, #6b7280);
  text-decoration: none;
  transition: color 0.2s;
}

.lp-breadcrumb a:hover {
  color: #e89c0a;
}

.lp-breadcrumb-separator {
  color: var(--color-text-muted, #9ca3af);
  font-weight: 300;
}

html[data-theme="dark"] .lp-breadcrumb {
  background: #1a2332;
  border-color: rgba(232, 156, 10, 0.2);
}

/* Haupt-Container mit modernem Card-Design */
.item-section-card {
  background: var(--color-bg-body, #fff);
  border: 1px solid var(--color-border, #e5e7eb);
  border-radius: 6px;
  padding: 14px;
  margin-bottom: 12px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  transition: box-shadow 0.2s ease;
}

html[data-theme="dark"] .item-section-card {
  background: #1a2332;
  border-color: #334155;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Section-Header mit Icon */
.section-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--color-border, #e5e7eb);
}

.section-header svg {
  flex-shrink: 0;
  color: #e89c0a;
  width: 18px;
  height: 18px;
}

.section-header h2 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text-primary, #111827);
}

html[data-theme="dark"] .section-header h2 {
  color: #f3f4f6;
}

html[data-theme="dark"] .section-header {
  border-bottom-color: rgba(255, 255, 255, 0.1);
}

/* Titel-Bereich */
.item-title-wrapper {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.item-title-content {
  flex: 1;
  min-width: 0;
}

.item-title-content h1 {
  font-size: 22px;
  font-weight: 700;
  color: var(--color-text-primary, #111827);
  margin: 0 0 8px 0;
  line-height: 1.3;
  word-wrap: break-word;
}

html[data-theme="dark"] .item-title-content h1 {
  color: #f3f4f6;
}

.item-pro-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  background: linear-gradient(135deg, #e89c0a 0%, #f4b740 100%);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(232, 156, 10, 0.3);
}

.item-qrcode {
  flex-shrink: 0;
}

.item-qrcode img {
  width: 140px;
  height: 140px;
  border-radius: 6px;
  border: none;
  padding: 0;
  background: transparent;
}

html[data-theme="dark"] .item-qrcode img {
  background: transparent;
}

@media (max-width: 768px) {
  .item-qrcode img {
    width: 120px;
    height: 120px;
  }
}

@media (max-width: 480px) {
  .item-qrcode img {
    width: 100px;
    height: 100px;
  }
}

/* Preis-Box: wieder getrennte Kacheln (und stärker als cpayments.css) */
.item-section-card .lp-prices-bar {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.item-section-card .lp-prices-bar .lp-price-item {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  background: rgba(15, 23, 42, 0.04);
  border: 1px solid var(--color-border, #e5e7eb);
  border-radius: 8px;
  line-height: 1.1;
}

.item-section-card .lp-prices-bar .lp-price-item.lp-euro-price {
  grid-column: 1 / -1;
  font-size: 22px;
  font-weight: 800;
}

.item-section-card .lp-prices-bar .lp-price-item.lp-crypto-price {
  font-size: 13px;
}

html[data-theme="dark"] .item-section-card .lp-prices-bar .lp-price-item {
  background: rgba(15, 23, 42, 0.6);
  border-color: rgba(232, 156, 10, 0.2);
}

@media (max-width: 768px) {
  .item-section-card .lp-prices-bar {
    grid-template-columns: 1fr;
  }

  .item-section-card .lp-prices-bar .lp-price-item.lp-euro-price {
    grid-column: auto;
  }
}

/* Eigenschaften als kompakte 2-Spalten-Liste (ohne Einzelboxen) */
.item-section-card .properties-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 0 !important;
  column-gap: 32px !important;
  font-size: 13px;
  line-height: 1.5;
}

.item-section-card .properties-grid .property-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06) !important;
  transition: none;
}

.item-section-card .properties-grid .property-item:hover {
  background: transparent !important;
}

.item-section-card .properties-grid .property-item:last-child,
.item-section-card .properties-grid .property-item:nth-last-child(2):nth-child(odd) {
  border-bottom: none;
}

.item-section-card .property-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--color-text-muted, #6b7280);
  flex-shrink: 0;
  letter-spacing: 0.01em;
}

.item-section-card .property-value {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text-primary, #111827);
  text-align: right;
  line-height: 1.4;
}

html[data-theme="dark"] .item-section-card .properties-grid {
  border-top-color: rgba(255, 255, 255, 0.08);
}

html[data-theme="dark"] .item-section-card .properties-grid .property-item {
  border-bottom-color: rgba(255, 255, 255, 0.08) !important;
}

html[data-theme="dark"] .item-section-card .properties-grid .property-item:hover {
  background: transparent !important;
}

html[data-theme="dark"] .item-section-card .property-label {
  color: #94a3b8;
}

html[data-theme="dark"] .item-section-card .property-value {
  color: #f1f5f9;
}

@media (max-width: 768px) {
  .item-section-card .properties-grid {
    grid-template-columns: 1fr !important;
  }
}

/* Preis-Box (Sidebar) */
.lp-prices-bar {
  padding: 14px;
  background: linear-gradient(135deg, rgba(232, 156, 10, 0.08) 0%, rgba(91, 168, 49, 0.08) 100%);
  border: 2px solid #e89c0a;
  border-radius: 6px;
  text-align: center;
}

.price-amount {
  font-size: 26px;
  font-weight: 700;
  color: #16a34a;
  margin-bottom: 6px;
}

.price-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--color-text-muted, #6b7280);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

html[data-theme="dark"] .lp-prices-bar {
  background: rgba(232, 156, 10, 0.15);
  border-color: #e89c0a;
}

/* Verkäufer-Info */
.seller-info {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--color-bg-secondary, #f9fafb);
  border-radius: 6px;
  margin-bottom: 12px;
}

.seller-avatar {
  flex-shrink: 0;
}

.seller-avatar img {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 2px solid #e89c0a;
  object-fit: cover;
}

.seller-details {
  flex: 1;
  min-width: 0;
}

.seller-name {
  margin: 0 0 4px 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--color-text-primary, #111827);
}

.seller-name a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}

.seller-name a:hover {
  color: #e89c0a;
}

.seller-description {
  margin: 0;
  font-size: 14px;
  color: var(--color-text-secondary, #6b7280);
  line-height: 1.5;
}

html[data-theme="dark"] .seller-info {
  background: rgba(255, 255, 255, 0.05);
}

html[data-theme="dark"] .seller-name {
  color: #f3f4f6;
}

/* Metadaten-Box */
.lp-item-metadata {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
}

.lp-item-metadata > div {
  display: flex;
  justify-content: space-between;
  padding: 6px 10px;
  background: var(--color-bg-secondary, #f9fafb);
  border-radius: 4px;
}

.lp-item-metadata strong {
  color: var(--color-text-secondary, #6b7280);
  font-weight: 600;
}

html[data-theme="dark"] .lp-item-metadata > div {
  background: rgba(255, 255, 255, 0.05);
}

/* Buttons */
.lp-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
  text-align: center;
}

.lp-button svg {
  flex-shrink: 0;
}

.lp-button.lp-orange2 {
  background: #e89c0a;
  color: #fff;
  box-shadow: 0 2px 6px rgba(232, 156, 10, 0.3);
}

.lp-button.lp-orange2:hover {
  background: #d68c09;
  box-shadow: 0 4px 10px rgba(232, 156, 10, 0.4);
}

.lp-button.lp-green {
  background: #16a34a;
  color: #fff;
  box-shadow: 0 2px 6px rgba(22, 163, 74, 0.3);
}

.lp-button.lp-green:hover {
  background: #15803d;
  box-shadow: 0 4px 10px rgba(22, 163, 74, 0.4);
}

.lp-button.lp-border {
  background: transparent;
  border: 2px solid var(--color-border, #e5e7eb);
  color: var(--color-text-primary, #111827);
}

.lp-button.lp-border:hover {
  border-color: #e89c0a;
  color: #e89c0a;
}

.lp-button.lp-red {
  background: #dc2626;
  color: #fff;
  box-shadow: 0 2px 6px rgba(220, 38, 38, 0.3);
}

.lp-button.lp-red:hover {
  background: #b91c1c;
  box-shadow: 0 4px 10px rgba(220, 38, 38, 0.4);
}

html[data-theme="dark"] .lp-button.lp-border {
  border-color: rgba(232, 156, 10, 0.3);
  color: #f3f4f6;
}

html[data-theme="dark"] .lp-button.lp-border:hover {
  border-color: #e89c0a;
  color: #e89c0a;
}

/* Panel-Nachrichten */
.lp-panel {
  padding: 12px;
  border-radius: 6px;
  margin-bottom: 12px;
  border: 1px solid;
  font-size: 14px;
}

.lp-panel.lp-green {
  background: #dcfce7;
  border-color: #16a34a;
  color: #166534;
}

.lp-panel.lp-red {
  background: #fee2e2;
  border-color: #dc2626;
  color: #991b1b;
}

html[data-theme="dark"] .lp-panel.lp-green {
  background: rgba(22, 163, 74, 0.2);
  color: #4ade80;
}

html[data-theme="dark"] .lp-panel.lp-red {
  background: rgba(220, 38, 38, 0.2);
  color: #f87171;
}

/* Features-Liste */
.lp-feature-header {
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 12px 0;
  color: var(--color-text-primary, #111827);
}

.lp-feature-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}

.lp-feature-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: var(--color-bg-secondary, #f9fafb);
  border-radius: 4px;
  border: 1px solid var(--color-border, #e5e7eb);
  transition: all 0.2s;
  font-size: 13px;
}

.lp-feature-item:hover {
  border-color: #e89c0a;
  background: rgba(232, 156, 10, 0.05);
}

.lp-feature-item label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex: 1;
  cursor: pointer;
  margin: 0;
}

.lp-feature-name {
  font-weight: 500;
  color: var(--color-text-primary, #111827);
}

.lp-feature-price {
  font-weight: 600;
  color: #16a34a;
}

html[data-theme="dark"] .lp-feature-item {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.1);
}

html[data-theme="dark"] .lp-feature-name {
  color: #f3f4f6;
}

/* Aktions-Buttons nebeneinander */
.lp-actions {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}

/* Map-Container */
#map {
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--color-border, #e5e7eb);
  margin-top: 12px;
}

html[data-theme="dark"] #map {
  border-color: rgba(232, 156, 10, 0.2);
}

/* Responsive */
@media (max-width: 992px) {
  .item-title-wrapper {
    flex-direction: column;
    align-items: flex-start;
  }

  .item-qrcode {
    align-self: flex-start;
  }

  .item-qrcode img {
    width: 70px;
    height: 70px;
  }

  .item-title-content h1 {
    font-size: 24px;
  }

  .lp-row {
    display: flex;
    flex-direction: column;
  }

  .lp-twothird,
  .lp-third {
    width: 100%;
  }
}

@media (max-width: 768px) {
  .item-section-card {
    padding: 16px;
  }

  .section-header h2 {
    font-size: 18px;
  }

  .item-title-content h1 {
    font-size: 22px;
  }

  .properties-grid {
    grid-template-columns: 1fr;
  }
  
  .property-item {
    padding: 9px 12px;
    gap: 10px;
  }
  
  .property-value {
    font-size: 12px;
  }

  .seller-info {
    padding: 12px;
  }

  .seller-avatar img {
    width: 50px;
    height: 50px;
  }

  .seller-name {
    font-size: 16px;
  }

  .lp-actions {
    flex-direction: column;
  }

  .lp-actions a,
  .lp-actions button {
    width: 100% !important;
  }
}

@media (max-width: 480px) {
  .lp-breadcrumb {
    font-size: 12px;
    padding: 8px 12px;
  }

  .item-title-content h1 {
    font-size: 20px;
  }

  .item-qrcode img {
    width: 60px;
    height: 60px;
  }

  .price-amount {
    font-size: 26px;
  }

  .lp-button {
    padding: 10px 16px;
    font-size: 14px;
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .item-section-card,
  .lp-button,
  .lp-breadcrumb a,
  .lp-feature-item {
    transition: none !important;
  }
}
