/*
 * PDF Block Enhancements
 * Styles for improving the UI/UX of PDF preview and download blocks.
 */

/* General layout for the PDF block */
.wp-block-file {
  display: grid;
  gap: 14px;
}

/* Styling for the PDF preview iframe */
.pdf-preview-frame {
  width: 100%;
  min-height: 420px;
  height: min(78vh, 720px);
  border: 1px solid #d8dee8;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 6px 24px rgba(11, 28, 43, 0.08);
}

/* Styling for the download panel */
.pdf-download-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 14px 16px;
  border: 1px solid #d8dee8;
  border-radius: 12px;
  background: linear-gradient(180deg, #ffffff 0%, #f6f9fc 100%);
}

/* Styling for the file metadata */
.pdf-file-meta {
  min-width: 0;
  flex: 1 1 240px;
}

/* Styling for the file link */
.pdf-file-link {
  display: inline-block;
  max-width: 100%;
  color: #19324d;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pdf-file-link:hover {
  text-decoration: underline;
}

/* Styling for the download button */
.pdf-download-btn.wp-block-file__button {
  border-radius: 10px;
  padding: 10px 16px;
  font-weight: 700;
  letter-spacing: 0.01em;
  background: #0f6cbf;
  border: 1px solid #0f6cbf;
  color: #fff;
}

.pdf-download-btn.wp-block-file__button:hover {
  background: #0b5a9f;
  border-color: #0b5a9f;
}

/* Responsive adjustments for smaller screens */
@media (max-width: 767px) {
  .pdf-preview-frame {
    min-height: 340px;
    height: min(68vh, 520px);
  }

  .pdf-download-btn.wp-block-file__button {
    width: 100%;
    text-align: center;
  }
}