/**
 * Form Expiry Field - Frontend CSS
 * @copyright (C) 2026 blaho.hu
 * @license GPL
 * @version 1.5.0
 */

/* Field konténer */
.formexpiry-field-container {
   margin-bottom: 1rem;
}

/* Figyelmeztetési üzenet (hamarosan lejár) */
.formexpiry-warning-message {
   background: #fff3cd;
   border: 1px solid #ffc107;
   border-radius: 4px;
   padding: 12px 16px;
   margin-bottom: 10px;
   color: #856404;
   font-weight: 500;
   display: flex;
   align-items: center;
}

.formexpiry-warning-message::before {
   content: "⚠️";
   font-size: 20px;
   margin-right: 10px;
}

/* Lejárati üzenet (form lejárt) */
.formexpiry-expired-message {
   background: #f8d7da;
   border: 1px solid #dc3545;
   border-radius: 4px;
   padding: 12px 16px;
   margin-bottom: 10px;
   color: #721c24;
   font-weight: 500;
   display: flex;
   align-items: center;
}

.formexpiry-expired-message::before {
   content: "🚫";
   font-size: 20px;
   margin-right: 10px;
}

/* Notification popup overlay */
.formexpiry-notification-overlay {
   position: fixed;
   top: 0;
   left: 0;
   width: 100%;
   height: 100%;
   background: rgba(0, 0, 0, 0.5);
   z-index: 9998;
   display: flex;
   align-items: center;
   justify-content: center;
   animation: fadeIn 0.3s ease;
}

/* Notification popup */
.formexpiry-notification {
   position: fixed;
   top: 50%;
   left: 50%;
   transform: translate(-50%, -50%);
   background: white;
   border-radius: 8px;
   box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
   z-index: 9999;
   max-width: 500px;
   width: 90%;
   animation: slideIn 0.3s ease;
}

.formexpiry-notification-content {
   padding: 24px;
   position: relative;
}

.formexpiry-notification-icon {
   font-size: 48px;
   display: block;
   text-align: center;
   margin-bottom: 16px;
}

.formexpiry-notification p {
   margin: 0;
   font-size: 16px;
   line-height: 1.5;
   color: #333;
   text-align: center;
}

.formexpiry-notification-close {
   position: absolute;
   top: 12px;
   right: 12px;
   background: transparent;
   border: none;
   font-size: 28px;
   line-height: 1;
   color: #999;
   cursor: pointer;
   padding: 0;
   width: 32px;
   height: 32px;
   display: flex;
   align-items: center;
   justify-content: center;
   border-radius: 4px;
   transition: all 0.2s ease;
}

.formexpiry-notification-close:hover {
   background: #f0f0f0;
   color: #333;
}

/* Animációk */
@keyframes fadeIn {
   from {
      opacity: 0;
   }
   to {
      opacity: 1;
   }
}

@keyframes slideIn {
   from {
      transform: translate(-50%, -60%);
      opacity: 0;
   }
   to {
      transform: translate(-50%, -50%);
      opacity: 1;
   }
}

/* Responsive */
@media (max-width: 768px) {
   .formexpiry-notification {
      max-width: 90%;
      width: 90%;
   }
   
   .formexpiry-notification-content {
      padding: 20px;
   }
   
   .formexpiry-warning-message,
   .formexpiry-expired-message {
      font-size: 14px;
   }
}

/* Kapacitás számláló - egyszerű, statikus design */
.formexpiry-capacity-counter {
   display: inline-block;
   padding: 6px 12px;
   margin-bottom: 12px;
   background: #f8f9fa;
   color: #495057;
   border: 1px solid #dee2e6;
   border-radius: 4px;
   font-weight: 500;
   font-size: 14px;
}

.formexpiry-capacity-counter .capacity-text {
   vertical-align: middle;
}

/* Live countdown */
.formexpiry-live-countdown {
   display: block;
   padding: 8px 12px;
   margin-bottom: 12px;
   background: #f8f9fa;
   color: #495057;
   border: 1px solid #dee2e6;
   border-radius: 4px;
   font-size: 14px;
}

.formexpiry-live-countdown .countdown-prefix {
   font-weight: 500;
   margin-right: 8px;
}

.formexpiry-live-countdown .countdown-time {
   font-weight: 600;
   color: #212529;
}

.formexpiry-live-countdown .countdown-suffix {
   font-weight: 400;
   margin-left: 8px;
}

/* Countdown egységek (days, hours, minutes, seconds) */
.formexpiry-live-countdown .countdown-unit {
   display: inline-block;
   margin-right: 8px;
}

.formexpiry-live-countdown .countdown-unit:last-child {
   margin-right: 0;
}

.formexpiry-live-countdown .countdown-value {
   font-weight: 700;
   font-size: 16px;
   color: #212529;
}

.formexpiry-live-countdown .countdown-label {
   font-weight: 400;
   font-size: 13px;
   color: #6c757d;
}

/* Specific units - testreszabható */
.formexpiry-live-countdown .countdown-days .countdown-value {
   /* color: #dc3545; */ /* Példa: piros szín napokhoz */
}

.formexpiry-live-countdown .countdown-hours .countdown-value {
   /* color: #fd7e14; */ /* Példa: narancs órákhoz */
}

.formexpiry-live-countdown .countdown-minutes .countdown-value {
   /* color: #ffc107; */ /* Példa: sárga percekhez */
}

.formexpiry-live-countdown .countdown-seconds .countdown-value {
   /* color: #28a745; */ /* Példa: zöld másodpercekhez */
}

/* Static countdown */
.formexpiry-static-countdown {
   display: block;
   padding: 8px 12px;
   margin-bottom: 12px;
   background: #f8f9fa;
   color: #495057;
   border: 1px solid #dee2e6;
   border-radius: 4px;
   font-size: 14px;
}

.formexpiry-static-countdown .countdown-prefix {
   font-weight: 500;
}

.formexpiry-static-countdown .countdown-time {
   font-weight: 600;
   color: #212529;
}

.formexpiry-static-countdown .countdown-suffix {
   font-weight: 400;
}

/* Form overlay sráfozás */
.formexpiry-form-overlay {
   position: absolute;
   top: 0;
   left: 0;
   width: 100%;
   height: 100%;
   background: repeating-linear-gradient(
      45deg,
      rgba(220, 53, 69, 0.03),
      rgba(220, 53, 69, 0.03) 10px,
      transparent 10px,
      transparent 20px
   );
   pointer-events: all;
   cursor: not-allowed;
   z-index: 998;
   backdrop-filter: grayscale(0.3);
}

/* Hover effekt az overlay-n */
.formexpiry-form-overlay:hover {
   background: repeating-linear-gradient(
      45deg,
      rgba(220, 53, 69, 0.05),
      rgba(220, 53, 69, 0.05) 10px,
      transparent 10px,
      transparent 20px
   );
}

