/* ================================
   Global Theme - White & Blue Premium
   ================================ */
:root {
  --primary: #007bff;        /* Blue */
  --primary-light: #cce5ff;
  --secondary: #ffffff;      /* White */
  --text-dark: #1e1e2f;
  --card-bg: #f8faff;        /* Light bluish white card */
  --radius: 14px;
  --shadow: 0 8px 25px rgba(0, 123, 255, 0.15);
  --transition: 0.3s ease-in-out;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

body {
  background: #f1f5f9; /* Very light tone */
  color: var(--text-dark);
  min-height: 100vh;
  display: flex;
  justify-content: center; /* Horizontal center */
  align-items: center;     /* Vertical center */
  padding: 20px;
}

.container,
.auth-container {
  background: var(--card-bg);
  padding: 30px 25px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: 100%;
  max-width: 650px;
  text-align: center;
  margin: 0 auto;  /* Horizontal center */
  transition: transform var(--transition), box-shadow var(--transition);
}


.container:hover,
.auth-container:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 123, 255, 0.25);
}

h2 {
  color: var(--primary);
  font-size: 1.8rem;
  margin-bottom: 20px;
  font-weight: 700;
}

p {
  font-size: 1rem;
  color: #3b3b3b;
  margin-bottom: 15px;
  line-height: 1.6;
}

/* ================================
   Forms
   ================================ */
form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

label {
  text-align: left;
  font-size: 0.95rem;
  color: var(--text-dark);
}

input,
select,
textarea {
  padding: 14px;
  border-radius: var(--radius);
  border: 1px solid #d1d5db;
  outline: none;
  font-size: 1rem;
  background: #ffffff;
  color: #1e1e2f;
  width: 100%;
  transition: border-color var(--transition), box-shadow var(--transition);
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 8px rgba(0, 123, 255, 0.3);
}

/* ================================
   Buttons
   ================================ */
button {
  background: var(--primary);
  color: var(--secondary);
  padding: 14px 20px;
  border: none;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
}

button:hover {
  background: #0056b3;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 123, 255, 0.2);
}

/* ================================
   Error Message
   ================================ */
.error {
  color: #ff4d4f;
  margin-top: 10px;
  font-size: 0.9rem;
  animation: shake 0.3s ease-in-out;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  50% { transform: translateX(5px); }
  75% { transform: translateX(-5px); }
}

/* ================================
   Tables - Premium White & Blue
   ================================ */
.styled-table {
  width: 100%;
  border-collapse: collapse;
  font-family: "Poppins", sans-serif;
  font-size: 14px;
  background: var(--secondary);
  border-radius: var(--radius);
  overflow: hidden;
  color: var(--text-dark);
  box-shadow: var(--shadow);
}

.styled-table thead {
  background: linear-gradient(135deg, #007bff, #3399ff);
  color: #fff;
  text-align: left;
}

.styled-table th,
.styled-table td {
  padding: 16px 20px;
  text-align: left;
  border-bottom: 1px solid #e2e8f0;
}

.styled-table tbody tr:nth-child(even) {
  background-color: #f1f5f9;
}

.styled-table tbody tr:hover {
  background-color: #e0f0ff;
  transform: scale(1.01);
  transition: all var(--transition);
}

.styled-table td a {
  text-decoration: none;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 8px;
  transition: all var(--transition);
}

.styled-table td a.download {
  background: #10b981;
  color: #fff;
}

.styled-table td a.download:hover {
  background: #059669;
  transform: translateY(-2px);
}

.styled-table td a.view {
  background: #3b82f6;
  color: #fff;
}

.styled-table td a.view:hover {
  background: #2563eb;
  transform: translateY(-2px);
}

.styled-table td.empty {
  text-align: center;
  padding: 20px;
  font-style: italic;
  color: #6b7280;
}

/* ================================
   Responsive Tables
   ================================ */
@media (max-width: 768px) {
  .styled-table thead {
    display: none;
  }
  .styled-table,
  .styled-table tbody,
  .styled-table tr,
  .styled-table td {
    display: block;
  }
  .styled-table tr {
    margin-bottom: 15px;
    background: #ffffff;
    border-radius: var(--radius);
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    overflow: hidden;
  }
  .styled-table td {
    text-align: right;
    padding: 12px;
    position: relative;
  }
  .styled-table td::before {
    content: attr(data-label);
    position: absolute;
    left: 12px;
    top: 12px;
    font-weight: 600;
    color: #374151;
    text-align: left;
  }
}

/* ================================
   Mobile Fixes
   ================================ */
@media (max-width: 480px) {
  .container,
  .auth-container {
    max-width: 100%;
    padding: 20px 15px;
    border-radius: 10px;
    margin: 15px auto;
  }
}
