:root {
  --bg-dark: #08090c;
  --bg-surface: #12141d;
  --bg-surface-elevated: #1a1d2b;
  --bg-input: #171926;
  
  --accent-gold: #d4af37;
  --accent-gold-light: #f0c265;
  --accent-amber: #e08a3c;
  --accent-gold-glow: rgba(212, 175, 55, 0.25);
  
  --text-primary: #f3f4f8;
  --text-secondary: #a0a6b8;
  --text-muted: #6b7280;
  
  --border-subtle: rgba(212, 175, 55, 0.18);
  --border-light: rgba(255, 255, 255, 0.08);
  
  --color-success: #10b981;
  --color-danger: #ef4444;
  --color-warning: #f59e0b;
  
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", sans-serif;
  --font-serif: "Georgia", "Playfair Display", serif;
  
  --bottom-nav-height: 64px;
  --header-height: 60px;
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 9999px;
  
  --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.4);
  --shadow-gold: 0 4px 15px rgba(212, 175, 55, 0.2);
  --shadow-elevated: 0 10px 30px rgba(0, 0, 0, 0.7);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

body, html {
  width: 100%;
  height: 100%;
  background-color: var(--bg-dark);
  color: var(--text-primary);
  font-family: var(--font-family);
  font-size: 15px;
  line-height: 1.5;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-font-smoothing: antialiased;
}

/* Allow text selection inside prompts and copyable areas */
.selectable, input, textarea, select {
  user-select: text;
}

/* Scrollbar customization */
::-webkit-scrollbar {
  width: 5px;
}
::-webkit-scrollbar-track {
  background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
  background: #2a2d3d;
  border-radius: 4px;
}

/* App Container Layout */
#app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding-bottom: calc(var(--bottom-nav-height) + 16px);
  position: relative;
}

/* Header */
.app-header {
  height: var(--header-height);
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.app-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.app-brand .sax-icon {
  font-size: 1.4rem;
}

.app-brand h1 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--accent-gold);
  letter-spacing: 0.3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.app-header .header-action-btn {
  background: transparent;
  border: none;
  color: var(--accent-gold);
  font-size: 1.3rem;
  min-width: 44px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: var(--radius-sm);
}

.app-header .header-action-btn:active {
  background: rgba(212, 175, 55, 0.15);
}

/* Main View Container */
.main-content {
  flex: 1;
  padding: 16px;
  max-width: 600px;
  width: 100%;
  margin: 0 auto;
}

/* Typography & Headings */
h1, h2, h3, h4 {
  color: var(--text-primary);
  font-weight: 600;
}

.section-title {
  font-size: 1.05rem;
  color: var(--accent-gold-light);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
