:root {
  --primary-color: #0066cc;
  --primary-light: #0077dd;
  --primary-dark: #004488;
  --secondary-color: #f8fafc;
  --accent-color: #ffc220;
  --text-color: #1e293b;
  --text-light: #64748b;
  --text-muted: #94a3b8;
  --border-color: #e2e8f0;
  --border-light: #f1f5f9;
  --success-color: #0071ce;
  --danger-color: #ef4444;
  --warning-color: #ffc220;
  --surface: #ffffff;
  --surface-hover: #f8fafc;
  --shadow-sm: none;
  --shadow-md: none;
  --shadow-lg: none;
  --shadow-xl: none;
  --radius-sm: 4px;
  --radius-md: 4px;
  --radius-lg: 6px;
  --radius-xl: 8px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Inter", sans-serif;
}

body {
  background: linear-gradient(135deg, var(--secondary-color) 0%, #ffffff 100%);
  color: var(--text-color);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.app-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  position: relative;
  transition: all 0.3s ease;
}

/* Header Styles (was Sidebar) */
.sidebar {
  width: 100%;
  background: var(--primary-dark);
  border-bottom: 1px solid var(--border-color);
  padding: 0 24px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-md);
  transition: all 0.3s ease;
  position: sticky;
  top: 0;
  z-index: 100;
  height: 64px;
}

@media (max-width: 768px) {
  .sidebar {
    padding: 0 16px;
    height: 56px;
  }
}

.logo {
  display: flex;
  align-items: center;
  padding: 0;
  margin-bottom: 0;
}

@media (max-width: 768px) {
  .logo {
    padding: 0;
    margin-bottom: 0;
  }
}

.logo a {
  display: flex;
  align-items: center;
}

.logo-img {
  width: 40px;
  height: 40px;
  margin-right: 12px;
  border-radius: 8px;
  box-shadow: none;
  display: block;
}

/* Search Bar Styles */
.search-container {
  flex: 1;
  max-width: 600px;
  margin: 0 24px;
  position: relative;
  display: flex;
}

.search-input {
  width: 100%;
  padding: 12px 50px 12px 20px;
  border: none;
  border-radius: 24px;
  font-size: 14px;
  background: #ffffff;
  color: var(--text-color);
  outline: none;
  cursor: default;
}

.search-input::placeholder {
  color: var(--text-light);
}

.search-button {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: var(--primary-color);
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.search-button:hover {
  background: var(--primary-light);
}

@media (max-width: 768px) {
  .search-container {
    display: none;
  }
}

.logo-text {
  font-size: 22px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.025em;
}

.pay-text {
  font-size: 12px;
  background: var(--accent-color);
  color: var(--primary-dark);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  margin-left: 4px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.nav-menu {
  display: flex;
  flex-direction: row;
  gap: 4px;
  align-items: center;
}

@media (max-width: 768px) {
  .nav-menu {
    gap: 2px;
  }
}

.nav-item {
  display: flex;
  align-items: center;
  padding: 8px 16px;
  color: #ffffff;
  text-decoration: none;
  position: relative;
  border-radius: 8px;
  margin: 0 4px;
  transition: all 0.2s ease;
  font-weight: 500;
  font-size: 14px;
}

.nav-item-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.2;
}

.nav-item-small {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.7);
  font-weight: 400;
}

.nav-item-main {
  font-size: 14px;
  font-weight: 600;
  color: #ffffff;
}

@media (max-width: 768px) {
  .nav-item {
    padding: 6px 12px;
  }
  .nav-item-small {
    font-size: 10px;
  }
  .nav-item-main {
    font-size: 12px;
  }
}

.nav-item:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

/* Cart Item Styles */
.cart-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cart-icon {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
}

.cart-icon svg {
  stroke: #ffffff;
}

.cart-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  background: var(--accent-color);
  color: var(--primary-dark);
  font-size: 10px;
  font-weight: 700;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-total {
  font-size: 14px;
  font-weight: 600;
  color: #ffffff;
}

.nav-item.active {
  background: rgba(255, 255, 255, 0.15);
}

.nav-item.active:hover {
  background: rgba(255, 255, 255, 0.2);
}

.nav-icon {
  width: 18px;
  height: 18px;
  margin-right: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-icon img {
  width: 18px;
  height: 18px;
  filter: brightness(0) invert(1);
}

.notification-badge {
  display: none;
}

/* Main Content Styles */
.main-content {
  flex: 1;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 100%;
  overflow-x: hidden;
}

@media (max-width: 768px) {
  .main-content {
    padding: 16px;
    gap: 16px;
  }
}

.welcome-section {
  background: var(--surface);
  border-radius: var(--radius-xl);
  padding: 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: var(--shadow-sm);
  border: 2px solid var(--border-color);
  transition: all 0.3s ease;
}

@media (max-width: 768px) {
  .welcome-section {
    flex-direction: column;
    gap: 20px;
    padding: 24px;
    text-align: center;
  }
}

.welcome-section:hover {
  border-color: var(--primary-color);
}

.welcome-section h1 {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-color);
  letter-spacing: -0.025em;
}

@media (max-width: 768px) {
  .welcome-section h1 {
    font-size: 22px;
  }
}

.connect-button {
  background: var(--primary-color);
  color: white;
  border: none;
  padding: 12px 28px;
  border-radius: 24px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: var(--shadow-sm);
  font-size: 14px;
}

.connect-button:hover {
  background: var(--primary-dark);
}

/* Account Section */
.account-section {
  background: var(--surface);
  border-radius: var(--radius-xl);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  border: 2px solid var(--border-color);
  transition: all 0.3s ease;
}

@media (max-width: 768px) {
  .account-section {
    padding: 24px;
  }
}

.account-section:hover {
  border-color: var(--primary-color);
}

.account-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

@media (max-width: 768px) {
  .account-header {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
}

.account-header h2 {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-color);
  letter-spacing: -0.025em;
}

@media (max-width: 768px) {
  .account-header h2 {
    font-size: 18px;
  }
}

.currency-badge {
  background: #1e293b;
  color: #ffffff;
  padding: 8px 16px;
  border-radius: var(--radius-lg);
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  box-shadow: var(--shadow-md);
  border: 1px solid #334155;
}

.balance-display {
  margin-bottom: 32px;
  text-align: center;
  padding: 16px 0;
}

@media (max-width: 768px) {
  .balance-display {
    flex-direction: column !important;
    align-items: center !important;
    gap: 24px !important;
    margin-bottom: 32px;
    padding: 20px 0;
  }

  .balance-display .detail-item {
    margin-left: 0 !important;
    width: 100%;
    max-width: 280px;
    text-align: center;
  }
}

.balance-amount {
  font-size: 56px;
  font-weight: 800;
  color: var(--primary-color);
  letter-spacing: -0.05em;
}

@media (max-width: 768px) {
  .balance-amount {
    font-size: 42px;
  }
}

.account-details {
  display: flex;
  justify-content: space-between;
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-light);
}

@media (max-width: 768px) {
  .account-details {
    flex-direction: column;
    gap: 20px;
    text-align: center;
    margin-top: 40px;
    margin-bottom: 40px;
    padding: 24px 16px;
    background: var(--surface-hover);
    border-radius: var(--radius-lg);
    border-bottom: none;
  }
}

.detail-item {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.detail-label {
  font-size: 14px;
  color: var(--text-light);
}

.detail-value {
  font-size: 16px;
  font-weight: 500;
}

.number-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.copy-button {
  width: 20px;
  height: 20px;
  background: transparent;
  border: none;
  cursor: pointer;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.action-buttons {
  display: flex;
  gap: 16px;
}

@media (max-width: 768px) {
  .action-buttons {
    flex-direction: column;
    gap: 12px;
  }
}

.action-button {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 18px 24px;
  border-radius: 4px;
  border: 2px solid var(--primary-color);
  background: linear-gradient(to bottom, #ffffff 0%, #f0f0f0 100%);
  color: var(--primary-color);
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

@media (max-width: 768px) {
  .action-button {
    padding: 14px 20px;
    font-size: 14px;
  }
}

.action-button:hover {
  background: var(--primary-color);
  color: #ffffff;
}

/* Withdraw button style */
.withdraw-button {
  background: linear-gradient(to bottom, #0077dd 0%, #0055aa 100%) !important;
  border: 2px solid #004488 !important;
  color: #ffffff !important;
}

.withdraw-button:hover {
  background: linear-gradient(to bottom, #0055aa 0%, #003366 100%);
}

/* Payout button style */
.hello-world-button {
  background: linear-gradient(to bottom, #ffffff 0%, #e8e8e8 100%) !important;
  border: 2px solid #0066cc !important;
  color: #0066cc !important;
}

.hello-world-button:hover {
  background: linear-gradient(to bottom, #0066cc 0%, #004488 100%) !important;
  color: #ffffff !important;
}

.button-icon {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.withdraw-button .button-icon img {
  filter: brightness(0) invert(1) !important;
  opacity: 1 !important;
}

.hello-world-button .button-icon img {
  filter: invert(27%) sepia(95%) saturate(1500%) hue-rotate(200deg)
    brightness(95%) contrast(101%);
  opacity: 1 !important;
}

.hello-world-button:hover .button-icon img {
  filter: brightness(0) invert(1) !important;
}

.button-icon img {
  opacity: 0.7;
  transition: opacity 0.2s ease;
}

.action-button:hover .button-icon img {
  opacity: 1;
}

/* Withdraw Modal Styles */
.withdraw-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  animation: fadeIn 0.2s ease;
}

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

.withdraw-modal-content {
  background-color: white;
  border-radius: 12px;
  padding: 24px;
  width: 90%;
  max-width: 400px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
  position: relative;
  animation: slideUp 0.3s ease;
}

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

.withdraw-modal-content h3 {
  margin-top: 0;
  margin-bottom: 20px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-color);
  text-align: center;
}

.modal-option-button {
  width: 100%;
  display: flex;
  align-items: center;
  padding: 14px;
  margin-bottom: 12px;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  background-color: white;
  color: var(--text-color);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.modal-option-button:hover {
  background-color: rgba(108, 92, 231, 0.05);
  border-color: rgba(108, 92, 231, 0.3);
  transform: translateY(-1px);
}

.modal-option-button .button-icon {
  margin-right: 10px;
}

.modal-close-button {
  position: absolute;
  top: 10px;
  right: 10px;
  background: transparent;
  border: none;
  font-size: 24px;
  color: var(--text-light);
  cursor: pointer;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.modal-close-button:hover {
  background-color: rgba(0, 0, 0, 0.05);
}

/* Prepayment Section */
.prepayment-section {
  background-color: white;
  border-radius: 12px;
  padding: 24px;
}

/* Quick Actions Section */
.quick-actions-section {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 24px;
}

@media (max-width: 768px) {
  .quick-actions-section {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
}

.quick-action-card {
  background: var(--surface);
  border-radius: var(--radius-xl);
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  border: 2px solid var(--border-color);
  cursor: pointer;
  transition: all 0.2s ease;
}

.quick-action-card:hover {
  border-color: var(--primary-color);
  background: #f0f7ff;
}

.quick-action-icon {
  font-size: 32px;
  margin-bottom: 4px;
}

.quick-action-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-color);
}

.quick-action-desc {
  font-size: 13px;
  color: var(--text-light);
}

/* Notification Styles */
.notification {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 12px 20px;
  border-radius: 8px;
  background-color: #333;
  color: white;
  font-size: 14px;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  opacity: 0;
  transform: translateY(-20px);
  transition: opacity 0.3s, transform 0.3s;
}

.notification.show {
  opacity: 1;
  transform: translateY(0);
}

.notification.success {
  background-color: var(--success-color);
}

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

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

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

.prepayment-icon {
  width: 40px;
  height: 40px;
  background-color: var(--primary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 15px;
}

.prepayment-icon img {
  width: 24px;
  height: 24px;
  color: white;
}

.prepayment-info {
  flex: 1;
}

.prepayment-header h3 {
  font-size: 16px;
  font-weight: 500;
  margin-bottom: 5px;
}

.prepayment-description {
  font-size: 14px;
  color: var(--text-light);
}

.details-button {
  background-color: transparent;
  border: 1px solid var(--border-color);
  padding: 8px 16px;
  border-radius: 8px;
  color: var(--text-color);
  font-weight: 500;
  cursor: pointer;
}

.details-button:hover {
  background-color: var(--secondary-color);
}

/* Styles for withdraw page */
.back-button-container {
  margin-bottom: 20px;
}

.back-button {
  background-color: transparent;
  border: 1px solid var(--border-color);
  padding: 8px 16px;
  border-radius: 8px;
  color: var(--text-color);
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  transition: all 0.2s;
}

.back-button:hover {
  background-color: var(--secondary-color);
}

.transaction-details {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.detail-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-color);
}

.detail-label {
  font-size: 14px;
  color: var(--text-light);
}

.detail-value {
  font-weight: 500;
}

.number-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.copy-button {
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border-radius: 4px;
}

.copy-button:hover {
  background-color: var(--secondary-color);
}

.status-badge {
  padding: 6px 12px;
  border-radius: 16px;
  font-size: 12px;
  font-weight: 600;
  color: white;
}

.status-badge.success {
  background-color: var(--success-color);
}

.status-badge.error {
  background-color: var(--danger-color);
}

.status-badge.pending {
  background-color: #f39c12;
}

.currency-badge {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  background-color: #3498db;
  color: white;
}

.json-container {
  background-color: #2d3436;
  border-radius: 8px;
  padding: 16px;
  margin-top: 16px;
  overflow-x: auto;
}

.json-container pre {
  color: #f5f6fa;
  font-family: "Courier New", monospace;
  margin: 0;
  white-space: pre-wrap;
}

.note {
  margin-top: 16px;
  padding: 12px 16px;
  background-color: #f8f9fa;
  border-left: 4px solid var(--primary-color);
  border-radius: 4px;
}

.note p {
  margin: 0;
  font-size: 14px;
  color: var(--text-light);
}

/* Styles for React Application Container */
.react-app-placeholder {
  background-color: var(--secondary-color);
  border-radius: 8px;
  padding: 30px;
  margin-top: 16px;
  text-align: center;
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.placeholder-message {
  max-width: 500px;
}

.placeholder-message h3 {
  margin-top: 0;
  margin-bottom: 16px;
  color: var(--primary-color);
}

.placeholder-message p {
  margin-bottom: 12px;
  color: var(--text-light);
  font-size: 14px;
  line-height: 1.5;
}

.placeholder-message p:last-child {
  margin-bottom: 0;
  font-weight: 500;
}
