/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    color: #333;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    line-height: 1.6;
}

.container {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
}

/* Header Styles */
.header {
    text-align: center;
    margin-bottom: 30px;
}

.gift-icon {
    font-size: 64px;
    margin-bottom: 16px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.title {
    font-size: 32px;
    font-weight: 700;
    background: linear-gradient(135deg, #FFD700 0%, #8B5CF6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}

.subtitle {
    font-size: 16px;
    color: #a0a0a0;
}

/* Progress Indicator */
.progress-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 30px;
    padding: 0 20px;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 0 0 auto;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #2a2a3e;
    color: #666;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 16px;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.progress-step.active .step-number {
    background: linear-gradient(135deg, #FFD700 0%, #8B5CF6 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
}

.step-label {
    font-size: 12px;
    color: #666;
    white-space: nowrap;
}

.progress-step.active .step-label {
    color: #FFD700;
}

.progress-line {
    width: 60px;
    height: 2px;
    background: #2a2a3e;
    margin: 0 10px;
}

/* Card Styles */
.card {
    background: white;
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    margin-bottom: 20px;
}

/* Input Group */
.input-group {
    margin-bottom: 24px;
}

.input-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

/* Phone Input */
.phone-input-wrapper {
    display: flex;
    align-items: center;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    transition: border-color 0.3s ease;
}

.phone-input-wrapper:focus-within {
    border-color: #8B5CF6;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.country-prefix {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 16px;
    background: #f5f5f5;
    border-right: 2px solid #e0e0e0;
    font-weight: 600;
    color: #333;
}

.flag {
    font-size: 24px;
}

.prefix {
    font-size: 16px;
}

.phone-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 16px;
    font-size: 16px;
    font-weight: 500;
    min-width: 0;
}

/* PIN Input */
.pin-input {
    width: 100%;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px 16px;
    font-size: 28px;
    font-weight: 700;
    text-align: center;
    letter-spacing: 12px;
    outline: none;
    transition: all 0.3s ease;
    background: #fafafa;
    color: #333;
}

.pin-input::placeholder {
    color: #d0d0d0;
    font-weight: 400;
    letter-spacing: 16px;
    font-size: 24px;
}

.pin-input:focus {
    border-color: #8B5CF6;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
    background: white;
    transform: scale(1.02);
}

/* Input Hints and Errors */
.input-hint {
    font-size: 12px;
    color: #666;
    margin-top: 8px;
}

.error-message {
    font-size: 14px;
    color: #EF4444;
    margin-top: 8px;
    min-height: 20px;
}

/* Buttons */
.btn {
    width: 100%;
    border: none;
    border-radius: 12px;
    padding: 16px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, #FFD700 0%, #8B5CF6 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 215, 0, 0.4);
}

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

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

.btn-secondary {
    background: #f5f5f5;
    color: #666;
    margin-top: 12px;
}

.btn-secondary:hover:not(:disabled) {
    background: #e0e0e0;
}

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

.btn-link {
    background: transparent;
    color: #8B5CF6;
    margin-top: 12px;
    font-size: 14px;
    text-decoration: none;
}

.btn-link:hover {
    background: rgba(139, 92, 246, 0.1);
    color: #7C3AED;
}

/* Button Loader */
.btn-loader {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.hidden {
    display: none !important;
}

/* Step Info */
.step-info {
    text-align: center;
    margin-bottom: 24px;
}

.verification-text {
    font-size: 14px;
    color: #666;
    margin-bottom: 4px;
}

.phone-display {
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

/* Success Message */
.success-container {
    text-align: center;
    background: white;
    border-radius: 16px;
    padding: 50px 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.success-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #10B981 0%, #059669 100%);
    color: white;
    font-size: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    animation: scaleIn 0.5s ease-out;
}

@keyframes scaleIn {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.success-title {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin-bottom: 12px;
}

.success-text {
    font-size: 16px;
    color: #666;
}

/* Footer */
.footer {
    text-align: center;
    margin-top: 30px;
}

.footer-text {
    font-size: 12px;
    color: #666;
}

/* Step Container */
.step-container {
    animation: fadeIn 0.3s ease-in;
}

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

/* Shake Animation for Errors */
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-10px); }
    20%, 40%, 60%, 80% { transform: translateX(10px); }
}

.shake {
    animation: shake 0.5s ease-in-out;
}

/* Responsive Design */
@media (max-width: 480px) {
    .title {
        font-size: 28px;
    }

    .card {
        padding: 24px;
    }

    .step-label {
        font-size: 10px;
    }

    .progress-line {
        width: 40px;
    }
}

@media (max-width: 360px) {
    .title {
        font-size: 24px;
    }

    .gift-icon {
        font-size: 48px;
    }
}
