/* Solana Launchpad - Modern UI Styles */

:root {
    --primary: #9945FF;
    --primary-dark: #7d38d9;
    --secondary: #14F195;
    --background: #0f0f0f;
    --surface: #1a1a1a;
    --surface-light: #2a2a2a;
    --text: #ffffff;
    --text-muted: #a0a0a0;
    --border: #333333;
    --success: #14F195;
    --warning: #FFB800;
    --error: #FF4444;
    --shadow: rgba(153, 69, 255, 0.2);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
    background: var(--background);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Styles */
header {
    background: var(--surface);
    border-bottom: 2px solid var(--primary);
    padding: 20px 0;
    margin-bottom: 40px;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

nav a {
    color: var(--text);
    text-decoration: none;
    margin-left: 30px;
    transition: color 0.3s;
    font-weight: 500;
}

nav a:hover {
    color: var(--primary);
}

/* Button Styles */
.btn {
    background: var(--primary);
    color: var(--text);
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s;
    display: inline-block;
    text-decoration: none;
    text-align: center;
}

.btn:hover:not(:disabled) {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--shadow);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-secondary {
    background: var(--surface-light);
    border: 2px solid var(--primary);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--primary);
}

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

.btn-large {
    padding: 16px 32px;
    font-size: 18px;
}

/* Card Styles */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.card-title {
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--primary);
    font-weight: 700;
}

.card-subtitle {
    font-size: 18px;
    margin-bottom: 15px;
    color: var(--secondary);
    font-weight: 600;
}

/* Form Styles */
.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-muted);
    font-weight: 500;
}

input[type="text"],
input[type="number"],
textarea,
select {
    width: 100%;
    padding: 12px;
    background: var(--background);
    border: 2px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-size: 16px;
    transition: border-color 0.3s;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--primary);
}

input::placeholder {
    color: var(--text-muted);
}

/* Alert Styles */
.alert {
    padding: 16px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid;
}

.alert-info {
    background: rgba(153, 69, 255, 0.1);
    border-color: var(--primary);
    color: var(--text);
}

.alert-warning {
    background: rgba(255, 184, 0, 0.1);
    border-color: var(--warning);
    color: #FFD93D;
}

.alert-success {
    background: rgba(20, 241, 149, 0.1);
    border-color: var(--success);
    color: #4FFFB0;
}

.alert-error {
    background: rgba(255, 68, 68, 0.1);
    border-color: var(--error);
    color: #FF8888;
}

/* Light background utility class for better contrast */
.alert-light-bg {
    background: #fff3cd !important;
    color: #664d03 !important;
    border-color: #ffc107 !important;
}

.alert-light-bg strong {
    color: #664d03 !important;
}

.alert-light-bg small {
    color: #856404 !important;
}

/* Status Display */
.status-box {
    background: var(--surface-light);
    border: 2px solid var(--border);
    border-radius: 8px;
    padding: 15px;
    margin: 15px 0;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    word-break: break-all;
}

.status-connected {
    border-color: var(--success);
    color: var(--success);
}

.status-disconnected {
    border-color: var(--text-muted);
    color: var(--text-muted);
}

/* Grid Layout */
.grid {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 60px 20px;
}

.hero h1 {
    font-size: 48px;
    margin-bottom: 20px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero p {
    font-size: 20px;
    color: var(--text-muted);
    margin-bottom: 30px;
}

/* Feature Cards */
.feature {
    text-align: center;
    padding: 20px;
}

.feature-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.feature h3 {
    margin-bottom: 10px;
    color: var(--primary);
}

/* Transaction Display */
.tx-link {
    color: var(--secondary);
    text-decoration: none;
    word-break: break-all;
    display: inline-block;
    margin-top: 10px;
}

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

/* Loading Spinner */
.spinner {
    border: 3px solid var(--surface-light);
    border-top: 3px solid var(--primary);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Address Display */
.address {
    font-family: 'Courier New', monospace;
    background: var(--background);
    padding: 10px 15px;
    border-radius: 6px;
    display: inline-block;
    margin: 10px 0;
    word-break: break-all;
}

/* Info Grid */
.info-grid {
    display: grid;
    gap: 15px;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: var(--background);
    border-radius: 8px;
    border-left: 3px solid var(--primary);
}

.info-label {
    font-weight: 600;
    color: var(--text-muted);
}

.info-value {
    color: var(--text);
    font-family: 'Courier New', monospace;
}

/* Footer */
footer {
    background: var(--surface);
    border-top: 2px solid var(--primary);
    padding: 30px 20px;
    margin-top: 60px;
    text-align: center;
    color: var(--text-muted);
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        text-align: center;
    }
    
    nav {
        width: 100%;
    }
    
    nav a {
        margin: 0 15px;
        font-size: 14px;
    }
    
    .hero h1 {
        font-size: 32px;
    }
    
    .hero p {
        font-size: 16px;
    }
    
    .card {
        padding: 15px;
    }
    
    .grid,
    .grid-2 {
        grid-template-columns: 1fr;
    }
    
    /* Mobile-friendly buttons */
    .btn-large {
        padding: 14px 24px;
        font-size: 16px;
    }
    
    /* Touch-friendly inputs */
    input[type="text"],
    input[type="number"] {
        font-size: 16px !important; /* Prevents zoom on iOS */
    }
    
    /* Mobile trading interface */
    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
}

/* App-ready styles */
@media (max-width: 480px) {
    .container {
        padding: 10px;
    }
    
    .card {
        padding: 12px;
        margin-bottom: 15px;
    }
    
    .logo span {
        font-size: 22px !important;
    }
    
    nav a {
        margin: 0 8px;
        font-size: 12px;
    }
    
    /* Single column stats on small screens */
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    /* Larger touch targets */
    .btn {
        min-height: 44px;
    }
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

.hidden {
    display: none;
}

.fade-in {
    animation: fadeIn 0.5s;
}

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

/* Contrast Helper Classes */
.text-dark {
    color: #333 !important;
}

.text-dark-muted {
    color: #666 !important;
}

.text-light {
    color: #ffffff !important;
}

.bg-light-warning {
    background: #fff3cd !important;
    color: #856404 !important;
}

.bg-light-success {
    background: #d1f4e0 !important;
    color: #0f5132 !important;
}

.bg-light-info {
    background: #cfe2ff !important;
    color: #084298 !important;
}

.bg-light-danger {
    background: #f8d7da !important;
    color: #842029 !important;
}

