/* ============================================================
   STANDALONE CMS CSS
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans:wght@400;500;600;700;800&display=swap');

* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Noto Sans', sans-serif; background: #f0f2f5; color: #333; }

/* Login */
.login-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
}
.login-box {
  background: #fff;
  padding: 40px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  width: 100%;
  max-width: 400px;
  text-align: center;
}
.login-box h2 { margin-bottom: 24px; color: #111; }
.login-box input {
  width: 100%;
  padding: 12px;
  margin-bottom: 16px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
}
.login-box button {
  width: 100%;
  padding: 12px;
  background: #f26522;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
}
.error-msg {
  background: #ffebee;
  color: #c62828;
  padding: 10px;
  margin-bottom: 16px;
  border-radius: 4px;
  font-size: 14px;
}

/* Dashboard Layout */
.cms-dashboard {
  display: flex;
  min-height: 100vh;
}
.cms-sidebar {
  width: 250px;
  background: #2c3e50;
  color: #fff;
  padding: 20px 0;
}
.cms-sidebar h2 {
  text-align: center;
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 1px solid #34495e;
}
.cms-sidebar ul { list-style: none; }
.cms-sidebar li {
  padding: 15px 20px;
  cursor: pointer;
  border-left: 4px solid transparent;
  transition: all 0.2s;
}
.cms-sidebar li:hover { background: #34495e; }
.cms-sidebar li.active { background: #34495e; border-left-color: #f26522; font-weight: bold; }

.cms-main {
  flex: 1;
  padding: 30px;
  background: #f5f6fa;
}

.cms-tab { display: none; }
.cms-tab.active { display: block; }

.cms-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
}
.btn-primary {
  padding: 10px 20px;
  background: #3498db;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 600;
}

/* Settings Form */
.settings-form {
  background: #fff;
  padding: 30px;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
  max-width: 600px;
}
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 8px; font-weight: 600; }
.form-group input, .form-group textarea, .form-group select {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-family: inherit;
}

/* Table */
.cms-table {
  width: 100%;
  background: #fff;
  border-radius: 8px;
  border-collapse: collapse;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.cms-table th, .cms-table td {
  padding: 15px;
  text-align: left;
  border-bottom: 1px solid #eee;
}
.cms-table th { background: #fafafa; font-weight: 600; }
.cms-thumb { width: 60px; height: 40px; object-fit: cover; border-radius: 4px; }
.action-btn {
  padding: 6px 12px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  margin-right: 5px;
}
.btn-edit { background: #f39c12; color: #fff; }
.btn-del { background: #e74c3c; color: #fff; }

/* Modal */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}
.modal-overlay.active { display: flex; }
.modal-content {
  background: #fff;
  width: 100%;
  max-width: 600px;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  max-height: 90vh;
}
.modal-header {
  padding: 20px;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.modal-close { font-size: 24px; cursor: pointer; }
.modal-body { padding: 20px; overflow-y: auto; }
.modal-footer { padding: 20px; border-top: 1px solid #eee; text-align: right; }
