/* Distantec ssl page styles. Extracted from index.html for caching and CSP readiness. */
:root {
  --bg: #0a0a0f;
  --surface: rgba(255,255,255,0.04);
  --surface-hover: rgba(255,255,255,0.07);
  --border: rgba(255,255,255,0.08);
  --primary: #6366f1;
  --primary-light: #818cf8;
  --accent: #8b5cf6;
  --text: #e2e8f0;
  --text-muted: #64748b;
  --text-sub: #94a3b8;
}

body {
  min-height: 100vh;
  display: block;
  align-items: unset;
  justify-content: unset;
  padding: 0 0 4rem;
  background: var(--bg);
  background-image:
    radial-gradient(ellipse at 15% 40%, rgba(99,102,241,0.12) 0%, transparent 55%),
    radial-gradient(ellipse at 85% 15%, rgba(139,92,246,0.1) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 90%, rgba(59,130,246,0.08) 0%, transparent 50%);
  color: var(--text);
}


.search-box {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.input-box {
  min-width: 0;
  flex: 1;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  color: #fff;
  padding: 0.9rem 1.2rem;
  font-size: 1rem;
  outline: none;
  transition: border-color 0.2s;
}
.input-box:focus { border-color: #6366f1; }
.input-box::placeholder { color: #4b5563; }

.btn {
  flex-shrink: 0;
  white-space: nowrap;
  padding: 0.9rem 2rem;
  border-radius: 12px;
  border: none;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: white;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}
.btn:hover { transform: translateY(-2px); filter: brightness(1.1); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; filter: none; }

.hint {
  font-size: 0.8rem;
  color: #64748b;
  margin-bottom: 1.5rem;
}

    /* Results */
    .result-area {
      display: none;
      flex-direction: column;
      gap: 1rem;
    }

    .result-area.visible { display: flex; }

    .loading {
      text-align: center;
      padding: 3rem;
      color: #64748b;
    }

    .loading .spinner {
      display: inline-block;
      width: 32px;
      height: 32px;
      border: 3px solid rgba(255,255,255,0.1);
      border-top-color: #818cf8;
      border-radius: 50%;
      animation: spin 0.8s linear infinite;
      margin-bottom: 1rem;
    }

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

    /* Domain card */
    .domain-card {
      background: rgba(0, 0, 0, 0.25);
      border: 1px solid rgba(255, 255, 255, 0.08);
      border-radius: 18px;
      padding: 1.5rem;
      animation: fadeIn 0.3s ease;
    }

    @keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

    .card-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      margin-bottom: 1.25rem;
      gap: 0.75rem;
    }

    .domain-name {
      font-size: 1.1rem;
      font-weight: 700;
      color: #e2e8f0;
      word-break: break-all;
    }

    .status-badge {
      padding: 0.35rem 0.9rem;
      border-radius: 9999px;
      font-size: 0.75rem;
      font-weight: 700;
      white-space: nowrap;
      letter-spacing: 0.03em;
    }

    .status-valid { background: rgba(34,197,94,0.15); color: #4ade80; border: 1px solid rgba(34,197,94,0.3); }
    .status-warning { background: rgba(234,179,8,0.15); color: #facc15; border: 1px solid rgba(234,179,8,0.3); }
    .status-critical { background: rgba(249,115,22,0.15); color: #fb923c; border: 1px solid rgba(249,115,22,0.3); }
    .status-expired { background: rgba(239,68,68,0.15); color: #f87171; border: 1px solid rgba(239,68,68,0.3); }
    .status-error { background: rgba(239,68,68,0.15); color: #f87171; border: 1px solid rgba(239,68,68,0.3); }

    /* Info grid */
    .info-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
      gap: 1rem;
    }

    .info-item {
      display: flex;
      flex-direction: column;
      gap: 0.2rem;
    }

    .info-label {
      font-size: 0.75rem;
      color: #64748b;
      text-transform: uppercase;
      letter-spacing: 0.05em;
      font-weight: 600;
    }

    .info-value {
      font-size: 0.92rem;
      color: #cbd5e1;
      word-break: break-all;
      font-family: 'JetBrains Mono', 'Consolas', monospace;
    }

    .info-value.mono-small {
      font-size: 0.78rem;
      color: #94a3b8;
    }

    /* Days progress bar */
    .days-bar-container {
      margin-top: 1rem;
      padding-top: 1rem;
      border-top: 1px solid rgba(255,255,255,0.05);
    }

    .days-bar-label {
      display: flex;
      justify-content: space-between;
      margin-bottom: 0.5rem;
      font-size: 0.8rem;
    }

    .days-bar-label span:first-child { color: #64748b; }
    .days-bar-label span:last-child { font-weight: 700; }

    .days-bar {
      height: 6px;
      background: rgba(255,255,255,0.08);
      border-radius: 3px;
      overflow: hidden;
    }

    .days-bar-fill {
      height: 100%;
      border-radius: 3px;
      transition: width 0.5s ease;
    }

    .fill-valid { background: linear-gradient(90deg, #22c55e, #4ade80); }
    .fill-warning { background: linear-gradient(90deg, #eab308, #facc15); }
    .fill-critical { background: linear-gradient(90deg, #f97316, #fb923c); }
    .fill-expired { background: linear-gradient(90deg, #ef4444, #f87171); }

    /* SAN tags */
    .san-section {
      margin-top: 1rem;
      padding-top: 1rem;
      border-top: 1px solid rgba(255,255,255,0.05);
    }

    .san-label {
      font-size: 0.75rem;
      color: #64748b;
      text-transform: uppercase;
      letter-spacing: 0.05em;
      font-weight: 600;
      margin-bottom: 0.6rem;
    }

    .san-tags {
      display: flex;
      flex-wrap: wrap;
      gap: 0.4rem;
    }

    .san-tag {
      background: rgba(129, 140, 248, 0.1);
      border: 1px solid rgba(129, 140, 248, 0.2);
      color: #a5b4fc;
      padding: 0.25rem 0.65rem;
      border-radius: 8px;
      font-size: 0.78rem;
      font-family: 'JetBrains Mono', monospace;
    }

    .san-tag.match {
      background: rgba(34,197,94,0.12);
      border-color: rgba(34,197,94,0.25);
      color: #86efac;
    }

    /* Error card */
    .error-msg {
      color: #f87171;
      padding: 1rem;
      background: rgba(239,68,68,0.08);
      border: 1px solid rgba(239,68,68,0.15);
      border-radius: 12px;
      font-size: 0.9rem;
    }


.info-item-wide { grid-column: 1 / -1; }
.days-left { font-weight: 700; }
.days-left-valid { color: #4ade80; }
.days-left-warning { color: #facc15; }
.days-left-critical { color: #fb923c; }
.days-left-expired { color: #f87171; }
.w-0 { width: 0%; }
.w-5 { width: 5%; }
.w-10 { width: 10%; }
.w-15 { width: 15%; }
.w-20 { width: 20%; }
.w-25 { width: 25%; }
.w-30 { width: 30%; }
.w-35 { width: 35%; }
.w-40 { width: 40%; }
.w-45 { width: 45%; }
.w-50 { width: 50%; }
.w-55 { width: 55%; }
.w-60 { width: 60%; }
.w-65 { width: 65%; }
.w-70 { width: 70%; }
.w-75 { width: 75%; }
.w-80 { width: 80%; }
.w-85 { width: 85%; }
.w-90 { width: 90%; }
.w-95 { width: 95%; }
.w-100 { width: 100%; }


@media (max-width: 600px) {
  .search-box { flex-direction: column; }
  .btn { width: 100%; text-align: center; }
  .info-grid { grid-template-columns: 1fr; }
  .card-header { flex-direction: column; align-items: flex-start; }
}


/* Local visibility utility; avoids stale cached /css/common.css keeping loaders visible. */
.is-hidden { display: none !important; }
