* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Orange selection highlight */
::selection {
    background: rgba(255, 126, 31, 0.4);
    color: #ffffff;
}
::-moz-selection {
    background: rgba(255, 126, 31, 0.4);
    color: #ffffff;
}

/* Prevent text copying */
body {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Allow selection in input/textarea fields */
input, textarea, [contenteditable="true"] {
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #2a2a2a;
    min-height: 100vh;
    color: #ffffff;
}

/* Navbar */
.navbar {
    background: #1a1a1a;
    border-bottom: 1px solid #333;
    padding: 1rem 2rem;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-size: 1.5rem;
    font-weight: 600;
    color: #ffffff;
    text-decoration: none;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-email {
    color: #b0b0b0;
    font-size: 0.9rem;
}

.btn-signin,
.btn-signout {
    background: #ffffff;
    color: #1a1a1a;
    border: none;
    padding: 10px 24px;
    border-radius: 6px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-signin:hover,
.btn-signout:hover {
    background: #e0e0e0;
    transform: translateY(-1px);
}

.btn-signin:active,
.btn-signout:active {
    transform: translateY(0);
}

.btn-signout {
    background: transparent;
    color: #ffffff;
    border: 1px solid #666;
}

.btn-signout:hover {
    background: #333;
    border-color: #888;
}

/* Main Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 100px 2rem 2rem;
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 4rem 0;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #ffffff;
}

.hero p {
    font-size: 1.25rem;
    color: #b0b0b0;
}

/* Auth Pages */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 2rem 2rem;
}

.auth-card {
    background: #1a1a1a;
    border-radius: 12px;
    padding: 3rem;
    max-width: 450px;
    width: 100%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.auth-card h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: #ffffff;
}

.auth-subtitle {
    color: #b0b0b0;
    margin-bottom: 2rem;
}

.auth-form {
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: #ffffff;
    font-weight: 500;
    font-size: 0.95rem;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    background: #2a2a2a;
    border: 1px solid #404040;
    border-radius: 6px;
    color: #ffffff;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.form-group input:focus {
    outline: none;
    border-color: #ffffff;
}

.form-group input::placeholder {
    color: #666;
}

.form-group small {
    display: block;
    margin-top: 0.25rem;
    color: #888;
    font-size: 0.85rem;
}

.btn-primary {
    width: 100%;
    background: #ffffff;
    color: #1a1a1a;
    border: none;
    padding: 14px 24px;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}

.btn-primary:hover {
    background: #e0e0e0;
    transform: translateY(-1px);
}

.btn-primary:active {
    transform: translateY(0);
}

.message {
    margin-top: 1rem;
    padding: 12px;
    border-radius: 6px;
    font-size: 0.95rem;
    display: none;
}

.message.show {
    display: block;
}

.message.success {
    background: #1e4620;
    color: #4ade80;
    border: 1px solid #2d5a2f;
}

.message.error {
    background: #4a1e1e;
    color: #ef4444;
    border: 1px solid #5a2d2d;
}

.auth-footer {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid #333;
}

.auth-footer p {
    color: #b0b0b0;
}

.auth-footer a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 500;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Insufficient Tokens Modal */
/* Insufficient Tokens Modal - Matches Alert Settings Style */
.insufficient-tokens-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    overflow-y: auto;
}

.insufficient-tokens-modal {
    width: 100%;
    max-width: 550px;
    background: #141517;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.insufficient-tokens-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.insufficient-tokens-brand {
    display: flex;
    align-items: center;
    gap: 8px;
}

.insufficient-tokens-brand-text {
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 700;
    font-size: 16px;
    color: #ffffff;
}

.insufficient-tokens-badge {
    font-size: 8px;
    padding: 3.2px 6.4px;
    background: #ff6b00;
    color: #fff;
    border-radius: 3px;
    font-weight: 700;
    font-family: 'IBM Plex Mono', monospace;
}

.insufficient-tokens-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.insufficient-tokens-close:hover {
    color: rgba(255, 255, 255, 0.9);
}

.insufficient-tokens-content {
    padding: 24px;
}

.insufficient-tokens-title-section {
    margin-bottom: 24px;
}

.insufficient-tokens-icon-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.insufficient-tokens-icon-title svg {
    color: #ff6b00;
    flex-shrink: 0;
}

.insufficient-tokens-icon-title h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: white;
    margin: 0;
}

.insufficient-tokens-intro {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
    line-height: 1.5;
    margin: 0;
}

.insufficient-tokens-details {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 24px;
}

.insufficient-tokens-detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.insufficient-tokens-detail-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.insufficient-tokens-detail-item:first-child {
    padding-top: 0;
}

.insufficient-tokens-detail-item.highlight {
    background: rgba(255, 107, 0, 0.05);
    border: 1px solid rgba(255, 107, 0, 0.2);
    border-radius: 6px;
    padding: 12px;
    margin-top: 8px;
}

.insufficient-tokens-detail-label {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 500;
}

.insufficient-tokens-detail-value {
    font-size: 0.9375rem;
    color: white;
    font-weight: 600;
    font-family: 'IBM Plex Mono', monospace;
}

.insufficient-tokens-detail-item.highlight .insufficient-tokens-detail-label {
    color: rgba(255, 107, 0, 0.9);
}

.insufficient-tokens-detail-item.highlight .insufficient-tokens-detail-value {
    color: #ff6b00;
}

.insufficient-tokens-footer {
    display: flex;
    flex-direction: row;
    gap: 12px;
}

.insufficient-tokens-btn-primary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    background: #ff6b00;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'IBM Plex Mono', monospace;
    width: 100%;
}

.insufficient-tokens-btn-primary svg {
    width: 14px;
    height: 14px;
}

.insufficient-tokens-btn-primary:hover {
    background: #ff8020;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 107, 0, 0.3);
}

.insufficient-tokens-btn-primary:active {
    transform: translateY(0);
}

.insufficient-tokens-btn-secondary {
    padding: 10px 24px;
    background: transparent;
    color: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'IBM Plex Mono', monospace;
    width: 100%;
}

.insufficient-tokens-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.8);
}

