/* Import Google Font */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
  --bg-primary: #ffffff;
  --bg-secondary: #f6fafd;
  --bg-glass: rgba(255, 255, 255, 0.85);
  --border-glass: rgba(0, 0, 0, 0.08);
  --text-primary: #444444;
  --text-secondary: #777777;
  
  /* Gradient accents using Monterrey/SARE blues and standard theme colors */
  --primary-gradient: linear-gradient(135deg, #2487ce 0%, #124265 100%);
  --success-gradient: linear-gradient(135deg, #198754 0%, #157347 100%);
  --warning-gradient: linear-gradient(135deg, #ffc107 0%, #e0a800 100%);
  --danger-gradient: linear-gradient(135deg, #dc3545 0%, #bd2130 100%);
  --info-gradient: linear-gradient(135deg, #0dcaf0 0%, #0bacce 100%);
  
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 15px 40px rgba(0, 0, 0, 0.12);
  
  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset and Global Styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  height: 100%;
}

body {
  min-height: 100%;
  font-family: 'Poppins', 'Roboto', sans-serif;
  line-height: 1.5;
  overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}
::-webkit-scrollbar-thumb {
  background: #ccd1d9;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #aab2bd;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #124265;
}

a {
  color: #2487ce;
  text-decoration: none;
  transition: var(--transition-smooth);
}
a:hover {
  color: #124265;
}

/* Glassmorphism Containers */
.glass-panel {
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: var(--shadow-md);
  transition: var(--transition-smooth);
}
.glass-panel:hover {
  border-color: rgba(0, 0, 0, 0.12);
  box-shadow: var(--shadow-lg);
}

/* Forms Styling */
.form-group {
  margin-bottom: 1.5rem;
}
.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: #124265;
}
.form-input {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: inherit;
  font-size: 0.95rem;
  color: #495057;
  background: #ffffff;
  border: 1px solid #ced4da;
  border-radius: 10px;
  outline: none;
  transition: var(--transition-smooth);
}
.form-input:focus {
  border-color: #2487ce;
  box-shadow: 0 0 0 3px rgba(36, 135, 206, 0.25);
  background: #ffffff;
}

select.form-input {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23777777'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 1.25rem;
  padding-right: 2.5rem;
}

select.form-input option {
  background: #ffffff;
  color: #495057;
}

/* Custom Alert Messages */
.alert-custom {
  padding: 1rem 1.25rem;
  border-radius: 12px;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  border: 1px solid transparent;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  box-shadow: var(--shadow-sm);
}
.alert-custom-success {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.25);
  color: #34d399;
}
.alert-custom-error {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.25);
  color: #f87171;
}

/* Buttons */
.btn-gradient {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  color: #fff;
  background: var(--primary-gradient);
  box-shadow: 0 4px 15px rgba(36, 135, 206, 0.2);
  transition: var(--transition-smooth);
  text-decoration: none;
  gap: 0.5rem;
}
.btn-gradient:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(36, 135, 206, 0.3);
  color: #fff;
}
.btn-gradient:active {
  transform: translateY(0);
}

.btn-secondary-custom {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  font-size: 0.95rem;
  border-radius: 10px;
  border: 1px solid #ced4da;
  cursor: pointer;
  color: #495057;
  background: #f8f9fa;
  transition: var(--transition-smooth);
  text-decoration: none;
}
.btn-secondary-custom:hover {
  background: #e2e6ea;
  border-color: #dae0e5;
  color: #212529;
}

/* Layout and Navigation */
.navbar-custom {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-glass);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
}
.navbar-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.brand {
  font-size: 1.5rem;
  font-weight: 700;
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  list-style: none;
}
.nav-link-custom {
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  transition: var(--transition-smooth);
}
.nav-link-custom:hover, .nav-link-custom.active {
  color: #2487ce;
  background: rgba(36, 135, 206, 0.05);
}

.main-content {
  max-width: 1200px;
  margin: 2.5rem auto;
  padding: 0 1.5rem;
  min-height: calc(100vh - 200px);
}

/* Footer */
.footer-custom {
  text-align: center;
  padding: 2rem 0;
  border-top: 1px solid var(--border-glass);
  color: var(--text-secondary);
  font-size: 0.875rem;
}

/* User Card and Profile Styles */
.user-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
}
.badge-admin {
  background: rgba(168, 85, 247, 0.1);
  color: #a855f7;
  border: 1px solid rgba(168, 85, 247, 0.2);
}
.badge-customer {
  background: rgba(36, 135, 206, 0.1);
  color: #2487ce;
  border: 1px solid rgba(36, 135, 206, 0.2);
}
.badge-office {
  background: rgba(245, 158, 11, 0.1);
  color: #d97706;
  border: 1px solid rgba(245, 158, 11, 0.2);
}

/* Page Login/Register Specific Layout */
.auth-wrapper {
  max-width: 450px;
  margin: 4rem auto;
}
.auth-header {
  text-align: center;
  margin-bottom: 2rem;
}
.auth-header h1 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}
.auth-header p {
  color: var(--text-secondary);
}
.auth-footer {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* Grid & Dashboard layout */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.dashboard-card {
  padding: 2rem;
}
.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
}
.icon-purple {
  background: rgba(168, 85, 247, 0.1);
  color: #a855f7;
}
.icon-blue {
  background: rgba(36, 135, 206, 0.1);
  color: #2487ce;
}
.icon-orange {
  background: rgba(245, 158, 11, 0.1);
  color: #d97706;
}

.stats-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: #124265;
  margin: 1rem 0 0.5rem 0;
}

/* Validation styling */
.text-danger {
  color: #dc3545;
  font-size: 0.8rem;
  margin-top: 0.25rem;
  display: block;
}

.validation-summary-errors {
  padding: 1rem;
  background: rgba(220, 53, 69, 0.05);
  border: 1px solid rgba(220, 53, 69, 0.15);
  border-radius: 10px;
  color: #dc3545;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}
.validation-summary-errors ul {
  list-style: none;
  padding-left: 0;
}