/*
  Base styles for the digital services website.
  The design opts for a clean and classic look with generous spacing and
  readable typography. Colors are chosen to provide good contrast and
  ensure accessibility.
*/

/* Reset margin and padding for all elements */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen,
    Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  /* Soft gradient background to add depth and modern feel */
  background: linear-gradient(180deg, #f0f4f8 0%, #f7faff 100%);
  color: #1f2937;
  line-height: 1.6;
}

/* Header styling */
header {
  /* Gradient header for a modern, engaging look */
  background: linear-gradient(90deg, #2563eb 0%, #3b82f6 50%, #6366f1 100%);
  color: #ffffff;
  padding: 1.25rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

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

header nav a {
  margin-left: 1rem;
  color: #ffffff;
  text-decoration: none;
  font-weight: 500;
  transition: opacity 0.2s ease-in-out;
}

header nav a:hover {
  opacity: 0.8;
}

/* Container centers the content and constrains max width */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

/* Product grid layout */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

/* Individual product card */
.product-card {
  background-color: #ffffff;
  border-radius: 0.5rem;
  padding: 1.5rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  border-top: 4px solid #2563eb; /* accent border */
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.1s ease-in-out, box-shadow 0.2s ease-in-out;
}

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

.product-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
  color: #111827;
}

.product-card p {
  margin: 0.25rem 0;
}

.quantity-control {
  margin-top: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.quantity-control label {
  font-size: 0.875rem;
  color: #374151;
}

.quantity-control input {
  width: 60px;
  padding: 0.25rem;
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
}
.product-card .price {
  font-weight: 600;
  margin-top: 0.5rem;
  color: #374151;
}

/* Generic button styles */
.btn {
  align-self: flex-start;
  background-color: #2563eb; /* blue */
  color: #ffffff;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
  margin-top: 1rem;
}

.btn:hover {
  background-color: #1d4ed8;
}

/* Cart table styling */
.cart-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
  background-color: #ffffff;
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

.cart-table th,
.cart-table td {
  padding: 0.75rem 1rem;
  text-align: left;
}

.cart-table thead {
  background-color: #1e40af; /* royal blue */
  color: #ffffff;
}

.cart-table tbody tr:nth-child(even) {
  background-color: #f3f4f6; /* light gray */
}

.cart-table tbody tr:hover {
  background-color: #e5e7eb;
}

/* Actions column (remove buttons) */
.cart-actions button {
  background-color: #ef4444; /* red */
  border: none;
  color: #ffffff;
  padding: 0.25rem 0.5rem;
  border-radius: 0.375rem;
  font-size: 0.75rem;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}

.cart-actions button:hover {
  background-color: #dc2626;
}

/* Icon inside product cards */
.product-card .icon {
  width: 48px;
  height: 48px;
  margin-bottom: 1rem;
  filter: invert(20%) sepia(94%) saturate(512%) hue-rotate(200deg) brightness(93%) contrast(88%);
}

/* Payment section styling */
.payment-section {
  margin-top: 2rem;
  background-color: #ffffff;
  border-radius: 0.5rem;
  padding: 1.5rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.payment-section h3 {
  margin-top: 0;
  margin-bottom: 1rem;
  color: #1e3a8a;
  font-size: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  margin-bottom: 1rem;
}

.form-group label {
  margin-bottom: 0.25rem;
  font-weight: 500;
  color: #374151;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 0.5rem;
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  width: 100%;
  color: #1f2937;
}

.submit-payment {
  background-color: #2563eb;
  color: #ffffff;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}

.submit-payment:hover {
  background-color: #1d4ed8;
}

.confirmation-message {
  margin-top: 1rem;
  background-color: #d1fae5;
  color: #065f46;
  padding: 1rem;
  border-radius: 0.375rem;
}

/* Checkout button styling distinct from standard buttons. A green
   palette signals the action of completing a purchase. */
/* Checkout button styles have been removed since external payment options
   have been replaced with a manual payment form. */

/* Total price text */
.total {
  text-align: right;
  margin-top: 1rem;
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
}

/* Footer styling */
footer {
  background-color: #1e3a8a;
  color: #ffffff;
  padding: 1rem 0;
}

footer p {
  margin: 0;
  text-align: center;
  font-size: 0.875rem;
}