/* Base */
* { box-sizing: border-box; }
html, body {
  margin: 0;
  padding: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, 'Noto Sans';
  color: #0b2b36;
  min-height: 100%;
  background: #0b0d10; /* never white flash */
  background-image:
  radial-gradient(1200px 800px at 20% 10%, rgba(255,255,255,0.08), transparent 60%),
  url('/.codes/background.jpg'); /* <- pick your one file */
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

/* Container */
.content-container {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.uploader-container {
  width: min(100%, 960px);
  background: #fff;
  border: 1px solid #e0eef2;
  border-radius: 16px;
  padding: 20px 20px 28px;
  box-shadow: 0 1px 6px rgba(0,0,0,0.05);
  text-align: center;
}

.upload-text { font-size: 22px; margin: 0 0 4px; font-weight: 700; color: #0e5167; }
.upload-info-text { margin: 0 0 14px; color: #0e5167; }

/* Project ID */
.project-id-input {
  width: 320px;
  padding: 14px;
  border: 2px solid #0e91b4;
  border-radius: 10px;
  font-size: 18px;
  font-weight: 700;
  text-align: center;
  color: #0e5167;
}
.project-id-input::placeholder { font-weight: 600; color: #0e5167; opacity: 0.7; }
.project-id-input.invalid { border-color: #e53935 !important; background: #ffebee; }

/* Picker row */
.picker-row { display: flex; align-items: stretch; gap: 12px; margin-top: 12px; }
.choose-file-btn {
  flex: 0 0 20%;
  display: flex; align-items: center; justify-content: center;
  min-height: 72px; background: #0e91b4; color: #fff;
  padding: 10px 12px; border-radius: 10px; cursor: pointer;
  font-size: 16px; line-height: 1.2; text-align: center;
}
.choose-file-btn:hover { background: #0b7895; }
.drag-drop-box {
  flex: 1 1 80%; border: 2px dashed #7ab4c5; border-radius: 14px; background: #ffffff;
  padding: 10px; display: flex; align-items: center; justify-content: center;
  min-height: 72px; text-align: center; transition: background .2s, border-color .2s;
}
.drag-drop-box.drag-over { background: #e6f4f8; border-color: #0e91b4; }
.drag-drop-text { margin: 0; color: #355f6d; }

/* Rename hint + grid */
.rename-hint { margin: 12px 0 8px; font-size: 13px; color: #355f6d; }
.selected-files {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}

/* Preview card */
.preview-wrapper {
  position: relative; background: #fff; border: 1px solid #e0eef2;
  border-radius: 12px; padding: 10px; box-shadow: 0 1px 0 rgba(0,0,0,0.03);
}
.preview-wrapper img {
  display: block; width: 100%; height: 150px; object-fit: cover;
  border-radius: 8px; background: #f0f6f8;
}

/* Badges & controls */
.file-size-indicator {
  position: absolute; top: 6px; left: 6px;
  background: rgba(0,0,0,0.7); color: #fff; font-size: 11px;
  padding: 2px 6px; border-radius: 6px;
}
.remove-button {
  position: absolute; top: 6px; right: 6px;
  width: 26px; height: 26px; border-radius: 50%;
  background: rgba(0,0,0,0.65); color: #fff; display: grid; place-items: center;
  font-weight: 700; cursor: pointer;
}
.remove-button:hover { background: rgba(0,0,0,0.8); }

.name-editor { margin-top: 8px; display: grid; gap: 6px; }
.name-input {
  width: 100%; padding: 8px 10px; border: 1px solid #cfe3e9; border-radius: 8px; font-size: 13px;
}
.name-input.invalid { border-color: #e53935 !important; background: #ffebee; }
.name-meta {
  margin-top: 4px; font-size: 11px; color: #607d8b; display: flex; justify-content: space-between;
}
.note-badge {
  display: inline-block; margin-right: 6px; padding: 2px 6px; font-size: 11px;
  color: #8a6d3b; background: #fff3cd; border: 1px solid #ffeeba; border-radius: 6px;
}

/* Quota line */
.upload-limits-text { margin-top: 10px; font-size: 13px; color: #355f6d; }
.upload-limits-text.over { color: #e53935; font-weight: 600; }

/* Actions */
.actions { display: flex; gap: 10px; justify-content: center; margin-top: 8px; }
.submit-btn {
  background: #0e91b4; color: #fff; border: none; padding: 10px 16px;
  border-radius: 10px; cursor: pointer; font-size: 15px;
}
.submit-btn:disabled { background: #b7c8ce; cursor: not-allowed; }
.secondary-btn {
  background: #edf6f9; color: #0e5167; border: 1px solid #cfe3e9;
  padding: 10px 16px; border-radius: 10px; cursor: pointer; font-size: 15px;
}
.secondary-btn:disabled { opacity: .5; cursor: not-allowed; }

/* Modal */
.modal { display: none; position: fixed; z-index: 10; left: 0; top: 0; width: 100%; height: 100%;
  background: rgba(0,0,0,0.35);
}
.modal.open { display: grid; place-items: center; }
.modal-content { background: #fff; width: min(92%, 720px); border-radius: 16px; padding: 18px; border: 1px solid #e0eef2; }
.close { float: right; cursor: pointer; font-size: 22px; }

/* Progress bars */
.progress-wrap {
  width: 100%; height: 8px; background: rgba(0,0,0,0.08);
  border-radius: 999px; margin: 10px 0;
}
.progress-bar {
  height: 100%; width: 0%; background: #4ade80; border-radius: 999px; transition: width .2s ease;
}

/* Log */
#modal-log {
  background: #f9fcfd; border: 1px solid #e0eef2; padding: 10px; border-radius: 10px;
  max-height: 260px; overflow: auto; font-size: 12px; white-space: pre-wrap; margin-top: 10px;
}

.btn-innskraning{
  display:inline-flex; align-items:center; gap:.5rem;
  padding:.55rem .9rem;
  background:#005b78; color:#fff; text-decoration:none;
  border-radius:12px; font-weight:700; line-height:1;
  box-shadow:0 1px 0 rgba(0,0,0,.05), 0 6px 16px rgba(0,91,120,.18);
  transition:filter .15s, transform .02s;
	position:fixed; top:16px; right:16px; z-index:9999;
}

.btn-innskraning:hover{ filter:brightness(1.06); }
.btn-innskraning:active{ transform:translateY(1px); }
.btn-innskraning svg{ margin-left:.1rem; }


/* Responsive */
@media (max-width: 640px) {
  .picker-row { flex-direction: column; }
  .choose-file-btn, .drag-drop-box { min-height: 60px; flex: 0 0 auto; }
}
