.cert-content {
  padding-top: 0;
  padding-bottom: 0;
}

.cert-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
  margin: 30px;
}

.cert-item {
  background: #fff;
  border-radius: var(--radius-lg, 12px);
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
  transition: transform var(--transition-default, 0.3s ease), box-shadow var(--transition-default, 0.3s ease);
  text-align: center;
  padding-bottom: 20px;
  width: 280px;
  flex-grow: 0;
  flex-shrink: 0;
  max-width: 100%;
}

.cert-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.cert-grid--single .cert-item {
  width: min(420px, 100%);
}


.cert-item--pending:hover {
  transform: none;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.cert-preview--pending {
  cursor: default;
  aspect-ratio: 3 / 4;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cert-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 14px;
  line-height: 1.4;
  color: #8c99a8;
}

.cert-placeholder i {
  font-size: 46px;
  color: #b9c6d6;
}

.cert-preview {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: linear-gradient(160deg, #eef3f9 0%, #dfe8f3 100%);
  cursor: pointer;
  line-height: 0;
}

.cert-canvas {
  display: block;
  width: 100%;
  height: auto;
}

.cert-canvas--real {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.cert-canvas--real.is-visible {
  opacity: 1;
}

.zoom-icon {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(20, 75, 138, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-default, 0.3s ease);
}

.zoom-icon i {
  font-size: 30px;
  color: #fff;
}

.cert-item:hover .zoom-icon,
.cert-preview:focus-visible .zoom-icon {
  opacity: 1;
}

.cert-item h3 {
  margin: 15px 0 5px;
  font-size: 18px;
  color: var(--dark-color, #1a1a2e);
}

.cert-item p {
  font-size: 14px;
  color: var(--text-muted, #777);
  padding: 0 15px;
}

.cert-reg {
  margin: 0 0 12px;
}

.cert-open {
  display: inline-block;
  font-size: 14px;
  color: var(--primary-color, #144B8A);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color var(--transition-default, 0.3s ease), border-color var(--transition-default, 0.3s ease);
}

.cert-open:hover,
.cert-open:focus-visible {
  color: var(--accent-color, #e94560);
  border-bottom-color: currentColor;
}


.cert-open--disabled,
.cert-open--disabled:hover,
.cert-open--disabled:focus-visible {
  color: var(--text-muted, #999);
  border-bottom-color: transparent;
  cursor: default;
  pointer-events: none;
}

.cert-empty {
  margin: 0;
  font-size: 16px;
  color: var(--text-muted, #777);
}

.cert-modal {
  padding: 20px;
  box-sizing: border-box;
}

.cert-modal .close-lightbox {
  background: none;
  border: 0;
  padding: 0;
  line-height: 1;
}

.cert-modal-body {
  width: min(1000px, 100%);
  height: 82vh;
  display: flex;
  justify-content: center;
}

.cert-modal-frame {
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
}

body.cert-modal-open {
  overflow: hidden;
}

.cert-info {
  background: #fff;
  padding: 40px;
  border-radius: var(--radius-lg, 12px);
  border-left: 5px solid var(--accent-color, #e94560);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.cert-info h2 {
  margin-bottom: 15px;
  color: var(--dark-color, #1a1a2e);
}

.cert-info p {
  line-height: 1.6;
  color: #555;
}

#caption {
  font-size: 18px;
}
