.matrix-payment-page {
    font-family: 'Tajawal', -apple-system, BlinkMacSystemFont, sans-serif;
    background: linear-gradient(135deg, #f8fafc, #e2e8f0);
    min-height: 100vh;
    margin: 0;
    padding: 20px;
    direction: rtl;
    color: #1e293b;
}

.matrix-container {
    max-width: 600px;
    margin: 0 auto;
}

.matrix-header {
    text-align: center;
    margin-bottom: 30px;
}

.matrix-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 10px;
}

.matrix-logo i {
    font-size: 2rem;
}

.matrix-header h1 {
    font-size: 1.3rem;
    color: #64748b;
    margin: 0;
}

.matrix-order-summary {
    background: #ffffff;
    border-radius: 16px;
    padding: 25px;
    margin-bottom: 25px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.matrix-order-summary h3 {
    margin: 0 0 15px;
    font-size: 1rem;
    color: #64748b;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #e2e8f0;
}

.detail-row:last-child {
    border: none;
}

.detail-row.total {
    font-size: 1.2rem;
    color: #10b981;
}

.matrix-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.form-section {
    background: #ffffff;
    border-radius: 16px;
    padding: 25px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.form-section h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 20px;
    font-size: 1.1rem;
}

.form-section h3 i {
    color: #6366f1;
}

.payment-methods {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.payment-method {
    display: block;
    cursor: pointer;
}

.payment-method input {
    display: none;
}

.method-content {
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 15px;
    transition: all 0.3s;
}

.payment-method input:checked+.method-content {
    border-color: #6366f1;
    background: rgba(99, 102, 241, 0.05);
}

.method-name {
    font-weight: 700;
    font-size: 1.1rem;
    display: block;
    margin-bottom: 8px;
}

.method-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 0.9rem;
    color: #64748b;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group:last-child {
    margin: 0;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #64748b;
    font-weight: 500;
}

.form-group input[type="text"],
.form-group input[type="tel"] {
    width: 100%;
    padding: 14px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    color: #1e293b;
    font-family: inherit;
    font-size: 1rem;
}

.form-group input:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.file-upload {
    position: relative;
}

.file-upload input[type="file"] {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.file-upload>label {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    background: #f8fafc;
    border: 2px dashed #e2e8f0;
    border-radius: 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.file-upload>label:hover {
    border-color: #6366f1;
}

.file-upload>label i {
    font-size: 2.5rem;
    color: #6366f1;
    margin-bottom: 10px;
}

.file-preview {
    margin-top: 15px;
    text-align: center;
}

.file-preview img {
    max-width: 100%;
    max-height: 200px;
    border-radius: 10px;
}

.submit-btn {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border: none;
    border-radius: 12px;
    color: white;
    font-family: inherit;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s;
}

.submit-btn:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.3);
}

.submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.matrix-footer {
    text-align: center;
    margin-top: 30px;
    color: #64748b;
}

.matrix-footer a {
    color: #6366f1;
    text-decoration: none;
}

@media (max-width: 600px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}