.vsw-w-card {
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.08);
  padding: 16px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  max-width: 650px;
  margin: 15px auto;
  border: 1px solid #e2e8f0;
}
.vsw-w-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid #edf2f7;
  padding-bottom: 8px;
  margin-bottom: 12px;
}
.vsw-w-header h3 { margin: 0; font-size: 1.15rem; color: #1a202c; font-weight: 700; }
.vsw-w-time { font-size: 0.8rem; color: #718096; }
.vsw-w-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 135px), 1fr));
  gap: 10px;
}
.vsw-w-item {
  background: #f8fafc;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}
.vsw-w-highlight {
  grid-column: 1 / -1;
  background: #eff6ff;
  border-color: #bfdbfe;
}
.vsw-w-label { font-size: 0.75rem; color: #4a5568; font-weight: 600; margin-bottom: 4px; }
.vsw-w-val { font-size: 1.25rem; font-weight: bold; color: #1a202c; }
.vsw-w-val .vsw-w-sub { font-size: 0.85rem; color: #2b6cb0; font-weight: normal; }
.vsw-w-subtext { font-size: 0.75rem; color: #718096; margin-top: 4px; }

.vsw-w-webcam {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

[data-vsw-hafencam] .vsw-w-header {
  flex-wrap: wrap;
  gap: 4px 12px;
}

.vsw-w-webcam-link {
  display: block;
  border-radius: 8px;
  cursor: zoom-in;
}

.vsw-w-webcam-link:focus-visible {
  outline: 2px solid #2b6cb0;
  outline-offset: 3px;
}

@media (max-width: 781px) {
  .gb-container:has(> [data-vsw-hafencam]) {
    box-sizing: border-box;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0;
  }

  .wp-block-columns:has(> .wp-block-column [data-vsw-hafencam]) {
    flex-wrap: wrap !important;
  }

  .wp-block-columns:has(> .wp-block-column [data-vsw-hafencam]) > .wp-block-column {
    flex-basis: 100% !important;
    min-width: 0;
    max-width: 100%;
  }

  .vsw-w-card[data-vsw-hafencam] {
    padding: 12px;
  }
}

/* Die beiden Karten teilen sich die Höhe ihrer gemeinsamen Spaltenzeile. */
@media (min-width: 782px) {
  .wp-block-columns:has([data-vsw-hafencam]):has([data-vsw-weather]) {
    align-items: stretch !important;
  }

  .wp-block-columns:has([data-vsw-hafencam]):has([data-vsw-weather]) > .wp-block-column {
    display: flex;
    flex-direction: column;
    flex: 1 1 0 !important;
    min-width: 0;
  }

  .wp-block-columns:has([data-vsw-weather]) .gb-container:has(> [data-vsw-hafencam]) {
    display: flex;
    flex-direction: column;
    flex: 1;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0;
  }

  .wp-block-columns:has([data-vsw-hafencam]):has([data-vsw-weather]) .vsw-w-card {
    display: flex;
    flex-direction: column;
    flex: 1;
    max-width: none;
  }

  .vsw-w-webcam-link {
    display: flex;
    flex: 1;
    align-items: center;
  }

  .vsw-w-webcam {
    object-fit: contain;
  }

  .vsw-w-grid {
    flex: 1;
    align-content: start;
  }
}

.vsw-w-header {
  flex-wrap: wrap;
  gap: 4px 12px;
}
