/* =============================================================================
   TRADING PAGES - LOCAL STYLES
   Consolidated from style.css + inline styles from HTML templates
   ============================================================================= */

/* =============================================================================
   BASE CONTAINER
   ============================================================================= */

.trading-container {
    max-width: 700px;
    margin: 60px auto;
    padding: 0 20px;
}

.trading-title {
    text-align: center;
    font-size: 28px;
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: 8px;
}

.trading-help {
    text-align: center;
    margin-top: 0;
    margin-bottom: 16px;
    font-size: 14px;
}

.trading-help a {
    color: var(--color-text-tertiary);
    text-decoration: none;
}

.trading-help a:hover {
    color: var(--color-blue);
}

/* =============================================================================
   ERROR HANDLING
   ============================================================================= */

.error-banner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: #fef2f2;
    border: 1px solid var(--color-red);
    color: var(--color-red);
    border-radius: var(--radius-md);
    margin-bottom: 20px;
    font-size: 14px;
}

.error-icon {
    font-size: 18px;
}

.error-dismiss {
    margin-left: auto;
    background: none;
    border: none;
    color: var(--color-red);
    cursor: pointer;
    font-size: 20px;
    padding: 0;
    line-height: 1;
}

.error-dismiss:hover {
    opacity: 0.7;
}

.error-message {
    padding: 12px 16px;
    background: #fef2f2;
    border: 1px solid var(--color-red);
    color: var(--color-red);
    border-radius: var(--radius-md);
    font-size: 13px;
    margin-bottom: 16px;
    display: none;
}

/* =============================================================================
   TRADE CARD (MAIN TRADING PAGE)
   ============================================================================= */

.trade-card {
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    overflow: hidden;
}

/* Tabs */
.tabs {
    display: flex;
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-border);
}

.tab {
    flex: 1;
    padding: 16px;
    background: transparent;
    border: none;
    font-family: var(--font-mono);
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text-tertiary);
    cursor: pointer;
    transition: all 0.15s;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    text-align: center;
    text-decoration: none;
}

.tab:hover {
    color: var(--color-text-primary);
}

.tab.active {
    background: var(--color-card);
    color: var(--color-blue);
    border-bottom-color: var(--color-blue);
}

.card-content {
    padding: 32px;
}

/* =============================================================================
   TIMELINE & STEPS
   ============================================================================= */

.timeline {
    position: relative;
    padding-left: 48px;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 15px;
    top: 32px;
    bottom: 32px;
    width: 2px;
    background: var(--color-border);
}

.step {
    position: relative;
    margin-bottom: 40px;
}

.step:last-child {
    margin-bottom: 0;
}

.step-number {
    position: absolute;
    left: -48px;
    top: 0;
    width: 32px;
    height: 32px;
    background: var(--color-blue);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 600;
    z-index: 1;
}

.step-header {
    margin-bottom: 16px;
}

.step-question {
    font-size: 18px;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--color-text-primary);
    margin-bottom: 4px;
}

.step-subtext {
    font-size: 13px;
    color: var(--color-text-tertiary);
    line-height: 1.5;
    margin: 0;
}

/* =============================================================================
   BUNDLE SELECTION
   ============================================================================= */

.bundle-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.bundle-card {
    position: relative;
}

.bundle-card input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.bundle-card label {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 20px 16px;
    background: var(--color-bg);
    border: 2px solid transparent;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.15s;
    text-align: center;
}

.bundle-card input:checked + label {
    border-color: var(--color-blue);
    background: rgba(22, 97, 119, 0.03);
}

.bundle-card label:hover {
    background: #e0e0e0;
}

.bundle-card input:checked + label:hover {
    background: rgba(22, 97, 119, 0.03);
}

.bundle-icon {
    font-size: 28px;
    margin-bottom: 10px;
}

.bundle-name {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 6px;
    color: var(--color-text-primary);
}

.bundle-desc {
    font-size: 12px;
    color: var(--color-text-secondary);
    line-height: 1.4;
    margin-bottom: 12px;
    flex: 1;
}

.bundle-tag {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    align-self: center;
}

.tag-stable {
    background: rgba(22, 97, 119, 0.15);
    color: var(--color-blue);
}

.tag-degen {
    background: rgba(248, 114, 45, 0.15);
    color: var(--color-orange);
}

.tag-chaos {
    background: rgba(177, 59, 60, 0.15);
    color: var(--color-red);
}

/* =============================================================================
   TOKEN COUNT SELECTOR
   ============================================================================= */

.token-selector {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 16px 0;
}

.token-display {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 12px;
}

.token-btn {
    width: 52px;
    height: 52px;
    border: 1px solid var(--color-border);
    background: var(--color-card);
    border-radius: 50%;
    font-size: 22px;
    color: var(--color-text-secondary);
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font-mono);
}

.token-btn:hover {
    border-color: var(--color-blue);
    color: var(--color-blue);
}

.token-count {
    font-size: 56px;
    font-weight: 600;
    letter-spacing: -0.03em;
    color: var(--color-text-primary);
    min-width: 80px;
    text-align: center;
}

.token-hint {
    font-size: 13px;
    color: var(--color-text-tertiary);
}

/* =============================================================================
   AMOUNT INPUT
   ============================================================================= */

.amount-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 16px 0;
}

.amount-input-wrapper {
    position: relative;
    margin-bottom: 10px;
}

.amount-input {
    width: 180px;
    padding: 16px 20px;
    padding-right: 60px;
    background: var(--color-bg);
    border: 2px solid transparent;
    border-radius: 10px;
    font-family: var(--font-mono);
    font-size: 28px;
    font-weight: 600;
    color: var(--color-text-primary);
    text-align: center;
    transition: border-color 0.15s;
}

.amount-input:focus {
    outline: none;
    border-color: var(--color-blue);
}

.amount-suffix {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text-tertiary);
}

.amount-hint {
    font-size: 13px;
    color: var(--color-text-tertiary);
}

/* =============================================================================
   SLIPPAGE BUTTONS
   ============================================================================= */

.slippage-section {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 8px 0;
}

.slippage-buttons {
    display: flex;
    gap: 8px;
}

.slippage-btn {
    padding: 12px 20px;
    background: var(--color-bg);
    border: 2px solid transparent;
    border-radius: 8px;
    font-family: var(--font-mono);
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text-secondary);
    cursor: pointer;
    transition: all 0.15s;
}

.slippage-btn:hover {
    border-color: var(--color-border);
}

.slippage-btn.selected {
    border-color: var(--color-blue);
    color: var(--color-blue);
    background: rgba(22, 97, 119, 0.03);
}

/* =============================================================================
   HOLDINGS LIST (SELL/WITHDRAW)
   ============================================================================= */

.holdings-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 320px;
    overflow-y: auto;
}

.holding-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--color-bg);
    border: 2px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s;
}

.holding-item:hover {
    background: #e0e0e0;
}

.holding-item.selected {
    border-color: var(--color-blue);
    background: rgba(22, 97, 119, 0.03);
}

.holding-checkbox {
    width: 20px;
    height: 20px;
    border: 2px solid var(--color-border);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.15s;
}

.holding-item.selected .holding-checkbox {
    background: var(--color-blue);
    border-color: var(--color-blue);
}

.holding-item.selected .holding-checkbox::after {
    content: "✓";
    color: white;
    font-size: 12px;
    font-weight: 600;
}

.holding-logo {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.holding-info {
    flex: 1;
    min-width: 0;
}

.holding-symbol {
    font-weight: 600;
    font-size: 14px;
    color: var(--color-text-primary);
}

.holding-address {
    font-size: 12px;
    color: var(--color-text-tertiary);
    text-decoration: none;
}

.holding-address:hover {
    color: var(--color-blue);
}

.holding-balance {
    text-align: right;
    font-weight: 600;
    font-size: 14px;
    color: var(--color-text-secondary);
}

.holding-value {
    font-weight: normal;
    color: var(--color-text-tertiary);
    font-size: 12px;
}

.selection-count {
    text-align: center;
    padding: 12px;
    background: rgba(22, 97, 119, 0.1);
    border-radius: 8px;
    margin-top: 12px;
    font-size: 14px;
    font-weight: 500;
    color: var(--color-blue);
}

/* =============================================================================
   EMPTY STATE
   ============================================================================= */

.empty-state {
    text-align: center;
    padding: 48px 24px;
    color: var(--color-text-tertiary);
}

.empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-text {
    font-size: 14px;
    margin-bottom: 8px;
}

.empty-link {
    color: var(--color-blue);
    text-decoration: none;
    font-weight: 500;
}

.empty-link:hover {
    color: var(--color-orange);
}

/* =============================================================================
   INFO BOX
   ============================================================================= */

.info-box {
    padding: 16px;
    background: var(--color-bg);
    border-radius: 8px;
    font-size: 13px;
    color: var(--color-text-secondary);
    line-height: 1.5;
    text-align: center;
}

/* =============================================================================
   SUMMARY SECTION (BLUE BAR)
   ============================================================================= */

.summary-section {
    background: var(--color-blue);
    margin: 32px -32px -32px;
    padding: 28px 32px;
    color: white;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 24px;
}

.summary-item {
    text-align: center;
}

.summary-label {
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 6px;
}

.summary-value {
    font-size: 18px;
    font-weight: 600;
}

.summary-address {
    font-size: 14px;
}

/* =============================================================================
   FOOTER NOTE
   ============================================================================= */

.footer-note {
    text-align: center;
    margin-top: 24px;
    font-size: 13px;
    color: var(--color-text-tertiary);
}

.footer-note a {
    color: var(--color-blue);
    text-decoration: none;
}

.footer-note a:hover {
    color: var(--color-orange);
}

/* =============================================================================
   APPROVAL PAGE
   ============================================================================= */

.approval-container {
    max-width: 500px;
}

.approval-card {
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    overflow: hidden;
}

.approval-header {
    background: var(--color-bg);
    padding: 20px 32px;
    border-bottom: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    gap: 12px;
}

.approval-header-icon {
    font-size: 24px;
}

.approval-header-text {
    font-size: 16px;
    font-weight: 600;
    color: var(--color-text-primary);
}

.approval-content {
    padding: 32px;
}

.approval-title {
    font-size: 22px;
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: 8px;
}

.approval-desc {
    font-size: 14px;
    color: var(--color-text-secondary);
    line-height: 1.6;
    margin-bottom: 24px;
}

.approval-details {
    background: var(--color-bg);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 24px;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--color-border);
}

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

.detail-row:first-child {
    padding-top: 0;
}

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

.detail-value {
    font-size: 13px;
    font-weight: 600;
    color: var(--color-text-primary);
}

.approval-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.approval-note {
    text-align: center;
    margin-top: 20px;
    font-size: 12px;
    color: var(--color-text-tertiary);
}

/* =============================================================================
   CONFIRM PAGE
   ============================================================================= */

.confirm-container {
    max-width: 480px;
    margin: 80px auto;
}

.confirm-card {
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: 48px 32px;
    text-align: center;
}

.confirm-note {
    font-size: 13px;
    color: var(--color-text-tertiary);
    margin-bottom: 24px;
}

.confirm-note a {
    color: var(--color-blue);
    text-decoration: none;
}

.confirm-note a:hover {
    text-decoration: underline;
}

.status-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    font-size: 40px;
}

.status-icon.pending {
    background: rgba(22, 97, 119, 0.1);
}

.status-icon.success {
    background: rgba(5, 150, 105, 0.1);
    color: #059669;
}

.status-icon.failed {
    background: rgba(177, 59, 60, 0.1);
    color: var(--color-red);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--color-border);
    border-top-color: var(--color-blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.confirm-title {
    font-size: 22px;
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: 8px;
}

.confirm-desc {
    font-size: 14px;
    color: var(--color-text-secondary);
    margin-bottom: 24px;
    line-height: 1.6;
}

.tx-box {
    background: var(--color-bg);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 24px;
    text-align: left;
}

.tx-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-tertiary);
    margin-bottom: 8px;
}

.tx-hash {
    font-size: 12px;
    color: var(--color-text-secondary);
    word-break: break-all;
    line-height: 1.5;
}

.confirm-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* =============================================================================
   PREVIEW PAGE
   ============================================================================= */

.preview-container {
    max-width: 600px;
}

.preview-card {
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    overflow: hidden;
}

.preview-header {
    padding: 24px 32px;
    border-bottom: 1px solid var(--color-border);
}

.preview-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: 4px;
}

.preview-subtitle {
    font-size: 13px;
    color: var(--color-text-tertiary);
    margin: 0;
}

.preview-content {
    padding: 24px 32px;
}

.preview-summary {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    padding: 20px;
    background: var(--color-bg);
    border-radius: var(--radius-lg);
    margin-bottom: 24px;
}

.summary-stat {
    text-align: center;
}

.summary-stat-value {
    font-size: 18px;
    font-weight: 600;
    color: var(--color-text-primary);
}

.summary-stat-label {
    font-size: 11px;
    color: var(--color-text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.token-list-header {
    font-size: 13px;
    font-weight: 600;
    color: var(--color-text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.token-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 320px;
    overflow-y: auto;
}

/* Preview Item */
.preview-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--color-bg);
    border-radius: var(--radius-lg);
    border: 2px solid transparent;
}

.preview-item.featured {
    border-color: var(--color-orange);
    background: rgba(248, 114, 45, 0.05);
}

.preview-item-logo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.preview-item-logo-placeholder {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 16px;
    flex-shrink: 0;
}

.preview-item-info {
    flex: 1;
    min-width: 0;
}

.preview-item-name {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 2px;
}

.preview-item-symbol {
    font-weight: 600;
    font-size: 14px;
    color: var(--color-text-primary);
}

.featured-badge {
    padding: 2px 6px;
    background: var(--color-orange);
    color: white;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
}

.preview-item-address {
    font-size: 12px;
    color: var(--color-text-tertiary);
    text-decoration: none;
}

.preview-item-address:hover {
    color: var(--color-blue);
}

.preview-item-amounts {
    text-align: right;
}

.preview-item-primary {
    font-weight: 600;
    font-size: 14px;
    color: var(--color-text-primary);
    margin-bottom: 2px;
}

.preview-item-secondary {
    font-size: 12px;
    color: var(--color-text-tertiary);
}

.preview-item-impact {
    color: var(--color-orange);
}

.preview-item-impact.warning {
    color: #f59e0b;
    font-weight: bold;
}

.preview-footer {
    padding: 24px 32px;
    border-top: 1px solid var(--color-border);
    background: var(--color-bg);
}

.preview-actions {
    display: flex;
    gap: 12px;
}

.preview-note {
    text-align: center;
    margin-top: 16px;
    margin-bottom: 0;
    font-size: 12px;
    color: var(--color-text-tertiary);
}

/* Copy Context Banner */
.copy-context {
    padding: 16px 32px;
    background: rgba(22, 97, 119, 0.08);
    border-bottom: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    gap: 12px;
}

.copy-context-icon {
    font-size: 20px;
}

.copy-context-text {
    flex: 1;
}

.copy-context-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-tertiary);
}

.copy-context-trader {
    font-size: 14px;
    font-weight: 500;
    color: var(--color-blue);
}

.copy-context-trader a {
    color: inherit;
    text-decoration: none;
}

.copy-context-trader a:hover {
    text-decoration: underline;
}

.copy-context-meta {
    font-size: 12px;
    color: var(--color-text-tertiary);
    text-align: right;
}

/* =============================================================================
   ENTRY PAGE (COPY TRADE + GROUP TRADE - UNIFIED)
   ============================================================================= */

.entry-container {
    max-width: 600px;
    margin: 60px auto;
    padding: 0 20px;
}

.entry-title {
    text-align: center;
    font-size: 28px;
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: 8px;
}

.entry-subtitle {
    text-align: center;
    font-size: 14px;
    color: var(--color-text-tertiary);
    margin-bottom: 24px;
}

.entry-card {
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    overflow: hidden;
}

/* Entry Context (header section - copy or group) */
.entry-context {
    padding: 24px 32px;
    border-bottom: 1px solid var(--color-border);
    background: var(--color-bg);
}

.entry-context-simple {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 32px;
    background: rgba(22, 97, 119, 0.08);
}

.entry-context-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.entry-context-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-tertiary);
    margin-bottom: 4px;
}

.entry-context-icon {
    font-size: 24px;
}

.entry-context-text {
    flex: 1;
}

.entry-context-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--color-text-primary);
}

.entry-context-name a {
    color: inherit;
    text-decoration: none;
}

.entry-context-name a:hover {
    color: var(--color-blue);
}

.entry-context-meta {
    text-align: right;
}

.entry-context-date {
    font-size: 13px;
    color: var(--color-text-secondary);
}

.entry-context-tx {
    font-size: 12px;
    color: var(--color-text-tertiary);
}

.entry-context-tx a {
    color: inherit;
    text-decoration: none;
}

.entry-context-tx a:hover {
    color: var(--color-blue);
}

/* Original Trader (copy trade context) */
.original-trader {
    display: flex;
    align-items: center;
    gap: 8px;
}

.trader-avatar {
    width: 32px;
    height: 32px;
    background: var(--color-blue);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: white;
    font-weight: 600;
}

.trader-info {
    display: flex;
    flex-direction: column;
}

.trader-address {
    font-size: 14px;
    font-weight: 600;
    color: var(--color-text-primary);
}

.trader-link {
    font-size: 12px;
    color: var(--color-blue);
    text-decoration: none;
}

.trader-link:hover {
    text-decoration: underline;
}

/* Entry Warning (copy trade only) */
.entry-warning {
    margin: 24px 32px;
    padding: 16px;
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 8px;
}

.entry-warning-title {
    font-size: 14px;
    font-weight: 600;
    color: #f59e0b;
    margin-bottom: 4px;
}

.entry-warning-text {
    font-size: 13px;
    color: var(--color-text-secondary);
    line-height: 1.5;
}

/* Entry Form */
.entry-form {
    padding: 24px 32px;
}

/* Entry Footer */
.entry-footer {
    padding: 24px 32px;
    background: var(--color-blue);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.entry-summary {
    display: flex;
    justify-content: space-between;
    color: white;
}

.entry-summary-item {
    text-align: center;
}

.entry-summary-label {
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 4px;
}

.entry-summary-value {
    font-size: 16px;
    font-weight: 600;
}

.entry-actions {
    display: flex;
    gap: 12px;
}

.entry-note {
    text-align: center;
    margin-top: 20px;
    font-size: 13px;
    color: var(--color-text-tertiary);
}

.entry-note a {
    color: var(--color-blue);
    text-decoration: none;
}

/* Pattern Section */
.pattern-section {
    padding: 24px 32px;
    border-bottom: 1px solid var(--color-border);
    background: var(--color-bg);
}

.pattern-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-tertiary);
    margin-bottom: 12px;
}

.pattern-tokens {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pattern-token {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: var(--color-card);
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
}

.pattern-token-icon {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    object-fit: cover;
}

.pattern-token-icon-placeholder {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 600;
    color: white;
}

/* Trade Form */
.trade-form {
    padding: 24px 32px;
}

.form-section {
    margin-bottom: 24px;
}

.form-section:last-child {
    margin-bottom: 0;
}

.form-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: 8px;
    display: block;
}

.form-hint {
    font-size: 12px;
    color: var(--color-text-tertiary);
    margin-top: 6px;
}

/* ETH Input (alternate style for copy/group pages) */
.eth-input-wrapper {
    position: relative;
    max-width: 200px;
}

.eth-input {
    width: 100%;
    padding: 14px 16px;
    padding-right: 50px;
    background: var(--color-bg);
    border: 2px solid transparent;
    border-radius: 8px;
    font-family: inherit;
    font-size: 20px;
    font-weight: 600;
    color: var(--color-text-primary);
    transition: border-color 0.15s;
}

.eth-input:focus {
    outline: none;
    border-color: var(--color-blue);
}

.eth-suffix {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text-tertiary);
}

/* Trade Footer */
.trade-footer {
    padding: 24px 32px;
    background: var(--color-blue);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.trade-summary {
    display: flex;
    justify-content: space-between;
    color: white;
}

.trade-summary-item {
    text-align: center;
}

.trade-summary-label {
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 4px;
}

.trade-summary-value {
    font-size: 16px;
    font-weight: 600;
}

.trade-actions {
    display: flex;
    gap: 12px;
}

.trade-note {
    text-align: center;
    margin-top: 20px;
    font-size: 13px;
    color: var(--color-text-tertiary);
}

/* =============================================================================
   SHARED BUTTONS
   ============================================================================= */

.btn {
    flex: 1;
    padding: 14px 24px;
    border-radius: var(--radius-lg);
    font-family: var(--font-mono);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    text-align: center;
    text-decoration: none;
    border: none;
    display: inline-block;
}

.btn-primary {
    background: var(--color-blue);
    color: white;
}

.btn-primary:hover {
    background: #124f5f;
}

.btn-primary:disabled {
    background: var(--color-border);
    cursor: not-allowed;
}

.btn-secondary {
    background: var(--color-card);
    color: var(--color-text-secondary);
    border: 1px solid var(--color-border);
}

.btn-secondary:hover {
    background: var(--color-bg);
}

.btn-orange {
    background: var(--color-orange);
    color: white;
}

.btn-orange:hover {
    background: #e66525;
}

.btn-cancel {
    background: rgba(255, 255, 255, 0.15);
    color: white;
}

.btn-cancel:hover {
    background: rgba(255, 255, 255, 0.25);
}

.btn-submit {
    width: 100%;
    padding: 16px;
    background: var(--color-orange);
    color: white;
    border: none;
    border-radius: 8px;
    font-family: var(--font-mono);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
}

.btn-submit:hover {
    background: #e66525;
}

.btn-submit:disabled {
    background: rgba(255, 255, 255, 0.2);
    cursor: not-allowed;
}

/* =============================================================================
   MOBILE RESPONSIVE
   ============================================================================= */

@media (max-width: 640px) {
    .trading-container,
    .copy-container,
    .trade-container {
        margin: 40px auto;
    }

    .card-content {
        padding: 24px;
    }

    /* Timeline */
    .timeline {
        padding-left: 40px;
    }

    .timeline::before {
        left: 11px;
    }

    .step-number {
        left: -40px;
        width: 24px;
        height: 24px;
        font-size: 11px;
    }

    .step-question {
        font-size: 16px;
    }

    /* Bundle grid */
    .bundle-grid {
        grid-template-columns: 1fr;
    }

    /* Token selector */
    .token-count {
        font-size: 44px;
    }

    .token-btn {
        width: 44px;
        height: 44px;
        font-size: 18px;
    }

    /* Amount input */
    .amount-input {
        font-size: 24px;
        width: 160px;
    }

    /* Slippage */
    .slippage-section,
    .slippage-buttons {
        flex-wrap: wrap;
    }

    .slippage-btn {
        padding: 10px 16px;
        font-size: 13px;
    }

    /* Summary section */
    .summary-section {
        margin: 32px -24px -24px;
        padding: 24px;
    }

    .summary-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    /* Approval */
    .approval-content {
        padding: 24px;
    }

    .approval-header {
        padding: 16px 24px;
    }

    /* Confirm */
    .confirm-container {
        margin: 40px auto;
    }

    .confirm-card {
        padding: 32px 24px;
    }

    /* Preview */
    .preview-summary {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .preview-actions {
        flex-direction: column;
    }

    .preview-content,
    .preview-header,
    .preview-footer {
        padding: 20px;
    }

    .preview-item {
        display: grid;
        grid-template-columns: 32px 1fr;
        gap: 10px;
        padding: 12px;
    }

    .preview-item-logo,
    .preview-item-logo-placeholder {
        width: 32px;
        height: 32px;
        font-size: 14px;
        grid-row: span 2;
    }

    .preview-item-info {
        min-width: 0;
    }

    .preview-item-symbol {
        font-size: 14px;
    }

    .preview-item-address {
        font-size: 11px;
    }

    .featured-badge {
        font-size: 9px;
        padding: 2px 5px;
    }

    .preview-item-amounts {
        text-align: left;
        font-size: 12px;
        color: var(--color-text-secondary);
    }

    .preview-item-primary {
        font-size: 12px;
        font-weight: 500;
    }

    .preview-item-secondary {
        font-size: 11px;
        color: var(--color-text-tertiary);
    }

    /* Copy context */
    .copy-context {
        padding: 20px;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .copy-context-meta {
        text-align: left;
    }

    /* Holding Item */
    .holding-item {
        display: grid;
        grid-template-columns: 20px 28px 1fr;
        gap: 10px;
        align-items: center;
        padding: 12px;
    }

    .holding-checkbox {
        width: 18px;
        height: 18px;
    }

    .holding-logo {
        width: 28px;
        height: 28px;
    }

    .holding-info {
        min-width: 0;
    }

    .holding-symbol {
        font-size: 14px;
    }

    .holding-address {
        display: none;
    }

    .holding-balance {
        grid-column: 3;
        text-align: left;
        font-size: 13px;
        font-weight: 500;
    }

    .holding-value {
        font-weight: normal;
        color: var(--color-text-tertiary);
        font-size: 12px;
    }

    /* Entry page (copy + group trade) */
    .entry-container {
        margin: 40px auto;
    }

    .entry-context,
    .entry-context-simple,
    .pattern-section,
    .entry-form,
    .entry-footer {
        padding: 20px;
    }

    .entry-warning {
        margin: 20px;
    }

    .entry-context-header {
        flex-direction: column;
        gap: 12px;
    }

    .entry-context-meta {
        text-align: left;
    }

    .entry-summary {
        flex-direction: column;
        gap: 12px;
    }

    .entry-summary-item {
        display: flex;
        justify-content: space-between;
        text-align: left;
    }
}
