/* Core App Styles */
.imei-app {
    max-width: 480px;
    margin: 2rem auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.imei-field {
    width: 100%;
    padding: 12px 16px;
    margin: 8px 0;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.imei-field:focus {
    outline: none;
    border-color: #635bff;
}

.status-message {
    text-align: center;
    padding: 10px;
    border-radius: 4px;
    margin: 10px 0;
    font-size: 14px;
    font-weight: 500;
}

.status-message.info {
    color: #3498db;
    background: #ebf5fb;
    border: 1px solid #bce0fd;
}

.status-message.error {
    color: #e74c3c;
    background: #fdedec;
    border: 1px solid #f5c6cb;
}

/* Card Results & Checkout */
.card-result {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    border: 1px solid #eaeaea;
}

.device-model {
    margin: 0 0 10px 0;
    font-size: 1.5rem;
    color: #2c3e50;
}

.device-price {
    font-size: 2.5rem;
    font-weight: 700;
    color: #27ae60;
    margin-bottom: 20px;
}

.wa-group {
    display: flex;
    gap: 10px;
    align-items: stretch;
}

.country-select {
    width: 130px;
    flex-shrink: 0;
    padding: 12px 8px;
}

.payment-links {
    margin-top: 20px;
}

.pay-link {
    display: block;
    width: 100%;
    text-align: center;
    padding: 14px;
    margin-bottom: 10px;
    border-radius: 8px;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    transition: opacity 0.2s;
    box-sizing: border-box;
}

.pay-link:hover {
    opacity: 0.9;
    color: #fff;
}

.pay-link.stripe { background: #635bff; }
.pay-link.binance { background: #fcd535; color: #1e2329; }
.pay-link.nowpay { background: #000000; }
.pay-link.paypal { background: #00457c; }

/* NEW: Order Tracking Widget Styles */
.tracking-header {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
}

.tracking-details {
    margin-top: 20px;
}

.tracking-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
    font-size: 15px;
}

.tracking-row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.tracking-label {
    color: #666;
    font-weight: 500;
}

.tracking-value {
    color: #333;
    font-weight: 600;
}

.status-badge {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Dynamic colors injected by JS based on text content, or default below */
.status-badge {
    background: #f0f0ff;
    color: #635bff;
    border: 1px solid #dcdceb;
}

/* NEW: Dual Pricing UI Styles */
.device-header {
    text-align: center;
    border-bottom: 1px solid #eee;
    padding-bottom: 20px;
}

.pricing-tiers {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 15px;
}

.price-tier {
    background: #f8f9fa;
    padding: 10px 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.price-tier small {
    display: block;
    color: #6c757d;
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
}

.tier-amount {
    font-size: 1.5rem;
    font-weight: 700;
    color: #27ae60;
}

.price-tier.crypto .tier-amount {
    color: #f39c12;
}

/* Ensure all payment links have explicit white text so they are clear */
.pay-link {
    display: block;
    width: 100%;
    text-align: center;
    padding: 14px;
    margin-bottom: 10px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    transition: opacity 0.2s;
    box-sizing: border-box;
    color: #ffffff !important; /* Forces solid white text */
}

.pay-link:hover {
    opacity: 0.85;
    color: #ffffff !important;
}

.pay-link.stripe { background: #635bff; }
.pay-link.paypal { background: #00457c; }
.pay-link.binance { background: #fcd535; color: #1e2329 !important; } /* Binance black text */
.pay-link.nowpay { background: #000000; }

/* Flexbox Layout Fixes */
.device-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #eee;
    padding-bottom: 20px;
}

.device-info {
    text-align: left;
}

.pricing-tiers {
    display: flex;
    gap: 15px;
    margin-top: 10px;
}

/* Animated Loading Spinner */
.tuh-spinner {
    border: 4px solid rgba(99, 91, 255, 0.1); /* Light purple background */
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border-left-color: #635bff; /* Solid purple spinning line */
    animation: tuh-spin 1s cubic-bezier(0.5, 0.1, 0.4, 0.9) infinite;
    margin: 0 auto;
}

@keyframes tuh-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.pay-link.momo { 
    background: #008000; /* Hubtel Green */
    color: #ffffff !important; 
}