/* Global Styles */
:root {
  --primary-color: #3498db;
  --secondary-color: #2ecc71;
  --dark-color: #2c3e50;
  --light-color: #ecf0f1;
  --danger-color: #e74c3c;
  --warning-color: #f39c12;
  --box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f4f4f4;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.header {
  background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
  color: white;
  padding: 1rem 0;
  box-shadow: var(--box-shadow);
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header h1 {
  margin: 0;
  font-size: 1.8rem;
}

.nav-links {
  display: flex;
  list-style: none;
}

.nav-links li {
  margin-left: 20px;
}

.nav-links a {
  color: white;
  text-decoration: none;
}

.nav-links a:hover {
  color: var(--secondary-color);
}

/* Main Content */
.main {
  padding: 2rem 0;
}

/* Products Section */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 15px;
  margin-top: 20px;
}

.product-card {
  background: white;
  border-radius: 10px;
  padding: 1rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  border: 2px solid transparent;
  position: relative;
  overflow: hidden;
}

.product-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #2ecc71, #3498db, #9b59b6);
}

.product-card.popular {
  border: 2px solid #e74c3c;
  transform: scale(1.05);
  box-shadow: 0 8px 25px rgba(231, 76, 60, 0.2);
  animation: pulse 1.5s infinite;
}

.product-card.popular::after {
  content: 'HOT ITEM!';
  position: absolute;
  top: 10px;
  right: -30px;
  background: #e74c3c;
  color: white;
  padding: 5px 40px;
  font-size: 0.8rem;
  font-weight: bold;
  transform: rotate(45deg);
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.product-card.popular:hover {
  transform: scale(1.05) translateY(-8px);
}

@keyframes pulse {
  0% {
    box-shadow: 0 8px 25px rgba(231, 76, 60, 0.2);
  }
  50% {
    box-shadow: 0 8px 28px rgba(231, 76, 60, 0.4);
  }
  100% {
    box-shadow: 0 8px 25px rgba(231, 76, 60, 0.2);
  }
}

/* WhatsApp Floating Button */
.whatsapp-float {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
}

.whatsapp-button {
  background: #25d366;
  color: white;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
  transition: all 0.3s ease;
  animation: whatsappPulse 2s infinite;
}

.whatsapp-button:hover {
  background: #20c558;
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
}

.whatsapp-button span {
  position: absolute;
  right: 70px;
  background: #2c3e50;
  color: white;
  padding: 8px 12px;
  border-radius: 20px;
  font-size: 0.9rem;
  white-space: nowrap;
  opacity: 0;
  transform: translateX(10px);
  transition: all 0.3s ease;
  pointer-events: none;
}

.whatsapp-button:hover span {
  opacity: 1;
  transform: translateX(0);
}

.whatsapp-number {
  background: #2c3e50;
  color: white;
  padding: 8px 12px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: bold;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  animation: numberBounce 3s infinite ease-in-out;
}

@keyframes whatsappPulse {
  0% {
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
  }
  50% {
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.6);
  }
  100% {
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
  }
}

@keyframes numberBounce {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-5px);
  }
}

/* Hero WhatsApp Button */
.hero-whatsapp-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(45deg, #25d366, #20c558);
  color: white;
  padding: 12px 24px;
  border-radius: 30px;
  text-decoration: none;
  font-weight: bold;
  box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.hero-whatsapp-btn:hover {
  background: linear-gradient(45deg, #20c558, #1ab852);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
  border-color: #25d366;
  color: white;
}

.hero-whatsapp-btn svg {
  animation: whatsappBounce 2s infinite;
}

@keyframes whatsappBounce {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

/* Mobile responsive */
@media (max-width: 768px) {
  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 10px;
  }
  
  .product-card {
    padding: 0.8rem;
  }
  
  .product-card h3 {
    font-size: 1rem;
  }
  
  .product-card .description {
    font-size: 0.8rem;
  }
  
  .product-card .price {
    font-size: 1rem;
  }
  
  .whatsapp-float {
    bottom: 15px;
    right: 15px;
  }
  
  .whatsapp-button {
    width: 50px;
    height: 50px;
  }
  
  .whatsapp-number {
    font-size: 0.8rem;
    padding: 6px 10px;
  }
  
  .hero-whatsapp-btn {
    font-size: 0.9rem;
    padding: 10px 20px;
  }
}

.product-card h3 {
  margin-bottom: 8px;
  color: var(--dark-color);
  font-size: 1.1rem;
}

.product-card p {
  color: #666;
  margin-bottom: 12px;
  font-size: 0.9rem;
}

.product-card .description {
  color: #333;
  margin-bottom: 12px;
  line-height: 1.4;
  font-size: 0.85rem;
}

.product-card .price {
  font-weight: bold;
  color: var(--primary-color);
  font-size: 1.1rem;
  margin-bottom: 12px;
}

.product-card .btn {
  width: 100%;
}

/* Admin Panel */
.admin-controls {
  margin-bottom: 2rem;
  background: white;
  padding: 1rem;
  border-radius: 5px;
  box-shadow: var(--box-shadow);
}

.admin-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

.form-group {
  margin-bottom: 15px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

.form-control {
  width: 100%;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.admin-card {
  background: white;
  border-radius: 5px;
  padding: 1rem;
  box-shadow: var(--box-shadow);
  position: relative;
}

.admin-card .code {
  background: #f4f4f4;
  padding: 10px;
  border-radius: 4px;
  font-family: monospace;
  margin: 10px 0;
  word-break: break-all;
}

.delete-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--danger-color);
  color: white;
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* Order Card */
.order-card {
  margin-bottom: 20px;
}

.order-card .receipt-image {
  margin: 10px 0;
}

.order-actions {
  margin-top: 15px;
  display: flex;
  justify-content: flex-end;
}

.status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 3px;
  font-size: 0.8rem;
}

.status-badge.pending {
  background-color: var(--warning-color);
  color: white;
}

.status-badge.verified {
  background-color: var(--secondary-color);
  color: white;
}

/* Admin Tabs */
.tab-buttons {
  display: flex;
  margin-bottom: 20px;
}

.tab-button {
  padding: 10px 20px;
  background-color: #f4f4f4;
  border: none;
  cursor: pointer;
  font-weight: bold;
  border-radius: 5px 5px 0 0;
}

.tab-button.active {
  background-color: white;
  border-bottom: 3px solid var(--primary-color);
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  overflow-y: auto;
}

.modal-content {
  background: white;
  margin: 5% auto;
  padding: 20px;
  border-radius: 5px;
  max-width: 600px;
  box-shadow: var(--box-shadow);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  border-bottom: 1px solid #eee;
  padding-bottom: 10px;
}

.modal-header h2 {
  margin: 0;
}

.close-modal {
  font-size: 1.5rem;
  cursor: pointer;
}

.modal-body {
  margin-bottom: 20px;
}

.modal-footer {
  border-top: 1px solid #eee;
  padding-top: 15px;
  display: flex;
  justify-content: flex-end;
}

.modal-footer .btn {
  margin-left: 10px;
}

/* Payment Tutorials */
.payment-methods {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 15px;
  margin-top: 15px;
}

.payment-method {
  border: 1px solid #ddd;
  padding: 15px;
  border-radius: 5px;
  text-align: center;
}

.payment-method h4 {
  margin-bottom: 10px;
  color: var(--dark-color);
}

.tutorial-step {
  margin: 20px 0;
  padding: 15px;
  background: #f9f9f9;
  border-radius: 5px;
  border-left: 3px solid var(--primary-color);
}

.tutorial-step h4 {
  margin-bottom: 10px;
  color: var(--dark-color);
}

/* Receipt Upload */
.receipt-preview {
  margin: 15px 0;
  text-align: center;
}

/* Login Form */
.login-container {
  max-width: 400px;
  margin: 2rem auto;
  background: white;
  padding: 2rem;
  border-radius: 5px;
  box-shadow: var(--box-shadow);
}

.login-container h2 {
  margin-bottom: 1rem;
  text-align: center;
}

/* Buttons */
.btn {
  display: inline-block;
  background: var(--primary-color);
  color: white;
  padding: 8px 15px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  text-decoration: none;
  font-size: 1rem;
  text-align: center;
  transition: background 0.3s ease;
}

.btn-block {
  display: block;
  width: 100%;
}

.btn-primary {
  background: var(--primary-color);
}

.btn-secondary {
  background: var(--secondary-color);
}

.btn-danger {
  background: var(--danger-color);
}

.btn:hover {
  opacity: 0.9;
}

.btn.disabled {
  background: #ccc;
  cursor: not-allowed;
}

/* Alerts */
.alert {
  padding: 10px 15px;
  border-radius: 4px;
  margin-bottom: 15px;
}

.alert-success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.alert-danger {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.alert-warning {
  background: #fff3cd;
  color: #856404;
  border: 1px solid #ffeeba;
}

/* Trust Section */
.trust-section {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  padding: 3rem 0;
  margin-top: 3rem;
}

.trust-indicators {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.trust-item {
  text-align: center;
  padding: 1.5rem;
  background: white;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.trust-item .icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.trust-item h3 {
  color: var(--dark-color);
  margin-bottom: 0.5rem;
}

.trust-item p {
  color: #666;
  font-size: 0.9rem;
}

/* Testimonials */
.testimonials {
  background: white;
  padding: 3rem 0;
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.testimonial {
  background: #f8f9fa;
  padding: 1.5rem;
  border-radius: 10px;
  border-left: 4px solid #2ecc71;
}

.testimonial .stars {
  color: #f39c12;
  font-size: 1.2rem;
  margin-bottom: 1rem;
}

.testimonial .quote {
  font-style: italic;
  margin-bottom: 1rem;
  color: #555;
}

.testimonial .author {
  font-weight: bold;
  color: var(--dark-color);
}

/* Footer */
.footer {
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
  color: white;
  text-align: center;
  padding: 2rem 0;
  margin-top: 2rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
  text-align: left;
}

.footer-section h3 {
  margin-bottom: 1rem;
  color: #3498db;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 0.5rem;
}

.footer-section ul li a {
  color: #bdc3c7;
  text-decoration: none;
}

.footer-section ul li a:hover {
  color: white;
}

/* Responsive Design */
@media (max-width: 768px) {
  .admin-form {
    grid-template-columns: 1fr;
  }
  
  .header .container {
    flex-direction: column;
  }
  
  .nav-links {
    margin-top: 10px;
  }
  
  .nav-links li:first-child {
    margin-left: 0;
  }
  
  .modal-content {
    width: 95%;
    margin: 10% auto;
  }
}