@import "https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap";

:root {
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --primary-light: #a5b4fc;
    --shopee-orange: #EE4D2D;
    --success-green: #10B981;
    --bg: #f8fafc;
    --white: #ffffff;
    --text: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --border: #e2e8f0;
    --radius-md: 12px;
    --radius-lg: 16px;
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, .1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, .1);
    --transition: all .2s cubic-bezier(.4, 0, .2, 1);
    --gradient-primary: linear-gradient(135deg, #6366F1 0%, #8B5CF6 100%);
    --gradient-accent: linear-gradient(135deg, #8B5CF6 0%, #EE4D2D 100%);
    --gradient-success: linear-gradient(135deg, #10B981 0%, #34D399 100%);
}

* {
    font-family: 'Inter', sans-serif;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    margin: 0; padding: 0;
}

body {
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* ==========================================
   LAYOUT GỐC (HOANTIEN.CLICK)
   ========================================== */
.minimal-container {
    min-height: 100vh;
    padding-bottom: 80px;
}

.minimal-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px) saturate(180%);
    border-bottom: 1px solid var(--border);
    padding: 14px 0;
}

.header-inner {
    max-width: 640px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.minimal-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 18px;
    font-weight: 800;
    color: var(--text);
    text-decoration: none;
}

.minimal-logo:before {
    content: "💰";
    font-size: 24px;
}

.auth-buttons .ant-btn {
    height: 40px;
    border-radius: 8px;
    font-weight: 500;
    padding: 0 16px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
}

.auth-buttons .btn-guide {
    background: #f1f5f9;
    color: var(--text-secondary);
}

.auth-buttons .btn-guide:hover {
    background: #e2e8f0;
}

.minimal-content {
    max-width: 640px;
    margin: 0 auto;
    padding: 32px 20px 0;
}

.minimal-hero {
    text-align: center;
    margin-bottom: 32px;
}

.minimal-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 10px;
    letter-spacing: -0.3px;
    line-height: 1.4;
}

.minimal-title:before { content: "🎁 "; }

.minimal-features {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 15px;
    color: var(--text-secondary);
    font-weight: 500;
}

.minimal-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 32px 24px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
    margin-bottom: 32px;
}

.input-group {
    margin-bottom: 16px;
}

.input-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text);
}

.input-label i { color: var(--primary); }

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.smart-input {
    width: 100%;
    height: 52px;
    border-radius: var(--radius-md);
    border: 1.5px solid var(--border);
    font-size: 15px;
    transition: var(--transition);
    background: var(--white);
    padding: 0 16px;
    outline: none;
}

.smart-input:hover { border-color: var(--primary-light); }
.smart-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px #6366f11a;
}

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

/* Nút Xóa / Dán bên trong input */
.btn-paste, .btn-clear {
    position: absolute;
    right: 8px;
    background: var(--bg);
    border: 1px solid var(--border);
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    color: var(--text-secondary);
    transition: 0.2s;
}
.btn-paste:hover, .btn-clear:hover { background: #e2e8f0; }
.btn-clear { border: none; background: transparent; right: 10px; font-size: 16px; }

/* Nút CTA Gradient Siêu Mượt */
.minimal-cta {
    height: 56px;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, #8b5cf6, #ee4d2d, #8b5cf6);
    background-size: 200% 200%;
    border: none;
    font-weight: 700;
    font-size: 16px;
    width: 100%;
    color: white;
    box-shadow: 0 4px 12px #8b5cf64d, 0 0 #ee4d2d99;
    transition: var(--transition);
    margin-top: 8px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    animation: ctaPulse 2.5s ease-in-out infinite, ctaGradient 4s ease infinite;
}

.minimal-cta:before {
    content: "";
    position: absolute;
    top: 0; left: -100%;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.3), transparent);
    animation: ctaShimmer 3.5s ease-in-out infinite;
    z-index: 1;
    pointer-events: none;
}

.minimal-cta:hover:not(:disabled) {
    animation: ctaPulseHover 1.2s ease-in-out infinite, ctaGradient 4s ease infinite;
    transform: translateY(-2px) scale(1.01);
    box-shadow: 0 8px 25px #8b5cf680, 0 0 #ee4d2db3;
}

.minimal-cta span, .minimal-cta i { position: relative; z-index: 2; }

@keyframes ctaPulse {
    0%, to { box-shadow: 0 4px 12px #8b5cf64d, 0 0 #ee4d2d99; transform: scale(1); }
    50% { box-shadow: 0 4px 18px #8b5cf666, 0 0 0 10px #ee4d2d00; transform: scale(1.01); }
}
@keyframes ctaPulseHover {
    0%, to { box-shadow: 0 8px 25px #8b5cf680, 0 0 #ee4d2db3; transform: translateY(-2px) scale(1.01); }
    50% { box-shadow: 0 10px 30px #8b5cf699, 0 0 0 12px #ee4d2d00; transform: translateY(-2px) scale(1.02); }
}
@keyframes ctaShimmer { 0% { left: -100%; } 50%, to { left: 100%; } }
@keyframes ctaGradient { 0%, to { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }

.info-text { font-size: 13px; color: var(--primary); margin-top: 10px; font-weight: 600; text-align: center; }

/* 4 Bước (Steps Inline) */
.steps-inline {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.steps-horizontal-inline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
}

.step-item-inline {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
    position: relative;
    text-align: center;
    flex: 1;
}

.step-item-inline:hover { transform: translateY(-2px); }

.step-number-badge {
    position: absolute;
    top: -4px; left: 50%;
    transform: translateX(-16px);
    width: 20px; height: 20px;
    background: var(--gradient-primary);
    color: #fff;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 800;
    box-shadow: 0 2px 8px #6366f14d;
}

.step-icon-inline {
    width: 44px; height: 44px;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
    background: #6366f114;
    border-radius: 12px;
    color: var(--primary);
    transition: var(--transition);
    margin: 0 auto;
}

.step-item-inline:hover .step-icon-inline { background: #6366f126; transform: scale(1.1); }
.step-text-inline { font-size: 12px; font-weight: 600; color: var(--text); }
.step-arrow-inline { font-size: 14px; color: var(--text-muted); margin-top: 12px; }

/* Result Box */
.result-box {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    animation: fadeIn 0.4s ease-out;
}

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

.success-txt { color: var(--success-green); font-size: 14px; font-weight: 600; margin-bottom: 10px; display: flex; align-items: center; gap: 6px; }
.result-wrapper { display: flex; gap: 10px; }
.result-wrapper .smart-input { background: #f0fdf4; border-color: #86efac; color: #166534; font-weight: 600; }
.btn-copy { background: var(--text); color: var(--white); border: none; padding: 0 20px; border-radius: 12px; font-weight: 600; cursor: pointer; transition: 0.2s; white-space: nowrap; }
.btn-copy:hover { background: #1e293b; }

/* ==========================================
   TRA CỨU VÀ RÚT TIỀN (MODAL, BALANCE CARD)
   ========================================== */
.btn-secondary {
    background: var(--text);
    animation: none;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.btn-secondary:before { display: none; }
.btn-secondary:hover:not(:disabled) {
    background: #1e293b;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.15);
}

.lookup-result-box { margin-top: 20px; animation: fadeIn 0.4s ease-out; }

/* Balance Card */
.balance-card {
    background: linear-gradient(135deg, #fff7ed, #fff);
    border: 1px solid #fed7aa;
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 15px;
}
.balance-row { display: flex; justify-content: space-between; align-items: center; padding: 8px 0; border-bottom: 1px solid #fef3c7; }
.balance-row:last-child { border-bottom: none; }
.balance-row.balance-available { padding-top: 12px; margin-top: 5px; border-top: 2px dashed #fed7aa; border-bottom: none; }
.balance-label { font-size: 14px; color: var(--text-secondary); font-weight: 500; }
.balance-value { font-size: 16px; font-weight: 700; color: var(--shopee-orange); }

.error-txt {
    color: #ef4444; font-size: 14px; font-weight: 500; text-align: center;
    padding: 12px; background: #fef2f2; border-radius: 8px; border: 1px solid #fca5a5;
}

/* Order List */
.order-list { display: flex; flex-direction: column; gap: 12px; }
.order-item {
    background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
    padding: 12px 15px; display: flex; flex-direction: column; gap: 6px;
}
.order-main { display: flex; justify-content: space-between; align-items: center; }
.order-name { font-size: 14px; font-weight: 600; color: var(--text); }
.order-price { font-size: 15px; font-weight: 700; color: var(--shopee-orange); }
.order-sub { display: flex; justify-content: flex-start; }
.order-status { font-size: 12px; font-weight: 600; padding: 4px 8px; border-radius: 6px; display: inline-flex; align-items: center; gap: 4px; }
.status-paid { background: #ecfdf5; color: #059669; }
.status-pending { background: #fef3c7; color: #d97706; }
.status-rejected { background: #fef2f2; color: #dc2626; }

/* Modals */
.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(15, 23, 42, 0.7); backdrop-filter: blur(4px);
    display: flex; justify-content: center; align-items: center;
    z-index: 2000; padding: 20px; animation: fadeIn 0.3s ease-out;
}

.modal-box {
    background: var(--white); border-radius: 20px; padding: 30px;
    max-width: 440px; width: 100%; box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    animation: slideUp 0.3s ease-out; max-height: 90vh; overflow-y: auto;
}

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

.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; }
.modal-header h3 { font-size: 18px; font-weight: 700; color: var(--text); display: flex; align-items: center; gap: 8px; }
.modal-close { background: #f1f5f9; border: none; width: 32px; height: 32px; border-radius: 50%; font-size: 16px; color: var(--text-secondary); cursor: pointer; transition: 0.2s; display: flex; justify-content: center; align-items: center; }
.modal-close:hover { background: #e2e8f0; color: var(--text); }
.modal-desc { font-size: 14px; color: var(--text-secondary); margin-bottom: 20px; }
.modal-note { font-size: 12px; color: #d97706; margin-top: 15px; text-align: center; display: flex; align-items: center; justify-content: center; gap: 5px; }

/* Select Bank dropdown */
select.smart-input {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2364748b' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 16px center; cursor: pointer;
}

.withdraw-balance {
    background: linear-gradient(135deg, #ecfdf5, #fff); border: 1px solid #86efac; border-radius: 12px;
    padding: 15px; display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px;
}
.withdraw-balance span { font-size: 14px; color: var(--text-secondary); font-weight: 600; }
.withdraw-balance strong { font-size: 22px; color: var(--success-green); font-weight: 800; }

.btn-success { background: var(--gradient-success); color: white; animation: none; }
.btn-success:before { display: none; }
.btn-success:hover { box-shadow: 0 8px 25px rgba(16, 185, 129, 0.4); transform: translateY(-2px); }

/* Toast */
.toast {
    position: fixed; bottom: -100px; left: 50%; transform: translateX(-50%);
    background: var(--text); color: var(--white); padding: 12px 24px;
    border-radius: 30px; font-size: 14px; font-weight: 500;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2); transition: bottom 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 3000; display: flex; align-items: center; gap: 8px;
}
.toast.show { bottom: 30px; }

/* Responsive */
@media (max-width: 640px) {
    .minimal-title { font-size: 26px; }
    .minimal-card { padding: 24px 20px; }
    .step-text-inline { font-size: 11px; }
    .step-icon-inline { width: 40px; height: 40px; font-size: 18px; }
    .modal-box { padding: 24px; }
}

/* ==========================================
   SEEDING POPUP STYLES
   ========================================== */
.seeding-container {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 1000;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.seeding-popup {
    background: white;
    border-left: 4px solid var(--success-green);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    animation: slideUpFade 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards, fadeOutDown 0.5s 4.5s forwards;
    opacity: 0;
    max-width: 300px;
}

.seeding-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--light-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--success-green);
    font-size: 16px;
    flex-shrink: 0;
}

.seeding-content {
    font-size: 13px;
    line-height: 1.4;
    color: var(--text);
}

.seeding-content strong {
    color: var(--dark);
    font-weight: 700;
}

.seeding-time {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 2px;
    display: block;
}

@keyframes slideUpFade {
    0% { transform: translateY(20px); opacity: 0; }
    100% { transform: translateY(0); opacity: 1; }
}

@keyframes fadeOutDown {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(20px); opacity: 0; }
}

@media (max-width: 640px) {
    .seeding-container {
        bottom: 10px;
        left: 10px;
        right: 10px;
        align-items: center;
    }
    .seeding-popup {
        max-width: 100%;
        width: calc(100% - 20px);
    }
}
