@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;700&display=swap');
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.0/css/all.min.css');

body {
  font-family: 'DM Sans', sans-serif;
  background-color: #fff;
  color: #0f172a;
}
.qr-section {
    max-width: 1200px;
    width: 90%;
    margin: 0 auto;
    border-radius: 16px;
    padding: 2rem;
    margin-top: 10rem;
    box-shadow: 0 8px 20px rgb(155 155 155 / 43%);
    margin-bottom: 5rem;
    overflow: hidden;
}

.qr-container {
  background: #ffffff;
  border-radius: 16px;
  overflow: hidden;
}

.qr-container h2 {
  color: #002b5c;
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.qr-container p {
  color: #555;
  margin-bottom: 2rem;
}

.main-input-group {
  display: flex;
  gap: 10px;
  margin-bottom: 8px;
}

.qr-input {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 1rem;
}

.qr-btn {
  background: #ff6600;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  cursor: pointer;
  transition: 0.3s;
  font-weight: 600;
}
.qr-btn:hover {
  background: #e25a00;
}
.qr-btn.generate {
  background-color: #28a745;
}
.qr-btn.generate:hover {
  background-color: #218838;
}
.qr-btn:disabled {
  background-color: #ccc;
  cursor: not-allowed;
}

.qr-content-wrapper {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 40px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.qr-customize {
  flex: 1;
  min-width: 250px;
  max-width: 300px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  background: #fff;
  border: 1px solid #eee;
  border-radius: 10px;
  padding: 16px 20px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.color-options label,
.logo-upload label {
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 8px;
  display: block;
}

.color-list {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.color {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  cursor: pointer;
  border: 3px solid transparent;
  transition: 0.2s;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.color:hover {
  transform: scale(1.1);
}
.color.active {
  border-color: #007bff;
  box-shadow: 0 0 0 3px #007bff40;
}

.logo-box {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px dashed #bbb;
  border-radius: 8px;
  height: 80px;
  cursor: pointer;
  background-color: #fafafa;
  transition: background-color 0.2s, border-color 0.2s;
}
.logo-box:hover {
  background-color: #f0f0f0;
  border-color: #ff6600;
}

.add-logo {
  color: #555;
  font-size: 0.9rem;
  cursor: pointer;
}

.logo-info {
  font-size: 0.75rem;
  color: #999;
  margin-top: 6px;
  margin-bottom: 0;
}

.qr-preview-box {
  width: 250px;
  height: 250px;
  border: 2px dashed #ddd;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  border-radius: 8px;
  background: #f9f9f9;
}
.qr-preview-box label {
  font-weight: 600;
  font-size: 0.9rem;
  color: #555;
  display: none;
}
.qr-preview-box img {
  max-width: 100%;
  max-height: 100%;
}


.qr-list {
  margin-top: 1rem;
  overflow-x: auto;
}
.qr-list table {
  width: 100%;
  border-collapse: collapse;
}
.qr-list th, .qr-list td {
  border-bottom: 1px solid #ddd;
  text-align: left;
  padding: 0.75rem 1rem;
}
.qr-list th {
  background: #ff5003;
  color: white;
}
.qr-list td {
  vertical-align: middle;
}
.qr-thumb {
  width: 50px;
  height: 50px;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid #e2e8f0;
  transition: transform 0.2s ease;
}
.qr-thumb:hover {
  transform: scale(2.5);
  z-index: 10;
}
.qr-list td a {
  color: #ff5003;
  text-decoration: none;
  font-weight: 600;
}
.action-btn {
  margin-right: 0.5rem;
  border: none;
  border-radius: 6px;
  padding: 0.4rem 0.8rem;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 600;
}
.view-btn { background: #0055b1; color: white; }
.download-btn { background: #28a745; color: white; }
.delete-btn { background: #dc3545; color: white; }

.validation-error-message {
  color: #e53935;
  font-size: 0.875em;
  margin-top: 5px;
}
.hidden {
  display: none !important;
}

.popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
  opacity: 1;
}

.popup-content {
  background: #fff;
  border-radius: 12px;
  padding: 2rem;
  width: 90%;
  max-width: 450px;
  text-align: left;
  position: relative;
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
  animation: slideDown 0.35s ease;
}

@keyframes slideDown {
  from { transform: translateY(-30px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: none;
  border: none;
  font-size: 1.3rem;
  color: #444;
  cursor: pointer;
  transition: color 0.2s ease;
}
.modal-close:hover {
  color: #e11d48;
}

.qr-preview-in-modal, .qr-display-in-modal {
  display: flex;
  justify-content: center;
  margin-bottom: 1rem;
  padding: 1rem;
  border: 1px solid #eee;
  border-radius: 8px;
}
.qr-preview-in-modal img, .qr-display-in-modal img {
  width: 250px;
  height: 250px;
}
.popup-content .form-group {
  margin-bottom: 1.2rem;
}
.popup-content .form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.3rem;
}
.popup-content .form-group input {
  width: 100%;
  padding: 0.75rem;
  border: 1.5px solid #ddd;
  border-radius: 10px;
  font-size: 1rem;
}

.btn-primary {
  background: #28a745;
  color: white;
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  transition: background-color 0.2s;
}
.btn-primary:hover {
  background: #218838;
}
.btn-primary:disabled {
  background: #ccc;
  cursor: not-allowed;
}
.btn-secondary {
  background: #0055b1;
  color: white;
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  transition: background-color 0.2s;
}
.btn-secondary:hover {
  background: #004a9c;
}

.view-qr-modal-content p {
  margin-bottom: 0.5rem;
}
.view-qr-modal-content p strong {
  color: #333;
}
.view-qr-modal-content a {
  color: #ff6600;
  text-decoration: none;
  font-weight: 600;
}

.btn-remove-logo {
  background: #e53935;
  color: white;
  border: none;
  border-radius: 5px;
  padding: 4px 8px;
  font-size: 0.75rem;
  cursor: pointer;
  margin-top: 8px;
}
.btn-remove-logo:hover {
  background: #c62828;
}

.delete-modal-content p {
    margin-bottom: 1.5rem;
    color: #333;
    line-height: 1.6;
}
.delete-modal-content p:last-of-type {
    margin-bottom: 2rem;
}

.delete-modal-content p strong {
    color: #0f172a;
}

.modal-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.modal-actions button {
    width: auto;
    padding: 10px 20px;
    font-size: 0.9rem;
}

.btn-danger {
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.2s;
}
.btn-danger:hover {
    background: #c82333;
}
.btn-danger:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.modal-actions .btn-secondary {
    background: #6c757d;
    width: auto;
}
.modal-actions .btn-secondary:hover {
    background: #5a6268;
}

.links-tools {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.search-bar {
  background: #fff;
  border-radius: 15px;
  padding: 0.6rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid #e2e8f0;
  flex: 1;
  max-width: 400px;
  transition: box-shadow 0.3s ease;
}

.search-bar:hover,
.search-bar:focus-within {
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.search-bar i {
  color: #64748b;
}

.search-bar input {
  border: none;
  outline: none;
  width: 100%;
  font-size: 1rem;
  color: #0f172a;
}

.pagination-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 2rem;
  gap: 4px;
}

.page-btn {
  border: 1px solid #d1d5db;
  background-color: #ffffff;
  color: #475569;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 600;
  transition: all 0.2s ease;
  text-decoration: none;
}

.page-btn:hover {
  background-color: #f1f5f9;
  border-color: #ff5003;
  color: #ff5003;
}

.page-btn.active {
  background-color: #ff5003;
  border-color: #ff5003;
  color: #ffffff;
  z-index: 1;
}

.page-btn.disabled {
  color: #9ca3af;
  background-color: #f9fafb;
  cursor: not-allowed;
}

.qr-list .desc {
  color: #475569;
  margin-bottom: 1.5rem;
}






.qrc-section {
    max-width: 1200px;
    width: 90%;
    margin: 0 auto;
    border-radius: 16px;
    padding: 2rem;
    margin-top: 10rem;
    box-shadow: 0 8px 20px rgb(155 155 155 / 43%);
    margin-bottom: 5rem;
    overflow: hidden;
}

/* === HEADER === */
.qr-header {
  text-align: center;
  margin-bottom: 40px;
}

.qr-header h2 {
  font-size: 2rem;
  font-weight: 600;
  color: #222;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.qr-header p {
  color: #666;
  font-size: 1rem;
  margin-top: 5px;
}

/* === MAIN CONTENT === */
.qr-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  align-items: start;
  overflow: hidden;
}

/* === CREATE QR CARD === */
.qr-card {
  background: linear-gradient(135deg, #ff6600, #ff8533);
  border-radius: 20px;
  padding: 30px;
  color: #fff;
  box-shadow: 0 10px 20px rgba(255, 102, 0, 0.3);
}

.qr-card h3 {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.qr-card label {
  font-weight: 500;
  margin-bottom: 8px;
  display: block;
}

.qr-card input[type="url"] {
  width: 100%;
  padding: 12px 15px;
  border: none;
  border-radius: 10px;
  outline: none;
  margin-bottom: 20px;
  font-size: 0.95rem;
}

.btn-generate {
  width: 100%;
  padding: 12px;
  border: none;
  background: #fff;
  color: #ff6600;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.3s;
}

.btn-generate:hover {
  background: #f2f2f2;
}

/* === QR RESULT === */
.qr-result {
  margin-top: 25px;
  text-align: center;
}

.qr-result.hidden {
  display: none;
}

.qr-result h4 {
  margin-bottom: 10px;
  font-size: 1.1rem;
}

.qr-result img {
  width: 150px;
  margin: 10px 0;
}

.qr-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.qr-actions button {
  background: #fff;
  color: #ff6600;
  border: none;
  padding: 8px 15px;
  border-radius: 8px;
  font-weight: 500;
  cursor: pointer;
  transition: 0.3s;
}

.qr-actions button:hover {
  background: #f2f2f2;
}

/* === TABLE === */
.qr-table {
  background: #fff;
  border-radius: 20px;
  padding: 30px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.05);
}

.qr-table h3 {
  color: #222;
  font-size: 1.3rem;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.qr-table p {
  color: #666;
  font-size: 0.95rem;
  margin-bottom: 20px;
}

.table-placeholder {
  border: 2px dashed #ddd;
  border-radius: 15px;
  padding: 40px 20px;
  text-align: center;
  color: #999;
}

.table-placeholder i {
  font-size: 2rem;
  color: #ff6600;
  margin-bottom: 10px;
  display: block;
}

/* === STATS CARDS === */
.stats-cards {
  display: flex;
  justify-content: space-between;
  margin-top: 50px;
  gap: 20px;
}

.stat-card {
  flex: 1;
  background: #fff;
  border-radius: 15px;
  padding: 25px;
  text-align: center;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s;
}

.stat-card:hover {
  transform: translateY(-5px);
}

.stat-card i {
  font-size: 1.8rem;
  color: #ff6600;
  margin-bottom: 10px;
}

.stat-card h4 {
  font-size: 1rem;
  color: #444;
}

.stat-value {
  font-size: 1.5rem;
  font-weight: 600;
  color: #222;
  margin-top: 5px;
}

