/* css/base.css */
/* Temel tanımlamalar, root değişkenleri, genel body stilleri */
:root {
  --bg-main: #2e1a47;
  --bg-gradient: linear-gradient(to bottom right, #a678f2, #643dc0);
  --text-main: #fff;
  --card-bg: rgba(0, 0, 0, 0.85);
  --surface-1: var(--card-bg);
  --surface-2: rgba(255,255,255,0.08);
  --surface-3: rgba(255,255,255,0.12);
  --accent-color: #a678f2;
  /* Brand defaults (do not change original look unless user opts in) */
  --brand-primary: #f7c843; /* original button yellow */
  --brand-primary-contrast: #222;
  --sidebar-active: #a678f2; /* original active item color (dark) */
  --interactive-hover: #e0b020; /* hover for brand-primary */
  /* UI variables that may switch to accent when user opts in */
  --ui-accent: var(--brand-primary);
  --ui-accent-contrast: var(--brand-primary-contrast);
  --ui-accent-hover: var(--interactive-hover);
  --ui-sidebar-active: var(--sidebar-active);
  /* Customizable surface colors (overridable via inline styles) */
  --container-bg: var(--bg-main);
  --sidebar-bg: var(--glass-bg-color);
  --content-bg: var(--glass-bg-color);
  /* Approximate dark surface base tuned to #1f1339 when layered */
  --glass-bg-color: rgba(11, 11, 37, 0.4);
  --glass-border-color: rgba(255, 255, 255, 0.18);
  --glass-shadow-color: rgba(0, 0, 0, 0.37);
  --glass-input-bg: rgba(255, 255, 255, 0.1);
  --glass-input-border: rgba(255, 255, 255, 0.2);
  --glass-placeholder-color: rgba(255, 255, 255, 0.7);
  --light-glass-bg-color: rgba(255, 255, 255, 0.7);
  --light-glass-border-color: rgba(0, 0, 0, 0.1);
  --light-glass-shadow-color: rgba(0, 0, 0, 0.1);
  --light-glass-input-bg: rgba(0, 0, 0, 0.05);
  --light-glass-input-border: rgba(0, 0, 0, 0.1);
  --light-glass-placeholder-color: rgba(0, 0, 0, 0.5);
}

*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  line-height: 1.6;
  width: 100%;
  max-width: 100vw;
}

body {
  margin: 0;
  font-family: 'Roboto Condensed', sans-serif;
  background: var(--bg-gradient);
  color: var(--text-main);
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* İçeriği en üste hizala */
  align-items: center; /* Yatayda ortala */
  min-height: 100vh;
  padding: 20px;
  box-sizing: border-box;
  transition: background 0.3s, color 0.3s;
}

/* Card-like boxes share background only when surfaces are defined inline */
.feature-box, .compact-packages-section, .nft-gallery-container, .profile-content-section {
  color: var(--text-main);
}

body.light {
  --bg-main: #fffbe8;
  --bg-gradient: linear-gradient(to bottom right, #f7e7c3, #e0d6fa);
  --text-main: #222;
  --card-bg: #ffffff;
  --surface-1: var(--card-bg);
  --surface-2: rgba(0,0,0,0.05);
  --surface-3: rgba(0,0,0,0.08);
  --accent-color: #643dc0;
  /* Light theme brand default for active sidebar */
  --sidebar-active: #643dc0;
  /* Light defaults for customizable surfaces */
  --container-bg: #ffffff;
  --sidebar-bg: var(--light-glass-bg-color);
  --content-bg: var(--light-glass-bg-color);
  background: var(--bg-gradient);
  color: var(--text-main);
}

/* When user opts in, use accent color for interactive UI parts */
body.accent-ui {
  --ui-accent: var(--accent-color);
  --ui-accent-contrast: #fff;
  --ui-accent-hover: rgba(255,255,255,0.15);
  --ui-sidebar-active: var(--accent-color);
}
main.container, .full-page-profile, #tarotAppContainer, #authSection {
    flex-grow: 1;
}

@media (max-width: 600px) {
  body {
    padding: 0;
  }
  .container {
    padding: 10px;
    width: calc(100% - 20px);
  }
}

/* Wallet Modal Styles */
.wallet-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}

.wallet-modal-content {
    background: linear-gradient(135deg, #2a2a3a 0%, #1a1a2e 100%);
    border-radius: 20px;
    width: 90%;
    max-width: 380px;
    padding: 0;
    position: relative;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
}

.wallet-modal-header {
    padding: 24px 24px 0 24px;
    text-align: center;
    position: relative;
}

.wallet-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.wallet-modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.wallet-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #a678f2 0%, #f7c843 100%);
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: white;
    font-weight: bold;
}

.wallet-address {
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    margin-bottom: 8px;
    font-family: 'Courier New', monospace;
}

.wallet-balance {
    color: #a678f2;
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 24px;
}

.wallet-modal-body {
    padding: 0 24px 24px 24px;
}

.wallet-menu-item {
    display: flex;
    align-items: center;
    padding: 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    color: white;
}

.wallet-menu-item:hover {
    background: rgba(166, 120, 242, 0.1);
    border-color: rgba(166, 120, 242, 0.3);
    transform: translateY(-1px);
}

.wallet-menu-icon {
    width: 24px;
    height: 24px;
    margin-right: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(166, 120, 242, 0.2);
    border-radius: 8px;
    font-size: 16px;
}

.wallet-menu-text {
    flex: 1;
    font-size: 16px;
    font-weight: 500;
}

.wallet-menu-arrow {
    color: rgba(255, 255, 255, 0.4);
    font-size: 18px;
}

.wallet-disconnect {
    background: rgba(220, 53, 69, 0.1) !important;
    border-color: rgba(220, 53, 69, 0.3) !important;
    color: #dc3545 !important;
}

.wallet-disconnect:hover {
    background: rgba(220, 53, 69, 0.2) !important;
    border-color: rgba(220, 53, 69, 0.5) !important;
}

.wallet-disconnect .wallet-menu-icon {
    background: rgba(220, 53, 69, 0.2);
    color: #dc3545;
}

/* Loading Spinner Animation */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}