/* Vercel Standalone Topbar & Hub Cards */
html, body {
  margin: 0;
  padding: 0;
  background: #F4F8F9;
  font-family: 'Montserrat', sans-serif;
  color: #0E3E49;
}
.dms-topbar {
  background: #041216;
  border-bottom: 1px solid #145766;
  position: sticky;
  top: 0;
  z-index: 100;
}
.dms-topbar-inner {
  max-width: 1220px;
  margin: 0 auto;
  padding: 12px 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.dms-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #ffffff;
  text-decoration: none;
  font-weight: 800;
  font-size: 15px;
}
.dms-brand-logo {
  height: 34px;
  width: auto;
  filter: brightness(0) invert(1);
}
.dms-topnav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.dms-nav-link {
  color: #d9eef2;
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 13px;
  border-radius: 8px;
  border: 1px solid transparent;
  transition: background 0.18s ease, border-color 0.18s ease;
}
.dms-nav-link:hover, .dms-nav-link.is-active {
  background: #0E3E49;
  border-color: #3E8FA1;
  color: #ffffff;
}
.dms-nav-back {
  background: rgba(140, 195, 206, 0.12);
  border-color: rgba(140, 195, 206, 0.35);
}
.dms-hub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 16px;
}
.dms-hub-card {
  background: #ffffff;
  border: 1px solid #cbe0e5;
  border-radius: 14px;
  padding: 22px;
  text-decoration: none;
  color: #0E3E49;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: transform 0.16s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.dms-hub-card:hover {
  transform: translateY(-2px);
  border-color: #3E8FA1;
  box-shadow: 0 14px 32px rgba(14, 62, 73, 0.12);
}
.dms-hub-icon {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: #0E3E49;
  color: #8CC3CE;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}
.dms-hub-card h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
}
.dms-hub-card p {
  margin: 0;
  font-size: 13.5px;
  color: #3f6670;
  flex: 1;
}
.dms-hub-cta {
  font-size: 13px;
  font-weight: 800;
  color: #145766;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.dms-dropzone {
  border: 2px dashed #8CC3CE;
  border-radius: 12px;
  background: #F4F8F9;
  padding: 28px 16px;
  text-align: center;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease;
}
.dms-dropzone:hover, .dms-dropzone.is-drag {
  background: #e5f2f5;
  border-color: #0E3E49;
}

/* Droid Mining Solutions — Coordinate Converter CSS
   WordPress Location: Appearance > Customize > Additional CSS
   All selectors are strictly scoped under .dms-cc to avoid Astra theme conflicts. */

.dms-cc,
.dms-cc * {
  box-sizing: border-box;
}

.dms-cc {
  font-family: 'Montserrat', sans-serif;
  color: #0E3E49;
  background: #F4F8F9;
  padding: 24px 16px 56px;
  min-height: 100vh;
  line-height: 1.5;
}

.dms-cc-shell {
  max-width: 1220px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Header */
.dms-cc-header {
  background: linear-gradient(135deg, #041216 0%, #0E3E49 60%, #145766 100%);
  color: #ffffff;
  border-radius: 16px;
  padding: 22px 24px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  box-shadow: 0 12px 32px rgba(4, 18, 22, 0.16);
}

.dms-cc-kicker {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #8CC3CE;
  margin-bottom: 6px;
}

.dms-cc-title {
  margin: 0 0 6px;
  font-size: clamp(20px, 2.5vw, 28px);
  font-weight: 800;
  color: #ffffff;
  line-height: 1.2;
}

.dms-cc-subtitle {
  margin: 0;
  font-size: 13.5px;
  color: #d9eef2;
  max-width: 780px;
}

.dms-cc-header-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(140, 195, 206, 0.14);
  border: 1px solid rgba(140, 195, 206, 0.4);
  color: #8CC3CE;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

/* Tabs */
.dms-cc-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.dms-cc-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid #cbe0e5;
  border-radius: 10px;
  background: #ffffff;
  color: #0E3E49;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.dms-cc-tab:hover {
  border-color: #3E8FA1;
  background: #eaf4f6;
  color: #0E3E49 !important;
}

.dms-cc-tab:focus-visible,
.dms-cc-btn:focus-visible,
.dms-cc-select:focus-visible,
.dms-cc-textarea:focus-visible {
  outline: 3px solid #3E8FA1;
  outline-offset: 2px;
}

.dms-cc-tab.is-active {
  background: #0E3E49;
  color: #ffffff;
  border-color: #0E3E49;
  box-shadow: 0 6px 18px rgba(14, 62, 73, 0.22);
}

/* Settings Bar */
.dms-cc-settings {
  background: #ffffff;
  border: 1px solid #d5e5e9;
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 14px;
}

.dms-cc-setting-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 155px;
  flex: 1 1 160px;
}

.dms-cc-setting-group label {
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #145766;
}

.dms-cc-select {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid #bfd7dd;
  border-radius: 8px;
  background: #F4F8F9;
  color: #041216;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
}

.dms-cc-checkbox-wrap {
  flex: 0 1 auto;
  justify-content: center;
  padding-bottom: 6px;
}

.dms-cc-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 13px !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
  color: #0E3E49 !important;
}

.dms-cc-check input[type="checkbox"] {
  width: 17px;
  height: 17px;
  accent-color: #0E3E49;
}

/* Alerts */
.dms-cc-alert {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 13px;
}

.dms-cc-alert-warn {
  background: #fff8e6;
  border: 1px solid #f0c36d;
  color: #5c3d00;
}

.dms-cc-alert-warn i {
  color: #c97a00;
  font-size: 18px;
  margin-top: 2px;
}

/* Cards */
.dms-cc-card {
  background: #ffffff;
  border: 1px solid #d5e5e9;
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dms-cc-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.dms-cc-card-title {
  margin: 0 0 2px;
  font-size: 16px;
  font-weight: 800;
  color: #0E3E49;
}

.dms-cc-card-hint {
  margin: 0;
  font-size: 12.5px;
  color: #3f6670;
}

.dms-cc-actions-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* Buttons */
.dms-cc-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 14px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.18s ease, border-color 0.18s ease;
  text-decoration: none;
}

.dms-cc-btn:active {
  transform: translateY(1px);
}

.dms-cc-btn-primary {
  background: #0E3E49;
  color: #ffffff;
}

.dms-cc-btn-primary:hover {
  background: #145766;
}

.dms-cc-btn-secondary {
  background: #eaf4f6;
  color: #0E3E49;
  border-color: #8CC3CE;
}

.dms-cc-btn-secondary:hover {
  background: #d7ecf0;
  border-color: #3E8FA1;
}

.dms-cc-btn-ghost {
  background: #ffffff;
  color: #145766;
  border-color: #cbdce0;
}

.dms-cc-btn-ghost:hover {
  background: #F4F8F9;
  border-color: #3E8FA1;
}

.dms-cc-btn-danger {
  background: #fff2f2;
  color: #9b1c1c;
  border-color: #f3c6c6;
}

.dms-cc-btn-danger:hover {
  background: #fee2e2;
}

/* Sheet selector */
.dms-cc-sheet-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  background: #F4F8F9;
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid #d5e5e9;
  font-size: 13px;
  font-weight: 700;
}

.dms-cc-sheet-bar .dms-cc-select {
  width: auto;
  min-width: 220px;
}

.dms-cc-file-status {
  font-weight: 600;
  color: #145766;
  font-size: 12.5px;
}

/* Textarea */
.dms-cc-textarea {
  width: 100%;
  min-height: 150px;
  padding: 12px;
  border: 1px solid #bfd7dd;
  border-radius: 10px;
  background: #fbfdfe;
  color: #041216;
  font-family: 'Share Tech Mono', Consolas, monospace;
  font-size: 13px;
  resize: vertical;
}

/* Column Mapping */
.dms-cc-colmap {
  background: #F4F8F9;
  border: 1px solid #d5e5e9;
  border-radius: 10px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.dms-cc-colmap-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 800;
  color: #0E3E49;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.dms-cc-colmap-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.dms-cc-colmap-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 145px;
  flex: 1 1 145px;
}

.dms-cc-colmap-item label {
  font-size: 11px;
  font-weight: 700;
  color: #145766;
}

/* Toolbar & Stats */
.dms-cc-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.dms-cc-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.dms-cc-stat {
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 600;
  background: #ffffff;
  border: 1px solid #d5e5e9;
}

.dms-cc-stat-ok {
  color: #166534;
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.dms-cc-stat-err {
  color: #991b1b;
  border-color: #fecaca;
  background: #fef2f2;
}

.dms-cc-export-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* Table */
.dms-cc-table-card {
  padding: 0;
  overflow: hidden;
}

.dms-cc-table-wrap {
  width: 100%;
  max-height: 460px;
  overflow: auto;
}

.dms-cc-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.dms-cc-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #0E3E49;
  color: #ffffff;
  text-align: left;
  padding: 10px 12px;
  font-weight: 700;
  white-space: nowrap;
  border-bottom: 2px solid #3E8FA1;
}

.dms-cc-table tbody td {
  padding: 8px 12px;
  border-bottom: 1px solid #e4eff2;
  white-space: nowrap;
  font-family: 'Share Tech Mono', Consolas, monospace;
}

.dms-cc-table tbody tr:nth-child(even) {
  background: #f8fbfc;
}

.dms-cc-table tbody tr.is-error {
  background: #fef2f2 !important;
  color: #991b1b;
}

.dms-cc-empty-row td {
  text-align: center;
  padding: 28px 16px !important;
  font-family: 'Montserrat', sans-serif !important;
  color: #4f727b;
}

.dms-cc-trunc-note {
  padding: 10px 14px;
  background: #eaf4f6;
  color: #0E3E49;
  font-size: 12.5px;
  font-weight: 600;
  border-top: 1px solid #cde1e6;
}

/* Responsive Mobile (375px+) */
@media (max-width: 820px) {
  .dms-cc {
    padding: 16px 10px 36px;
  }
  .dms-cc-header {
    flex-direction: column;
    padding: 18px 16px;
  }
  .dms-cc-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .dms-cc-tabs {
    grid-template-columns: 1fr;
  }
  .dms-cc-actions-inline,
  .dms-cc-export-btns {
    width: 100%;
  }
  .dms-cc-btn {
    flex: 1 1 auto;
  }
}
