
:root{
  --red:#8e0e0e;
  --red-dark:#6f0a0a;
  --blue:#1e2c72;
  --blue2:#2a4e99;
  --bg:#f3f5f8;
  --card:#ffffff;
  --text:#1f2937;
  --muted:#6b7280;
  --ring:rgba(0,0,0,.08);
}

*{box-sizing:border-box}
html,body{margin:0;padding:0;font-family:'Inter',system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;color:var(--text);background:var(--bg)}

.container{max-width:1100px;margin:0 auto;padding:16px}
.row{display:flex}
.between{justify-content:space-between}
.center{align-items:center}
.gap{gap:10px}

.site-header{background:var(--card);border-bottom:1px solid #e5e7eb;position:sticky;top:0;z-index:10}
.brand{display:flex;align-items:center;gap:10px}
.brand .brand-name{font-weight:800;letter-spacing:.5px}
.logo{width:28px;height:28px}
.top-nav a{margin-left:16px;text-decoration:none;color:var(--text);font-weight:600}
.top-nav a.logout{color:var(--red)}

.login-wrapper{min-height:calc(100vh - 64px);display:flex;align-items:center;justify-content:center;padding:30px}
.login-card{background:var(--card);padding:32px;border-radius:16px;box-shadow:0 10px 20px var(--ring);width:420px;max-width:90vw}
.login-card h1{margin:0 0 12px;font-size:1.8rem;color:var(--blue)}
.login-card .sub{color:var(--muted);margin:0 0 24px;font-size:1rem;line-height:1.5}

/* Authentication Info Section */
.auth-info{margin:24px 0}
.info-item{display:flex;align-items:flex-start;gap:16px;margin-bottom:20px;padding:16px;background:#f8fafc;border-radius:12px;border-left:4px solid var(--blue)}
.info-item:last-child{margin-bottom:0}
.icon{width:24px;height:24px;flex-shrink:0;color:var(--blue)}
.info-text h3{margin:0 0 6px;font-size:1.1rem;color:var(--text)}
.info-text p{margin:0;color:var(--muted);font-size:.9rem;line-height:1.4}

/* Updated Form Styles */
.form{margin:24px 0}
.btn-primary{width:100%;padding:14px 16px;background:var(--blue);border:none;border-radius:12px;color:white;font-weight:700;cursor:pointer;font-size:1rem;display:flex;align-items:center;justify-content:center;gap:10px;transition:all 0.2s ease}
.btn-primary:hover{background:var(--blue2);transform:translateY(-1px)}
.btn-icon{width:20px;height:20px}

/* Error Message */
.err{background:#fee2e2;color:#7f1d1d;padding:12px 16px;border-radius:8px;margin-bottom:20px;border-left:4px solid var(--red)}

/* Troubleshooting Section */
.troubleshooting{margin:24px 0;padding:20px;background:#f1f5f9;border-radius:12px;border:1px solid #e2e8f0}
.troubleshooting h4{margin:0 0 12px;color:var(--text);font-size:1rem}
.troubleshooting ul{margin:0;padding-left:20px}
.troubleshooting li{margin-bottom:8px;color:var(--muted);font-size:.9rem;line-height:1.4}
.troubleshooting li:last-child{margin-bottom:0}

/* Hint Section */
.hint{color:var(--muted);margin-top:20px;font-size:.9rem;line-height:1.4;padding:12px;background:#fef3c7;border-radius:8px;border-left:4px solid #f59e0b}
.hint strong{color:var(--text)}

.top-panels{display:grid;grid-template-columns:1.1fr .9fr;gap:16px;margin-top:16px}
.panel{background:var(--card);border-radius:16px;box-shadow:0 10px 20px var(--ring);padding:16px}
.panel-header{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:10px}
.tiny-label{font-size:.8rem;color:var(--muted)}
.status-dot{font-size:.7rem;padding:4px 8px;border-radius:999px;background:#fee2e2;color:#7f1d1d;font-weight:800}
.status-dot.live{background:#dcfce7;color:#166534}
.grid-2{display:grid;grid-template-columns:repeat(2,1fr);gap:12px}
.stat{background:#fafafa;border:1px solid #f0f0f0;border-radius:12px;padding:12px}
.stat-label{color:var(--muted);font-size:.85rem}
.stat-value{font-weight:800;font-size:1.15rem;margin-top:4px}
.panel-footer .chip{display:inline-block;padding:8px 12px;border-radius:999px;background:#f3f4f6;text-decoration:none;color:#111827;font-weight:600}

.rightbox .badge.ok{background:#dcfce7;color:#166534;border:none}

.categories-panel{margin-top:20px;background:linear-gradient(135deg,var(--blue),var(--blue2));border-radius:18px;color:white;padding:16px 16px 18px 16px;box-shadow:0 14px 28px rgba(30,44,114,0.25)}
.categories-panel h3{margin:0 0 12px;font-weight:800}
.categories-grid{display:grid;grid-template-columns:repeat(6,1fr);gap:10px}
.cat-card{background:rgba(255,255,255,.08);border:1px solid rgba(255,255,255,.25);border-radius:14px;padding:12px;text-align:center}
.cat-icon{font-size:20px}
.cat-name{font-weight:700;margin-top:6px}
.cat-count{font-size:.8rem;opacity:.9}

.search-wrap{margin:16px 0}
.search-wrap input{width:100%;padding:14px 16px;border-radius:14px;border:1px solid #e5e7eb;box-shadow:inset 0 1px 2px rgba(0,0,0,.02)}

.tools-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin-bottom:40px}
.tool-card{background:var(--card);border-radius:16px;box-shadow:0 8px 16px var(--ring);padding:12px;border:1px solid #eee;display:flex;flex-direction:column}
.tool-header{display:flex;justify-content:space-between;align-items:center}
.tool-logo{width:44px;height:44px;border-radius:10px;background:#f3f4f6;display:flex;align-items:center;justify-content:center;font-weight:800}
.badges .badge{font-size:.7rem;padding:4px 8px;border-radius:999px;border:1px solid #e5e7eb;margin-left:6px}
.badges .badge.live{background:#dcfce7;color:#166534;border:none}
.badges .badge.new{background:#dbeafe;color:#1e3a8a;border:none}
.badges .badge.hot{background:#fee2e2;color:#7f1d1d;border:none}
.tool-body{margin:10px 0 12px}
.tool-name{font-weight:800}
.tool-desc{color:var(--muted);font-size:.9rem;margin-top:4px;min-height:18px}
.tool-footer{margin-top:auto;display:flex;gap:8px}
.btn-red,.btn-outline{flex:1;text-align:center;text-decoration:none;padding:10px 12px;border-radius:10px;font-weight:700}
.btn-red{background:var(--red);color:#fff}
.btn-red:hover{background:var(--red-dark)}
.btn-outline{border:1px solid #e5e7eb;color:#111827;background:#fff}

@media (max-width: 980px){
  .tools-grid{grid-template-columns:repeat(2,1fr)}
  .categories-grid{grid-template-columns:repeat(3,1fr)}
  .top-panels{grid-template-columns:1fr}
}
.tool-page { text-align:center; margin:20px auto; max-width:700px; }
.category-title {
  grid-column: 1 / -1;
  margin: 20px 0 10px;
  font-size: 1.5rem;
  color: var(--blue);
}

.category-divider {
  grid-column: 1 / -1;
  width: 100%;
  border: 0;
  border-top: 1px solid #e5e7eb;
  margin: 20px 0;
}
.category-section {
  grid-column: 1 / -1;
  display: contents; /* Allows children to be direct members of the grid */
}


.tool-logo img { max-height:80px; margin:10px auto; }
.card {
  border: 2px solid #a00;
  padding: 15px;
  border-radius: 12px;
  margin: 20px 0;
  background: #fff;
}
.server-buttons { display:flex; gap:15px; justify-content:center; }
.btn {
  background:#8b0000;
  color:#fff;
  padding:12px 25px;
  border-radius:25px;
  text-decoration:none;
  font-weight:bold;
  transition:0.2s;
}
.btn:hover { background:#600; }
.update-note {
  background:#a00;
  color:#fff;
  padding:10px;
  border-radius:10px;
}

.tool-logo.center-logo {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%; /* Ensure it takes full width to center content */
  height: auto; /* Adjust height as needed */
  background: none; /* Remove background if not needed */
}

.tool-logo.center-logo img {
  display: block;
  margin: 0 auto; /* Center the image itself */
}

/* Error Reporting Styles */
.error-reports-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.error-report-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fafafa;
}

.tool-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.tool-info .tool-logo {
  width: 36px;
  height: 36px;
  font-size: 0.8rem;
}

.tool-name {
  font-weight: 600;
}
.btn.working {
  cursor: not-allowed;
  opacity: 0.7;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.spinner {
  margin-left: 8px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: #fff;
  width: 16px;
  height: 16px;
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.report-count {
  color: var(--muted);
  font-size: 0.9rem;
}

.view-reports .btn-outline {
  padding: 6px 12px;
  font-size: 0.85rem;
}

.error-report-form .form-group {
  margin-bottom: 20px;
}

.error-report-form label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
}

.error-report-form select,
.error-report-form textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
}

.error-report-form textarea {
  min-height: 120px;
  resize: vertical;
}

.alert {
  padding: 12px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.alert.success {
  background: #dcfce7;
  color: #166534;
  border: 1px solid #bbf7d0;
}

/* Notification Badge Styles */
.nav-item {
  position: relative;
  display: inline-block;
}

.notification-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #ef4444;
  color: white;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  font-size: 0.7rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
}

/* Recent Reports Styles */
.recent-reports {
  margin-bottom: 30px;
}

.recent-reports h3 {
  margin-bottom: 15px;
}

.reports-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.report-item {
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 15px;
  background: #fafafa;
}

.report-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.report-type {
  font-size: 0.85rem;
  color: var(--muted);
}

.report-time {
  font-size: 0.8rem;
  color: var(--muted);
}

.report-description {
  margin-bottom: 10px;
  padding: 10px;
  background: white;
  border-radius: 5px;
}

.reporter {
  font-size: 0.85rem;
  color: var(--muted);
}

/* Stats Styles */
.stats {
  display: flex;
  justify-content: space-between;
  text-align: center;
}

.stat-item {
  flex: 1;
}

.stat-value {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary);
}
.stat-message {
  font-size: 0.9rem;
  font-weight: bold;
  color: var(--muted);
}
.stat-font {
  font-size: 1.2rem;
  font-weight: bold;
  color: var(--muted);
}


.resolve-btn {
  background: #8e0e0e !important;
  color: white !important;
  border: 1px solid #8e0e0e !important;
  font-weight: bold !important;
}
.stat-label {
  font-size: 0.85rem;
  color: var(--muted);
}

.report-actions {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid #e5e7eb;
}

.report-actions .btn-outline {
  padding: 6px 12px;
  font-size: 0.85rem;
  background: #8e0e0e;
  color: white;
  border: 1px solid #8e0e0e;
}
/* Add to your existing CSS file */
.tool-card {
    position: relative;
}

.favorite-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    line-height: 0;
    border-radius: 50%;
    color: #ccc;
    transition: color 0.2s, transform 0.2s;
}

.favorite-btn:hover {
    color: #ffc107;
    transform: scale(1.1);
}

.favorite-btn.favorited {
    color: #ff4500; /* A nice "favorited" color */
}

.favorite-btn svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}
#notification-content {
  color: #e20d0d;
  font-family: Arial, sans-serif;
  transition: all 0.3s ease;
}

#notification-content.update {
  color: #e63946;
  font-family: 'Poppins', sans-serif;
  font-weight: normal;
}
