/* ==========================================================================
   LGT (Laith Global General Trading) - User Profile Stylesheet
   Design System: LGT Brand Blue (#005BB7) - Strict No-Red Theme
   ========================================================================== */

/* Page Background & Layout */
.profile-page-body {
  background-color: #f8fafc;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.profile-main-container {
  padding-top: 18px;
  padding-bottom: 54px;
}

/* Breadcrumb */
.profile-breadcrumb {
  margin-bottom: 18px;
}

.profile-breadcrumb ol {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 13px;
  color: var(--color-text-muted, #64748b);
}

.profile-breadcrumb a {
  color: var(--color-text-muted, #64748b);
  text-decoration: none;
  transition: color 0.2s ease;
}

.profile-breadcrumb a:hover {
  color: #005bb7;
}

.profile-breadcrumb .separator {
  color: #94a3b8;
  font-size: 11px;
}

.profile-breadcrumb .current {
  color: #0f172a;
  font-weight: 600;
}

/* Profile Grid (2-Column on Desktop) */
.profile-layout-grid {
  display: grid;
  grid-template-columns: 270px 1fr;
  gap: 24px;
  align-items: flex-start;
}

/* ==========================================================================
   Left Sidebar Navigation
   ========================================================================== */
.profile-sidebar {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Brand Blue (#005BB7) User Identity Card */
.profile-user-card {
  background: #005bb7;
  background: linear-gradient(135deg, #005bb7 0%, #004085 100%);
  border-radius: 8px;
  padding: 18px 18px;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: 0 4px 14px rgba(0, 91, 183, 0.22);
}

.profile-user-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  border: 2px solid rgba(255, 255, 255, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.profile-user-avatar svg {
  width: 28px;
  height: 28px;
  fill: #ffffff;
}

.profile-user-meta {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.profile-user-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  opacity: 0.85;
  margin-bottom: 2px;
  font-weight: 500;
}

.profile-user-name {
  font-size: 16px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.2px;
}

/* Sidebar Menu Box */
.profile-menu-card {
  background: #ffffff;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.profile-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.profile-nav-item {
  border-bottom: 1px solid #f1f5f9;
}

.profile-nav-item:last-child {
  border-bottom: none;
}

.profile-nav-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  background: transparent;
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  color: #334155;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.profile-nav-btn svg {
  width: 20px;
  height: 20px;
  fill: #64748b;
  flex-shrink: 0;
  transition: fill 0.2s ease;
}

.profile-nav-btn:hover {
  background-color: #f8fafc;
  color: #005bb7;
}

.profile-nav-btn:hover svg {
  fill: #005bb7;
}

/* Active Nav State - #005BB7 */
.profile-nav-item.active .profile-nav-btn {
  color: #005bb7;
  font-weight: 600;
  background-color: #f0f7ff;
}

.profile-nav-item.active .profile-nav-btn svg {
  fill: #005bb7;
}

.profile-nav-item.active .profile-nav-btn::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: #005bb7;
  border-radius: 0 4px 4px 0;
}

/* Badge for Orders or RFQs */
.profile-nav-badge {
  margin-left: auto;
  background: #f1f5f9;
  color: #64748b;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
}

.profile-nav-item.active .profile-nav-badge {
  background: #e8f2fc;
  color: #005bb7;
}

/* ==========================================================================
   Right Main Content Panels
   ========================================================================== */
.profile-main-content {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Section Card */
.profile-section-card {
  background: #ffffff;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  padding: 24px 28px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.profile-section-title {
  font-size: 18px;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 20px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Header Action Link (e.g. + ADD NEW DELIVERY ADDRESS) */
.profile-card-action-link {
  font-size: 13px;
  font-weight: 700;
  color: #005bb7;
  text-decoration: none;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  letter-spacing: 0.2px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.profile-card-action-link:hover {
  color: #004b99;
  text-decoration: underline;
}

/* User Info Fields */
.profile-fields-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.profile-field-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #f1f5f9;
  padding-bottom: 16px;
}

.profile-field-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.profile-field-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.profile-field-label {
  font-size: 12px;
  color: #64748b;
  font-weight: 500;
}

.profile-field-value {
  font-size: 15px;
  font-weight: 600;
  color: #1e293b;
}

/* Edit Pill Button (e.g. EDIT NAME, EDIT EMAIL ID) - #005BB7 */
.btn-profile-pill-edit {
  background-color: #e8f2fc;
  color: #005bb7;
  border: none;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 700;
  padding: 8px 18px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-profile-pill-edit:hover {
  background-color: #d0e6f9;
  color: #004b99;
}

/* Language Selection Row */
.profile-language-section {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 10px;
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
}

.language-icon-box {
  width: 28px;
  height: 28px;
  background: #005bb7;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}

.language-title {
  font-size: 14px;
  font-weight: 600;
  color: #1e293b;
}

.language-selector-wrap {
  margin-left: auto;
}

.language-select {
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 500;
  color: #334155;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  cursor: pointer;
  outline: none;
  font-family: inherit;
}

.language-select:focus {
  border-color: #005bb7;
  box-shadow: 0 0 0 3px rgba(0, 91, 183, 0.12);
}

/* ==========================================================================
   Delivery Address Section - #005BB7 Accent
   ========================================================================== */
.delivery-address-card-outer {
  border: 1.5px solid #93c5fd;
  border-radius: 8px;
  padding: 18px 20px;
  background-color: #ffffff;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  position: relative;
  transition: all 0.2s ease;
}

.delivery-address-card-outer:hover {
  border-color: #005bb7;
  box-shadow: 0 4px 12px rgba(0, 91, 183, 0.08);
}

.address-content-left {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  flex: 1;
}

/* Checked Blue Radio Icon */
.address-radio-indicator {
  margin-top: 2px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 5px solid #005bb7;
  background: #ffffff;
  flex-shrink: 0;
  box-shadow: 0 0 0 1px #005bb7;
}

.address-details-meta {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.address-recipient-name {
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
}

.address-text-body {
  font-size: 13px;
  color: #475569;
  line-height: 1.45;
}

.address-phone-line {
  font-size: 13px;
  color: #334155;
  margin-top: 2px;
  font-weight: 500;
}

/* Address Action Buttons (DELETE & EDIT) */
.address-actions-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.btn-address-delete {
  background-color: #f1f5f9;
  color: #475569;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 700;
  padding: 7px 16px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-address-delete:hover {
  background-color: #e2e8f0;
  color: #0f172a;
}

.btn-address-edit {
  background-color: #005bb7;
  color: #ffffff;
  border: none;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 700;
  padding: 8px 22px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-address-edit:hover {
  background-color: #004b99;
}

/* ==========================================================================
   Horizontal Action Row Cards (Billing, Password, Logout)
   ========================================================================== */
.profile-row-card {
  background: #ffffff;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.profile-row-title {
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

.profile-row-title svg {
  width: 20px;
  height: 20px;
  fill: #64748b;
}

.profile-row-btn {
  font-size: 13px;
  font-weight: 700;
  color: #005bb7;
  text-decoration: none;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: color 0.2s ease;
}

.profile-row-btn:hover {
  color: #004b99;
  text-decoration: underline;
}

/* Logout Item */
.profile-logout-card {
  cursor: pointer;
  transition: all 0.2s ease;
}

.profile-logout-card:hover {
  background-color: #f0f7ff;
  border-color: #bfdbfe;
}

.profile-logout-card .profile-row-title {
  color: #334155;
  font-weight: 600;
  transition: color 0.2s ease;
}

.profile-logout-card:hover .profile-row-title {
  color: #005bb7;
}

.profile-logout-card svg {
  fill: #64748b;
  transition: fill 0.2s ease;
}

.profile-logout-card:hover svg {
  fill: #005bb7;
}

/* ==========================================================================
   Trust Pillars Strip - #005BB7 Brand Styling
   ========================================================================== */
.profile-trust-strip {
  background: #ffffff;
  border-top: 1px solid #e2e8f0;
  border-bottom: 1px solid #e2e8f0;
  padding: 24px 0;
  margin-top: 36px;
}

.profile-trust-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

.profile-trust-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.profile-trust-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e8f2fc;
  border-radius: 50%;
  color: #005bb7;
}

.profile-trust-icon svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.profile-trust-meta {
  display: flex;
  flex-direction: column;
}

.profile-trust-title {
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 3px;
}

.profile-trust-sub {
  font-size: 11px;
  color: #64748b;
  line-height: 1.4;
}

.profile-trust-whatsapp-link {
  color: #25d366;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 2px;
}

/* ==========================================================================
   Modals & Edit Overlays
   ========================================================================== */
.profile-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: fadeIn 0.2s ease;
}

.profile-modal-backdrop.active {
  display: flex;
}

.profile-modal-box {
  background: #ffffff;
  border-radius: 10px;
  width: 100%;
  max-width: 480px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  animation: slideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.profile-modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f8fafc;
}

.profile-modal-title {
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.profile-modal-close {
  background: none;
  border: none;
  font-size: 22px;
  color: #94a3b8;
  cursor: pointer;
  line-height: 1;
  padding: 4px;
}

.profile-modal-close:hover {
  color: #0f172a;
}

.profile-modal-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.profile-form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.profile-form-label {
  font-size: 13px;
  font-weight: 600;
  color: #334155;
}

.profile-form-input,
.profile-form-select,
.profile-form-textarea {
  width: 100%;
  padding: 10px 14px;
  font-size: 14px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-family: inherit;
  color: #1e293b;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.profile-form-input:focus,
.profile-form-select:focus,
.profile-form-textarea:focus {
  border-color: #005bb7;
  box-shadow: 0 0 0 3px rgba(0, 91, 183, 0.12);
}

.profile-modal-footer {
  padding: 14px 20px;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.btn-modal-cancel {
  padding: 9px 18px;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-modal-cancel:hover {
  background: #f1f5f9;
}

.btn-modal-save {
  padding: 9px 22px;
  font-size: 13px;
  font-weight: 600;
  color: #ffffff;
  background: #005bb7;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.btn-modal-save:hover {
  background: #004b99;
}

/* Toast alert notification */
.profile-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #0f172a;
  color: #ffffff;
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 10000;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

.profile-toast.show {
  transform: translateY(0);
  opacity: 1;
}

.profile-toast svg {
  width: 18px;
  height: 18px;
  fill: #38bdf8;
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */
@media (max-width: 1024px) {
  .profile-trust-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }
}

@media (max-width: 768px) {
  .profile-layout-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .profile-sidebar {
    gap: 10px;
  }

  .profile-section-card {
    padding: 18px 16px;
  }

  .delivery-address-card-outer {
    flex-direction: column;
    gap: 14px;
  }

  .address-actions-right {
    width: 100%;
    justify-content: flex-end;
  }

  .profile-trust-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
}

@media (max-width: 480px) {
  .profile-field-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .btn-profile-pill-edit {
    align-self: flex-start;
  }

  .profile-section-title {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .profile-row-card {
    padding: 14px 16px;
  }
}
