/* Reset for full-height layout */
html,
body {
  min-height: 100%;
  margin: 0;
  padding: 0;
}

body {
  font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  background: linear-gradient(
    180deg,
    rgba(31, 162, 183, 0.02) 2.4%,
    rgba(31, 162, 183, 0.12) 73.08%
  );
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  min-width: 200px;
  width: 100%;
  color: #000000;
  box-sizing: border-box;
  padding: 24px;
}

h1 { font-weight: 400; 
	margin: 0px;
}

/* Top-right logo */
.logo {
  position: fixed;
  top: 24px;
  left: 24px;
  width: 160px;
  height: 50px;

  background-image: url("https://www.elpro.com/hubfs/2024%20New%20Website/24%20-%20Homepage/ELPRO_Logo.svg");

  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;

  /* Optional: visual fallback while loading */
  background-color: transparent;

  z-index: 1000;
}

/* Centered card */
.card {
  width: 50vw;
  max-width: 820px;
  min-width: 0;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.05);
  backdrop-filter: blur(4px);
  box-sizing: border-box;
}

/* MUI lg: below 1200px */
@media (max-width: 1199.95px) {
  .card {
    width: 60vw;
  }
}

/* MUI md: below 900px */
@media (max-width: 899.95px) {
  .card {
    width: 75vw;
    max-width: 720px;
  }
}

/* MUI sm: below 600px */
@media (max-width: 599.95px) {
  body {
    padding: 80px 16px 24px;
  }

  .card {
    width: 100%;
    max-width: none;
    padding: 20px;
    gap: 20px;
  }
}

/* Very small phones */
@media (max-width: 359.95px) {
  body {
    padding-inline: 12px;
  }

  .card {
    padding: 16px;
    gap: 16px;
  }
}

/* Drop zone */
#drop-zone {
  width: 100%;
  height: 200px;
  display: grid;
  place-items: center;
  box-sizing: border-box;
  border: 2px dashed #ccc;
  border-radius: 6px;
  padding: 8px;
  cursor: pointer;
  transition: 0.2s ease;
}
#drop-zone:hover {
  border-color: #1aa2b7;
  background: rgba(31, 162, 183, 0.05);
}

/* Hide actual file input */
#file-input { display: none; }

/* Buttons */
button {
  background: #0B5F6C;
  color: #fff;
  padding: 12px 16px;
	float: right;
  margin-left: 16px;
	margin-top: 24px;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 
      0 2px 4px rgba(0, 0, 0, 0.12),
      0 4px 6px rgba(0, 0, 0, 0.10);
  transition: background 0.2s ease, box-shadow 0.2s ease, transform 0.1s ease;
}
button:hover {
  background: #094F5A;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.14), 0 6px 12px rgba(0, 0, 0, 0.10);
}
button:active {
  background: #073F48;
  transform: scale(0.98);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}
button:focus-visible {
  outline: 3px solid rgba(31, 162, 183, 0.5);
  outline-offset: 3px;
}

button:disabled {
  background: #ccc;
  color: #333;
  cursor: not-allowed;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

#clear-btn {
  background: #fff;
  color: #0B5F6C;
	
	box-shadow:
        inset 0 0 0 2px #0B5F6C,   /* inner border */
        0 2px 4px rgba(0, 0, 0, 0.12),
        0 4px 6px rgba(0, 0, 0, 0.10);

  transition: background 0.2s ease,
              color 0.2s ease,
              border-color 0.2s ease,
              box-shadow 0.2s ease,
              transform 0.1s ease;
}

/* Hover */
#clear-btn:hover {
  background: rgba(31, 162, 183, 0.18);
  color: #094F5A;
}

/* Active */
#clear-btn:active {
  background: rgba(31, 162, 183, 0.15);
  transform: scale(0.97);
}

/* Focus for accessibility */
#clear-btn:focus-visible {
  outline: 3px solid rgba(31, 162, 183, 0.4);
  outline-offset: 2px;
}

#clear-btn:disabled {
  background: #f0f0f0;
  color: #555;
  box-shadow: inset 0 0 0 2px #ddd;
}

/* Preview list reset */
#preview {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 260px;          /* scroll if many files */
  overflow-y: auto;
  border: 1px solid #eee;
  border-radius: 6px;
  background: #fafafa;
}

/* Each file item */
#preview li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid #eee;
  font-size: 15px;
  color: #333;
  justify-content: space-between;
}

#preview li:last-child {
  border-bottom: none;
}

/* File item content wrapper */
#preview li .file-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  flex: 1;
  min-width: 0;
}

/* File name */
#preview li .file-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: 100%;
}

#preview li .file-issue {
  font-size: 12px;
  line-height: 1.35;
  color: #b03a2e;
  word-break: break-word;
}

/* Simple file icon using emoji */
#preview li::before {
  content: "📄";
  font-size: 18px;
  opacity: 0.9;
}

/* Status indicator */
#preview li .status {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  white-space: nowrap;
  flex-shrink: 0;
}

#preview li .status.pending {
  color: #666;
}

#preview li .status.uploading {
  color: #1aa2b7;
}

#preview li .status.success {
  color: #2ecc71;
}

#preview li .status.error {
  color: #e74c3c;
}

/* Status icons */
.status-icon {
  font-size: 14px;
}

/* Hover state */
#preview li:hover {
  background: #f3fbfd; /* subtle hint aligning with your teal brand */
}

/* Hidden utility class */
.hidden {
  display: none !important;
}

/* Loading Spinner */
.loading-spinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 40px 24px;
  background: #fafafa;
  border-radius: 6px;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid #eee;
  border-top-color: #1aa2b7;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

#loading-text {
  margin: 0;
  color: #666;
  font-size: 16px;
}

/* Status Container */
.status-container {
  padding: 12px 16px;
  border-radius: 6px;
  border-left: 4px solid;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.status-container.success {
  background: #d4edda;
  border-left-color: #2ecc71;
  color: #155724;
}

.status-container.error {
  background: #f8d7da;
  border-left-color: #e74c3c;
  color: #721c24;
}

.status-container.warning {
  background: #fff3cd;
  border-left-color: #f39c12;
  color: #856404;
}

.status-container.info {
  background: #d1ecf1;
  border-left-color: #1aa2b7;
  color: #0c5460;
}

.status-icon-main {
  font-size: 20px;
  flex-shrink: 0;
}

.status-content {
  flex: 1;
}

.status-content h3 {
  margin: 0 0 4px 0;
  font-size: 16px;
  font-weight: 500;
}

.status-content p {
  margin: 0;
  font-size: 14px;
}
